1. 06 Jul, 2010 2 commits
  2. 30 Jun, 2010 1 commit
  3. 09 Jun, 2010 1 commit
  4. 16 Apr, 2010 1 commit
  5. 15 Apr, 2010 2 commits
    • Iustin Pop's avatar
      Fix cluster behaviour with disabled file storage · 0e3baaf3
      Iustin Pop authored
      
      
      There are a few issues with disabled file storage:
      - cluster initialization is broken by default, as it uses the 'no'
        setting which is not a valid path
      - some other parts of the code require the file storage dir to be a
        valid path; we workaround by skipping such code paths when it is
        disabled
      
      A side effect is that we abstract the storage type checks into a
      separate function and add validation in RepairNodeStorage (previously a
      luxi client which didn't use cli.py and submitted an invalid type would
      get "storage units of type 'foo' can not be repaired").
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarRené Nussbaumer <rn@google.com>
      0e3baaf3
    • Iustin Pop's avatar
      Fix cfgupgrade with non-default DATA_DIR · aeefe835
      Iustin Pop authored
      Commit 43575108 added bootstrap.GenerateclusterCrypto and commit
      7506a7f1
      
       changed cfgupgrade to use it. However, this lost the
      functionality of upgrading in non-default DATA_DIR.
      
      To fix this, we enhance bootstrap.GenerateclusterCrypto to accept custom
      file paths for the three files it modifies. If more files will be needed
      in the future, we could just pass in modified DATA_DIR, but for now it
      suffices.
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarRené Nussbaumer <rn@google.com>
      aeefe835
  6. 08 Apr, 2010 1 commit
  7. 17 Mar, 2010 1 commit
  8. 15 Mar, 2010 2 commits
  9. 12 Mar, 2010 1 commit
  10. 08 Mar, 2010 1 commit
  11. 19 Feb, 2010 1 commit
  12. 01 Feb, 2010 1 commit
  13. 13 Jan, 2010 1 commit
  14. 05 Nov, 2009 1 commit
    • Michael Hanselmann's avatar
      Add new “daemon-util” script to start/stop Ganeti daemons · f154a7a3
      Michael Hanselmann authored
      
      
      Until now, Ganeti started and stopped its own daemons using custom functions.
      To start, the daemon was just executed and then sent the appropriate signals to
      stop it again. Init scripts would have to pay attention to the PID file and
      other things.
      
      With this patch, a new script is added (“daemon-util”, installed in
      $prefix/lib/ganeti/), centralizing the starting and stopping of daemons. The
      provided example init script is adjusted to use this new script. Ganeti's code
      no longer calls its own init script.
      Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      f154a7a3
  15. 04 Nov, 2009 1 commit
    • Iustin Pop's avatar
      Introduce a wrapper for hostname resolving · 104f4ca1
      Iustin Pop authored
      
      
      Currently a few of the LU's CheckPrereq use utils.HostInfo which raises
      a resolver error in case of failure. This is an exception from the
      standard that CheckPrereq should raise an OpPrereqError if the error is
      in the 'pre' phase (so that it can be retried).
      
      This patch adds a new error code (resolver_error) and a wrapper over
      utils.HostInfo that just converts the ResolverError into
      OpPrereqError(…, errors.ECODE_RESOLVER). It then uses this wrapper in
      cmdlib, bootstrap and some scripts.
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarMichael Hanselmann <hansmi@google.com>
      104f4ca1
  16. 03 Nov, 2009 2 commits
  17. 02 Nov, 2009 1 commit
  18. 30 Oct, 2009 1 commit
  19. 27 Oct, 2009 1 commit
    • Michael Hanselmann's avatar
      Provide feedback from redistributing configuration · a4eae71f
      Michael Hanselmann authored
      
      
      This is particularily useful for “gnt-cluster redist-conf”, but
      also for all other cases where the configuration files are
      rewritten on other nodes.
      
      $ gnt-cluster redist-conf
      … Copy of file /var/lib/ganeti/config.data to node … failed: Error while
      executing backend function: [Errno 1] Operation not permitted
      … Error while uploading ssconf files to node …: Error while executing backend
      function: [Errno 1] Operation not permitted
      
      $ gnt-node modify --offline no --force node3.example.com
      … - WARNING: Not enough master candidates (desired 10, new value will be 4)
      … Copy of file /var/lib/ganeti/config.data to node node8.example.com failed:
      Error while executing backend function: [Errno 1] Operation not permitted
      Modified node node3.example.com
       - offline -> True
       - master_candidate -> auto-demotion due to offline
      Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      a4eae71f
  20. 22 Oct, 2009 1 commit
  21. 16 Oct, 2009 2 commits
  22. 25 Sep, 2009 1 commit
    • Iustin Pop's avatar
      Add uuid on node/instance add and cluster init · 430b923c
      Iustin Pop authored
      
      
      This patch does a little bit of cleanup first, since we want to call
      GenerateUniqueID without reacquiring the lock.
      
      Note that we don't necessarily need to do this for the cluster, since at
      first startup ConfigWriter will do it anyway. But it's better to
      explicitely do this instead of relying on the automated upgrade.
      
      Additionally this patch adds ctime/mtime population at cluster init
      time. mtime is not necessarily needed (master will update it
      automatically, but we're doing it anyway for consistency).
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarMichael Hanselmann <hansmi@google.com>
      430b923c
  23. 24 Sep, 2009 1 commit
  24. 17 Sep, 2009 1 commit
  25. 16 Sep, 2009 1 commit
  26. 03 Sep, 2009 1 commit
  27. 17 Aug, 2009 1 commit
  28. 13 Aug, 2009 1 commit
  29. 10 Aug, 2009 1 commit
  30. 29 Jul, 2009 1 commit
  31. 20 Jul, 2009 1 commit
  32. 16 Jul, 2009 4 commits
    • Guido Trotter's avatar
      b119bccb
    • Guido Trotter's avatar
      Get rid of the default_hypervisor slot · 066f465d
      Guido Trotter authored
      
      
      Currently we have both a default_hypervisor and an enabled_hypervisors
      list. The former is only settable at cluster init time, while the latter
      can be changed with cluster modify.
      
      This becomes cumbersome in a few ways: at cluster init time for example
      if we pass in a list of enabled hypervisors which doesn't include the
      "default" xen-pvm one, we're also forced to pass a default hypervisor,
      or an error will be reported. It is also currently possible to disable
      the default hypervisor in cluster-modify (with unknown results).
      
      In order to avoid this we get rid of this field altogether, and define
      the "first" enabled hypervisor as the default one. This allows ease of
      changing which one is the default, and at the same time maintains
      coherency.
      
      At configuration upgrade we make sure that the old default is first in
      the list, so that 2.0 cluster defaults are preserved.
      Signed-off-by: default avatarGuido Trotter <ultrotter@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      066f465d
    • Guido Trotter's avatar
      Simplify InitConfig and remove SimpleConfigWriter · a33848a5
      Guido Trotter authored
      
      
      InitConfig currently creates the cluster config_data, then puts it into
      a dict, passes it to SimpleConfigWriter to load it from a dict (which
      just reuses the dict value) and then saves it. The SimpleConfigWriter is
      then returned, but ignored. With this patch we just write out the
      config_data at InitConfig time, and thus can remove SimpleConfigWriter
      altogether. The now unused SimpleConfigReader.FromDict is also gone.
      Signed-off-by: default avatarGuido Trotter <ultrotter@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      a33848a5
    • Guido Trotter's avatar
      InitCluster, don't use SimpleConfigWriter · 9e1333b9
      Guido Trotter authored
      
      
      InitConfig returns a SimpleConfigWriter to InitCluster, which then
      passes it on to ssh.WriteKnownHostsFile, which extracts a couple of
      values from it. One line later the full ConfigWriter is initialized.
      
      By initializing it one line before we can pass the full writer to
      ssh.WriteKnownHostsFile, and thus we don't need to care anymore for the
      InitConfig returned SimpleConfigWriter
      Signed-off-by: default avatarGuido Trotter <ultrotter@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      9e1333b9