Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Commits on Dec 6, 2010
  1. Kirill Kolyshkin

    vzctl set --features bridge: enable CAP_NET_ADMIN

    kolyshkin authored
    Capability CAP_NET_ADMIN is required for VE_FEATURE_BRIDGE
    to work, so let's raise it automagically.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Nov 24, 2010
  1. Kirill Kolyshkin

    vzlist: introduce uptime

    kolyshkin authored
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Nov 23, 2010
  1. Kirill Kolyshkin

    vzlist: rename Cla to Ccpustat

    kolyshkin authored
    Should not have any visible effect.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
  2. Kirill Kolyshkin

    vzlist.h: load average should be float

    kolyshkin authored
    No need for double precision here.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
  3. Kirill Kolyshkin

    vzctl start/runscript: add ability to set per-CT osrelease

    kolyshkin authored
    Some distros (like recent Fedora versions) expect a kernel
    version to be x.y.z or newer, and won't work with older kernels.
    Our kernels are usually sufficiently patched to work with new
    userspace, but this check for kernel version requires some
    trickery.
    
    Introduce /etc/vz/osrelease.conf to have these requirements
    configurable. Use new /dev/vzctl ioctl to set per-CT osrelease
    field, based on distro name and contents of osrelease.conf
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Nov 18, 2010
  1. Kirill Kolyshkin

    quota_ctl(), vps_set_quota(): refactor/fix

    kolyshkin authored
    There is no need to do hairy trickery with return values
    in quota_ctl() -- always return the exit code of vzquota.
    
    In vps_set_quota(), when we run quota_ctl(STAT2), we need
    to find out if UGID quota is running or not. If it's not
    running vzquota returns exit code of 9, which we check for.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Oct 29, 2010
  1. Cyrill Gorcunov Kirill Kolyshkin

    iptables mask should be 64 bit

    cyrillos authored kolyshkin committed
    It is defined this way in the kernel, so as long as we will start
    using bits more than 2^31 we will loose functionality.
    
    Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
  2. Cyrill Gorcunov Kirill Kolyshkin

    Introduce ARRAY_SIZE helper

    cyrillos authored kolyshkin committed
    Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
  3. Cyrill Gorcunov Kirill Kolyshkin

    iptables: Sync modules control bits with the kernel

    cyrillos authored kolyshkin committed
    iptable modules control bits are quite sensitive
    with the ones being used by the kernel. The patch syncs them.
    
    Also, VE_IP_MATCH_RECENT_MOD intersects with kernel's
    VE_IP_IPTABLES6_MOD. This is not a problem at the moment
    but could become one. Fixed as well.
    
    [kir@openvz.org: added undef, keep 80 col width, English fixes]
    Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Sep 1, 2010
  1. Kirill Kolyshkin

    vzctl stop: try to untangle CT IP cleanup mess

    kolyshkin authored
    OK, here is a mess.
    
    First, vps_stop() calls vps_cleanup_res() which calls run_net_script()
    which calls external shell script vps_net-del to clean up CT IPs.
    One problem is vps_cleanup_res() is called with STATE_STOPPING, which
    is ignored and run_net_script() is called with STATE_RUNNING (for
    whatever reason).
    
    Second, vps_stop() calls external shell script vps-stop which is
    supposed to take IP_ADDR environment variable. The problem is IP_ADDR
    is never passed. It's not a problem really since IP addresses were
    cleaned up already, there's actually no need for vps-stop at all.
    
    This is how we try to untangle it:
    
    1. Remove vps_cleanup_res(), do call run_net_script() directly.
    2. Supply STATE_STOPPING to the vps_net-del script.
    3. In vps_net-del, remove a file with CT IPs in case CT is stopping.
    4. Remove vps_stop and call to it -- it wasn't working/needed anyway.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Aug 31, 2010
  1. Kirill Kolyshkin

    logger: add set_log_quiet() and set_log_ctid()

    kolyshkin authored
    In principle these two can be set using init_log(), but it has too
    many arguments, so provide a separate functions (to be used by
    vzeventd).
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
  2. Kirill Kolyshkin

    include/logger.h: fix description for quiet parameter

    kolyshkin authored
    ...and add description for CTID while we are at it.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Jul 23, 2010
  1. Cyrill Gorcunov Kirill Kolyshkin

    Add vz_strdup helper

    cyrillos authored kolyshkin committed
    In case if strdup failed the logger will record the case.
    
    Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
Commits on Jul 6, 2010
  1. Kirill Kolyshkin

    get_netaddr(): last argument should be void*

    kolyshkin authored
    This one is used as last argument to inet_pton
    which is void*, so let it be void* as well.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Jul 1, 2010
  1. Kirill Kolyshkin

    vzctl set: remove obsoleted --veth_{add,del} options

    kolyshkin authored
    These options were introduced in June 2006 in vzctl-3.0.10
    and later in December 2006 (vzctl-3.0.14) were obsoleted
    by --netif_{add,del}. Since then vzctl prints warning
    then these options are used.
    
    Now, remove these options completely, stop parsing
    VETH= line in configuration file and print a warning
    that one should remove it and use --netif_* instead.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Jun 30, 2010
  1. Kirill Kolyshkin

    Get rid of obsoleted pkgset/pkgver parameters

    kolyshkin authored
    Those were used in ancient Rome before ostemplate
    was introduced. Remove those, and rename a couple
    of defines that still have _PKGSET_ in their names
    to have _OSTEMPLATE_ instead.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
  2. Kirill Kolyshkin

    Move set_opt[] to where it belongs

    kolyshkin authored
    I am not sure why it was defined in src/lib/config.c
    with a kludge get_set_opt() to make it availabe in
    vzctl-actions.c. In fact it is only needed inside
    parse_set_options() function, so move it.
    
    Pure refactoring, should have no visible effect.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Jun 1, 2010
  1. Kirill Kolyshkin

    vzlist: add support for OSTEMPLATE field

    kolyshkin authored
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
  2. Kirill Kolyshkin

    vzlist: clean up some unneeded RES_ defines

    kolyshkin authored
    Defines RES_NAME, RES_DESCRIPTION, RES_ONBOOT, RES_BOOTORDER and RES_IO
    are completely unnecessary. Remove them.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on May 26, 2010
  1. Kirill Kolyshkin

    vzlist: add ioprio field

    kolyshkin authored
    Currently the value is only obtained from CT config files.
    We could add support for getting the value from /proc/bc/$CTID/ioprio
    some time later.
    
    http://bugzilla.openvz.org/show_bug.cgi?id=1526
    
    Reported-by: Dennis P. Nikolaenko <dennis@nikolaenko.ru>
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on May 11, 2010
  1. Cyrill Gorcunov Kirill Kolyshkin

    execvep: Use vz_strlcat helper

    cyrillos authored kolyshkin committed
    Otherwise we may get stack overwritten.
    
    Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
Commits on Apr 30, 2010
  1. Kirill Kolyshkin

    Use enum instead of defines for ACTION_s

    kolyshkin authored
    This makes compiler do some stricter checking,
    also debugging is easier since you see the name not value.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
  2. Kirill Kolyshkin

    Minor cleanup

    kolyshkin authored
    Removed unused #defines and some commented out code that used those.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Mar 10, 2010
  1. Kirill A. Korinskiy Kirill Kolyshkin

    Add a premount and postumount action scripts to vzctl

    catap authored kolyshkin committed
Commits on Mar 5, 2010
  1. Kirill Kolyshkin

    vps_set_ioprio(): remove unused param

    kolyshkin authored
    Parameter vps_param *vps_p is not used by vps_set_ioprio, so let's
    remove it.
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Mar 3, 2010
  1. Kirill Kolyshkin

    Copyright year fixes

    kolyshkin authored
  2. Kirill Kolyshkin

    Declare get_veid_by_name() argument as const

    kolyshkin authored
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Mar 2, 2010
  1. Kirill Kolyshkin

    Copyright year fixes, or Happy New Year!

    kolyshkin authored
    Use the following snippet of shell code to fix copyright years
    according to latest git commit date:
    
    for f in $(git ls-files); do
    	date=$(git log --pretty=format:%cD -1 $f) || continue
    	year=$(echo $date | awk '{print $4}')
    	sed -e "s/\(Copyright (C) 200[0-9]-\)20[0-9][0-9]\(, Parallels\)/\1${year}\2/" -i $f
    done
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Feb 25, 2010
  1. ott Kirill Kolyshkin
Commits on Feb 15, 2010
  1. Andrew Vagin Kirill Kolyshkin

    Handle hardlink directory during chkpnt/restore

    avagin authored kolyshkin committed
    The OpenVZ kernel (since 028stab065) has a feature to support
    creating hardlink files during chkpnt. This is needed to prevent
    a live migration fail when CT is over NFS and there is a deleted but
    opened file in container being migrated. The error you get from
    the kernel in this case is the following:
    
     # vzctl suspend 100
     Setup checkpoint ...
     Can not dump Container: Device or resource busy
     Error: deleted reference to existing inode, checkpointing is impossible: -2
     Checkpointing of Container failed
    
    The test case is:
     Open r/w and unlink file, and fork before migration
     Check that the child can write to it and the parent
     Check that file can be read from it after migration
    
    Now with this support in the kernel vzctl needs to do some trickery.
    In particular, it should (a) tell the kernel where to store such
    hardlinked files (during chkpnt) and (b) during restore, enable these
    files.
    
    vzctl now does:
    a) On chkpnt: call ioctl CPT_LINKDIR_ADD to tell directory for
       storing hardlinked files.
    b) On restore: call CPT_HARDLNK_ON ioctl to enable open hardlinked
       files.
    c) Clean hardlinked directory (delete hardlinks) in the following cases:
      1. Before 'chkpnt --dump' (Filesystem must be clean before doing dump)
      2. Before 'chkpnt --resume'
      3. Before 'start' (To prevent: vzctl dump; vzctl start)
      4. After successfull 'restore --undump' (or in other words,
         before 'restore --resume')
      5. After failed 'chkpnt --dump'
    
    Note, that vzctl doesn't clean hardlink directory after stopping CT.
    
    Patch is based on code from Igor Sukhih <igor@openvz.org>
    
    [kir@openvz.org: expanded the description, trim down to 80 column width,
     fixed an error message, moved _GNU_SOURCE declaration to the .c file]
Commits on Jan 28, 2010
  1. Kirill Kolyshkin

    Introduce "nfsd" feature

    kolyshkin authored
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Commits on Jan 25, 2010
  1. Cyrill Gorcunov Kirill Kolyshkin

    vzfeatures: Add ipgre and bridge features

    cyrillos authored kolyshkin committed
    ipgre feature is already supported in 2.6.18 kernel
    and we're going to support per-ve bridges too soon.
    
    In turn vzctl should support the whole set of features
    and leave a kernel to decide which particular feature
    is supported on a specified kernel.
    
    Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
Commits on Dec 9, 2009
  1. Kirill Kolyshkin

    Cleanup: use const when passing CT root path

    kolyshkin authored
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
  2. Kirill Kolyshkin

    Trivial whitespace cleanup: get rid of empty lines at EOF

    kolyshkin authored
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
  3. Kirill Kolyshkin

    init_log(): declare progname argument as const

    kolyshkin authored
    This fixes the following compilation warning:
    
      CC     vzcfgvalidate.o
    vzcfgvalidate.c: In function ‘main’:
    vzcfgvalidate.c:67: warning: passing argument 6 of ‘init_log’ discards qualifiers from pointer target type
    
    Signed-off-by: Kir Kolyshkin <kir@openvz.org>
Something went wrong with that request. Please try again.