[lxc-devel] LXC_DIRECTORY remounted read-only
Harald Dunkel
harri at afaics.de
Sat Aug 31 06:29:15 UTC 2013
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Hi Serge,
On 08/26/13 13:41, Serge Hallyn wrote:
>
> Lxc should be creating a $lxcpath/$lxcname/rootfs.hold and keeping that open for write, which should prevent the remount -o ro. Does that file exist in your case? Which filesystem is mounted on /export/lxc?
>
Filesystem is ext4.
It seems that this problem comes up, if I run "halt" within
the container. Using lxc-stop on the server I couldn't
reproduce it by now. Sample session:
{root at cecil:~ 501} lxc-create -t debian -n no2
debootstrap is /usr/sbin/debootstrap
Checking cache download in /var/cache/lxc/debian/rootfs-squeeze-amd64 ...
Copying rootfs to /usr/lib/x86_64-linux-gnu/lxc...Generating locales (this might take a while)...
Generation complete.
update-rc.d: using dependency based boot sequencing
update-rc.d: using dependency based boot sequencing
update-rc.d: using dependency based boot sequencing
update-rc.d: using dependency based boot sequencing
Root password is 'root', please change !
{root at cecil:~ 501} mount | grep /export
/dev/md0p4 on /export type ext4 (rw,noatime,stripe=32,data=ordered)
{root at cecil:~ 501} lxc-start -n no2
INIT: version 2.88 booting
Using makefile-style concurrent boot in runlevel S.
:
:
Debian GNU/Linux 6.0 no2 console
no2 login: root
Password:
Linux no2 3.10.10 #1 SMP PREEMPT Fri Aug 30 06:47:21 CEST 2013 x86_64
root at no2:~# passwd
Enter new UNIX password:
Retype new UNIX password:
passwd: password updated successfully
root at no2:~# halt
Broadcast message from root at no2 (console) (Sat Aug 31 06:19:47 2013):
The system is going down for system halt NOW!
INIT: Switching to runlevel: 0
INIT: Sending processes the TERM signal
Using makefile-style concurrent boot in runlevel 0.
Asking all remaining processes to terminate...done.
All processes ended within 2 seconds....done.
Deconfiguring network interfaces...ifdown: failed to open statefile /etc/network/run/ifstate: Read-only file system
failed.
Cleaning up ifupdown...rm: cannot remove `/etc/network/run/ifstate': Read-only file system
Will now halt.
{root at cecil:~ 501} mount | grep /export
/dev/md0p4 on /export type ext4 (ro,noatime,stripe=32,data=ordered)
{root at cecil:~ 501} ls -al /export/lxc/no2
total 16
drwxr-xr-x 3 root root 4096 Aug 31 08:19 .
drwxr-xr-x 8 root root 4096 Aug 31 08:18 ..
- -rw-r--r-- 1 root root 1001 Aug 31 08:18 config
drwxr-xr-x 20 root root 4096 Aug 31 08:19 rootfs
- -rw------- 1 root root 0 Aug 31 08:19 rootfs.hold
AFAICS the file system is remounted read-only, while the container
is still active.
Hope this helps.
Harri
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.14 (GNU/Linux)
iQEcBAEBCAAGBQJSIY07AAoJEAqeKp5m04HLOZkH/AqZGf4mUHB/GbLfg7zDYfRK
XeJbFbBQOFzA+/YiEtrBJlD/Uh6M2QS44C8QiKfT76PHcf3GZku8EyybUaR1hqRM
Qho5ADmW/TIEMP/unV6kI9WZ7srE6kj7OSWUEVVpwdH0TQpvcnYwNR0bmhL7H4O6
cmDcuJc5dJGDPTcbejcW4/tt22P4TWkn+6rOfAHfgQQtUWCJlZy2g+IxG0A0E/Ix
yhRotBK/OR1m+wlVfNtDgcO2TdiavS+NSOAuxqiUjOuKg7chs3TQjtJ5/2rWWAVt
cL8hDZ6cruLgEqPtXJn4Z0wfA6nATy9MncNEcB977KG9wjr4XsdAaC9BldueM28=
=2iPO
-----END PGP SIGNATURE-----
More information about the lxc-devel
mailing list