Move docker /var/lib/docker folder on external drive

    • OMV 4.x

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • In OMV go to Services | Docker | Settings. Make a change to the setting: The location of the Docker base path. This must be an OMV shared folder, so create one on the target drive beforehand if you have not already done so.
      --
      Google is your friend and Bob's your uncle!

      OMV 4.x - ASRock Rack C2550D4I - 16GB ECC - Silverstone DS380
    • I have very bad experience with changing this setting. During one of the updates of Docker addon i received bunch of folders (docker related) in /sharedfolders/
      + the setting was back to default which created a complete mess ....

      So my solution is :

      1) don't touch the setting in Docker tab
      2) Move /var/lib/docker to external drive (ex. /sharedfolders/data/docker)
      3) sym-lync /sharedfolders/data/docker to /var/lib/docker

      Done.

      No problems so far....
    • New

      ivanovlk wrote:

      I have very bad experience with changing this setting. During one of the updates of Docker addon i received bunch of folders (docker related) in /sharedfolders/
      + the setting was back to default which created a complete mess ....

      So my solution is :

      1) don't touch the setting in Docker tab
      2) Move /var/lib/docker to external drive (ex. /sharedfolders/data/docker)
      3) sym-lync /sharedfolders/data/docker to /var/lib/docker

      Done.

      No problems so far....
      I am very interested to move my dockers to my external drive just need to know the pros and cons for doing it, and above all, what is the way to create a symlink in order to achieve this.
    • New

      macom wrote:

      You can create symlinks with ln -s

      linux.die.net/man/1/ln
      Well I have to confess,i am not too good to navigate in cmd i did actually succeed but gave an existent link.So in order to create the link so I used win scp and cmd
      but now my docker place is empty I renamed the link docker but nothing
      I did try this

      root@rockpro64:/sharedfolders# ln -s /docker /var/lib/docker-link
      but it is wrong what could be the exact cmd?

      The post was edited 1 time, last by Nefertiti ().

    • New

      I am replying to myself!
      This time I stopped the plugin succeed to navigate to the appdata folder where I had copied the docker folder from var/lib and did the cmd ln -s /docker /var/lib/docker
      so far it is working before deleting the original docker I renamed it old the only difference all my docker images is empty but not the docker container witch show only numeric ID maybe because of towerwatch or some error I produced a long the way.
      I am unable to download the new images but I have connection to the repo!
      Images
      • 2019-06-16_190950.jpg

        111.27 kB, 1,168×901, viewed 3 times

      The post was edited 1 time, last by Nefertiti ().

    • New

      The main issue for me is to get a proper copy of my original docker in my appdata folder but I only get only a partial copy of the docker folder I am using

      rsync -avr --progress /var/lib/docker /sharedfolders/AppData/data/docker
      and after for the link ln -s /docker /var/lib/docker but probably this is not right
      Should I put back the noexec I modified some time ago for plex problem?