Skip to content
Snippets Groups Projects
  1. Sep 30, 2011
    • Iustin Pop's avatar
      Optimise cli.JobExecutor with many pending jobs · 11705e3d
      Iustin Pop authored
      
      In the case we submit many pending jobs (> 100) to the masterd, the
      JobExecutor 'spams' the master daemon with status requests for the
      status of all the jobs, even though in the end it will only choose a
      single job for polling.
      
      This is very sub-optimal, because when the master is busy processing
      small/fast jobs, this query forces reading all the jobs from
      this. Restricting the 'window' of jobs that we query from the entire
      set to a smaller subset makes a huge difference (masterd only, 0s
      delay jobs, all jobs to tmpfs thus no I/O involved):
      
      - submitting/waiting for 500 jobs:
        - before: ~21 s
        - after:   ~5 s
      - submitting/waiting for 1K jobs:
        - before: ~76 s
        - after:   ~8 s
      
      This is with a batch of 25 jobs. With a batch of 50 jobs, it goes from
      8s to 12s. I think that choosing the 'best' job for nice output only
      matters with a small number of jobs, and that for more than that
      people will not actually watch the jobs. So changing from 'perfect
      job' to 'best job in the first 25' should be OK.
      
      Note that most jobs won't execute as fast as 0 delay, but this is
      still a good improvement.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      Reviewed-by: default avatarMichael Hanselmann <hansmi@google.com>
      11705e3d
  2. Aug 30, 2011
  3. Aug 25, 2011
  4. Aug 08, 2011
    • Michael Hanselmann's avatar
      Detect globbing patterns as query arguments · f8638e28
      Michael Hanselmann authored
      
      Short: this patch enables the use of “gnt-instance list '*.site'”.
      
      Detailed description: This patch changes the command line interface code
      to try to deduce the kind of filter from the arguments to a “list”
      command. If it's a list of plain names an old-style name filter is used.
      If filtering is forced or the single argument is potentially a filter,
      it is parsed as a query filter string. Any name looking like a globbing
      pattern (e.g. “*.site” or “web?.example.com”) is treated as such.
      
      Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      f8638e28
  5. Aug 04, 2011
    • Michael Hanselmann's avatar
      ganeti-watcher: Split for node groups · 16e0b9c9
      Michael Hanselmann authored
      
      This patch brings a huge change to ganeti-watcher to make it aware of
      node groups. Each node group is processed in its own subprocess,
      reducing the impact of long-running operations.
      
      The global watcher state file, $datadir/ganeti/watcher.data, is replaced
      with a state file per node group ($datadir/ganeti/watcher.${uuid}.data).
      
      Previously a lock on the state file was used to ensure only one instance
      of watcher was running at the same time. Some operations, e.g.
      “gnt-cluster renew-crypto”, blocked the watcher by acquiring an
      exclusive lock on the state file. Since the watcher processes now use
      different files, this method is no longer usable. Locking multiple files
      isn't atomic. Instead a dedicated lock file is used and every watcher
      process acquires a shared lock on it. If a Ganeti command wants to block
      the watcher it acquires the lock in exclusive mode.
      
      Each per-nodegroup watcher process also acquires an exclusive lock on
      its state file. This prevents multiple watchers from running for the
      same nodegroup.
      
      The code is reorganized heavily to clear up dependencies between
      functions and to get rid of the global “client” variable. The utility
      class “Watcher” is removed in favour of stand-alone utility functions.
      
      Since the parent watcher process won't wait for its children by
      default, a new option (--wait-children) was added. It is used, for
      example, by QA.
      
      Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      16e0b9c9
  6. Jul 29, 2011
  7. Jul 28, 2011
    • Iustin Pop's avatar
      Revert "cli.JobExecutor: Feedback function for info output" · 4474f112
      Iustin Pop authored
      
      This reverts commit 7421df8e.
      
      The feedback_fn argument to JobExecutor is used for PollJob, and thus
      has a fixed signature: a single arg, tuple of (timestamp, log type,
      log message). It's use as drop-in replacement for ToStdout doesn't
      work, as that function has a different signature.
      
      For now, I propose to revert this, until we either change JobExecutor
      to use the same log messages (and add an intermediate wrapper between
      JobExecutor and ToStdout) or we add another parameter to
      JobExecutor.__init__.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarMichael Hanselmann <hansmi@google.com>
      4474f112
  8. Jul 26, 2011
  9. Jul 25, 2011
  10. Jul 21, 2011
  11. Jul 12, 2011
  12. Jul 08, 2011
  13. Jul 05, 2011
  14. Jun 07, 2011
  15. Jun 01, 2011
  16. May 25, 2011
  17. May 19, 2011
  18. May 16, 2011
  19. May 02, 2011
  20. Apr 21, 2011
  21. Apr 18, 2011
  22. Apr 13, 2011
  23. Apr 06, 2011
  24. Mar 17, 2011
  25. Mar 15, 2011
  26. Mar 09, 2011
  27. Mar 08, 2011
  28. Mar 01, 2011
    • Apollon Oikonomopoulos's avatar
      Core shared file storage support · 4b97f902
      Apollon Oikonomopoulos authored
      
      This patch introduces core file storage support, consisting of the following:
      
      A configure-time switch for enabling/disabling shared file storage
      support and controlling the shared file storage location:
      --with-shared-file-storage-dir=.  Shared file storage configuration is then
      available as _autoconf.ENABLE_SHARED_FILE_STORAGE and
      _autoconf.SHARED_FILE_STORAGE_DIR and there is a cluster-wide ssconf
      key named "shared_file_storage_dir" for changing the file location.
      
      A new disk template named "sharedfile" (DT_SHARED_FILE), using
      ganeti.bdev.FileStorage.
      
      Auxiliary functions in lib/config.py to handle shared file storage.
      
      Signed-off-by: default avatarApollon Oikonomopoulos <apollon@noc.grnet.gr>
      [iustin@google.com: small style fixes]
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      4b97f902
  29. Feb 25, 2011
  30. Feb 24, 2011
  31. Feb 22, 2011
  32. Feb 18, 2011
  33. Feb 04, 2011
  34. Feb 03, 2011
Loading