Statistics
| Branch: | Tag: | Revision:

root / lib / rpc.py @ 4b9e8c93

History | View | Annotate | Download (46.4 kB)

# Date Author Comment
ccfbbd2d 02/17/2011 07:24 pm Iustin Pop

Fix RPC mismatch in blockdev_getsize[s]

Commit 92fd2250 added consistency checks in the RPC layer, which broke
the call_blockdev_getsizes RPC call (declared with 's' at the end in
rpc.py, without 's' in the node daemon).

The immediate fix is to correct the rpc function name, the long term...

c417e115 01/28/2011 06:44 pm Iustin Pop

Re-create instance disk symlinks on activate

This patch implements recreation of instance disk symlinks when the
activate-disks operation is run. Until now, it was not possible to
re-create these symlinks without stopping and starting or migrating an
instance as the RPC call where this is done was in instance startup...

9c007da8 01/11/2011 02:44 pm René Nussbaumer

Add RPC calls for pause/resume sync of devices

Signed-off-by: René Nussbaumer <>
Reviewed-by: Iustin Pop <>

d2cd6944 01/06/2011 12:33 pm Iustin Pop

RPC: mark jobqueue functions as URGENT

Recently, we've seen more and more cases of a specific breakage
pattern in Ganeti: master candidates which are semi-alive (as in, they
respond to ping, they can complete a TCP/SSL handshake, but otherwise
the root filesystem is broken) cause lots of confusion within masterd....

2c0f74f2 12/17/2010 03:00 pm Iustin Pop

RpcResult: simplify some asserts

data ≫ code, eom.

Signed-off-by: Iustin Pop <>
Reviewed-by: Guido Trotter <>

0092d621 12/09/2010 05:03 pm René Nussbaumer

Adding missing timeout parameter to rpc interface

Signed-off-by: René Nussbaumer <>
Reviewed-by: Iustin Pop <>

4f6014d4 12/01/2010 03:36 pm René Nussbaumer

Adding RPC infrastructure to call oob

Signed-off-by: René Nussbaumer <>
Reviewed-by: Iustin Pop <>

c6a9dffa 11/03/2010 04:44 pm Michael Hanselmann

Fix disk checks in “gnt-cluster verify”

Tests have shown that the changes in commit b8d26c6e5 don't work as
wanted. If any disk wasn't found on the node, all disks located on the
same node would show as faulty. The cause was incorrect exception
handling on the node....

b8d26c6e 10/28/2010 02:34 pm Michael Hanselmann

LUClusterVerify: Complain if disk is marked faulty

This will show a warning if, for example, one side of a DRBD
disk becomes unavailable. The data is collected separately
from the other verification data.

Example output:

  • Verifying instance status
    - ERROR: instance inst1: disk/0 on node2 is faulty...
c29e35fe 10/26/2010 04:39 pm Michael Hanselmann

rpc: Work around epydoc warning

Aliasing the “threading” module allows us to avoid the “No information
available for ganeti.rpc._RpcThreadLocal's base threading.local” warning
by epydoc.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: René Nussbaumer <>

271b7cf9 10/26/2010 12:13 pm René Nussbaumer

Adding RPC call for blockdev_wipe

Signed-off-by: René Nussbaumer <>
Reviewed-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

8d8c4eff 10/21/2010 12:57 pm Michael Hanselmann

gnt-instance reinstall: Allow overriding OS parameters

This allows OS installation scripts to make use of special parameters,
e.g. to retain some data on reinstallation.

The RAPI resource is not updated as it takes all parameters via the
query string and encoding arbitrary data in a query string is tricky....

69750d44 10/11/2010 04:16 pm Iustin Pop

Merge branch 'devel-2.2'

  • devel-2.2:
    RPC: disable curl's Expect header

Conflicts:
lib/rpc.py (trivial, copyright header)

Signed-off-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

8e29563f 10/11/2010 04:15 pm Iustin Pop

RPC: disable curl's Expect header

This patch solves the very slow (~8-9 seconds) gnt-instance modify
behaviour. Well, it solves in general the slow RPC behaviour, but it was
most visible in that LU.

It seems that curl's behaviour with regard to file uploads (via PUT) and...

19ddc57a 08/23/2010 03:40 pm René Nussbaumer

Add RPC calls to update /etc/hosts

Signed-off-by: René Nussbaumer <>
Reviewed-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

17f7fd27 08/23/2010 02:58 pm Manuel Franceschini

Fix a few epydoc docstrings

Signed-off-by: Manuel Franceschini <>
Reviewed-by: Iustin Pop <>

e8d61457 08/19/2010 03:12 pm René Nussbaumer

Removing all ssh setup code from the core

Signed-off-by: René Nussbaumer <>
Reviewed-by: Iustin Pop <>

b43dcc5a 08/19/2010 12:44 pm Manuel Franceschini

Support IPv6 node add

Signed-off-by: Manuel Franceschini <>
Reviewed-by: Iustin Pop <>

b705c7a6 08/18/2010 11:27 am Manuel Franceschini

Support for resolving hostnames to IPv6 addresses

This patch enables IPv6 name resolution by using socket.getaddrinfo
instead of socket.gethostbyname_ex.

It renames the HostInfo class to Hostname and unifies its use throughout
the code. This is achieved by using static calls where no object is...

eb202c13 08/18/2010 11:27 am Manuel Franceschini

Always use address instead of hostname in rpc.Client

In light of the upcoming IPv6 support, this patch enables the rpc.Client
to always use a node's address to connect to it. This is necessary as we
do not want to rely on name resolution to connect to the correct IP...

e0e916fe 07/26/2010 05:45 pm Iustin Pop

Move the UsesRPC decorator from cli to rpc

This is needed because not just the cli scripts need this decorator, but
the master daemon too (and it already duplicated the code once).

In cli.py we just leave a stub, so that we don't have to modify all the
scripts to import rpc.py....

33231500 07/16/2010 06:18 pm Michael Hanselmann

Convert RPC client to PycURL

Instead of using our custom HTTP client, using PycURL's multi
interface allows us to get rid of the HTTP client threadpool.
The majority of the code is still in the ganeti.http.client
module.

A simple per-thread HTTP client pool gives cURL a chance to...

a744b676 07/09/2010 04:37 pm Manuel Franceschini

Introduce lib/netutils.py

This patch moves network utility functions to a dedicated module.

Signed-off-by: Manuel Franceschini <>
Reviewed-by: Iustin Pop <>

c46b9782 07/06/2010 12:24 pm Luca Bigliardi

Add drbd_helper rpc call

Signed-off-by: Luca Bigliardi <>
Reviewed-by: Iustin Pop <>

1bdcbbab 06/23/2010 07:23 pm Iustin Pop

Add OS parameters to cluster and instance objects

The patch also modifies the instance RPC calls to fill the osparameters
correctly with the cluster defaults, and exports the OS parameters in
the instance/OS environment.

Signed-off-by: Iustin Pop <>...

acd9ff9e 06/23/2010 07:23 pm Iustin Pop

Introduce an RPC call for OS parameters validation

While we only support the 'parameters' check today, the RPC call is
generic enough that will be able to support other checks in the future.
The backend function will both validate the parameters list (so as to...

31ca841c 06/14/2010 09:33 pm Iustin Pop

Merge branch 'devel-2.1' into master

Signed-off-by: Iustin Pop <>
Reviewed-by: Balazs Lecz <>

27137e55 06/14/2010 12:17 am Iustin Pop

Fix RpcResult.Raise error code

A typo in the Raise() method of rpc.RpcResult means that any remote
errors will lack an appropriate error code; this will confuse e.g. RAPI
users.

Signed-off-by: Iustin Pop <>
Reviewed-by: Guido Trotter <>

6abf7f2c 06/11/2010 12:23 pm Guido Trotter

Remove the job queue drain rpc call

This call was introduced but never used. In two years.
Since it's just creating/removing a file it can also be in simpler ways,
without a special rpc call, if/when we need it again. In the meantime,
let's give it to history....

92fd2250 06/04/2010 06:05 pm Iustin Pop

Introduce harcdoded timeouts for each RPC call

This patch adds a table with per-opcode timeouts. They were chosen in an
empiric, rather than scientific, way - see the comments in lib/rpc.py.

The patch also shows how custom timeouts can be used - call_test_delay...

e0036155 06/04/2010 05:26 pm Iustin Pop

http client: support per-request read timeout

Currently, the read timeout is hardcoded in the
HttpClientRequestExecutor class. The patch changes the timeout so that
it's a per-request property, and makes the rpc.Client class pass one
explicitly in. Furthermore, we modify the rpc.RpcRunner class to support...

eb630f50 05/21/2010 06:17 pm Michael Hanselmann

Put common import/export daemon options into object

The X509 key name and CA are passed from cmdlib all the way to
the backend import/export daemon. With the addition of an option
to choose the compression method, another parameter would have
to be passed all the way. By moving these options to a separate...

47f8a2d2 04/23/2010 05:50 pm Michael Hanselmann

Remove two unused RPC functions

Both of these functions, “snapshot_export” and “instance_os_import”,
have been replaced by the instance import/export daemon.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Guido Trotter <>

37549316 04/22/2010 03:16 pm Michael Hanselmann

Complete what was begun in commit ef40fbfb4

The X509 certificate RPC functions were also renamed, but I
forgot to rename them in rpc.py. Fortunately they aren't used
yet.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

f81c4737 04/22/2010 02:35 pm Michael Hanselmann

Add RPC call to send SIGTERM to import/export daemon

This will be used to stop the daemon without doing complete cleanup (yet).

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

ef40fbfb 04/22/2010 02:35 pm Michael Hanselmann

Rename import/export RPC calls to match others

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

1651d116 04/16/2010 04:24 pm Michael Hanselmann

Add RPC calls to import and export instance data

These RPC calls can be used to start, monitor and stop the instance data
import/export daemon.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

f942a838 03/17/2010 07:19 pm Michael Hanselmann

Add RPC calls to create and remove X509 certificates

Certificates and keys generated using these functions will be used for
inter-cluster instance moves. As per design, the private key should never
leave the node.

Signed-off-by: Michael Hanselmann <>...

168c1de2 03/15/2010 06:40 pm Michael Hanselmann

Rename SSL_CERT_FILE to NODED_CERT_FILE

To be consistent with RAPI_CERT_FILE, the rather generic named
“SSL_CERT_FILE” constant is renamed to “NODED_CERT_FILE”. The actual file
name is not changed.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

4a0e011f 02/03/2010 07:04 pm Iustin Pop

Implement debug level across OS-related RPC calls

This doesn't implement the full functionality, we need to add the debug
level to the opcodes too, but at least won't require changing the RPC
calls during the 2.1 series.

Signed-off-by: Iustin Pop <>...

7260cfbe 01/04/2010 11:15 am Iustin Pop

Add targeted pylint disables

This patch should have only:

- pylint disables
- docstring changes
- whitespace changes

Signed-off-by: Iustin Pop <>
Reviewed-by: Olivier Tharan <>

d984846d 12/28/2009 02:05 pm Iustin Pop

Merge branch 'devel-2.0' into devel-2.1

  • devel-2.0:
    Fix indentation in hv_kvm
    Implement BuildHooksEnv for NoHooksLU
    Clarifiy some more wide pylint disables
    Fix two bugs in seldom-used codepaths
    Update pylintrc
    Add targetted pylint disables
    Partial cherry-pick of 6c881c5 from the 2.1 branch...
fe267188 12/28/2009 12:43 pm Iustin Pop

Add targetted pylint disables

This patch adds targeted pylint disables, where it makes sense (either
due to limitations in pylint or due to historical usage), and also a few
blanket ones in rapi where all the names are… “different”.

Signed-off-by: Iustin Pop <>...

8d0a4f99 11/25/2009 01:08 pm Michael Hanselmann

Add check for OpenSSL entropy status

By checking for this explicitly, the errors (SSLEAY_RAND_BYTES, “PRNG
not seeded”) will happen in the start-up phase of the daemon and not
only when executing remote procedure calls.

Signed-off-by: Michael Hanselmann <>...

045dd6d9 11/02/2009 04:14 pm Iustin Pop

Add ecode to rpc.py's RpcResult.Raise()

This patch adds a new ecode argument to RpcResult.Raise(). This allows
specifying the error code (for both OpExec and OpPrereq errors).

Note that this patch also makes the OpExecError exceptions raised from
_FindFaultInstanceDisks have the error code classification....

8f215968 10/30/2009 12:46 pm Michael Hanselmann

Make cluster initialization more reliable

There was a race condition between starting the node daemon
and sending requests to write the ssconf files. With this
patch, the initialization waits up to ten seconds for the
node daemon to become responsive.

Signed-off-by: Michael Hanselmann <>...

b989b9d9 10/22/2009 04:40 pm Ken Wehr

Adding '--no-ssh-init' option to 'gnt-cluster init'.

Allows the initialization of a cluster without the creation or distribution
of SSH key pairs. Includes changes for LeaveCluster and RPC.

Signed-off-by: Ken Wehr <>
Signed-off-by: Guido Trotter <>...

1645d22d 10/21/2009 12:26 pm Michael Hanselmann

Ensure RpcResult has “payload” attribute

Also add assertions to avoid missing attributes in the future.
They won't be included in optimized bytecode.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Guido Trotter <>

17c3f802 10/13/2009 01:24 pm Guido Trotter

Add timeout options to other LUs

All the LUs that shut down the instance need to be able too pass the
timeout parameter as well.

Signed-off-by: Guido Trotter <>
Reviewed-by: Michael Hanselmann <>

6263189c 10/09/2009 06:28 pm Guido Trotter

Accept shutdown timeout from the user

Using the new --timeout option:

- gnt-instance shutdown is changed to accept a timeout
- the opcode is changed to hold one
- the LU is changed to optionally get one
- the rpc is changed to carry one
- the backend is changed to take it as a parameter rather than...

84e3f66f 10/05/2009 12:39 pm Guido Trotter

Fix rpc.call_os_get to actually return the OS

Since nobody ever read the actual OS object, this bug was introduced in
the rpc conversion.

Signed-off-by: Guido Trotter <>
Reviewed-by: Olivier Tharan <>

3cebe102 09/17/2009 06:53 pm Michael Hanselmann

Remove RpcResult.RemoteFailMsg completely

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

edb4b374 09/16/2009 07:13 pm Michael Hanselmann

Remove RpcResult.failed attribute

It's redundant with RpcResult.fail_msg. This change survived QA, burnin and
unittests.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

fe89794e 09/14/2009 02:17 pm Michael Hanselmann

RpcResult: Fix cases where “failed” wouldn't be set to True

This broke “gnt-instance replace-disks --auto” when the instance
is down.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Olivier Tharan <>

858f3d18 08/24/2009 03:13 pm Iustin Pop

Add disk copy support at backend and the rpc level

This uses a simple 'dd if=… | ssh $target dd of=…' method, like the
ExportSnapshot (which uses the OS export; here we want full disk-level
copy and not any FS-level changes).

Signed-off-by: Iustin Pop <>...

637b8d7e 08/17/2009 02:26 pm Michael Hanselmann

Add RPC call for storage operations

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

b142ef15 08/13/2009 02:41 pm Iustin Pop

Merge commit 'origin/next' into branch-2.1

  • commit 'origin/next': (28 commits)
    Fix a typo in InitCluster
    Ignore results from drained nodes in iallocator
    Ship the ethers hook
    Ethers hook, compatibility with old lockfile
    Remove a few unused imports from noded/masterd...
8486ffc0 08/07/2009 02:22 pm Guido Trotter

Merge branch 'master' into next

  • master:
    Update NEWS and version for 2.0.3 release
    devel/upload: revert rsync -p
    export: add meaningful exit code
    Fix detecting of errors in export
    Implement gnt-cluster check-disk-sizes
    rpc: add rpc call for getting disk size...
36145b12 08/05/2009 12:13 pm Michael Hanselmann

Use objects for blockdev_getmirrorstatus RPC call result

This patch changes the return type for backend.BlockdevGetmirrorstatus from
a list of tuples to a list of objects.BlockDevStatus instances.

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

96acbc09 08/05/2009 12:12 pm Michael Hanselmann

Use object for blockdev_find RPC call result

This patch changes the return type for backend.BlockdevFind to an object
(objects.BlockDevStatus). Before a tuple was used. Adding more values to
this tuple causes a lot of work. Converting the result to an object with...

968a7623 08/04/2009 05:35 pm Iustin Pop

rpc: add rpc call for getting disk size

Note that this exports the disk size as bdev returns it, in bytes. The
value will be converted to MiB in cmdlib.

Signed-off-by: Iustin Pop <>
Reviewed-by: Guido Trotter <>

8979196a 08/04/2009 12:44 pm Michael Hanselmann

Add RPC calls to modify storage fields

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Guido Trotter <>

e337de97 07/29/2009 06:56 pm Michael Hanselmann

Add RPC calls for storage unit list

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

2503680f 07/29/2009 11:59 am Guido Trotter

Extend call_node_start_master rpc with no_voting

When the parameter is set to True and start_daemons is also True,
ganeti-masterd will be started with the new --no-voting --yes-do-it
options.

This new option is set to True only on masterfailover, when no_voting is...

cd50653c 07/24/2009 03:04 pm Guido Trotter

Change GetNodeDaemonPort to GetDaemonPort in utils

GetNodeDaemonPort is used to lookup the node daemon port in the services
file, and if not found to return the default one. We make it a generic
function, which accepts the daemon name in input, so that it can be used...

25f9901f 07/19/2009 07:47 pm Iustin Pop

Merge commit 'origin/next' into branch-2.1

Conflicts:
lib/cli.py: trivial extra empty line

6af6270a 07/19/2009 07:38 pm Iustin Pop

Fix a couple of epydoc warnings

It seems epydoc needs fully-qualified references, and doesn't deal with
relative ones (not even in the current module) if there are any
ambiguities.

There are other epydoc warnings, in the rapi docstrings, but those are
left as-is as they're removed in 2.1....

3583908a 07/08/2009 12:49 pm Guido Trotter

Extend call_node_start_master rpc with no_voting

When the parameter is set to True and start_daemons is also True,
ganeti-masterd will be started with the new --no-voting --yes-do-it
options.

This new option is set to True only on masterfailover, when no_voting is...

2f7140ba 07/08/2009 12:28 pm Guido Trotter

Merge branch 'next' into branch-2.1

  • next:
    Create a new --no-voting option for masterfailover
    ganeti-masterd: allow non-interactive --no-voting
    Fix pylint warnings
    Add custom pylintrc
    bootstrap: Don't leak file descriptor when generating SSL certificate...
7c4d6c7b 07/07/2009 03:54 pm Michael Hanselmann

Fix pylint warnings

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

5bbd3f7f 07/07/2009 03:51 pm Michael Hanselmann

Fix some typos

Signed-off-by: Michael Hanselmann <>
Reviewed-by: Iustin Pop <>

b2a6ccd4 06/29/2009 05:33 pm Iustin Pop

Rename the volume_list RPC call to lv_list

There are volume-related rpc calls. This patch renames the ‘volume_list’
call to ‘lv_list’ to make more clear its purpose.

Signed-off-by: Iustin Pop <>
Reviewed-by: Guido Trotter <>

af0413bb 06/16/2009 02:28 pm Guido Trotter

Merge branch 'next' into branch-2.1

  • next: (22 commits)
    Update NEWS and version for 2.0.1 release
    gnt-{instance,backup}(8) --nic is actually --net
    Fix a wrong function name in backend.DrbdAttachNet
    GNT-CLUSTER fix search-tags example
    Enable stripped LVs...
4c4e4e1e 06/15/2009 08:13 pm Iustin Pop

Simplify RPC call result check in cmdlib.py

Now that all results are the same, we can even more simplify the
handling in cmdlib more. Almost all if result.RemoteFailMsg()…
constructs are similar, and we resurect the RpcResult.Raise() function
to take a message argument, which it will process and raise an...

d3c8b360 06/15/2009 08:08 pm Iustin Pop

Pre-compute error status in RpcResult

Since now all RPCs have the new style result type, we can pre-compute
the error message at RpcResult() init time and not wait until it's
requested.

Signed-off-by: Iustin Pop <>
Reviewed-by: Guido Trotter <>

83d92ad8 06/15/2009 08:08 pm Iustin Pop

Convert os_diagnose rpc to new style result

This also removes custom post-processing from rpc.py; since this call
has only one user, it was simple to move it back to the caller.

Signed-off-by: Iustin Pop <>
Reviewed-by: Guido Trotter <>

070e998b 06/15/2009 08:08 pm Iustin Pop

Convert node_info rpc to new style result

This patch also does some cleanup and enforces valid results (with
proper type, i.e. int for memory/disk values) from remote node,
otherwise we handle the result as failure.

We do this so that we can remove custom processing in rpc.py which is...

3eccac06 06/15/2009 07:37 pm Iustin Pop

Convert export_info rpc to new style result

This also removes some code from ganeti-noded and rpc.py, which should
not do such processing of data (and be simply glue code). (Or
alternatively they could, if we had better infrastructure).

Signed-off-by: Iustin Pop <>...

b848ce79 06/15/2009 01:52 pm Guido Trotter

rpc: fill in NIC parameters in instances

Signed-off-by: Guido Trotter <>
Reviewed-by: Iustin Pop <>

abe609b2 06/08/2009 07:58 pm Guido Trotter

Move FillDict at module level

This way it can be also used by scripts and other object types.

Signed-off-by: Guido Trotter <>
Reviewed-by: Iustin Pop <>

a97da6b7 06/03/2009 03:17 pm Iustin Pop

Fix two issues with exports and snapshot errors

This patch fixes two issues related to failed snapshots during exports:
- first, the error messages used disk.logical_id1, which is a node
name for DRBD, and it resulted in strange error messages like...

f5118ade 05/27/2009 01:19 pm Iustin Pop

Add a node powercycle command

This (somewhat big) patch adds support for remotely rebooting the nodes
via whatever support the hypervisor has for such a concept.

For KVM/fake (and containers in the future) this just uses sysrq plus a
‘reboot’ call if the sysrq method failed. For Xen, it first tries the...

622533d5 05/19/2009 04:43 pm Iustin Pop

Merge commit 'origin/next' into branch-2.1

  • commit 'origin/next': (25 commits)
    Move more hypervisor strings into constants
    Add -H/-B startup parameters to gnt-instance
    call_instance_start: add optional hv/be parameters
    Fix gnt-job list argument handling...
0eca8e0c 05/19/2009 11:39 am Iustin Pop

call_instance_start: add optional hv/be parameters

This patch modifies the rpc.call_instance_start - the master side - to
take optional hv/be parameters. The noded side is unchanged and
oblivious to the change.

This will allow implementation of single-user capability and such on...

e557bae9 05/06/2009 02:56 pm Guido Trotter

Inform the OS create script of reinstalls

Sometimes reinstalls are slightly different than new installs. For
example certain partitions may need to be preserved accross reinstalls.
In order to do that on a per-os basis we pass in the INSTANCE_REINSTALL
variable to inform the create script about when a reinstall is...

5fcc718f 02/27/2009 03:06 pm Iustin Pop

Fix some epydoc style issues

99% of the epydoc return tags are "@return:", but each of the modified files
had one "@returns:" line. We fix this for consistency.

Reviewed-by: imsnah

07813a9e 02/24/2009 05:25 pm Iustin Pop

Remove the extra_args parameter in instance start

This patch removes the extra_args parameter and instead switches the
instance to the HV_KERNEL_ARGS hypervisor option.

This is a big change, but it's a needed cleanup, this extra parameter on
all RPC calls is not generic and we also need to have a persistent value...

f2def43a 02/09/2009 11:24 am Iustin Pop

RpcResult: add a new payload field

For results which use the (status, payload) response type, it's easier
to define a ‘payload’ field on the result holding the payload than to
extract it using “data1” in the caller code.

Reviewed-by: ultrotter

84b45587 01/23/2009 12:15 pm Iustin Pop

Fill the 'call' attribute of offline rpc results

When creating ‘fake’ results for offline nodes, we currently don't pass
the call attribute. This complicates debugging, so even though this
should not matter in practice, it's better to fix it.

Reviewed-by: imsnah

1b8acf70 01/21/2009 12:48 pm Iustin Pop

Log the rpc call name in the RPC errors message

Currently the rpc module logs the error description and target node in
rpc calls logging, as such:

2009-01-21 00:50:01,456:  pid=1051/Thread-21 ERROR RPC error from node
node1.example.com: Connection failed (111: Connection...
6906a9d8 01/21/2009 11:54 am Guido Trotter

Add calls in the intra-node migration protocol

Currently the hypervisor is expected to do all the migration from the
source side. With this patch we also add the option of passing some
information to the target side, and starting some operation there.

As a bonus, a function to cleanup any started operation is included....

6b93ec9d 01/13/2009 05:20 pm Iustin Pop

Forward-port DrbdNetReconfig

This is a modified forward-port of DrbdNetReconfig and their associated
RPCs. In Ganeti 2.0, these functions will be used for two things:
- live migration (as in 1.2)
- and for other network reconfiguration tasks, since DRBD8.Attach()...

186ec53c 01/09/2009 02:52 pm Iustin Pop

Silence warning on node list for offline nodes

The warning in node list is meant for nodes that return wrong
information, but for offline nodes this case is normal.

Reviewed-by: imsnah

3247bbac 01/08/2009 06:05 pm Iustin Pop

rpc: Add a method for easy check of remote results

The patch adds a new method to the rpc.RpcResult class called
"RemoteFailMsg" which is useful for the RPC calls which return a
(status, payload) style result.

Reviewed-by: imsnah

56e7640c 01/08/2009 04:16 pm Iustin Pop

Add an instance_migratable rpc call

This is a forward-port of commit 1194 on the 1.2 branch:

This call will check whether an instance is up on its primary, and that
it has been started with symlinks. We currently have no on-secondary
checks, nor any hypervisor specific call....
b2e7666a 01/07/2009 07:02 pm Iustin Pop

Pass instance name to rpc call blockdev_close

This is an extract of commit 1166 on the 1.2 branch (Add a rpc call for
drbd network reconfiguration), but only the blockdev_close part.

The patch changes the blockdev_close call to take the instance so that...

dd875d32 12/18/2008 06:39 pm Michael Hanselmann

Job queue: Allow more than one file rename per RPC call

Reviewed-by: ultrotter

fab1e3a4 12/14/2008 02:01 pm Iustin Pop

cleanup: fix 'variable unused' warning

In the iteration we don't care about the node names, so we change the
for loop to be over the values (and not itervalues).

Reviewed-by: amishchenko

c41eea6e 12/11/2008 07:13 pm Iustin Pop

Fix epydoc format warnings

This patch should fix all outstanding epydoc parsing errors; as such, we
switch epydoc into verbose mode so that any new errors will be visible.

Reviewed-by: imsnah

12bce260 12/09/2008 03:24 pm Michael Hanselmann

RPC: Compress file upload data

Adding compression to larger amounts of data is more efficient than
transferring it (len(nodes) - 1) times over the network without
compression. We were able to compress a 800KB config file to about
30 KB, which is about 40 KB with Base64 encoding (required due to...