]> git.proxmox.com Git - pve-container.git/log
pve-container.git
8 years agovzdump: always check if we have a valid rootfs volid
Dietmar Maurer [Wed, 26 Aug 2015 06:27:51 +0000 (08:27 +0200)]
vzdump: always check if we have a valid rootfs volid

8 years agodo not pass 'noerr' flags to parse_volume_id
Dietmar Maurer [Wed, 26 Aug 2015 06:04:56 +0000 (08:04 +0200)]
do not pass 'noerr' flags to parse_volume_id

8 years agovzdump: fail if we have mountpoints
Dietmar Maurer [Wed, 26 Aug 2015 05:46:05 +0000 (07:46 +0200)]
vzdump: fail if we have mountpoints

8 years agocode cleanup
Dietmar Maurer [Wed, 26 Aug 2015 05:41:59 +0000 (07:41 +0200)]
code cleanup

8 years agobump version to 0.9-13
Dietmar Maurer [Tue, 25 Aug 2015 10:55:48 +0000 (12:55 +0200)]
bump version to 0.9-13

8 years agodetect ostype when restoring OpenVZ containers
Wolfgang Bumiller [Mon, 24 Aug 2015 12:05:53 +0000 (14:05 +0200)]
detect ostype when restoring OpenVZ containers

Fixes #692

8 years agoTypo in create_rootfs() subroutine
Emmanuel Kasper [Mon, 24 Aug 2015 15:58:38 +0000 (17:58 +0200)]
Typo in create_rootfs() subroutine

8 years agobump version to 0.9-12
Dietmar Maurer [Mon, 24 Aug 2015 04:33:04 +0000 (06:33 +0200)]
bump version to 0.9-12

8 years agomountpoint_mount: remove unused parameter $ms
Dietmar Maurer [Fri, 21 Aug 2015 15:32:13 +0000 (17:32 +0200)]
mountpoint_mount: remove unused parameter $ms

8 years agomake create_rootfs sub generic
Alexandre Derumier [Fri, 21 Aug 2015 15:10:19 +0000 (17:10 +0200)]
make create_rootfs sub generic

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agovolid_path: don't format $path with loop:/
Alexandre Derumier [Fri, 21 Aug 2015 15:10:18 +0000 (17:10 +0200)]
volid_path: don't format $path with loop:/

This is only used in lxc config and not a real path

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd mountpoint_mount sub
Alexandre Derumier [Fri, 21 Aug 2015 15:10:17 +0000 (17:10 +0200)]
add mountpoint_mount sub

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd dettach_loops sub
Alexandre Derumier [Fri, 21 Aug 2015 15:10:16 +0000 (17:10 +0200)]
add dettach_loops sub

an move code from vm_stop_cleanup inside it

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd attach_loops sub
Alexandre Derumier [Fri, 21 Aug 2015 15:10:15 +0000 (17:10 +0200)]
add attach_loops sub

and move code from prestart hook inside it

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agomount hook : code cleanup
Alexandre Derumier [Fri, 21 Aug 2015 03:14:46 +0000 (05:14 +0200)]
mount hook : code cleanup

- use sub path
- manage bind mount for non devices
- split mount and device_cgroup  (we'll need mount later for backup for example)

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoupdate_lxc_config : code_clenaup
Alexandre Derumier [Fri, 21 Aug 2015 03:14:45 +0000 (05:14 +0200)]
update_lxc_config : code_clenaup

- use volid_path sub
- we now manage only rootfs, subvol mount.entry will be manage in mount hook

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd volid_path
Alexandre Derumier [Fri, 21 Aug 2015 03:14:44 +0000 (05:14 +0200)]
add volid_path

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoimplement pct listsnapshot cli command
Dietmar Maurer [Thu, 20 Aug 2015 14:55:36 +0000 (16:55 +0200)]
implement pct listsnapshot cli command

8 years agosplit PVE::API2::LXC into smaller parts
Dietmar Maurer [Thu, 20 Aug 2015 11:20:06 +0000 (13:20 +0200)]
split PVE::API2::LXC into smaller parts

8 years agobump version to 0.9-11
Dietmar Maurer [Wed, 19 Aug 2015 13:51:19 +0000 (15:51 +0200)]
bump version to 0.9-11

8 years agoremove <vmid>.fw file after lxc vm destroy
Alen Grizonic [Wed, 19 Aug 2015 08:34:52 +0000 (10:34 +0200)]
remove <vmid>.fw file after lxc vm destroy

Related to Bugfix 603: vmid.fw file not deleted

Signed-off-by: Alen Grizonic <a.grizonic@proxmox.com>
8 years agocleanup directory structure
Dietmar Maurer [Wed, 19 Aug 2015 05:46:17 +0000 (07:46 +0200)]
cleanup directory structure

8 years agoadd file access methods to LXCSetup::Base
Wolfgang Bumiller [Wed, 19 Aug 2015 05:57:56 +0000 (07:57 +0200)]
add file access methods to LXCSetup::Base

These should be used for all container file access as in the
future they'll support user-id mapping.

8 years agomountpoint: add support for host /dev/xxx block device passthrough
Alexandre Derumier [Tue, 18 Aug 2015 08:24:24 +0000 (10:24 +0200)]
mountpoint: add support for host /dev/xxx block device passthrough

example:
mp0: volume=/dev/sda,mp=/home/

Fix this request:
http://forum.proxmox.com/threads/23256-LXC-Cannot-assign-a-block-device-to-container

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoAdded PVE::LXCSetup::Base::setup_securetty
Wolfgang Bumiller [Tue, 18 Aug 2015 14:56:31 +0000 (16:56 +0200)]
Added PVE::LXCSetup::Base::setup_securetty

8 years agoarchlinux template support
Wolfgang Bumiller [Tue, 18 Aug 2015 14:56:30 +0000 (16:56 +0200)]
archlinux template support

8 years agomark mp[N] as experimental feature
Dietmar Maurer [Tue, 18 Aug 2015 07:14:51 +0000 (09:14 +0200)]
mark mp[N] as experimental feature

8 years agocheck quorum inside pre-start hook
Dietmar Maurer [Tue, 18 Aug 2015 07:12:39 +0000 (09:12 +0200)]
check quorum inside pre-start hook

8 years agomove setup_mountpoint into mount hook
Dietmar Maurer [Tue, 18 Aug 2015 05:59:03 +0000 (07:59 +0200)]
move setup_mountpoint into mount hook

I want to keep that code private.

8 years agocleanup docs
Dietmar Maurer [Tue, 18 Aug 2015 05:32:36 +0000 (07:32 +0200)]
cleanup docs

8 years agouse standard code inside post stop hook
Dietmar Maurer [Tue, 18 Aug 2015 05:25:08 +0000 (07:25 +0200)]
use standard code inside post stop hook

8 years agouse standard code inside pre-start hook
Dietmar Maurer [Tue, 18 Aug 2015 05:18:15 +0000 (07:18 +0200)]
use standard code inside pre-start hook

no need to use those hacks.

8 years agomount hook : setup_mountpoints
Alexandre Derumier [Tue, 18 Aug 2015 03:56:09 +0000 (05:56 +0200)]
mount hook : setup_mountpoints

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd lxc.mount.entry for subvol
Alexandre Derumier [Tue, 18 Aug 2015 03:56:08 +0000 (05:56 +0200)]
add lxc.mount.entry for subvol

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd pve-prestart-hook and move activate volumes inside it
Alexandre Derumier [Tue, 18 Aug 2015 03:56:07 +0000 (05:56 +0200)]
add pve-prestart-hook and move activate volumes inside it

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd lxc-pve-poststop-hook and move vm_stop_cleanup
Alexandre Derumier [Tue, 18 Aug 2015 03:56:06 +0000 (05:56 +0200)]
add lxc-pve-poststop-hook and move vm_stop_cleanup

It's better to vm_stop_cleanup inside poststop hook,
in case of CT failure (wrong start for example)

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agovm_stop_cleanup : detach loopdevices for non rootfs mountpoint
Alexandre Derumier [Tue, 18 Aug 2015 03:56:05 +0000 (05:56 +0200)]
vm_stop_cleanup : detach loopdevices for non rootfs mountpoint

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agovm_start : attach loop devices for non rootfs mountpoint
Alexandre Derumier [Tue, 18 Aug 2015 03:56:04 +0000 (05:56 +0200)]
vm_start : attach loop devices for non rootfs mountpoint

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agodo not allow hotplug of cmode option
Dietmar Maurer [Mon, 17 Aug 2015 10:54:12 +0000 (12:54 +0200)]
do not allow hotplug of cmode option

Hotplug does not work because we use dtach.

8 years agoadd find_loopdev sub
Alexandre Derumier [Sun, 16 Aug 2015 17:43:00 +0000 (19:43 +0200)]
add find_loopdev sub

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd blockdevices_list sub
Alexandre Derumier [Sun, 16 Aug 2015 17:42:59 +0000 (19:42 +0200)]
add blockdevices_list sub

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd loopdevices_list sub
Alexandre Derumier [Sun, 16 Aug 2015 17:42:58 +0000 (19:42 +0200)]
add loopdevices_list sub

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoimplement new cmode option
Dietmar Maurer [Sat, 15 Aug 2015 07:56:37 +0000 (09:56 +0200)]
implement new cmode option

So that the user can choose to use /dev/ttyX or /dev/console or /bin/sh.

8 years agoforeach_mountpoint: loop with defined order
Dietmar Maurer [Fri, 14 Aug 2015 14:33:52 +0000 (16:33 +0200)]
foreach_mountpoint: loop with defined order

8 years agodeactivate all mountpoint at ct stop
Alexandre Derumier [Fri, 14 Aug 2015 12:56:45 +0000 (14:56 +0200)]
deactivate all mountpoint at ct stop

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoactivate all mountpoints at vmstart
Alexandre Derumier [Fri, 14 Aug 2015 12:56:44 +0000 (14:56 +0200)]
activate all mountpoints at vmstart

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd foreach_mountpoint
Alexandre Derumier [Fri, 14 Aug 2015 12:56:43 +0000 (14:56 +0200)]
add foreach_mountpoint

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoadd mpX mountpoint config
Alexandre Derumier [Fri, 14 Aug 2015 12:56:42 +0000 (14:56 +0200)]
add mpX mountpoint config

10 mountpoint max currently (should be enough I think)

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agorefine tty hack for centos
Dietmar Maurer [Fri, 14 Aug 2015 10:26:02 +0000 (12:26 +0200)]
refine tty hack for centos

8 years agonew helper: has_dev_console
Dietmar Maurer [Fri, 14 Aug 2015 07:20:40 +0000 (09:20 +0200)]
new helper: has_dev_console

8 years agodeny access to /dev/console if console is disabled
Dietmar Maurer [Fri, 14 Aug 2015 06:50:39 +0000 (08:50 +0200)]
deny access to /dev/console if console is disabled

8 years agoset default tty count to 2
Dietmar Maurer [Fri, 14 Aug 2015 06:47:31 +0000 (08:47 +0200)]
set default tty count to 2

8 years agoadd console option
Dietmar Maurer [Fri, 14 Aug 2015 06:46:25 +0000 (08:46 +0200)]
add console option

8 years agoremove ct access permissions after destroy
Dietmar Maurer [Fri, 14 Aug 2015 06:17:09 +0000 (08:17 +0200)]
remove ct access permissions after destroy

8 years agocorrectly compute lxc.rootfs for new subvol format
Dietmar Maurer [Thu, 13 Aug 2015 17:39:56 +0000 (19:39 +0200)]
correctly compute lxc.rootfs for new subvol format

8 years agoprint_ct_mountpoint: fix info variable substitution
Wolfgang Bumiller [Thu, 13 Aug 2015 12:01:38 +0000 (14:01 +0200)]
print_ct_mountpoint: fix info variable substitution

8 years agomountpount->mountpoint + call fix
Wolfgang Bumiller [Thu, 13 Aug 2015 11:52:10 +0000 (13:52 +0200)]
mountpount->mountpoint + call fix

8 years agoimplement template creation
Dietmar Maurer [Thu, 13 Aug 2015 10:31:33 +0000 (12:31 +0200)]
implement template creation

8 years agoadd rbd storage type support
Alexandre Derumier [Wed, 12 Aug 2015 09:08:02 +0000 (11:08 +0200)]
add rbd storage type support

Signed-off-by: Alexandre Derumier <aderumier@odiso.com>
8 years agoubuntu: generate correct init/tty<X>.conf file for upstart
Dietmar Maurer [Wed, 12 Aug 2015 06:23:10 +0000 (08:23 +0200)]
ubuntu: generate correct init/tty<X>.conf file for upstart

8 years agodo not use hardcoded disk image names
Dietmar Maurer [Wed, 12 Aug 2015 05:21:12 +0000 (07:21 +0200)]
do not use hardcoded disk image names

8 years agobump version to 0.9-10
Dietmar Maurer [Tue, 11 Aug 2015 08:23:54 +0000 (10:23 +0200)]
bump version to 0.9-10

8 years agopve-update-lxc-config: reduce logging
Dietmar Maurer [Tue, 11 Aug 2015 08:21:34 +0000 (10:21 +0200)]
pve-update-lxc-config: reduce logging

8 years agoadded pve-update-lxc-config postinstall hook
Wolfgang Bumiller [Mon, 10 Aug 2015 08:07:20 +0000 (10:07 +0200)]
added pve-update-lxc-config postinstall hook

8 years agoallow to set empty lxc.xxx values
Dietmar Maurer [Tue, 11 Aug 2015 07:19:43 +0000 (09:19 +0200)]
allow to set empty lxc.xxx values

For examply, one would like to delete the seccomp profile with

lxc.seccomp =

8 years agofix description of parameter 'rootfs'
Dietmar Maurer [Sat, 8 Aug 2015 15:17:05 +0000 (17:17 +0200)]
fix description of parameter 'rootfs'

I never commited that '<storage>:<size>' functionality.

8 years agoupdate README for new configuration format
Dietmar Maurer [Sat, 8 Aug 2015 15:11:40 +0000 (17:11 +0200)]
update README for new configuration format

8 years agoadd support for RHEL/CentOS 7 (systemd console setup)
Dietmar Maurer [Sat, 8 Aug 2015 10:07:41 +0000 (12:07 +0200)]
add support for RHEL/CentOS 7 (systemd console setup)

8 years agoavoid warning about undefined values
Dietmar Maurer [Sat, 8 Aug 2015 07:48:22 +0000 (09:48 +0200)]
avoid warning about undefined values

8 years agobump version to 0.9-9
Dietmar Maurer [Fri, 7 Aug 2015 10:11:50 +0000 (12:11 +0200)]
bump version to 0.9-9

8 years agoFix: If a Ct are created and a pool are given add the Ct to pool.
Wolfgang Link [Fri, 7 Aug 2015 09:37:17 +0000 (11:37 +0200)]
Fix: If a Ct are created and a pool are given add the Ct to pool.

8 years agoFix mem ans swap size when converted from OpenVz.
Wolfgang Link [Fri, 7 Aug 2015 09:35:34 +0000 (11:35 +0200)]
Fix mem ans swap size when converted from OpenVz.

8 years agoFix in PVE::LXC parse_ct_mountpoint
Wolfgang Link [Fri, 7 Aug 2015 07:49:52 +0000 (09:49 +0200)]
Fix in PVE::LXC parse_ct_mountpoint

there was the allocation missed

8 years agofix LXC backup after changing lxc to pct conf
Wolfgang Link [Fri, 7 Aug 2015 07:49:51 +0000 (09:49 +0200)]
fix LXC backup after changing lxc to pct conf

8 years agodon't set proxy_arp and forwarding on lxc veths
Wolfgang Bumiller [Fri, 7 Aug 2015 09:20:32 +0000 (11:20 +0200)]
don't set proxy_arp and forwarding on lxc veths

Setting these doesn't make much sense as the interfaces are
attached to bridges (this is old cruft from VZ venet).
(Hotplugging already leaves them be at their default.)

8 years agoactivate/deactivates volumes on container start/stop
Dietmar Maurer [Fri, 7 Aug 2015 09:42:46 +0000 (11:42 +0200)]
activate/deactivates volumes on container start/stop

8 years agoallow to use drbd storage for containers
Dietmar Maurer [Fri, 7 Aug 2015 08:31:41 +0000 (10:31 +0200)]
allow to use drbd storage for containers

8 years agoallow to add low level LXC configuration directly
Dietmar Maurer [Fri, 7 Aug 2015 07:15:59 +0000 (09:15 +0200)]
allow to add low level LXC configuration directly

8 years agoadd manual page for container configuration format
Dietmar Maurer [Thu, 6 Aug 2015 14:37:51 +0000 (16:37 +0200)]
add manual page for container configuration format

8 years agoremove unused code
Dietmar Maurer [Thu, 6 Aug 2015 14:09:17 +0000 (16:09 +0200)]
remove unused code

8 years agoconsistent interface names and live network update
Wolfgang Bumiller [Thu, 6 Aug 2015 13:46:47 +0000 (15:46 +0200)]
consistent interface names and live network update

veth${vmid}.${id} looks like a vlan device, with qemu we use
tap${vmid}i${id}, so it makes sense to use an 'i' for
containers, too.

Fixed update_net to work with the new configuration method,
it still expected the old configuration hash and errored
when trying to change the network interface configuration
of a running continer.

8 years agocleanup - remove prefix
Dietmar Maurer [Thu, 6 Aug 2015 14:02:35 +0000 (16:02 +0200)]
cleanup - remove prefix

8 years agofix lxc.rootfs path for zfs based containers
Dietmar Maurer [Thu, 6 Aug 2015 09:50:17 +0000 (11:50 +0200)]
fix lxc.rootfs path for zfs based containers

8 years agobump version to 0.9-8
Dietmar Maurer [Thu, 6 Aug 2015 09:28:49 +0000 (11:28 +0200)]
bump version to 0.9-8

8 years agoadopt snaptshot implementation for new config format
Dietmar Maurer [Thu, 6 Aug 2015 09:12:54 +0000 (11:12 +0200)]
adopt snaptshot implementation for new config format

8 years agouse our own configuration format for containers
Dietmar Maurer [Tue, 4 Aug 2015 09:29:00 +0000 (11:29 +0200)]
use our own configuration format for containers

8 years agobump version to 0.9-7
Dietmar Maurer [Fri, 31 Jul 2015 10:20:31 +0000 (12:20 +0200)]
bump version to 0.9-7

8 years agoFix warning if restore from OpenVZ
Wolfgang Link [Fri, 31 Jul 2015 09:47:40 +0000 (11:47 +0200)]
Fix warning if restore from OpenVZ

8 years agoFix disksize assign size when recover
Wolfgang Link [Fri, 31 Jul 2015 09:47:39 +0000 (11:47 +0200)]
Fix disksize assign size when recover

8 years agoFix assign function to correct module
Wolfgang Link [Fri, 31 Jul 2015 09:47:38 +0000 (11:47 +0200)]
Fix assign function to correct module

8 years agobump version to 0.9-6
Dietmar Maurer [Fri, 31 Jul 2015 09:10:04 +0000 (11:10 +0200)]
bump version to 0.9-6

8 years agoRemove snapshots from LXC config, when you create LXC Backup
Wolfgang Link [Fri, 31 Jul 2015 06:25:43 +0000 (08:25 +0200)]
Remove snapshots from LXC config, when you create LXC Backup

8 years agocleanup recover_config
Dietmar Maurer [Fri, 31 Jul 2015 08:25:46 +0000 (10:25 +0200)]
cleanup recover_config

8 years agocleanup: move OpenVZ to LXC hint into convert_ovz()
Dietmar Maurer [Fri, 31 Jul 2015 07:29:55 +0000 (09:29 +0200)]
cleanup: move OpenVZ to LXC hint into convert_ovz()

8 years agorestore: do not overwrite network device names
Dietmar Maurer [Fri, 31 Jul 2015 07:16:35 +0000 (09:16 +0200)]
restore: do not overwrite network device names

8 years agocleanup: use //= operator
Dietmar Maurer [Fri, 31 Jul 2015 07:09:48 +0000 (09:09 +0200)]
cleanup: use //= operator

8 years agocleanup: remove unused code
Dietmar Maurer [Fri, 31 Jul 2015 07:01:23 +0000 (09:01 +0200)]
cleanup: remove unused code

8 years agocleanup: new helper lxc_config_change_vmid()
Dietmar Maurer [Fri, 31 Jul 2015 07:00:25 +0000 (09:00 +0200)]
cleanup: new helper lxc_config_change_vmid()

8 years agoInsert capability for restore LXC- and OpenVZ- dumpfiles
Wolfgang Link [Thu, 30 Jul 2015 11:45:09 +0000 (13:45 +0200)]
Insert capability for restore LXC- and OpenVZ- dumpfiles

this patch recovers the config form the tarball.
It will nt recover the nework setting if you recover from OVZ

8 years agono need to expect an auto method for ipv4
Wolfgang Bumiller [Thu, 30 Jul 2015 11:06:36 +0000 (13:06 +0200)]
no need to expect an auto method for ipv4