Skip to content
This repository has been archived by the owner on Oct 10, 2020. It is now read-only.

'atomic images list' returns "No such file or directory: '/var/lib/containers/atomic/.storage'" #1138

Closed
miabbott opened this issue Nov 29, 2017 · 6 comments

Comments

@miabbott
Copy link
Contributor

While testing an RPM that @baude built for me to test #1137, I noticed the following error on F27 Atomic Host after using rpm-ostree ex override replace to install the atomic and atomic-registries RPMs.

[root@micah-f27ah-vm1129b ~]# rpm-ostree status
State: idle                                                                                              
Deployments:
● fedora-atomic:fedora/27/x86_64/atomic-host        
                   Version: 27.1 (2017-11-10 11:54:36)
                BaseCommit: d428d3ad8ecf44e53d138042bad56a10308883a0c5d64b9c51eff27fdc9da82c
              GPGSignature: Valid signature by 860E19B0AFA800A1751881A6F55E7430F5282EE4
      ReplacedBasePackages: atomic-registries 1.19.1-1.fc27 -> 1.20.1-5.fc27, atomic 1.19.1-1.fc27 -> 1.20.1-5.fc27

  fedora-atomic:fedora/27/x86_64/atomic-host
                   Version: 27.1 (2017-11-10 11:54:36)
                    Commit: d428d3ad8ecf44e53d138042bad56a10308883a0c5d64b9c51eff27fdc9da82c
              GPGSignature: Valid signature by 860E19B0AFA800A1751881A6F55E7430F5282EE4
[root@micah-f27ah-vm1129b ~]# rpm -q atomic
atomic-1.20.1-5.fc27.x86_64
[root@micah-f27ah-vm1129b ~]# docker pull busybox
Using default tag: latest
Trying to pull repository docker.io/library/busybox ...
sha256:bbc3a03235220b170ba48a157dd097dd1379299370e1ed99ce976df0355d24f0: Pulling from docker.io/library/busybox
0ffadd58f2a6: Pull complete
Digest: sha256:bbc3a03235220b170ba48a157dd097dd1379299370e1ed99ce976df0355d24f0
Status: Downloaded newer image for docker.io/busybox:latest
[root@micah-f27ah-vm1129b ~]# docker images
REPOSITORY          TAG                 IMAGE ID            CREATED             SIZE
docker.io/busybox   latest              6ad733544a63        3 weeks ago         1.13 MB
[root@micah-f27ah-vm1129b ~]# atomic --debug images list
Namespace(_class=<class 'Atomic.images.Images'>, all=False, assumeyes=False, debug=True, filter=None, func='display_all_image_info', heading=True, ignore=False, json=False, profile=False, quiet=False, truncate=T
rue)
Backends(docker: Active, ostree: Active, )

[Errno 2] No such file or directory: '/var/lib/containers/atomic/.storage'
Traceback (most recent call last):
  File "/usr/bin/atomic", line 185, in <module>
    sys.exit(_func())
  File "/usr/lib/python3.6/site-packages/Atomic/images.py", line 159, in display_all_image_info
    _images = self._get_images()
  File "/usr/lib/python3.6/site-packages/Atomic/images.py", line 217, in _get_images
    _images = self.be_utils.get_images(get_all=self.args.all)
  File "/usr/lib/python3.6/site-packages/Atomic/backendutils.py", line 149, in get_images
    img_objs += be.get_images(get_all=get_all)
  File "/usr/lib/python3.6/site-packages/Atomic/backends/_ostree.py", line 107, in get_images
    return [self._make_image(x['Id'], x) for x in self.syscontainers.get_system_images(get_all=get_all)]
  File "/usr/lib/python3.6/site-packages/Atomic/syscontainers.py", line 1499, in get_system_images
    repo = self._get_ostree_repo()
  File "/usr/lib/python3.6/site-packages/Atomic/syscontainers.py", line 1071, in _get_ostree_repo
    repo_location = self.get_ostree_repo_location()
  File "/usr/lib/python3.6/site-packages/Atomic/syscontainers.py", line 1037, in get_ostree_repo_location
    self._repo_location = self._find_ostree_repo_location()
  File "/usr/lib/python3.6/site-packages/Atomic/syscontainers.py", line 1063, in _find_ostree_repo_location
    if SystemContainers._is_repo_on_the_same_filesystem("/ostree/repo", storage_path):
  File "/usr/lib/python3.6/site-packages/Atomic/syscontainers.py", line 691, in _is_repo_on_the_same_filesystem
    destdir_stat = os.stat(destdir)
FileNotFoundError: [Errno 2] No such file or directory: '/var/lib/containers/atomic/.storage'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/bin/atomic", line 198, in <module>
    sys.exit(1)
SystemExit: 1
@miabbott
Copy link
Contributor Author

Here's the koji task that produced the RPMs

https://koji.fedoraproject.org/koji/taskinfo?taskID=23454142

@miabbott
Copy link
Contributor Author

atomic-1.20.1-3.fc27.x86_64 doesn't appear to show the same issue

# rpm-ostree status     
State: idle                                         
Deployments:                                        
● fedora-atomic:fedora/27/x86_64/testing/atomic-host
                   Version: 27.22 (2017-11-29 01:21:49)                                                  
                    Commit: 4f332b68becc0aaaa9720870b53f818e29742d4400c6f37c2b06a11efcfa99ec             
              GPGSignature: Valid signature by 860E19B0AFA800A1751881A6F55E7430F5282EE4                  

  fedora-atomic:fedora/27/x86_64/atomic-host        
                   Version: 27.1 (2017-11-10 11:54:36)                                                   
                    Commit: d428d3ad8ecf44e53d138042bad56a10308883a0c5d64b9c51eff27fdc9da82c             
              GPGSignature: Valid signature by 860E19B0AFA800A1751881A6F55E7430F5282EE4                  
[root@micah-f27ah-vm1129c ~]# rpm -q atomic         
atomic-1.20.1-3.fc27.x86_64                         
[root@micah-f27ah-vm1129c ~]# docker pull busybox   
Using default tag: latest                           
Trying to pull repository docker.io/library/busybox ...                                                  
sha256:bbc3a03235220b170ba48a157dd097dd1379299370e1ed99ce976df0355d24f0: Pulling from docker.io/library/busybox                                                                                                    
0ffadd58f2a6: Pull complete                         
Digest: sha256:bbc3a03235220b170ba48a157dd097dd1379299370e1ed99ce976df0355d24f0                          
Status: Downloaded newer image for docker.io/busybox:latest                                              
[root@micah-f27ah-vm1129c ~]# docker images         
REPOSITORY          TAG                 IMAGE ID            CREATED             SIZE                     
docker.io/busybox   latest              6ad733544a63        3 weeks ago         1.13 MB                  
[root@micah-f27ah-vm1129c ~]# atomic --debug images list                                                 
Namespace(_class=<class 'Atomic.images.Images'>, all=False, assumeyes=False, debug=True, filter=None, func='display_all_image_info', heading=True, ignore=False, json=False, profile=False, quiet=False, truncate=True)
Backends(docker: Active, ostree: Active, )          

   REPOSITORY          TAG      IMAGE ID       CREATED            VIRTUAL SIZE   TYPE                    
   docker.io/busybox   latest   6ad733544a63   2017-11-03 22:39   1.13 MB        docker                  

@miabbott
Copy link
Contributor Author

@giuseppe can you have a look? @baude says it is all your fault 😉

@miabbott
Copy link
Contributor Author

Not 100% certain but it d494e18 looks like it could be a culprit

@giuseppe
Copy link
Collaborator

yes, I confirm it is all my fault :-) Going to take a look

giuseppe added a commit to giuseppe/atomic that referenced this issue Nov 29, 2017
@ashcrow
Copy link
Contributor

ashcrow commented Nov 29, 2017

@giuseppe I have a fix incomming.

ashcrow added a commit to ashcrow/atomic that referenced this issue Nov 29, 2017
eyusupov pushed a commit to eyusupov/atomic that referenced this issue Mar 10, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants