Bonsoir,
J’ai un problème avec l’utilisation de conteneur lxc. L’intallation du conteneur se passe correctement mais le lancement ne se déroule pas bien.
Sur Debian Wheezy.
Noyau:
# uname -r
3.2.0-4-amd64
Version lxc:
# lxc version
lxc version: 0.8.0
Installation:
Utilisation:
# lxc-start -n cloud
INIT: version 2.88 booting
Using makefile-style concurrent boot in runlevel S.
hostname: you must be root to change the host name
mount: permission denied
mount: permission denied
mount: permission denied
Setting the system clock.
hwclock: Cannot access the Hardware Clock via any known method.
hwclock: Use the --debug option to see the details of our search for an access method.
Unable to set System Clock to: Mon Nov 19 22:03:22 UTC 2012 ... (warning).
Activating swap...done.
mount: permission denied
Cleaning up temporary files... /tmp.
mount: permission denied
mount: permission denied
mount: permission denied
Mount point '/dev/console' does not exist. Skipping mount. ... (warning).
Mount point '/dev/ptmx' does not exist. Skipping mount. ... (warning).
Activating lvm and md swap...done.
Checking file systems...fsck from util-linux 2.20.1
done.
Mounting local filesystems...done.
Activating swapfile swap...done.
mount: permission denied
mount: permission denied
mount: permission denied
Setting kernel variables ...done.
Cleaning up temporary files....
Configuring network interfaces...done.
Cleaning up temporary files....
startpar: service(s) returned failure: hostname.sh ... failed!
INIT: Entering runlevel: 2
Using makefile-style concurrent boot in runlevel 2.
Starting OpenBSD Secure Shell server: sshdCould not load host key: /etc/ssh/ssh_host_rsa_key
Could not load host key: /etc/ssh/ssh_host_dsa_key
Could not load host key: /etc/ssh/ssh_host_ecdsa_key
.
INIT: Id "1" respawning too fast: disabled for 5 minutes
INIT: Id "5" respawning too fast: disabled for 5 minutes
INIT: Id "6" respawning too fast: disabled for 5 minutes
INIT: Id "4" respawning too fast: disabled for 5 minutes
INIT: Id "3" respawning too fast: disabled for 5 minutes
INIT: Id "2" respawning too fast: disabled for 5 minutes
INIT: no more processes left in this runlevel
Arrêt forcé:
[code]cat /var/lib/lxc/cloud/config
/var/lib/lxc/cloud/config
Container
lxc.utsname = cloud
lxc.rootfs = /var/lib/lxc/cloud/rootfs
lxc.arch = x86_64
#lxc.console = /var/log/lxc/cloud.console
lxc.tty = 6
lxc.pts = 1024
Capabilities
lxc.cap.drop = mac_admin
lxc.cap.drop = mac_override
lxc.cap.drop = sys_admin
lxc.cap.drop = sys_module
Devices
Allow all devices
#lxc.cgroup.devices.allow = a
Deny all devices
lxc.cgroup.devices.deny = a
Allow to mknod all devices (but not using them)
lxc.cgroup.devices.allow = c : m
lxc.cgroup.devices.allow = b : m
/dev/console
lxc.cgroup.devices.allow = c 5:1 rwm
/dev/fuse
lxc.cgroup.devices.allow = c 10:229 rwm
/dev/null
lxc.cgroup.devices.allow = c 1:3 rwm
/dev/ptmx
lxc.cgroup.devices.allow = c 5:2 rwm
/dev/pts/*
lxc.cgroup.devices.allow = c 136:* rwm
/dev/random
lxc.cgroup.devices.allow = c 1:8 rwm
/dev/rtc
lxc.cgroup.devices.allow = c 254:0 rwm
/dev/tty
lxc.cgroup.devices.allow = c 5:0 rwm
/dev/urandom
lxc.cgroup.devices.allow = c 1:9 rwm
/dev/zero
lxc.cgroup.devices.allow = c 1:5 rwm
Limits
#lxc.cgroup.cpu.shares = 1024
#lxc.cgroup.cpuset.cpus = 0
#lxc.cgroup.memory.limit_in_bytes = 256M
#lxc.cgroup.memory.memsw.limit_in_bytes = 1G
Filesystem
lxc.mount.entry = proc proc proc nodev,noexec,nosuid 0 0
lxc.mount.entry = sysfs sys sysfs defaults,ro 0 0
#lxc.mount.entry = /srv/cloud /var/lib/lxc/cloud/rootfs/srv/cloud none defaults,bind 0 0
Network
lxc.network.type = veth
lxc.network.flags = up
lxc.network.hwaddr = 00:FF:37:65:C4:27
lxc.network.link = br0
lxc.network.name = eth0
[/code]
J’espère ne rien avoir oublier.
Merci d’avance de vos réponses.