1. 20 Oct, 2008 26 commits
    • Alexander Schreiber's avatar
      Set default hypervisor at cluster init · 02691904
      Alexander Schreiber authored
      During cluster init, set the default hypervisor to be used for instances.
      Ensure that the default hypervisor belongs to the set enabled hypervisors
      for this cluster. Also fix a small bug with setting the default enabled
      hypervisor list.
      
      Reviewed-by: imsnah
      
      02691904
    • Iustin Pop's avatar
      Convert the job queue rpcs to address-based · 99aabbed
      Iustin Pop authored
      The two main multi-node job queue RPC calls (jobqueue_update,
      jobqueue_rename) are converted to address-based calls, in order to speed
      up queue changes. For this, we need to change the _nodes attribute on
      the jobqueue to be a dict {name: ip}, instead of a set.
      
      Reviewed-by: imsnah
      99aabbed
    • Iustin Pop's avatar
      Convert rpc.call_upload_file to use addresses · 6b294c53
      Iustin Pop authored
      This patch allows rpc.call_upload_file to use addresses (if passed), and
      also converts the ConfigWriter._DistributeConfig to pass them, since
      this is an often-done operation.
      
      Reviewed-by: imsnah
      6b294c53
    • Iustin Pop's avatar
      Convert non-static rpc calls to use addresses · 25348212
      Iustin Pop authored
      This patch converts all non-staticmethods rpc calls to pass addresses to
      the Client calls.
      
      This is done via two new small helpers. These functions also deal with
      nodes that are not (yet) in the configuration file, and pass None for
      the address instead (which allow NodeControllers to do resolving).
      
      Reviewed-by: imsnah
      25348212
    • Iustin Pop's avatar
      Add infrastructure for using addresses in rpc.py · bdf7d8c0
      Iustin Pop authored
      The patch adds support for passing node addresses to NodeController
      objects, which should speed up the connect sequence.
      
      The patch also adds another very small optimization of computing the
      content-length header value in the parent Client class instead of each
      NodeController.
      
      Reviewed-by: imsnah
      bdf7d8c0
    • Iustin Pop's avatar
      Improve conformance with the style guide for rpc.py · 3ef3c771
      Iustin Pop authored
      This patch renames some internal function to camel case, for compliance
      with the style guide.
      
      It also fixes the module docstring (how old was that?).
      
      Reviewed-by: imsnah
      3ef3c771
    • Guido Trotter's avatar
      Use constants.VALUE_AUTO for ip comparison too · 6fde8221
      Guido Trotter authored
      Forward-port-of: r1889, Reviewed-by: imsnah
      
      Reviewed-by: imsnah
      6fde8221
    • Guido Trotter's avatar
      Document mac option for gnt-backup import · 8cd7cb4c
      Guido Trotter authored
      Forward-port-of: (r1888, r1891), Reviewed-by: (iustinp, imsnah)
      
      Reviewed-by: imsnah
      8cd7cb4c
    • Guido Trotter's avatar
      LUCreateInstance: reuse mac address on import · bc89efc3
      Guido Trotter authored
      When importing an instance with the same name as the exported one if the
      mac address is "auto" we try to reuse the previous mac address. One can
      still force generation of a new one with mac="generate".
      
      Forward-port-of: r1887, Reviewed-by: iustinp
      
      Reviewed-by: imsnah
      bc89efc3
    • Guido Trotter's avatar
      LUCreateInstance: accept mac = VALUE_GENERATE · c78995f0
      Guido Trotter authored
      VALUE_GENERATE is handled exactly the same as VALUE_AUTO and the mac
      address is generated randomly.
      
      Forward-port-of: r1886, Reviewed-by: iustinp
      
      Reviewed-by: imsnah
      c78995f0
    • Guido Trotter's avatar
      Add mac option to gnt-backup import · 3c8886a9
      Guido Trotter authored
      Before 'auto' was the only allowed possibility
      
      Forward-port-of: r1885, Reviewed-by: iustinp
      
      Reviewed-by: imsnah
      3c8886a9
    • Guido Trotter's avatar
      Add VALUE_AUTO and VALUE_GENERATE constants · 4c566ede
      Guido Trotter authored
      'auto' is used in multiple place in the code with a meaning similar to
      'default', 'generate' will be used to force generation of mac addresses
      when the default would be to reuse an old one.
      
      Forward-port-of: r1884, Reviewed-by: iustinp
      
      Reviewed-by: imsnah
      4c566ede
    • Iustin Pop's avatar
      Remove the logger.py module · 82d9caef
      Iustin Pop authored
      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
      82d9caef
    • Iustin Pop's avatar
      Convert http.py to use the logging module · 263ab7cf
      Iustin Pop authored
      Reviewed-by: imsnah
      263ab7cf
    • Iustin Pop's avatar
      Convert cmdlib.py to use the logging module · 9a4f63d1
      Iustin Pop authored
      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
      instead of being a logging call.
      
      Reviewed-by: imsnah
      9a4f63d1
    • Iustin Pop's avatar
      Convert hv_xen.py to use the logging module · b48909c8
      Iustin Pop authored
      Reviewed-by: imsnah
      b48909c8
    • Iustin Pop's avatar
      Convert mcpu.py to use the logging module · a5eb7789
      Iustin Pop authored
      Reviewed-by: imsnah
      a5eb7789
    • Iustin Pop's avatar
      Convert ssh.py to use the logging module · 23828f1c
      Iustin Pop authored
      Reviewed-by: imsnah
      23828f1c
    • Iustin Pop's avatar
      Convert rpc.py to use the logging module · 58b311ca
      Iustin Pop authored
      Reviewed-by: imsnah
      58b311ca
    • Iustin Pop's avatar
      Fix some pylint-detected issues on the scripts · 2f79bd34
      Iustin Pop authored
      Some names were wrong, and similar stuff detected by pylint.
      gnt-debug.GenericOpCode is still broken.
      
      Reviewed-by: imsnah
      2f79bd34
    • Iustin Pop's avatar
      Convert the gnt scripts to ToStdout/err · 3a24c527
      Iustin Pop authored
      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
      3a24c527
    • Iustin Pop's avatar
      Convert cli.py to logging · 46fbdd04
      Iustin Pop authored
      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)
      (instead of requiring formatting by the client.
      
      Reviewed-by: imsnah
      46fbdd04
    • Iustin Pop's avatar
      Fix gnt-instance modify with beparams · 61be6ba4
      Iustin Pop authored
      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
      61be6ba4
    • Alexander Schreiber's avatar
      Update gnt-cluster man page for removal of --hypervisor-type. · dcd7cbaf
      Alexander Schreiber authored
      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
      
      dcd7cbaf
    • Michael Hanselmann's avatar
      Remove old HTTP server code · fa10bdc5
      Michael Hanselmann authored
      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.
      
      Reviewed-by: ultrotter
      fa10bdc5
    • Alexander Schreiber's avatar
      Remove --hypervisor-type from gnt-cluster. · 4342e89b
      Alexander Schreiber authored
      We no longer use a single, cluster-wide hypervisor, but configure the
      actual to be used hypervisor on the instance level.
      
      Reviewed-by: imsnah
      
      4342e89b
  2. 18 Oct, 2008 2 commits
  3. 17 Oct, 2008 12 commits