Red Hat Bugzilla – Bug 741722
better chroot support
Last modified: 2013-07-04 08:59:10 EDT
I ran lorax (as part of pungi) in mock chroot.
It failed with:
Traceback (most recent call last):
File "/usr/bin/pungi", line 222, in <module>
File "/usr/bin/pungi", line 124, in main
File "/usr/lib/python2.7/site-packages/pypungi/__init__.py", line 845, in doBuildinstall
File "/usr/lib/python2.7/site-packages/pylorax/__init__.py", line 438, in run
File "/usr/lib/python2.7/site-packages/pylorax/yumhelper.py", line 120, in remove
File "/usr/lib64/python2.7/shutil.py", line 244, in rmtree
rmtree(fullname, ignore_errors, onerror)
File "/usr/lib64/python2.7/shutil.py", line 253, in rmtree
onerror(os.rmdir, path, sys.exc_info())
File "/usr/lib64/python2.7/shutil.py", line 251, in rmtree
OSError: [Errno 39] Directory not empty: '.../work/x86_64/yumroot//var/lib/yum/history'
This is probably due to using a NFS storage.
Lorax also needs /proc mounted (since /etc/mtab is a symlink to /proc/mounts).
Touching /proc/mounts is not enough, because /proc is also needed when creating images (efiboot, I think):
/proc/devices: fopen failed: No such file or directory
Failure to communicate with kernel device-mapper driver.
Check that device-mapper is available in the kernel.
unable to create efidisk image
if /proc is not mounted, it ends with various crashes and lorax should check whether /proc is mounted as soon as possible.
$ vim /usr/lib/python2.7/site-packages/pylorax/yumhelper.py +120
add: ignore_errors=True to rmtree()
(that's what mgracik proposed, seems to be working)
2) check if /proc is mounted when starting lorax
lorax-16.4.5-1.fc16 has been submitted as an update for Fedora 16.
* should fix your issue,
* was pushed to the Fedora 16 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing lorax-16.4.5-1.fc16'
as soon as you are able to.
Please go to the following url:
then log in and leave karma (feedback).
lorax-16.4.6-1.fc16 has been submitted as an update for Fedora 16.
lorax-16.4.6-1.fc16 has been pushed to the Fedora 16 stable repository. If problems still persist, please make note of it in this bug report.