How do i start over with a fresh install with my docker containers?

  • Bummer... I was able to set up some docker containers, on open media vault, with the help of a youtube video on my raspberry pi. Unfortunately i made some mistakes. My dockers seems to be installed on my root drive sd card with my os. I also installed my compose files on a drive that i didn't want to permently have them and i can't seem to find a easy way to move them. Don't get me wrong, my containers are working fine... but i need to install them on a SSD, not my sd card. I wish there was a easy way to backup (and if anyone can explain it to me i woud appreciate it) but it's looking like i have to start over from scratch and rebuild everything.


    So how do a get rid of my containers, how do i reset omv (not all of it as my nas runs on it too, just my docker stuff). how do i clear everything docker wise and start over?


    2 days of trying to migrate is enough for my poor brain, i could have just restarted and had it running in a few hours.... wasted time.


    oh well learning lesson.

    • Offizieller Beitrag

    Well, if its just your containers on your sdcard and you want to move them to your SSD, you don't have to start over because of that. That is a less than 5min fix


    Are there any other things that would cause you to want to restart? Or just because your containers are filling up your SDcard (i assume)

  • Well, if its just your containers on your sdcard and you want to move them to your SSD, you don't have to start over because of that. That is a less than 5min fix


    Are there any other things that would cause you to want to restart? Or just because your containers are filling up your SDcard (i assume)

    because i have spent 2 days now trying to figure this out... I am getting exhausted mentally, reading one thing this way and this way another, others saying its complicated. I just need to know how to do it, otherwise for a piece of mind i need to burn it all down and start from scratch.


    I don't mean to sound down... just tired and wasted 2 days in the summer (literately the entire day each day into the night.).


    My compose files shared folder was put on a usb flash drive while i waited for my SSD drive to come in the mail (thought it would be easy to switch). I don't want to use my usb flash drive (it was only supposed to be temporary)


    I assume my image files are created on my sd card (with my os on) I just want to keep the reads and writes less on that and would prefer to have everything run on my SSD drive. (i assume the files are on the sd card because i checked the flash drive and the hdd folders and don't see them anywhere... don't know how to check the pi/os because i have no gui)


    I installed a RSS container and new data is always being stored and for the like of me i can't find where it is being stored so i assume its on the sd card as well.


    volumes are on /var/lib/docker (which i also assume is on the sd card.


    I just need to figure out how to get everything installed on my SSD drive for speed, and not corrupting the os on the sd card with excessive reads/writes and filling up the card.


    I don't know if all this is possible, but my head is swimming...


    Off to bed.


    I appreciate any help.

    • Offizieller Beitrag

    Yes, /var/lib/docker is on your SDcard. As for your container and where it's storing data, I'd need to see the compose file for it.


    Get some sleep, we'll fix this tomorrow. You don't need to do a complete reinstall.


    Basic procedure:


    Stop docker

    Move /var/lib/docker to somewhere on your SSD

    update docker configs to point at the new location

    Restart docker.


    It's really that easy

  • Thank you for your kind words and patience...


    I have 3 containers up and running. here are the compose files...


    freshrss



    full test rss

    portainer

    If you can help my migrate these to my SSD off my os sd card I would appreciate it.


    After that I two more items I need to address...

    -set up a ongoing backup of all these on my large HDD also attached to my pi

    - want to update and expand (i am not sure the terms as still learning) the available repositories of my docker. I read that just updating can mess things up, so it is recommended to back up, fresh install docker, update with new repos, then re-install the containers. I need to know how to do that correctly. (there are weather containers and other cool stuff i want to try that isn't available on what i have now.)


    But one thing at a time, just letting you know what I am looking at... need to clean up how i installed everything then make backups, and finally i want to update and try other containers.


    I hope that makes sense.

  • I don't know how to view the files off of /var/lib/docker. I can only see the files that are on my hard drive connected to my pi-nas. I would prefer to do this in linux as I am trying to migrate away from windows. That being said i guess i just need to get this figured out.

    • Offizieller Beitrag

    I don't know how to view the files off of /var/lib/docker. I can only see the files that are on my hard drive connected to my pi-nas. I would prefer to do this in linux as I am trying to migrate away from windows. That being said i guess i just need to get this figured out.

    you don[t need to view them, you just need to move them


    First, please post the output of this command:


    Code
    docker info | grep Root            

    then post the full UUID to the drive you want to move the containers to...


    something like this:


    Code
    /srv/dev-disk-by-uuid-ac6fafbd-737a-4ecc-8231-cdc8dd22add8
  • I ran the docker info twice, once normally and once in root.


    Zitat

    docker info | grep Root

    ERROR: permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get "http://%2Fvar%2Frun%2Fdocker.sock/v1.24/info": dial unix /var/run/docker.sock: connect: permission denied

    errors pretty printing info

    Zitat

    # docker info | grep Root

    Docker Root Dir: /var/lib/docker

    WARNING: No memory limit support

    WARNING: No swap limit support

  • OK, just so you know, this will all have to be done at root.


    What is the full UUID path to your SSD where you want to move the docker folder?

    How do i find the UUID? ( i just added my SSD to my share, as i forgot to re-add it after i was playing around trying to figure this out.

    • Offizieller Beitrag

    How do i find the UUID? ( i just added my SSD to my share, as i forgot to re-add it after i was playing around trying to figure this out.

    Do you have any shared folders on the SSD? That bash error makes me think you've already screwed this up, but we'll see.

    • Offizieller Beitrag

    KM0201 take a look in the other thread. There's a little mess with the shared folders and relative paths that will need to be fixed as well. You have work ahead...

    • Offizieller Beitrag

    KM0201 take a look in the other thread. There's a little mess with the shared folders and relative paths that will need to be fixed as well. You have work ahead...

    Yeah, we might have to move this to discord.. i gotta feeling this will be an adventure.

    • Offizieller Beitrag

    this???

    No.


    Do you have discord? If not, go to discord.com and create a free account. This will be easier if we can chat cuz I have a feeling a lot's going to need fixed here.


    Once you've signed up (or if you already have an account) follow the link below and join the OMV discord. I'll be waiting for you there and i'll figure out what the issue is



    Join the OpenMediaVault Discord Server!
    Check out the OpenMediaVault community on Discord - hang out with 605 other members and enjoy free voice and text chat.
    discord.gg

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!