Thanks, now we have more info. First I have deleted all containers and images and relaunched wily from todays builds and noticed that I can run an interactive shell in it just fine. It does not exit. Even though the out file shows lots of file system permission errors, from a user perspective the container works just fine.
See attached file out.wily.no-prob Then I've installed upstart inside the container, published the image and launched wily-u-1. An interactive shell in that container exits. See attached file out.wily-u-1.exits . Interestingly, after starting the container and running the shell and waiting until it exits, only the first two line were written. The rest of the file has been written only after I've stopped the container. After having done this when I stop wily-u-1 and start the original wily container again, the shell exits also here. See attached file out.wily.exits . Also here, only the first two lines are written until I stop the container. I am running on btrfs and the subvolumes are generated just fine: root@kimera:~# btrfs sub list -t / | grep lxd 429 337692 257 var/lib/lxd/images/8eca2e28b14279723857f5757df870c09d1eaccbb841965f072b58eab98ab605.btrfs 430 337738 257 var/lib/lxd/containers/wily 431 337727 257 var/lib/lxd/images/9df3fc421acd4da88feb1bcb8f302bb20a894e95b69296f5fc4f49b4a156d7a4.btrfs 432 337734 257 var/lib/lxd/containers/wily-u-1 David -----"lxc-users" <[email protected]> wrote: ----- To: LXC users mailing-list <[email protected]> From: Serge Hallyn Sent by: "lxc-users" Date: 12/21/2015 17:55 Subject: Re: [lxc-users] Serge Hallyn's article "Publishing LXD images" Oh, that's because lxd has started setting lxc.console = 0. Add lxc.console = to the raw.lxc section to undo that. Quoting [email protected] ([email protected]): > And the same is true for the original wily container from the official image: > > david@kimera:~$ lxc stop wily > david@kimera:~$ lxc profile apply wily default,debug_init > Profile default,debug_init applied to wily > david@kimera:~$ lxc start wily > david@kimera:~$ time lxc exec wily /bin/bash > root@wily:~# > real 0m9.781s > user 0m0.008s > sys 0m0.000s > david@kimera:~$ lxc exec wily -- ls -alh /tmp/ > total 0 > drwxrwxrwt 1 root root 0 Dec 10 07:51 . > drwxr-xr-x 1 root root 132 Dec 9 03:54 .. > > I have also checked with a fresh trusty launch with the latest daily builds, > and still, the problem with the shell quitting by itself does not occur in > the trusty container, however, init does not write any debug log either: > > david@kimera:~$ lxc launch images:ubuntu/trusty/amd64 trusty > Creating trusty done. > Starting trusty done. > david@kimera:~$ lxc image list > +----------------+--------------+--------+-----------------------+--------+----------+------------------------------+ > | ALIAS | FINGERPRINT | PUBLIC | DESCRIPTION | ARCH | > SIZE | UPLOAD DATE | > +----------------+--------------+--------+-----------------------+--------+----------+------------------------------+ > | wily-w-upstart | ac1181e4561c | no | | x86_64 | > 130.31MB | Dec 9, 2015 at 4:36pm (CET) | > | | 2ad5a41c86ac | no | Ubuntu wily (amd64) | x86_64 | > 72.76MB | Dec 9, 2015 at 4:33pm (CET) | > | | 7f26ac9d570e | no | Ubuntu trusty (amd64) | x86_64 | > 63.93MB | Dec 10, 2015 at 8:55am (CET) | > +----------------+--------------+--------+-----------------------+--------+----------+------------------------------+ > david@kimera:~$ lxc stop trusty > david@kimera:~$ lxc profile apply trusty default,debug_init > Profile default,debug_init applied to trusty > david@kimera:~$ lxc start trusty > david@kimera:~$ time lxc exec trusty /bin/bash > root@trusty:~# ls -l /tmp/ > total 0 > root@trusty:~# exit > > real 2m15.496s > user 0m0.008s > sys 0m0.008s > david@kimera:~$ lxc exec trusty -- ls -alh /tmp/ > total 0 > drwxrwxrwt 1 root root 0 Dec 9 04:06 . > drwxr-xr-x 1 root root 132 Dec 9 04:05 .. > > > -----"lxc-users" <[email protected]> wrote: ----- > To: LXC users mailing-list <[email protected]> > From: Serge Hallyn > Sent by: "lxc-users" > Date: 12/10/2015 3:52 > Subject: Re: [lxc-users] Serge Hallyn's article "Publishing LXD images" > > Quoting [email protected] ([email protected]): > > Ok, after installing the daily builds, relaunching wily from scratch, > > installing upstart in it, creating a config profile and applying it to the > > container: > > > > david@kimera:~$ lxc profile show debug_init > > name: debug_init > > config: > > raw.lxc: |- > > lxc.console.logfile = /tmp/out > > lxc.init_cmd = /sbin/init --debug --verbose > > devices: {} > > > > david@kimera:~$ lxc profile apply wily-u-1 default,debug_init > > Profile default,debug_init applied to wily-u-1 > > > > No log is being written after running a bash shell and just waiting until > > it quits by itself: > > Wait, did you restart the container after applying the new > profile? Since we're setting debug arguments for init, we > need init to be restart anyway. > > _______________________________________________ > lxc-users mailing list > [email protected] > http://lists.linuxcontainers.org/listinfo/lxc-users > _______________________________________________ > lxc-users mailing list > [email protected] > http://lists.linuxcontainers.org/listinfo/lxc-users _______________________________________________ lxc-users mailing list [email protected] http://lists.linuxcontainers.org/listinfo/lxc-users
_______________________________________________ lxc-users mailing list [email protected] http://lists.linuxcontainers.org/listinfo/lxc-users
