How to move podman images from one location to another ?

Updated -

Environment

  • Red Hat Enterprise Linux 7
  • Red Hat Enterprise Linux 8
  • Red Hat Enterprise Linux 9
  • podman

How to migrate the images from one path to another?

  • podman images are store in directory specified by graphRoot and can be found for a specific user by running podman info | grep graphRoot
  • This path can be changed based on the requirement. How to change graphRoot for a user
  • However, just changing the path doesn't migrate the image to the newly assigned graphRoot.
  • One can follow the below steps to migrate the images from one path to another path within the host
    • Save the images in the old-graphRoot path using podman save
    • Stop and remove the containers and remove all the images
    • Change the configuration as described in the above steps and verify that the graphroot has changed by running podman info | grep graphRoot
    • Load back the images using podman load and rerun the containers. podman will now pick up the images from the newer location

Comments