Statistics
| Branch: | Tag: | Revision:

root / lib @ 30786fc9

Name Size
  build
  confd
  http
  hypervisor
  rapi
__init__.py 820 Bytes
asyncnotifier.py 1.9 kB
backend.py 86.5 kB
bdev.py 63 kB
bootstrap.py 20.8 kB
cli.py 59.5 kB
cmdlib.py 314 kB
config.py 46.5 kB
constants.py 21.7 kB
daemon.py 10.6 kB
errors.py 8.8 kB
jqueue.py 41.7 kB
jstore.py 3.8 kB
locking.py 40.3 kB
luxi.py 11.4 kB
mcpu.py 20.2 kB
objects.py 29.7 kB
opcodes.py 18.9 kB
rpc.py 35.2 kB
serializer.py 4.6 kB
ssconf.py 13.5 kB
ssh.py 7.8 kB
storage.py 12.5 kB
utils.py 72 kB
workerpool.py 8.9 kB

Latest revisions

# Date Author Comment
30786fc9 03/08/2010 03:52 pm Iustin Pop

hv_kvm: remove hard-coded path constructs

This switches hv_kvm to PathJoin. There are still a few cases of direct
path construction, but those should be safe.

Signed-off-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

3b80eb2c 03/08/2010 03:51 pm Iustin Pop

hv_fake: remove hard-coded path constructs

This changes to hv_fake to PathJoin.

Signed-off-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

6b0391b3 03/08/2010 03:51 pm Iustin Pop

hv_chroot: remove hard-coded path constructs

This patch abstract the computation of an instance's root directory into
a separate function (that uses PathJoin instead of "%s/%s").

Signed-off-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

6136f8f0 03/08/2010 03:49 pm Iustin Pop

Add strict name validation for the LVM backend

Currently we don't enforce name validation for the LVM backend, on the
idea that LVM itself will reject invalid names and we catch those
errors.

However, recent LVM documents the accepted VG/LV name space, so it's...

cb7c0198 03/08/2010 03:49 pm Iustin Pop

Implement disabling of file-based storage

Rationale: the file-based storage backend can add/remove files under a
certain directory. However, the master node is also controlling the
setting of the file-based root directory, so basically it means we can't
prevent arbitrary modifications by the master of the node's filesystem....

e02b9114 03/08/2010 03:48 pm Iustin Pop

Replace os.path.sep.join(seq) with utils.PathJoin

This is a no-op change, but at least we concentrate the calls to path
joins into a single function.

A use in utils.FindFile is left as-is (don't want to raise exceptions
there, at least for now).

Signed-off-by: Iustin Pop <>...

81a3406c 03/08/2010 03:48 pm Iustin Pop

Abstract OS log names computation

The various OS operations create log files in a specific directory
(constants.LOG_OS_DIR). The construction of the log names is however
spread and duplicated across multiple functions.

This patch abstracts this into a separate function that also validates...

a9b7e346 03/08/2010 03:48 pm Iustin Pop

Remove superfluous warnings in HooksRunner

For non-existing hooks (the majority of cases probably), logging a
warning every time is not helpful. So we first check if we have a valid
directory.

Signed-off-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

c4feafe8 03/08/2010 03:48 pm Iustin Pop

Switch from os.path.join to utils.PathJoin

This passes a full burnin with lots of instances, and should be safe as
we mostly to join a known root (various constants) to a run-time
variable.

Signed-off-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

4bb678e9 03/08/2010 03:46 pm Iustin Pop

utils: Add a PathJoin function

This will replace os.path.join since it is not safe for directory
traversal issues.

Signed-off-by: Iustin Pop <>
Reviewed-by: Michael Hanselmann <>

View revisions

Also available in: Atom