Statistics
| Branch: | Tag: | Revision:

root @ 82d9caef

# Date Author Comment
82d9caef 10/20/2008 03:50 pm Iustin Pop

Remove the logger.py module

Since now we use only one function from the logger module
(SetupLogging), we move it to utils.py (which is already imported by all
users of this function), and we remove the module.

Reviewed-by: imsnah

263ab7cf 10/20/2008 03:50 pm Iustin Pop

Convert http.py to use the logging module

Reviewed-by: imsnah

9a4f63d1 10/20/2008 03:50 pm Iustin Pop

Convert cmdlib.py to use the logging module

Note that many uses of logger.Error were used in 1.2 for their
side-effect of logging to stderr, where the user will see the messages,
and not for having the entry in the log. As such, we need to go over and
review every use of logging.* and decide if it should use feedback_fn...

b48909c8 10/20/2008 03:50 pm Iustin Pop

Convert hv_xen.py to use the logging module

Reviewed-by: imsnah

a5eb7789 10/20/2008 03:50 pm Iustin Pop

Convert mcpu.py to use the logging module

Reviewed-by: imsnah

23828f1c 10/20/2008 03:50 pm Iustin Pop

Convert ssh.py to use the logging module

Reviewed-by: imsnah

58b311ca 10/20/2008 03:49 pm Iustin Pop

Convert rpc.py to use the logging module

Reviewed-by: imsnah

2f79bd34 10/20/2008 03:33 pm Iustin Pop

Fix some pylint-detected issues on the scripts

Some names were wrong, and similar stuff detected by pylint.
gnt-debug.GenericOpCode is still broken.

Reviewed-by: imsnah

3a24c527 10/20/2008 03:33 pm Iustin Pop

Convert the gnt scripts to ToStdout/err

Currently the gnt-* scripts are using a mix of print, logger.ToStd* and
sys.stderr.write. We convert them all to using cli.ToStdout/err. This
way, we can easily change the implementation for all at once.

Reviewed-by: imsnah

46fbdd04 10/20/2008 03:33 pm Iustin Pop

Convert cli.py to logging

We also add two function for printing messages, so that scripts won't
have to import logger to get these. They are a simple extension over the
logger ones, as they accept the call style from logging:
ToStdout("Message: %s", msg)...

61be6ba4 10/20/2008 03:16 pm Iustin Pop

Fix gnt-instance modify with beparams

The gnt-instance modify didn't work correctly w.r.t the be parameters.
There was also a typo in the corresponding LU.

Reviewed-by: imsnah

dcd7cbaf 10/20/2008 02:09 pm Alexander Schreiber

Update gnt-cluster man page for removal of --hypervisor-type.

We no longer use a single, cluster-wide hypervisor, but configure the
actual to be used hypervisor on the instance level. The option has already
been removed from gnt-cluster.

Reviewed-by: imsnah

fa10bdc5 10/20/2008 02:04 pm Michael Hanselmann

Remove old HTTP server code

All users of this code have been migrated to the new and shiny HttpServer
class.

It also fixes a typo in the ApacheLogfile unittests. It has not yet been
decided whether we should keep ApacheLogfile or not, hence leaving it in....

4342e89b 10/20/2008 01:47 pm Alexander Schreiber

Remove --hypervisor-type from gnt-cluster.

We no longer use a single, cluster-wide hypervisor, but configure the
actual to be used hypervisor on the instance level.

Reviewed-by: imsnah

ea3a925f 10/19/2008 01:27 am Alexander Schreiber

Fix gnt-cluster init to set cluster defaults.

Reviewed-by: iustinp

7888a614 10/19/2008 01:26 am Alexander Schreiber

Add constants for cluster defaults

Reviewed-by: iustinp

d15a9ad3 10/17/2008 05:37 pm Guido Trotter

Cleanup os_add/rename rpc for OS API 10

- remove now unused osdev and swapdev arguments from backend, noded,
rpc, cmdlib
- convert docstrings to epydoc

Reviewed-by: iustinp

d324e3fc 10/17/2008 05:36 pm Guido Trotter

Temporarily explicitely break import/export

Since they're not converted to API 10 yet, we temporarily disable the
import/export functions.

Reviewed-by: iustinp

58f6e5ca 10/17/2008 05:36 pm Guido Trotter

AddOSToInstance: convert to api10

Reviewed-by: iustinp

ff38b6c0 10/17/2008 05:36 pm Guido Trotter

RunRenameInstance: convert to api10

Reviewed-by: iustinp

2266edb2 10/17/2008 05:36 pm Guido Trotter

Add new OSEnvironment function

This function calculates the basic environment for OS scripts in API
version 10.

Reviewed-by: iustinp

4dd69592 10/17/2008 05:35 pm Guido Trotter

Bump up the OS API version

Reviewed-by: iustinp

62dbbe7e 10/17/2008 05:35 pm Guido Trotter

OSFromDisk: use script names from constants

Reviewed-by: iustinp

8ee4dc80 10/17/2008 05:35 pm Guido Trotter

Change OSFromDisk's docstring to epydoc

Plus update it with the real variable name

Reviewed-by: iustinp

464736ae 10/17/2008 05:35 pm Guido Trotter

Add LDS_BLOCK for block device backed dev types

Reviewed-by: iustinp

ded1c679 10/17/2008 05:35 pm Guido Trotter

Create constants to replace os scripts names

Reviewed-by: iustinp

713faea6 10/17/2008 04:06 pm Oleksiy Mishchenko

ETag passing support.

Reviewed-by: imsnah

a570e2a8 10/17/2008 02:08 pm Guido Trotter

Mainloop: handle sigterm

This fixes removals of the pid files and clean exit in the init script

Reviewed-by: iustinp

07fc5289 10/17/2008 02:07 pm Guido Trotter

Mainloop: init sigchld_handler as None

There is no point in initializing sigchld_handler as an empty dict, when
it will be overwritten by an instance of utils.SignalHandler
immediately after.

Reviewed-by: iustinp

5d8d232c 10/17/2008 12:47 pm Michael Hanselmann

Fix remote API unittest

I broke it with rev 1864. This patch also removes whitespace at
line endings.

Reviewed-by: amishchenko

779c15bb 10/16/2008 11:39 pm Iustin Pop

Enable gnt-cluster modify to hv/beparams

This patch enables the cluster modify to change:
- enabled hypervisor list
- hvparams (per hypervisor)
- beparams (only the default group)

Syntax:
gnt-cluster modify -B vcpus=3 -H xen-pvm:no_initrd_path

Validation for parameters is somewhat missing - the individual...

16a8967d 10/16/2008 07:54 pm Michael Hanselmann

rapi: Convert to new HTTP server class

Requests are no longer logged to a separate file.

Reviewed-by: amishchenko

c5e2d3b9 10/16/2008 07:38 pm Guido Trotter

design-2.0-cluster-parameters: escape final _

In rst a final _ is used for linking. Escaping it prevents an error at
compile time on design-2.0-cluster-parameters.rst

Reviewed-by: iustinp

469f88e1 10/16/2008 07:26 pm Iustin Pop

Show the cluster parametrs in gnt-cluster info

This is just a raw update without any special formatting.

Reviewed-by: imsnah

2f7635f4 10/16/2008 05:40 pm Oleksiy Mishchenko

RAPI: Instance add/delete implementation.

Reviewed-by: iustinp

29fc6636 10/16/2008 04:35 pm Guido Trotter

OS Design: invert new and old name

Internally in ganeti we already have renamed the instance, so it's
better to pass the new name in INSTANCE_NAME and the old one in
OLD_INSTANCE_NAME rather than the old name in INSTANCE_NAME and the new
one in NEW_INSTANCE_NAME as this reflects what the cluster thinks....

09352fa4 10/16/2008 04:05 pm Iustin Pop

Really fix with the zombie test (hopefully)

So, instead of any timeouts for synchronization, we move to actual
events. We still have one (huge) timeout for pathological cases (just to
cleanup), but we don't sleep at all in normal usage.

The patch moves the zombie/cleaned up child creation out from setUp(),...

94ed59a5 10/16/2008 03:08 pm Iustin Pop

Fix job queue behaviour when loading jobs

Currently, if loading a job fails, the job queue code raises an
exception and prevents the proper processing of the jobs in the queue.
We change this so that unparseable jobs are instead archived (if not
already)....

d5927e48 10/16/2008 02:36 pm Iustin Pop

Prevent master failover if we have wrong data

If we don't actually know the current master (as determined via voting),
we prevent the failover.

The patch also changes some messages (capitalization, typos).

Reviewed-by: ultrotter

d7cdb55d 10/16/2008 02:36 pm Iustin Pop

Improvements to the master startup checks

In order to account for future improvements to master failover, we move
the actual data gathering capabilities from ganeti-masterd into
bootstrap.py, and we leave only the verification into masterd.

The verification procedure is then changed to retry multiple times (up...

10799c59 10/16/2008 11:37 am René Nussbaumer

Provide example for backend parameters

Update the design about cluster parameters and provide
some example of backend parameters. By now this includes
all supported parameters.

Reviewed-by: iustinp, ultrotter

3ccafd0e 10/16/2008 11:37 am Iustin Pop

Add an interface for the drain flag changes/query

This adds the set/reset in the jqueue and luxi modules, and a way to
query it in OpQueryConfigValues, and also the comand line interface for
it:
$ gnt-cluster queue info
The drain flag is unset
$ gnt-cluster queue drain...

0d0e9090 10/15/2008 04:38 pm René Nussbaumer

Adding batch-create to gnt-instance

This change is part of the integration of tools/batcher from
Ganeti 1.2 into Ganeti 2.0 core code. It has a compatible
submission interface to the version from 1.2 with these differences:

  • it's integrated into Ganeti directly: gnt-instance batch-create...
5d672980 10/15/2008 04:13 pm Iustin Pop

Add a rpc call for changing the drain flag

A new multi-node call is added that sets/resets the drain flag.

Reviewed-by: imsnah

686d7433 10/15/2008 01:52 pm Iustin Pop

Implement the job queue drain flag

We add a (per-node) queue drain flag that blocks new job submission.
There is not yet an interface to add/remove the flag (will come in next
patches).

Reviewed-by: imsnah

6797ec29 10/15/2008 01:51 pm Iustin Pop

Implement transport of ganeti errors across luxi

This patch adds a generic method to identify the ganeti error given its
class name, and implements this across the luxi protocol.

Reviewed-by: imsnah

d11bda8d 10/15/2008 01:51 pm Iustin Pop

Change the JobQueueError parent class

Currently this is not derived from GenericError, but there's no reason
for it to be so.

Reviewed-by: imsnah

966405b7 10/15/2008 01:13 pm Michael Hanselmann

rapi: Don't throw class as an exception

Reviewed-by: ultrotter

a2f92677 10/15/2008 11:22 am Michael Hanselmann

rapi: Whitespace fixes

Reviewed-by: ultrotter

b03efa30 10/14/2008 07:34 pm Guido Trotter

gnt-backup: update for cluster parameters

- add backend and hypervisor parameters
- fix beparams validation/passing
- pass hypervisor and hvparams
- remove deprecated flags

Reviewed-by: iustinp

7399cd55 10/14/2008 07:33 pm Guido Trotter

gnt-instance fix ValidateBeParams call

ValidateBeParams does not return, but its return value is assigned to a
variable which is never used. Avoid this assignment.

Reviewed-by: iustinp

7ac1fc45 10/14/2008 07:33 pm Guido Trotter

gnt-instance remove deprecated flags

kernel, initrd, hvm_boot_order and vnc_bind_address are now hypervisor
parameters and should not have their own flag. Moreover querying of
vnc_bind_address should of course pass through the hv/ namespace.

Reviewed-by: iustinp

6605411d 10/14/2008 07:23 pm Iustin Pop

grow-disk: wait until resync is completed

The patch adds a new ‘--no-wait-for-sync’ parameter to grow-disk similar
to the one in instance add, and changes the default to wait.

This is cleaner as at the moment when the command returns, we either
have a fully synced disk or there is an error....

659712c8 10/14/2008 07:22 pm Iustin Pop

Burnin OpGrowDisk

With this patch both the os and the swap disk are grown during
burnin. You can pass an increase size of 0 to skip this operation.

and:

burnin: don't try to grow diskless instances

When burnin is run on a diskless instance, it fails when trying...
6b5605e8 10/14/2008 05:47 pm Iustin Pop

Convert the KVM hypervisor to hvparams

I'm not sure which parameters it should use, I took all I saw in the
code. Update: ultrotter says the list is OK for now.

Reviewed-by: ultrotter

c0f2b229 10/14/2008 05:42 pm Iustin Pop

Some fixes related to auto_balance

Change the constant name to match the value (autobalance ->
auto_balance).

Also add the auto_balance header so that gnt-instance can list it.

Reviewed-by: ultrotter

647a5d80 10/14/2008 05:42 pm Iustin Pop

Fix auto_balance and memory modification

The secondary nodes should not be checked for free memory in case of non
auto-balanced instances.

This is a forward-port from rev 1567 on the 1.2 branch.

Reviewed-by: ultrotter

3924700f 10/14/2008 05:42 pm Iustin Pop

Use the auto_balance in cluster verify

This patch changes the cluster verify in two ways:
- do not use instances marked with auto_balance=False in N+1 memory
checks
- report, if any, the number of instances with auto_balance=False

Forward port from rev 1562 on the 1.2 branch....

c1f1cbb2 10/14/2008 05:42 pm Iustin Pop

Fix ordering of instance/nodes

After the locking changes, and the partial locking of nodes, the
instance/node list is not ordered anymore. Reorder so that it behaves as
before.

Reviewed-by: ultrotter

bf766476 10/14/2008 02:30 pm Iustin Pop

Remove old instance attributes

Reviewed-by: ultrotter

338e51e8 10/14/2008 02:29 pm Iustin Pop

Change over to beparams

This big patch changes the master code to use the beparams. Errors might
have crept in, but it passes a small burnin.

Reviewed-by: ultrotter

51de46bf 10/14/2008 02:29 pm Iustin Pop

Change the backend to use the beparams

The backend.FinalizeExport function is changed to use the beparams
instead of the instance attributes. Future enhancements should be done
in order to export and import/reuse the whole be/hv params.

Reviewed-by: ultrotter

8b3fd458 10/14/2008 02:29 pm Iustin Pop

Change hypervisors to use the beparams

This patch changes the hypervisor functions to use the beparams dict
instead of the instance attributes.

Reviewed-by: ultrotter

5b442704 10/14/2008 02:29 pm Iustin Pop

Correctly fill the beparams too over RPC

As for the hvparams, we need to replace the sent instance beparams.

Reviewed-by: ultrotter

a604f165 10/14/2008 02:29 pm Iustin Pop

Add cli function for beparams validation

This is used to validate the parameters in both “gnt-instance add” and
“gnt-backup import”.

Reviewed-by: ultrotter

cd3ab26e 10/14/2008 02:29 pm Iustin Pop

Modify the beparams constants

Memory is renamed for easier use.

Reviewed-by: ultrotter

8705eb96 10/14/2008 01:21 pm Iustin Pop

Fix a bug with instance creation and hvparameters

When creating an instance, we need to check not the opcode hvparams, but
the final, filled hvparams against validity. While we do this for the
remote node calls (i.e. ValidateParams), we didn't do this for...

57821cac 10/14/2008 01:21 pm Iustin Pop

Allow instance info to only query the config file

This patch adds a new '-s' parameter to ‘gnt-instance info’ that makes
it return only 'static' information. This is much faster, especially for
drbd instances.

This is a forward-port of rev 1570 on the ganeti-1.2 branch, resending...

24838135 10/14/2008 01:21 pm Iustin Pop

Convert gnt-instance info to the hvparams model

Some informations are not printed nicely (e.g. “virtual CDROM: False”),
but this is the first step.

Reviewed-by: imsnah

74409b12 10/14/2008 01:20 pm Iustin Pop

Change gnt-instance modify to the hvparams model

Reviewed-by: imsnah

5018a335 10/14/2008 01:20 pm Iustin Pop

Change gnt-instance list to the hvparams model

This is just a change of the various hvm_ and pvm parameters to the hv
model. Parameters are queried via hv/$name or via the whole dict as
returned by hvparams.

Reviewed-by: ultrotter,imsnah

6785674e 10/14/2008 01:20 pm Iustin Pop

Switch instance hypervisor parameters to hvparams

This big patch changes instance create to the new hvparams structure.
Old parameters are removed, so old jobs or old instances file will break
current clusters.

Reviewed-by: ultrotter

f23b5ae8 10/14/2008 01:20 pm Iustin Pop

Temporary fix for dual hvm/pvm instances

We have a problem with the current model of combining instance lists
from multiple hypervisors: we don't allow duplicates, but "xm list"
gives the same output for both pvm and hvm. This is a lack in the actual
xen hypervisor implementation/split between pvm and hvm, but for now we...

26ba2bd8 10/14/2008 01:20 pm Iustin Pop

Implement FillHV for instance-related rpc calls

We fill the instance hvparams with cluster defaults, and send a modified
dict over the wire to the node methods - they don't know anything about
cluster defaults versus instance parameters.

Reviewed-by: ultrotter

6217e295 10/14/2008 01:19 pm Iustin Pop

Export the hypervisor.ValidateParameters over RPC

The newly-added node-specific ValidateParams hypervisor method is
exported over RPC, using the semi-standard (success, message) return
value. Multi-node call, so that we call on both primary and secondary at...

f48148c3 10/14/2008 01:19 pm Iustin Pop

Implement the new hypervisor API in base/xen

This patch adds the new methods CheckParameterSyntax and the
ValidateParameters in the base and xen hypervisors. It also changes the
xen hypervisor to use the new hvparams field on instance.

Reviewed-by: imsnah

937e4814 10/14/2008 11:24 am Michael Hanselmann

Get rid of httperror module

This was a leftover from the early days of the remote API in Ganeti 1.2.

Reviewed-by: ultrotter

fcd62d84 10/14/2008 09:38 am Iustin Pop

Implement parameter removal in SplitKeyVal

This patch adds paramter removal in SplitKeyVal, by prefixing a
value-less key with "-"; this is needed in resetting parameters back to
cluster defaults, but care must be applied now that None can come from
the parser....

5bf7b5cf 10/14/2008 09:36 am Iustin Pop

Add the hv/be params object attributes

This patch adds the instance and cluster be/hvparams attributes, and the
Fill* methods on the cluster object. Nothing else is changes, except
that these attributes exist now on the objects.

Reviewed-by: ultrotter

e64b8beb 10/14/2008 09:36 am Iustin Pop

Add constants for the HV/BE parameter names

Since we don't want the string values of the parameters (e.g.
“kernel_path”) spread over the code, we introduce constants for these.

Reviewed-by: ultrotter,schreiberal

16ad1a83 10/13/2008 04:49 pm Iustin Pop

Fix a few rpc-related errors

This fixes:
- whitespace change, double lines between methods
- duplication of call_upload_file, introduced by mistake in rev 1795
and which went undetected because of the many changes in that ref
(only diff -b shows it clearly)...

a8469393 10/13/2008 03:17 pm Iustin Pop

Add two new options types for CLI usage

For the new 2.0-style command line options, we need to parse strings of
the type:
ident:key=val[,...]
and
key=val[,...]

This patch adds two new option builders for these two, which return
(ident, {key=val,}) and {key=val,} for the above two formats. It also...

2d8ed1fe 10/13/2008 03:15 pm Iustin Pop

Some small typos on design docs

Reviewed-by: imsnah

ca8ac26a 10/13/2008 12:19 pm Iustin Pop

Update the cluster parameters design doc

As discussed, we update the design doc with the three classes of
parameters and other changes.

Reviewed-by: imsnah

caad16e2 10/12/2008 11:40 pm Iustin Pop

Abstract checking own address into a function

Currently, we check if we have a given ip address (i.e. it's alive on
one of our interfaces) but manually calling TcpPing(source=localhost).
This works, but having it spread all over the code makes it hard to...

15396f60 10/10/2008 08:08 pm Michael Hanselmann

Mark call_node_leave_cluster as a static method

Reviewed-by: iustinp

082a7f91 10/10/2008 07:04 pm Guido Trotter

OS API: support for multiple versions in an OS

Allow multiple api versions in an OS. This is according to the OS API
changes design doc, by which an OS can support multiple versions of the
Ganeti API and if one is supported by Ganeti it will work. Since up to...

2eb78bc8 10/10/2008 07:04 pm Guido Trotter

LUVerifyCluster: fix error from rpc call

When calling node_verify leads to an error _VerifyNodes tries to iterate
over a non-sequence. Catch the error before and avoid this from
happening.

Reviewed-by: iustinp

cc28af80 10/10/2008 07:00 pm Michael Hanselmann

Convert ganeti-noded to new HTTP server class

Reviewed-by: iustinp

42242313 10/10/2008 07:00 pm Michael Hanselmann

Add new HTTP server implementation

This patch adds another implementation of an HTTP server. It's
based on code of Python's BaseHTTPServer, from both version
2.4 and 3k. In the future we can write code to decide whether
we should fork for a request or not. Keep-alive is not supported....

821d9e43 10/10/2008 07:00 pm Michael Hanselmann

Add daemon library with mainloop

This mainloop can be used in daemons like ganeti-noded.

Reviewed-by: iustinp

e9f242e4 10/10/2008 06:12 pm Iustin Pop

Some updates on the job queue design doc

This clarifies the job storage and the reason for choosing it.

Reviewed-by: imsnah

93c4f7f1 10/10/2008 12:55 pm René Nussbaumer

Update design-2.0-job-queue to reflect changes

With change 1773 a new status WAITLOCK was introduced if a job/opcode is
waiting for a lock. This change updates the document about the job-queue
accordingly.

Reviewed-by: iustinp

72737a7f 10/10/2008 12:55 pm Iustin Pop

Convert rpc module to RpcRunner

This big patch changes the call model used in internode-rpc from
standalong function calls in the rpc module to via a RpcRunner class,
that holds all the methods. This can be used in the future to enable
smarter processing in the RPC layer itself (some quick examples are not...

b9bddb6b 10/10/2008 12:52 pm Iustin Pop

Cleanup in cmdlib for standalone function calls

This patch is a cleanup of the standalone functions in cmdlib. Many of
them too as argument a ConfigWriter instance, but some also took other
parameters from the lu (e.g. proc), and in the future, if we want to...

7b3a8fb5 10/10/2008 12:51 pm Iustin Pop

Small random fixes

Indentation in bootstrap was wrong and some names in cmdlib.py were not
right.

Reviewed-by: imsnah

4b2f38dd 10/09/2008 02:29 pm Iustin Pop

Move instance hypervisor check to ExpandNames

This check can be done earlier, in ExpandNames, and is needed here for
the hypervisor parameter check.

Reviewed-by: ultrotter

c2b05d85 10/09/2008 02:13 am Alexander Schreiber

Update documentation & man pages for changed hypervisor names.

Reviewed-by: imsnah

c666722f 10/08/2008 09:48 pm Oleksiy Mishchenko

Ajust config unittest.

Reviewed-by: iustinp

e49099a4 10/08/2008 08:31 pm Alexander Schreiber

Update scripts and qa config for changed hypervisor names.

Reviewed-by: ultrotter