Bug 1107667

Summary: [ostree] OSError: [Errno 17] File exists: '/mnt/sysimage/ostree/deploy/fedora-atomic/deploy/60506ba30bdd1a5070dda106492f4bacd2cf947026f615343e78437608947c71.0/home'
Product: [Fedora] Fedora Reporter: Radek Vykydal <rvykydal>
Component: anacondaAssignee: Radek Vykydal <rvykydal>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: anaconda-maint-list, clumens, g.kaviyarasu, jonathan, ljozsa, vanmeeuwen+fedora, walters
Target Milestone: ---   
Target Release: ---   
Hardware: x86_64   
OS: Unspecified   
Whiteboard: abrt_hash:4bd9a0488dca783c9df08eb65ce34aab342d471b256ad93d88b609f3d7756052
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-10-03 14:46:33 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1108568    
Bug Blocks: 1147383    
Attachments:
Description Flags
File: anaconda-tb
none
File: anaconda.log
none
File: environ
none
File: ks.cfg
none
File: lsblk_output
none
File: nmcli_dev_list
none
File: os_info
none
File: program.log
none
File: storage.log
none
File: syslog
none
File: ifcfg.log none

Description Radek Vykydal 2014-06-10 12:36:02 UTC
Description of problem:
Installing ostree payload from local compose of fedora-atomic base

Version-Release number of selected component:
anaconda-21.39-1

The following was filed automatically by anaconda:
anaconda 21.39-1 exception report
Traceback (most recent call first):
  File "/usr/lib64/python2.7/os.py", line 157, in makedirs
    mkdir(name, mode)
  File "/usr/lib/python2.7/site-packages/blivet/util.py", line 281, in makedirs
    os.makedirs(path, 0755)
  File "/usr/lib/python2.7/site-packages/blivet/formats/fs.py", line 568, in mount
    util.makedirs(chrootedMountpoint)
  File "/usr/lib/python2.7/site-packages/blivet/formats/fs.py", line 832, in setup
    return self.mount(**kwargs)
  File "/usr/lib/python2.7/site-packages/blivet/__init__.py", line 2740, in mountFilesystems
    chroot=rootPath)
  File "/usr/lib/python2.7/site-packages/blivet/__init__.py", line 1777, in mountFilesystems
    readOnly=readOnly, skipRoot=skipRoot)
  File "/tmp/updates/pyanaconda/install.py", line 227, in doInstall
    storage.mountFilesystems(skipRoot=True)
  File "/usr/lib64/python2.7/threading.py", line 766, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/tmp/updates/pyanaconda/threads.py", line 227, in run
    threading.Thread.run(self, *args, **kwargs)
OSError: [Errno 17] File exists: '/mnt/sysimage/ostree/deploy/fedora-atomic/deploy/60506ba30bdd1a5070dda106492f4bacd2cf947026f615343e78437608947c71.0/home'

Additional info:
cmdline:        /usr/bin/python  /sbin/anaconda
cmdline_file:   initrd=test/rv/raw20140604/initrd.img root=live:http://10.34.39.2/trees/rv/raw20140604/squashfs.img lang=en_US.UTF-8 keymap=us inst.ks=http://10.34.39.2/ks/rv/ks.ostree.cfg updates=http://10.34.39.2/ks/rv/updates.ostree-rootmnt.img BOOT_IMAGE=test/rv/raw20140604/vmlinuz 
executable:     /sbin/anaconda
hashmarkername: anaconda
kernel:         3.15.0-0.rc8.git1.2.fc21.x86_64
product:        Fedora
release:        Cannot get release name.
type:           anaconda
version:        rawhide

Comment 1 Radek Vykydal 2014-06-10 12:36:06 UTC
Created attachment 907202 [details]
File: anaconda-tb

Comment 2 Radek Vykydal 2014-06-10 12:36:09 UTC
Created attachment 907203 [details]
File: anaconda.log

Comment 3 Radek Vykydal 2014-06-10 12:36:11 UTC
Created attachment 907204 [details]
File: environ

Comment 4 Radek Vykydal 2014-06-10 12:36:13 UTC
Created attachment 907205 [details]
File: ks.cfg

Comment 5 Radek Vykydal 2014-06-10 12:36:15 UTC
Created attachment 907206 [details]
File: lsblk_output

Comment 6 Radek Vykydal 2014-06-10 12:36:18 UTC
Created attachment 907207 [details]
File: nmcli_dev_list

Comment 7 Radek Vykydal 2014-06-10 12:36:20 UTC
Created attachment 907208 [details]
File: os_info

Comment 8 Radek Vykydal 2014-06-10 12:36:22 UTC
Created attachment 907209 [details]
File: program.log

Comment 9 Radek Vykydal 2014-06-10 12:36:25 UTC
Created attachment 907210 [details]
File: storage.log

Comment 10 Radek Vykydal 2014-06-10 12:36:27 UTC
Created attachment 907211 [details]
File: syslog

Comment 11 Radek Vykydal 2014-06-10 12:36:29 UTC
Created attachment 907212 [details]
File: ifcfg.log

Comment 12 Colin Walters 2014-06-10 14:18:48 UTC
This looks like the class of problem I was trying to fix with https://git.fedorahosted.org/cgit/anaconda.git/commit/?id=a5f48d26312bfde6800d8bb608c5f08186c8eed1

I think Chris may have found systemd-tmpfiles wasn't creating the dirs?

Comment 13 Chris Lumens 2014-06-10 14:19:43 UTC
Yeah, that's what it looked like to me.

Comment 14 Radek Vykydal 2014-06-11 12:16:40 UTC
I was able to fix the issue by adding

/usr/lib/tmpfiles.d/rpm-ostree-autovar.conf
/usr/lib/tmpfiles.d/tmpfiles-ostree-integration.conf

to installation image.

Comment 15 Colin Walters 2014-06-11 13:02:09 UTC
Hmm, to the installation image?  I think we should have systemd read those from the *target*.  Otherwise they're going to get out of sync.

Some sort of regression in systemd-tmpfiles with respect to handling of --root?

Comment 16 Radek Vykydal 2014-06-11 13:17:49 UTC
I was in doubts if the --root option really concerns also location of config files because it dindn't work this way (although man page says so) but yes it seems systemd-tmpfiles is probably broken.

As for getting out of sync, yeah I should have considered that with ostree we don't "install the package versions" (ie the ostree image is not composed of the version of packages) the installation image is composed of.

Comment 17 Chris Lumens 2014-10-02 19:28:21 UTC
Has anyone actually seen this problem recently?  I haven't, and I've got nightly ostree+anaconda tests going on here.

Comment 18 Radek Vykydal 2014-10-03 07:03:36 UTC
I think we can close this one.