1. 26 Jan, 2012 1 commit
  2. 13 Jan, 2012 1 commit
  3. 08 Dec, 2011 2 commits
  4. 24 Nov, 2011 4 commits
    • Michael Hanselmann's avatar
      ConfigWriter: Fix epydoc error · 1d4930b9
      Michael Hanselmann authored
      
      
      The parameter is called “mods”, not “modes”.
      Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
      Reviewed-by: default avatarAndrea Spadaccini <spadaccio@google.com>
      (cherry picked from commit 1730d4a1)
      1d4930b9
    • Michael Hanselmann's avatar
      ConfigWriter: Fix epydoc error · 1730d4a1
      Michael Hanselmann authored
      
      
      The parameter is called “mods”, not “modes”.
      Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
      Reviewed-by: default avatarAndrea Spadaccini <spadaccio@google.com>
      1730d4a1
    • Michael Hanselmann's avatar
      LUGroupAssignNodes: Fix node membership corruption · 54c31fd3
      Michael Hanselmann authored
      
      
      Note: This bug only manifests itself in Ganeti 2.5, but since the
      problematic code also exists in 2.4, I decided to fix it there.
      
      If a node was assigned to a new group using “gnt-group assign-nodes” the
      node object's group would be changed, but not the duplicate member list
      in the group object. The latter is an optimization to require fewer
      locks for other operations. The per-group member list is only kept in
      memory and not written to disk.
      
      Ganeti 2.5 starts to make use of the data kept in the per-group member
      list and consequently fails when it is out of date. The following
      commands can be used to reproduce the issue in 2.5 (in 2.4 the issue was
      confirmed using additional logging):
      
        $ gnt-group add foo
        $ gnt-group assign-nodes foo $(gnt-node list --no-header -o name)
        $ gnt-cluster verify  # Fails with KeyError
      
      This patch moves the code modifying node and group objects into
      “config.ConfigWriter” to do the complete operation under the config
      lock, and also to avoid making use of side-effects of modifying objects
      without calling “ConfigWriter.Update”. A unittest is included.
      Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      (cherry picked from commit 218f4c3d)
      54c31fd3
    • Michael Hanselmann's avatar
      LUGroupAssignNodes: Fix node membership corruption · 218f4c3d
      Michael Hanselmann authored
      
      
      Note: This bug only manifests itself in Ganeti 2.5, but since the
      problematic code also exists in 2.4, I decided to fix it there.
      
      If a node was assigned to a new group using “gnt-group assign-nodes” the
      node object's group would be changed, but not the duplicate member list
      in the group object. The latter is an optimization to require fewer
      locks for other operations. The per-group member list is only kept in
      memory and not written to disk.
      
      Ganeti 2.5 starts to make use of the data kept in the per-group member
      list and consequently fails when it is out of date. The following
      commands can be used to reproduce the issue in 2.5 (in 2.4 the issue was
      confirmed using additional logging):
      
        $ gnt-group add foo
        $ gnt-group assign-nodes foo $(gnt-node list --no-header -o name)
        $ gnt-cluster verify  # Fails with KeyError
      
      This patch moves the code modifying node and group objects into
      “config.ConfigWriter” to do the complete operation under the config
      lock, and also to avoid making use of side-effects of modifying objects
      without calling “ConfigWriter.Update”. A unittest is included.
      Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      218f4c3d
  5. 16 Nov, 2011 3 commits
  6. 14 Nov, 2011 2 commits
  7. 07 Nov, 2011 1 commit
  8. 03 Nov, 2011 3 commits
  9. 28 Oct, 2011 1 commit
  10. 27 Oct, 2011 1 commit
  11. 26 Oct, 2011 1 commit
  12. 05 Oct, 2011 1 commit
  13. 30 Aug, 2011 1 commit
  14. 25 Aug, 2011 1 commit
  15. 04 Aug, 2011 1 commit
  16. 03 Aug, 2011 2 commits
  17. 30 May, 2011 1 commit
    • Apollon Oikonomopoulos's avatar
      Fix argument order in ReserveLV and ReserveMAC · 8785b71b
      Apollon Oikonomopoulos authored
      
      
      ConfigWriter.ReserveLV() and Configwriter.ReserveMAC() called
      TemporaryReservationManager.Reserve() with the ec_id and resource arguments
      swapped. As a result, two reservation attempts for the same resource type
      within the same LU would fail, even if the resources requested were different,
      e.g.:
      
        $ gnt-instance add -t sharedfile -o debootstrap+default \
             --net 0:mac=00:01:02:03:04:00 \
             --net 1:mac=00:01:02:03:04:ff \
             --disk 0:size=2g  test_instance
        Failure: prerequisites not met for this operation:
        error type: resource_not_unique, error details:
        MAC address 00:01:02:03:04:ff already in use in cluster
      
      This patch fixes the argument order in the call to Reserve().
      Signed-off-by: default avatarApollon Oikonomopoulos <apollon@noc.grnet.gr>
      Signed-off-by: default avatarGuido Trotter <ultrotter@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      8785b71b
  18. 25 May, 2011 1 commit
  19. 19 May, 2011 1 commit
  20. 06 May, 2011 1 commit
  21. 05 May, 2011 1 commit
  22. 14 Apr, 2011 1 commit
    • Iustin Pop's avatar
      Prevent ssconf values from having non-string values · 2afc9238
      Iustin Pop authored
      
      
      For whatever reason, my test cluster managed to acquire
      shared_file_storage_dir with a None value, instead of empty
      string. This is not flagged in masterd itself, but the node daemon
      will fail in writing the value to disk, as it calls len() on the
      received value.
      
      Since this is a bad case, we should detect it as soon as possible (we
      basically shouldn't be able to set it), but in the meantime we at
      least prevent ssconf writes with such values.
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
      2afc9238
  23. 11 Mar, 2011 2 commits
  24. 01 Mar, 2011 1 commit
    • 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
  25. 01 Feb, 2011 2 commits
  26. 28 Jan, 2011 3 commits