Bugzilla will be upgraded to version 5.0 on a still to be determined date in the near future. The original upgrade date has been delayed.
Bug 242162 - os.symlink('../yum.conf', os.path.join(yumdir, 'yum.conf')) fails : File exists
os.symlink('../yum.conf', os.path.join(yumdir, 'yum.conf')) fails : File exists
Product: Fedora Hosted Projects
Classification: Retired
Component: mock (Show other bugs)
All Linux
low Severity high
: ---
: ---
Assigned To: Clark Williams
: 242167 (view as bug list)
Depends On:
  Show dependency treegraph
Reported: 2007-06-01 17:40 EDT by Philippe Valembois
Modified: 2013-01-09 23:19 EST (History)
5 users (show)

See Also:
Fixed In Version: 0.7.1-1.fc7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2007-06-21 16:04: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)
mock-autocache.patch (763 bytes, patch)
2007-06-05 06:47 EDT, Mark McLoughlin
no flags Details | Diff

  None (edit)
Description Philippe Valembois 2007-06-01 17:40:22 EDT
Description of problem:
When using cache, preping install fails because of yum.conf symlink already
present in cache tree

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

How reproducible:

Steps to Reproduce:
1. Create a mock cache like said in MockTricks
2. Try to build a package
Actual results:
Traceback (most recent call last):
  File "/usr/bin/mock", line 1046, in <module>
  File "/usr/bin/mock", line 1043, in main
    do_rebuild(config_opts, srpms)
  File "/usr/bin/mock", line 910, in do_rebuild
  File "/usr/bin/mock", line 254, in prep
  File "/usr/bin/mock", line 659, in _prep_install
    os.symlink('../yum.conf', os.path.join(yumdir, 'yum.conf'))
OSError: [Errno 17] File exists

Expected results:
Building of the package

Additional info:
A if os.path.exists should be done over the symlink path like it is done for
regular file yum.conf and devices above
Current workaround is to edit the cache to remove the symlink each time the
cache is generated.
Comment 1 Julian Sikorski 2007-06-02 20:38:13 EDT
*** Bug 242167 has been marked as a duplicate of this bug. ***
Comment 2 Mark McLoughlin 2007-06-05 06:47:43 EDT
Created attachment 156200 [details]

Simple patch to fix this
Comment 3 Wart 2007-06-08 11:21:38 EDT
This patch fixes the problem for me.
Comment 4 Fedora Update System 2007-06-14 17:12:29 EDT
mock-0.7.1-1.fc7 has been pushed to the Fedora 7 testing repository.  If problems still persist, please make note of it in this bug report.
Comment 5 Philippe Valembois 2007-06-17 08:33:46 EDT
Works for me but added another trouble related to koji
I fill a separate bug
Comment 6 Fedora Update System 2007-06-21 16:04:07 EDT
mock-0.7.1-1.fc7 has been pushed to the Fedora 7 stable repository.  If problems still persist, please make note of it in this bug report.

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