Hide Forgot
Description Could not create linux container with system OS. Version: # rpm -qa libvirt python-virtinst python-virtinst-0.600.0-18.el6.noarch libvirt-0.10.2-26.el6.x86_64 How reproducible: 100% Steps to Reproduce: 1.set host selinux to disable in /etc/selinux/config and reboot the host. 2. yum install febootstrap # rpm -qa febootstrap febootstrap-3.21-4.el6.x86_64 3.febootstrap fedora-13 rootfs.fedora 4. after finish install,add a new user #chroot /rootfs.fedora #useradd redhat #passwd redhat 5. #virt-install --connect lxc:/// -n demo -r 1024 --nodisk --container --filesystem /rootfs.fedora,/ --debug Thu, 26 Sep 2013 01:29:06 ERROR internal error Child process (PATH=/sbin:/usr/sbin:/bin:/usr/bin LIBVIRT_DEBUG=3 LIBVIRT_LOG_OUTPUTS=3:stderr /usr/libexec/libvirt_lxc --name demo --console 22 --security=none --handshake 26 --background --veth veth1) unexpected fatal signal 11 Thu, 26 Sep 2013 01:29:06 DEBUG Traceback (most recent call last): File "/usr/sbin/virt-install", line 629, in start_install noboot=options.noreboot) File "/usr/lib/python2.6/site-packages/virtinst/Guest.py", line 1223, in start_install noboot) File "/usr/lib/python2.6/site-packages/virtinst/Guest.py", line 1291, in _create_guest dom = self.conn.createLinux(start_xml or final_xml, 0) File "/usr/lib64/python2.6/site-packages/libvirt.py", line 2642, in createLinux if ret is None:raise libvirtError('virDomainCreateLinux() failed', conn=self) libvirtError: internal error Child process (PATH=/sbin:/usr/sbin:/bin:/usr/bin LIBVIRT_DEBUG=3 LIBVIRT_LOG_OUTPUTS=3:stderr /usr/libexec/libvirt_lxc --name demo --console 22 --security=none --handshake 26 --background --veth veth1) unexpected fatal signal 11 Thu, 26 Sep 2013 01:29:06 DEBUG Domain installation does not appear to have been successful. If it was, you can restart your domain by running: virsh --connect lxc:/// start demo otherwise, please restart your installation. Domain installation does not appear to have been successful. Actual results: Could not create linux container with system OS. Libvirt log: 2013-09-26 06:31:42.779+0000: 20554: error : virDomainObjParseNode:10526 : XML error: unexpected root element <domain>, expecting <domstatus> 2013-09-26 06:31:42.780+0000: 20554: error : virDomainObjParseNode:10526 : XML error: unexpected root element <domain>, expecting <domstatus> 2013-09-26 06:31:46.312+0000: 20547: error : virCommandWait:2319 : internal error Child process (PATH=/sbin:/usr/sbin:/bin:/usr/bin LIBVIRT_DEBUG=3 LIBVIRT_LOG_OUTPUTS=3:stderr /usr/libexec/libvirt_lxc --name demo --console 23 --security=none --handshake 26 --background --veth veth1) unexpected fatal signal 11 Expected results: Linux container with system OS is created.
Although the LXC is tech preview in rhel6.y, we should make sure the basic application and OS container are available for users in rhel6.y. In addition, whether we will provide virt-bootstrap tool to install OS container instead of febootstrap in rhel6.5?
(In reply to Alex Jia from comment #1) > Although the LXC is tech preview in rhel6.y, we should make sure the basic > application and OS container are available for users in rhel6.y. > > In addition, whether we will provide virt-bootstrap tool to install OS > container instead of febootstrap in rhel6.5? Full OS containers based on RHEL-6 are explicitly unsupported in RHEL-6. With the sysvinit style init scripts we have in RHEL-6, it is not practical to make the changes required to get standard RHEL6 packages booting in a container. Any full OS container must be systemd based. Thus you can run F19 on a RHEL-6 host, but you'll never be able to do RHEL-6 on any host. In addition do not use febootstrap for creating the install. Use yum directly # cat > yum-fedora.conf [main] cachedir=/var/cache/yum/$basearch/$releasever keepcache=0 debuglevel=2 logfile=/var/log/yum.log exactarch=1 obsoletes=1 gpgcheck=1 plugins=1 installonly_limit=3 [fedora] name=Fedora $releasever - $basearch failovermethod=priority #baseurl=http://download.fedoraproject.org/pub/fedora/linux/releases/$releasever/Everything/$basearch/os/ mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=fedora-$releasever&arch=$basearch enabled=1 metadata_expire=7d gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-$releasever-$basearch [updates] name=Fedora $releasever - $basearch - Updates failovermethod=priority #baseurl=http://download.fedoraproject.org/pub/fedora/linux/updates/$releasever/$basearch/ mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=updates-released-f$releasever&arch=$basearch enabled=1 gpgcheck=1 # yum -y --nogpg --releasever=19 --config=/root/yum-fedora.conf --installroot=/var/lib/libvirt/filesystems/f19x86_64 --disablerepo='*' --enablerepo=fedora install systemd passwd yum redhat-release vim-minimal openssh-server procps # virt-install --connect lxc:/// --name f19x86_64 --ram 800 --filesystem /var/lib/libvirt/filesystems/f19x86_64,/ # echo "pts/0" >> /var/lib/libvirt/filesystems/f19x86_64/etc/securetty # vi /var/lib/libvirt/filesystems/f19x86_64/etc/pam.d/login ...comment out the loginuid line... # chroot /var/lib/libvirt/filesystems/f19x86_64 /bin/passwd root
Opps, the 'virt-install' command above, should have been the very last thing in that command list.
Please let me know if you wish to retest with the steps from comment #2, otherwise I'll close this NOTABUG.
(In reply to Daniel Berrange from comment #4) > Please let me know if you wish to retest with the steps from comment #2, > otherwise I'll close this NOTABUG. Hi Daniel, I've tried the steps you mentioned to install a fedora based container and i meet the following issue. 1. cat /etc/yum.repos.d/yum-fedora.conf [main] cachedir=/var/cache/yum/$basearch/$releasever keepcache=0 debuglevel=2 logfile=/var/log/yum.log exactarch=1 obsoletes=1 gpgcheck=1 plugins=1 installonly_limit=3 [fedora] name=Fedora $releasever - $basearch failovermethod=priority #baseurl=http://download.fedoraproject.org/pub/fedora/linux/releases/$releasever/Everything/$basearch/os/ mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=fedora-$releasever&arch=$basearch enabled=1 metadata_expire=7d gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-fedora-$releasever-$basearch [updates] name=Fedora $releasever - $basearch - Updates failovermethod=priority #baseurl=http://download.fedoraproject.org/pub/fedora/linux/updates/$releasever/$basearch/ mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=updates-released-f$releasever&arch=$basearch enabled=1 gpgcheck=1 2. yum -y --nogpg --releasever=19 --config=/etc/yum.repos.d/yum-fedora.conf --installroot=/var/lib/libvirt/filesystems/f19x86_64 --disablerepo='*' --enablerepo=fedora install systemd passwd yum redhat-release vim-minimal openssh-server procps 3. echo "pts/0" >> /var/lib/libvirt/filesystems/f19x86_64/etc/securetty 4. vi /var/lib/libvirt/filesystems/f19x86_64/etc/pam.d/login I can't find the loginuid line. Could you please add the line here. 5. chroot /var/lib/libvirt/filesystems/f19x86_64 /bin/passwd root 6. virt-install --connect lxc:/// --name f19x86_64 --ram 800 --filesystem /var/lib/libvirt/filesystems/f19x86_64,/ Starting install... ERROR internal error guest failed to start: internal error Child process (ip link set veth1 netns 25121) unexpected exit status 2: RTNETLINK answers: No such process Can't install fedora based container. And I'd like confirm if fedora based container are fully supported on RHEL6.5 host. Thank you very much.
(In reply to hyao from comment #5) > 5. chroot /var/lib/libvirt/filesystems/f19x86_64 /bin/passwd root > 6. virt-install --connect lxc:/// --name f19x86_64 --ram 800 > --filesystem /var/lib/libvirt/filesystems/f19x86_64,/ > > Starting install... > ERROR internal error guest failed to start: > internal error Child process (ip link set veth1 netns 25121) unexpected exit > status 2: RTNETLINK answers: No such process > > Can't install fedora based container. > Refer to bug 984597,would you pls try kernel-2.6.32-421.el6?
I've retested the with latest tree and kernel-2.6.32-422.el6. I could install a fedora based container and login with root and passwd. So close the bug as not a bug. Thanks Daniel and tzheng. 1. vim /etc/yum.repos.d/yum-fedora.conf 2. yum -y --nogpg --releasever=19 --config=/etc/yum.repos.d/yum-fedora.conf --installroot=/var/lib/libvirt/filesystems/f19x86_64 --disablerepo='*' --enablerepo=fedora install systemd passwd yum redhat-release vim-minimal openssh-server procps 3. echo "pts/0" >> /var/lib/libvirt/filesystems/f19x86_64/etc/securetty 4. vi /var/lib/libvirt/filesystems/f19x86_64/etc/pam.d/login commnent out the following lines #session required pam_selinux.so close #session required pam_loginuid.so 5. chroot /var/lib/libvirt/filesystems/f19x86_64 /bin/passwd root 6. # virt-install --connect lxc:/// --name f19x86_64 --ram 800 --filesystem /var/lib/libvirt/filesystems/f19x86_64,/ Starting install... Creating domain...