Skip to content
Snippets Groups Projects
  1. Oct 26, 2012
  2. Oct 25, 2012
  3. Oct 19, 2012
  4. Oct 05, 2012
  5. Aug 23, 2012
    • Iustin Pop's avatar
      Bump pep8 version to 1.2 · 5ae4945a
      Iustin Pop authored
      
      Debian Wheezy will ship with this version, and it has many improved checks compared to 0.6, so let's:
      
      - bump version in the docs
      - silence some new checks that are wrong due to our indent=2 instead of 4
      - fix lots of errors in the code where the indentation was wrong by 1
        or 2 spaces
      - fix a few cases of == True, False, None and replace with 'is'
      - re-indent some cases where the code is OK, but pep8 complains
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarRené Nussbaumer <rn@google.com>
      5ae4945a
  6. Jul 19, 2012
  7. Jul 05, 2012
    • Iustin Pop's avatar
      Fix DRBD resize code · cad0723b
      Iustin Pop authored
      
      There are two bugs in the current resize code, affecting mostly DRBD.
      
      First, due to bugs in old DRBD versions (pre 8.0.14), the code currently
      calls `drbdsetup resize' on both the primary or secondary. However,
      this is actually wrong per current DRBD (from drbdsetup(8)):
      
           resize
             This causes DRBD to reexamine the size of the device's backing
             storage device. To actually do online growing you need to
             extend the backing storages on both devices and call the resize
             command on one of your nodes.
      
      So calling it just on the primary node should be enough. However, we
      can't simply remove the calls to the secondary nodes, since that would
      break the growth of the underlying storage (LVM) on the
      secondary. Which leads to the second existing bug: we call resize on
      each node, even before finish the growth of the underlying
      storage. This can leads to all kind of issues if DRDB is not well
      behaved.
      
      So to fix both these bugs, we have to extend the current RPC call with
      another parameter, which denotes whether to extend the actual backing
      storage or just the "logical" one (DRBD being the only one; MD would
      be another, if implemented). This allows us to do the growth in two
      steps, first the backing store on all nodes, then the logical storage
      on just the primary node.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarRené Nussbaumer <rn@google.com>
      cad0723b
  8. Jun 19, 2012
  9. Jun 12, 2012
  10. May 10, 2012
  11. Mar 23, 2012
  12. Feb 21, 2012
  13. Jan 23, 2012
  14. Dec 12, 2011
  15. Dec 08, 2011
  16. Dec 06, 2011
    • Andrea Spadaccini's avatar
      Add DRBD barriers disk parameters · 8a69b3a8
      Andrea Spadaccini authored
      
      Add the disk-barriers and meta-barriers parameters described in the
      design doc.
      
      constants.py:
      * add the needed LD and DT-level parameters, use the defaults provided
        at ./configure time;
      * add constants representing which barriers should be disabled and the
        set of valid options.
      
      lib/bdev.py:
      * factor the barriers handling code to a class method, for testing
        purposes;
      * implement the more granular version checking logic;
      * use the LD level parameters;
      * add stricter check on DRBD version (8.0, 8.2 or 8.3), as we do not
        support 8.4 yet.
      
      lib/cmdlib.py:
      * translate DT level parameters to LD level ones.
      
      configure.ac, Makefile.am:
      * set both disk and meta barriers parameters depending on the value of
        --enable-drbd-barriers.
      
      test/ganeti.bdev_unittest.py:
      * unit tests for the code that sets DRBD barrier parameters depending on
        the version.
      
      doc/design-resource-model.rst:
      * reword the description of meta-barriers;
      * change all disk parameters names to use dashes instead of underscores.
      
      Signed-off-by: default avatarAndrea Spadaccini <spadaccio@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      8a69b3a8
  17. Dec 02, 2011
  18. Dec 01, 2011
  19. Nov 21, 2011
  20. Aug 30, 2011
  21. Aug 25, 2011
  22. Aug 23, 2011
  23. Aug 05, 2011
    • Iustin Pop's avatar
      Zero DRBD metadata before creation · 18e4dee6
      Iustin Pop authored
      The docstring of the DRBD8 class says:
      
        … The meta device is checked for valid size and is zeroed on create.
      
      which is not done today, hence we have
      http://code.google.com/p/ganeti/issues/detail?id=182
      
      :
      
        node1# mkreiserfs -f /dev/xenvg/t8
        …
        ReiserFS is successfully created on /dev/xenvg/t8.
        node1# drbdmeta --force /dev/drbd256 v08 /dev/xenvg/t8 0 create-md
        md_offset 0
        al_offset 4096
        bm_offset 36864
      
        Found reiser filesystem
      
        This would corrupt existing data.
        If you want me to do this, you need to zero out the first part
        of the device (destroy the content).
        You should be very sure that you mean it.
        Operation refused.
      
      I've tested and even just 1MB is enough to wipe the meta, but let's be
      safer and pass a 'clean' meta to drbd.
      
      Note: I didn't copy _WipeDevice from backend.py since it seemed more
      complex than needed here.
      
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarMichael Hanselmann <hansmi@google.com>
      18e4dee6
  24. Jul 25, 2011
  25. May 10, 2011
  26. Mar 08, 2011
    • Apollon Oikonomopoulos's avatar
      Shared block storage support · b6135bbc
      Apollon Oikonomopoulos authored
      
      This patch introduces basic shared block storage support.
      
      It introduces a new storage backend, bdev.PersistentBlockDevice, to
      use as a backend for shared block storage. The new bdev requires a new
      BLOCKDEV_DRIVER_MANUAL constant with the value "manual" and uses it as
      the first part of the block device unique_id.
      
      A new disk template, DT_BLOCK is introduced as well and added to
      DTS_EXT_MIRROR and DTS_MAY_ADOPT. Also added DTS_MUST_ADOPT constant
      and use it to check for the presence of the adopt keyword during LU
      invocation. We enforce the /dev/disk limitation upon adoption, but we
      allow block devices to reside anywhere under /dev.
      
      This is very basic support and includes no storage manipulation (provisioning,
      resizing, renaming) which will have to be implemented through a "driver"
      framework.
      
      Signed-off-by: default avatarApollon Oikonomopoulos <apollon@noc.grnet.gr>
      [iustin@google.com: slight changes to bdev.py]
      Signed-off-by: default avatarIustin Pop <iustin@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      b6135bbc
  27. 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
  28. Jan 11, 2011
  29. Dec 02, 2010
  30. Sep 23, 2010
  31. Sep 22, 2010
  32. Aug 18, 2010
    • Manuel Franceschini's avatar
      Introduce new IPAddress classes · 8b312c1d
      Manuel Franceschini authored
      
      This patch unifies the netutils functions dealing with IP addresses to
      three classes:
      - IPAddress: Common IP address functionality
      - IPv4Address: IPv4 specific functionality
      - IPv6address: IPv6-specific functionality
      
      Furthermore it adds methods to check whether an address is a loopback
      address, replacing the .startswith("127") for IPv4 and adding IPv6
      support.
      
      It also provides the basis for future IPv6 address handling. Methods to
      convert IP strings to their corresponding interger values will allow to
      canonicalize IPv6 addresses.
      
      Signed-off-by: default avatarManuel Franceschini <livewire@google.com>
      Reviewed-by: default avatarIustin Pop <iustin@google.com>
      8b312c1d
  33. Aug 05, 2010
Loading