1. 17 Sep, 2008 2 commits
  2. 12 Sep, 2008 1 commit
  3. 11 Sep, 2008 15 commits
  4. 10 Sep, 2008 9 commits
    • Michael Hanselmann's avatar
      jqueue: Add common RPC error handling function · e74798c1
      Michael Hanselmann authored
      We didn't decide yet what exactly it should do with failed nodes.
      
      Reviewed-by: ultrotter
      e74798c1
    • Iustin Pop's avatar
      Remove locking of instances in certain queries · 57a2fb91
      Iustin Pop authored
      This patch is similar to the node patch (rev 1650). We disable locking
      of instance (and nodes) if we only query static information.
      
      Reviewed-by: ultrotter
      57a2fb91
    • Iustin Pop's avatar
      Add an atomic ConfigWrite.GetAllInstanceInfo() · 0b2de758
      Iustin Pop authored
      In order to be able to query instance without locking them, we need the
      same atomic query of multiple instances as for nodes.
      
      Reviewed-by: ultrotter
      0b2de758
    • Iustin Pop's avatar
      Add ConfigWriter._UnlockedGetInstanceList/Info() · 94bbfece
      Iustin Pop authored
      This patch splits the GetInstanceInfo and GetInstanceList methods into
      two parts, one locked one _Unlocked similar to the way nodes are
      queried.
      
      Reviewed-by: ultrotter
      94bbfece
    • Iustin Pop's avatar
      Do not use jobs in gnt-instance _ExpandNames() · b7329c9c
      Iustin Pop authored
      In the gnt-instance script, _ExpandNames() uses jobs to query instance
      names. This is not optimal, so we change it to use queries.
      
      Reviewed-by: ultrotter
      b7329c9c
    • Iustin Pop's avatar
      Implement "--submit" on gnt-instance · 6340bb0a
      Iustin Pop authored
      This patch adds support for the “--submit” parameter in the gnt-instance
      script, for the commands where it makes sense.
      
      Reviewed-by: ultrotter
      6340bb0a
    • Iustin Pop's avatar
      Rewrite the 'only submit job' handling in scripts · e9d741b6
      Iustin Pop authored
      The "sys.exit(0)" was not nice as you couldn't differentiate it from
      other exit codes. We change this to a specially defined exception for
      this, so that multi-opcode commands can handle this nicely.
      
      Reviewed-by: imsnah
      e9d741b6
    • Iustin Pop's avatar
      Optimize the OpQueryNodes for names only · c8d8b4c8
      Iustin Pop authored
      Currently, OpQueryNodes is locking all nodes (in shared mode), which
      will also block the special case of querying only for the node names
      (this is needed for gnt-cluster command, for example). There is no
      logical requirement to not give the administrator enough power if she/he
      knows what to do, so it would be logical that querying the node names
      works without a lock.
      
      The patch changes the LUQuerytNodes.ExpandNodes to only request locking
      when the selected fields contain dynamic attributes, and a small change
      in the Exec() method to use the new, atomic query method from
      ConfigWriter.
      
      Reviewed-by: ultrotter
      c8d8b4c8
    • Iustin Pop's avatar
      Add a way to export all node information at once · d65e5776
      Iustin Pop authored
      The patch adds a new function to export all node information at once
      (i.e. atomically with respect to the configuration lock).
      
      Reviewed-by: ultrotter
      d65e5776
  5. 09 Sep, 2008 13 commits
    • Michael Hanselmann's avatar
      ganeti-noded: Add constant for queue lock timeout · 8785cb30
      Michael Hanselmann authored
      Reviewed-by: iustinp
      8785cb30
    • Michael Hanselmann's avatar
      Never remove job queue lock in node daemon · 1bc59f76
      Michael Hanselmann authored
      Otherwise, corruption could occur in some corner cases. E.g. when
      LeaveNode is running in a child and is in the process of removing
      queue files, the main process gets killed, started again and gets
      a request to update the queue. This is rather extreme corner case,
      but we should opt for safety.
      
      Reviewed-by: iustinp
      1bc59f76
    • Iustin Pop's avatar
      Implement master startup safety check · 36205981
      Iustin Pop authored
      This is an initial version of the master startup checks. It's a very
      rudimentary change, however in normal usage (an old master was started,
      the rest of the cluster is functioning normally) it will succeed in
      preventing wrong startups.
      
      Reviewed-by: imsnah
      36205981
    • Iustin Pop's avatar
      Export backend.GetMasterInfo over the rpc layer · 4e071d3b
      Iustin Pop authored
      We create a multi-node call so that querying all nodes for agreement
      will be fast.
      
      Reviewed-by: imsnah
      4e071d3b
    • Iustin Pop's avatar
      Change backend._GetMasterInfo to return more data · bd1e4562
      Iustin Pop authored
      The _GetMasterInfo() function needs to export the master name too to be
      useful in master safety checks. This patch makes it a public (no _)
      function and adds a third element in the return tuple. Its callers are
      modified too.
      
      Reviewed-by: imsnah
      bd1e4562
    • Guido Trotter's avatar
      Parallelize LUQueryInstanceData · a987fa48
      Guido Trotter authored
      Reviewed-by: iustinp
      a987fa48
    • Guido Trotter's avatar
      Parallelize LUVerify{Cluster,Disks} · d4b9d97f
      Guido Trotter authored
      These are two easy querying LUs which require shared access to all
      nodes/instances.
      
      Reviewed-by: iustinp
      d4b9d97f
    • Guido Trotter's avatar
      Parallelize LUReplaceDisks · efd990e4
      Guido Trotter authored
      This is the most complex parallelization so far. We have to lock one
      instance (and its nodes) plus one more node if doing a remote replace,
      or all nodes if doing a remote replace with iallocator.
      
      Reviewed-by: iustinp
      efd990e4
    • Guido Trotter's avatar
      _LockInstancesNodes: support append mode · 9513b6ab
      Guido Trotter authored
      This will be used to lock the instance's nodes in addition to some more.
      
      Reviewed-by: iustinp
      9513b6ab
    • Guido Trotter's avatar
      Processor: remove ChainOpCode · b2751b57
      Guido Trotter authored
      This function was incompatible with the new locking system, and its
      usage has been removed from the code. For now LUs share code by calling
      common module-private functions in cmdlib.py, in the future they will
      use tasklets (when those will be implemented).
      
      Reviewed-by: iustinp
      b2751b57
    • Guido Trotter's avatar
      Parallelize LU{A,Dea}ctivateInstanceDisks · f22a8ba3
      Guido Trotter authored
      Now that they are not used in other opcodes by chaining,
      this can easily be done.
      
      Reviewed-by: iustinp
      f22a8ba3
    • Guido Trotter's avatar
      LUReplaceDisks: remove use of ChainOpCode · 023e3296
      Guido Trotter authored
      The calls to OpActivateInstanceDisks and OpDeactivateInstanceDisks has
      been replaced by _StartInstanceDisks and _SafeShutdownInstanceDisks
      respectively. This is the last usage of ChainOpCode.
      
      Reviewed-by: iustinp
      023e3296
    • Guido Trotter's avatar
      Create new _SafeShutdownInstanceDisks function · 155d6c75
      Guido Trotter authored
      This new function checks whether an instance is running, before shutting
      down its disks. This is what the Exec() of LUDeactivateInstanceDisks
      did, so that is replaced by a call to this function.
      
      Reviewed-by: iustinp
      155d6c75