Bug 842855 - umount pylorax errors when running livecd-creator
umount pylorax errors when running livecd-creator
Status: CLOSED NOTABUG
Product: Fedora
Classification: Fedora
Component: lorax (Show other bugs)
17
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Brian Lane
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-07-24 14:11 EDT by Joey Boggs
Modified: 2012-07-24 15:11 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-07-24 15:11:14 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Joey Boggs 2012-07-24 14:11:17 EDT
Description of problem:
When running livecd-creator for ovirt-node some pylorax errors are shown. In %post I'd like to edit the efiboot.img by editing BOOTX64.conf and then rerunning mkefiboot using the right paths but livecd-creator seems to fail on unmount errors from pylorax even without the editing present.

It seems like the error spawns from when it wants to run mkfs.msdos on the loopback device returned from check_output.  The loopback device does return manually when ran with the mounts still existing, not familiar enough to finish tracking this down


------- cut ------
  Installing: ql23xx-firmware              ##################### [471/482] 
  Installing: ql2500-firmware              ##################### [472/482] 
  Installing: ql2200-firmware              ##################### [473/482] 
  Installing: ql2100-firmware              ##################### [474/482] 
  Installing: ql2400-firmware              ##################### [475/482] 
  Installing: rootfiles                    ##################### [476/482] 
  Installing: kernel                       ##################### [477/482] 
  Installing: fuse                         ##################### [478/482] 
  Installing: zfs-fuse                     ##################### [479/482] 
  Installing: libguestfs                   ##################### [480/482] 
  Installing: libguestfs-tools-c           ##################### [481/482] 
  Installing: python-libguestfs            ##################### [482/482] 
  Installing: systemtap-runtime            ##################### [483/482] 
--- cut service enables/disable messages ---

umount: /tmp/lorax.imgutils.ANaFnO: target is busy.
        (In some cases useful info about processes that use
         the device is found by lsof(8) or fuser(1))
WARNING:pylorax.imgutils:failed to unmount /tmp/lorax.imgutils.ANaFnO. retrying (1/3)...
umount: /tmp/lorax.imgutils.Qt3Cee: target is busy.
        (In some cases useful info about processes that use
         the device is found by lsof(8) or fuser(1))
WARNING:pylorax.imgutils:failed to unmount /tmp/lorax.imgutils.Qt3Cee. retrying (1/3)...
Starting Kickstart Post
Creating shadow files
Lock root account
Locking password for user root.
passwd: Success
Saved 1 file(s)
Saved 1 file(s)
Saved 1 file(s)
patching file sosreport.py
patching file plugins/general.py
Listing /usr/lib/python2.7/site-packages/sos ...
Listing /usr/lib/python2.7/site-packages/sos/plugins ...
Compiling /usr/lib/python2.7/site-packages/sos/plugins/general.py ...
Compiling /usr/lib/python2.7/site-packages/sos/sosreport.py ...
Saved 1 file(s)
Saved 1 file(s)
Saved 2 file(s)
Configuring IPTables
Listing /usr/share/virt-manager ...
Listing /usr/share/virt-manager/virtManager ...
Listing /usr/share/virt-manager/virtManagerTui ...
Listing /usr/share/virt-manager/virtManagerTui/importblacklist ...
Configuring SELinux
Compiling targeted ovirt module
/usr/bin/checkmodule:  loading policy configuration from tmp/ovirt.tmp
/usr/bin/checkmodule:  policy configuration loaded
/usr/bin/checkmodule:  writing binary representation (version 15) to tmp/ovirt.mod
Creating targeted ovirt.pp policy package
rm tmp/ovirt.mod tmp/ovirt.mod.fc
Attempting to install module 'ovirt.pp':
Ok: return value of 0.
Committing changes:
Ok: transaction number 0.
Fixing boot menu
/home/jboggs/ovirt-cache/node-creator-x86_64-tmp/imgcreate-uoytCr/iso-uiASyy/EFI/BOOT /home/jboggs/ovirt-cache/node-creator-x86_64-tmp/imgcreate-uoytCr/iso-uiASyy/isolinux/efiboot.img
Traceback (most recent call last):
  File "/usr/sbin/mkefiboot", line 150, in <module>
    mkefiboot(opt.bootdir, opt.outfile, opt.label)
  File "/usr/sbin/mkefiboot", line 32, in mkefiboot
    mkdosimg(None, outfile, label=label, graft={'EFI/BOOT':bootdir})
  File "/usr/lib/python2.7/site-packages/pylorax/imgutils.py", line 329, in mkdosimg
    mkfsargs=["-n", label], graft=graft)
  File "/usr/lib/python2.7/site-packages/pylorax/imgutils.py", line 313, in mkfsimage
    with LoopDev(outfile, size) as loopdev:
  File "/usr/lib/python2.7/site-packages/pylorax/imgutils.py", line 216, in __enter__
    self.loopdev = loop_attach(self.filename)
  File "/usr/lib/python2.7/site-packages/pylorax/imgutils.py", line 73, in loop_attach
    dev = check_output(["losetup", "--find", "--show", outfile], stderr=PIPE)
  File "/usr/lib64/python2.7/subprocess.py", line 537, in check_output
    process = Popen(stdout=PIPE, *popenargs, **kwargs)
  File "/usr/lib64/python2.7/subprocess.py", line 679, in __init__
    errread, errwrite)
  File "/usr/lib64/python2.7/subprocess.py", line 1249, in _execute_child
    raise child_exception
OSError: [Errno 2] No such file or directory
ignoring %post failure (code 1)
Comment 1 Brian Lane 2012-07-24 15:11:14 EDT
I think you mean livemedia-creator :)

If you want to change the efiboot.img you cannot do that from %post -- the kickstart is running inside the install. The images are created outside the install, by the lorax templates. To change those you will need to copy them to a new location, edit them accordingly and then use --lorax-templates= to pass the location of them.

Note that the templates are not shell scripts. They are Mako templates with special lorax commands added to them. Look at the existing ones for examples, but don't expect to deviate from their syntax. Also be careful with paths. The templates are not run in a chroot so you *can* overwrite things on the host if you put in absolute paths.

(yes, this will eventually be better documented).

Note You need to log in before you can comment on or make changes to this bug.