Bug 723490 - have to manually delete directories when lorax aborts and needs restart
have to manually delete directories when lorax aborts and needs restart
Product: Fedora
Classification: Fedora
Component: lorax (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Martin Gracik
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2011-07-20 06:59 EDT by Karsten Hopp
Modified: 2013-07-04 08:57 EDT (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2011-07-20 07:31:32 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Karsten Hopp 2011-07-20 06:59:35 EDT
Description of problem:
lorax aborted with the following error:
  File "/usr/lib/python2.7/site-packages/pylorax/yumhelper.py", line 61, in install
    logger.error(msg.format(pattern, e))
UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position 38: ordinal not in range(128)

after setting LANG=C and starting pungi with --force, lorax aborts with a different error:
Traceback (most recent call last):
  File "/usr/bin/pungi", line 218, in <module>
  File "/usr/bin/pungi", line 122, in main
  File "/usr/lib/python2.7/site-packages/pypungi/__init__.py", line 845, in doBuildinstall
    workdir=workdir, outputdir=outputdir)
  File "/usr/lib/python2.7/site-packages/pylorax/__init__.py", line 192, in run
    self.yum = yumhelper.LoraxYumHelper(ybo)
  File "/usr/lib/python2.7/site-packages/pylorax/yumhelper.py", line 47, in __init__
  File "/usr/lib64/python2.7/os.py", line 157, in makedirs
    mkdir(name, mode)
OSError: [Errno 17] File exists: '/tmp/kh/work/ppc64/yumroot/installroot'

several options:
- lorax removes that directory on startup
- protect os.makedirs in lorax/LoraxYumHelper by 'try:'
- pungi passes that --force option to lorax and lorax should then do the right thing

Version-Release number of selected component (if applicable):

Steps to Reproduce:
1. export LANG=de_DE.UTF-8
2. run pungi -B
3. watch pungi abort and re-run it with pungi -B --force
Comment 1 Martin Gracik 2011-07-20 07:31:32 EDT
The installroot directory is not created anymore. This was changed in the new version.

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