1. 16 Jul, 2008 1 commit
    • Guido Trotter's avatar
      Fork ganeti-noded · 761ce945
      Guido Trotter authored
      Create a new ForkingHTTPServer in ganeti-noded by deriving both from
      NodeDaemonHttpServer and ForkingMixin. This will allow us to process
      concurrent requests.
      Reviewed-by: imsnah
  2. 14 Jul, 2008 2 commits
  3. 11 Jul, 2008 2 commits
  4. 10 Jul, 2008 2 commits
  5. 09 Jul, 2008 7 commits
    • Iustin Pop's avatar
      Fix double-logging in daemons · ff5fac04
      Iustin Pop authored
      Currently, in debug mode, both the logfile handler and the stderr
      handler will log debug messages. Since the stderr is redirected to the
      same logfile (to catch non-logged errors), it means log entries are
      The patch adds an extra parameter to the logger.SetupDaemon() function
      that allows disabling of the stderr logging. The master and node daemon
      will use this to enable stderr logging only when running in foreground.
      Reviewed-by: imsnah
    • Iustin Pop's avatar
      ganeti-noded logging improvements · c89189b1
      Iustin Pop authored
      The patch adds some more logging to the node daemon:
      - log methods at beggining not only at the end
      - log method parameters (they are very verbose, but useful)
      A separate change is to initialize the global variable in the global
      scope, not inside main().
      Reviewed-by: imsnah
    • Iustin Pop's avatar
      Remove the old locking functions · d4fa5c23
      Iustin Pop authored
      This removes (hopefully) all traces of the old locking functions and
      Reviewed-by: imsnah
    • Michael Hanselmann's avatar
      Remove old job queue code · 2467e0d3
      Michael Hanselmann authored
      Reviewed-by: iustinp
    • Michael Hanselmann's avatar
      Change masterd/client RPC protocol · 0bbe448c
      Michael Hanselmann authored
      - Introduce abstraction class on client side
      - Use constants for method names
      - Adopt legacy function SubmitOpCode to use it
      Reviewed-by: iustinp
    • Michael Hanselmann's avatar
      Make luxi RPC more flexible · 3d8548c4
      Michael Hanselmann authored
      - Use constants for dict entries
      - Handle exceptions on server side
      - Rename client function to CallMethod to match server side naming
      Reviewed-by: iustinp
    • Michael Hanselmann's avatar
      Instantiate new job queue in master daemon · 50a3fbb2
      Michael Hanselmann authored
      Reviewed-by: iustinp
  6. 08 Jul, 2008 1 commit
  7. 04 Jul, 2008 1 commit
    • Iustin Pop's avatar
      Fix some issues with the watcher · 26517d45
      Iustin Pop authored
      This patch fixes two bugs:
        - the state file is not saved because we use the method for checking
          for udpated data
        - in two places 'Error' was used instead of 'Exception', which breaks
          error handling
        - the unused 're' import has been removed
        - a variable named 'id' which collides with a builtin function has
          been renamed
      Note that comparing the serialized forms might create false negatives
      (due to the dicts being reordered) but that will just cause an extra
      write of the file, which is sub-optimal but harmless.
      Reviewed-by: ultrotter
  8. 03 Jul, 2008 1 commit
    • Iustin Pop's avatar
      Add custom logging setup for daemons · 3b316acb
      Iustin Pop authored
      It's better for daemons if:
        - they log only to one log file
        - the log level is included
        - for debug runs, the filename/line number is included
      This patch moves the custom formatter from the watcher to the logging
      module and generalizes it; then it changes the master daemon to use this
      function instead of the generic logging (which might be deprecated
      anyway in the future).
      Reviewed-by: imsnah
  9. 02 Jul, 2008 2 commits
  10. 01 Jul, 2008 3 commits
    • Guido Trotter's avatar
      Context: s/GLM/glm/ · 984f7c32
      Guido Trotter authored
      Make the GanetiLockManager instance of GanetiContext lowercase
      Reviewed-by: imsnah
    • Guido Trotter's avatar
      Increase the thread size to 5 · a478cd7e
      Guido Trotter authored
      Now that we use the locking library to make sure running opcodes cannot
      step on each other toes we can have a bigger thread size, and
      potentially process many opcodes in a parallel manner.
      Reviewed-by: iustinp
    • Guido Trotter's avatar
      Processor: pass context in and use it. · 1c901d13
      Guido Trotter authored
      The processor used to create a new ConfigWriter when it was initialized.
      We now have one in the context, so we'll just recycle it. First of all
      we'll pass the context in when creating a new Processor object, then
      we'll just use context.cfg, which is granted to be initialized, wherever
      we used self.cfg, and stop checking whether the config is already
      initialized or not.
      In the future the Processor will be able to use the context also to
      acquire the BGL for LUs that require it, and to push the context down to
      LUs that don't in order for them to manage their own locking.
      Reviewed-by: iustinp
  11. 30 Jun, 2008 1 commit
    • Guido Trotter's avatar
      ganeti-masterd: init and distribute common context · 39dcf2ef
      Guido Trotter authored
      This patch creates a new GanetiContext class, which is used to hold
      context common to all ganeti worker threads. As for the
      GanetiLockingManager class it is paramount that there is only one such
      class throughout the execution of Ganeti, so the class checks for that,
      and also forbids its own modification after it's been initialized. The
      context for now contains a ConfigWriter and a GanetiLockingManager and
      is created by the daemon and propagated to PoolWorker(s) and
      Reviewed-by: iustinp
  12. 27 Jun, 2008 1 commit
  13. 26 Jun, 2008 2 commits
    • Guido Trotter's avatar
      ganeti-noded: quit on QuitGanetiException · 9ae49f27
      Guido Trotter authored
      Accoring to the usage documented in the QuitGanetiException docstring,
      if we receive such an exception we'll set the global _EXIT_GANETI_NODED
      variable to True, and then return either a valid value or an error
      message to the user. This will be the last request we serve, though,
      because the main loop will be interrupted and the daemon will terminate.
      Reviewed-by: iustinp
    • Guido Trotter's avatar
      ganeti-noded: serve not quite forever · 3b3db8fd
      Guido Trotter authored
      Rather than calling httpd.serve_forever() in ganeti-noded we'll call
      httpd.handle_request() but just while a global variable, which we'll
      call _EXIT_GANETI_NODED, remains false.
      Reviewed-by: iustinp
  14. 23 Jun, 2008 1 commit
    • Guido Trotter's avatar
      Handle any exception in ganeti-masterd · 0db7ac4d
      Guido Trotter authored
      If an uncaught exception is thrown currently it destroys the calling
      thread. This patch changes the behaviour to failing the current job,
      logging a message, but trying to keep the daemon up.
      Reviewed-by: imsnah
  15. 20 Jun, 2008 1 commit
    • Iustin Pop's avatar
      Add a rpc call for BlockDev.Close() · d61cbe76
      Iustin Pop authored
      This patch adds rpc layer calls (in rpc.py and the equivalent in
      ganeti-noded) to close a list of block devices, and the wrapper in
      backend.py that takes a list of Disk objects, identifies them and
      returns correctly formatted results.
      The reason why this very basic call was missing until now from the rpc
      layer is that we usually don't care about device closes (though we
      should, and will do so in the future) as only drbd has a meaningful
      Close() operation; right now we directly do Shutdown().
      The patch is clean enough that it's actually independent of the live
      migration implementation.
      Reviewed-by: imsnah
  16. 19 Jun, 2008 1 commit
  17. 18 Jun, 2008 8 commits
  18. 17 Jun, 2008 1 commit
    • Iustin Pop's avatar
      Implement block device grow at the rpc layer · 4c8ba8b3
      Iustin Pop authored
      This simple patch exposes the block device grow operation at the rpc
      layer. It does not increase the protocol version as it has been recently
      changed by the live failover rpc call.
      Reviewed-by: imsnah
  19. 16 Jun, 2008 1 commit
    • Iustin Pop's avatar
      Add migration support at the rpc layer · 2a10865c
      Iustin Pop authored
      This patch adds the migration rpc call and its implementation in the
      backend. The patch does not deal with the correct activation of disks.
      Because of the new RPC, the protocol version is increased.
      Reviewed-by: imsnah
  20. 13 Jun, 2008 1 commit