chris1259 Posted January 16, 2019 Share Posted January 16, 2019 Both servers are unRaid v6.6.6 Is this possible? Is everything needed contained within the docker image? Or are there additional directories/files that also need to be transferred. Thank You. Quote Link to comment
chris1259 Posted January 16, 2019 Author Share Posted January 16, 2019 I made some headway. Open a terminal and change to the dir you want to save the image. # Display a list of installed docker images. docker ps # Use the name of the docker image and zip it up. docker export PlexMediaServer | gzip > PlexMediaServer.tar.gz # Copy it to the new server. # Open a terminal and change to the directory where you saved the tar.gz file on the new server. # Import the docker image. The name, plexmediaserver, must be in lower case. zcat PlexMediaServer.tar.gz | docker import - plexmediaserver Now checking the Docker tab in unRaid i see this. # Launch the docker container. docker run -i -t plexmediaserver /bin/bash But there is no way to connect to it or edit it. Quote Link to comment
itimpi Posted January 16, 2019 Share Posted January 16, 2019 3 hours ago, chris1259 said: Both servers are unRaid v6.6.6 Is this possible? Is everything needed contained within the docker image? Or are there additional directories/files that also need to be transferred. Thank You. Normally the docker images only contain the binaries - all variable data is external to the docker. The normal place to configure for this variable data is under the appdata share, although it is up to the user where such data is placed. Quote Link to comment
CHBMB Posted January 16, 2019 Share Posted January 16, 2019 (edited) Easiest solution is to just copy across your /appdata share and then repull the containers from Docker hub. Just make sure your volume mounts are still valid on the second server. You could also copy across the XML files from your flash to have easy access to the templates as you've configured them. Essentially there are only two points in the docker ecosystem on Unraid where the data is custom to your install. Appdata and XML files. Personally I'd just copy across the appdata and recreate the containers manually so you can still leverage CA for reinstalling/management. Edited January 17, 2019 by CHBMB 1 Quote Link to comment
chris1259 Posted January 16, 2019 Author Share Posted January 16, 2019 Just now, CHBMB said: Easiest solution is to just copy across your /appdata share and then repull the containers from Docker hub. That's what i was hoping for. I see this /mnt/%username%/appdata/PlexMediaServer/. I will try what you suggested. Quote Link to comment
CHBMB Posted January 17, 2019 Share Posted January 17, 2019 Huh, it should be /mnt/user/appdata Quote Link to comment
trurl Posted January 17, 2019 Share Posted January 17, 2019 There is no need to copy or transfer the docker image. Its contents, which is just the executable code for each container, are downloaded when a docker is installed or updated. What might be worthwhile transferring is the appdata for your dockers, and the templates for each. Probably you already know where the appdata is. The templates are on flash in config/plugins/dockerMan/templates-user. The templates contain the settings for each container, which is all those things you have to fill out when you create or edit a container, such as the mappings, etc. Quote Link to comment
chris1259 Posted January 17, 2019 Author Share Posted January 17, 2019 1 minute ago, CHBMB said: Huh, it should be /mnt/user/appdata i was using %username% as a variable in this case. Quote Link to comment
CHBMB Posted January 17, 2019 Share Posted January 17, 2019 (edited) But it isn't a variable. I'm not being arsey, just want to ensure you understand the file structure before you start copying stuff to /mnt/chris1259/appdata and find yourself wondering where it all went when you restarted your server, as I think it would be in RAM and "poof" disappear. Edited January 17, 2019 by CHBMB Quote Link to comment
chris1259 Posted January 17, 2019 Author Share Posted January 17, 2019 1 minute ago, CHBMB said: But it isn't a variable. I didn't want to assume that everyone had "user" in their path. Quote Link to comment
CHBMB Posted January 17, 2019 Share Posted January 17, 2019 Just now, chris1259 said: I didn't want to assume that everyone had "user" in their path. They do, it's part of the filesystem. Quote Link to comment
chris1259 Posted January 17, 2019 Author Share Posted January 17, 2019 Got it. I will report back the steps i took to get it working. Quote Link to comment
CHBMB Posted January 17, 2019 Share Posted January 17, 2019 One easy way to do it, power down the server with your appdata on (which should all be on a cache disk, not sure I'd try this with a BTRFS pool) and mount it in the new server with unassigned devices, then copy from disk to array. (Make sure you copy rather than move!! And I'd probably back it up on server 1 before doing this as well, can't be too careful.) Quote Link to comment
trurl Posted January 17, 2019 Share Posted January 17, 2019 55 minutes ago, chris1259 said: I didn't want to assume that everyone had "user" in their path. All user shares are mounted in /mnt/user. Simple as that. Quote Link to comment
chris1259 Posted February 27, 2019 Author Share Posted February 27, 2019 I ended not moving the dockers and would suggest having a tab open on each server to transfer the settings over manually. All the attempts to copy over the appdata directory were unsuccessful as i didn't want to remove the cache drive from the server. So no matter what i tried, i was struck with symbolic link errors, rights errors, copy errors, you name it. But thanks for trying to help. Quote Link to comment
bombz Posted February 8, 2021 Share Posted February 8, 2021 (edited) On 1/16/2019 at 6:57 PM, CHBMB said: Easiest solution is to just copy across your /appdata share and then repull the containers from Docker hub. Just make sure your volume mounts are still valid on the second server. You could also copy across the XML files from your flash to have easy access to the templates as you've configured them. Essentially there are only two points in the docker ecosystem on Unraid where the data is custom to your install. Appdata and XML files. Personally I'd just copy across the appdata and recreate the containers manually so you can still leverage CA for reinstalling/management. Hm I am looking into this concern as well. I currently have a cache disk in production (xfs) that I need to recreate on a new cache disk (btrfs) so I can make a raid1 cache set. I attempted to add a second cache disk to the production array (xfs) and when I added the second cache disk it stated UNMOUNTABLE: NO POOL UUID. So my thoughts are I need to backup my current production cache appdata folder to an offline disk format my current cache disk to btrfs enable docker so it creates a blank image add all the docker containers then copy app data back I feel this may pose concerns but I am not sure. I also do use CA backup and restore but never have restored from it, maybe this will make the process smoother, I don't know Edited February 8, 2021 by bombz Quote Link to comment
JonathanM Posted February 8, 2021 Share Posted February 8, 2021 6 minutes ago, bombz said: I am looking into this concern as well. I currently have a cache disk in production (XFS) that I need to recreate on a new cache disk (BTRFS) so I can make a raid1 cache set. https://wiki.unraid.net/Replace_A_Cache_Drive Quote Link to comment
JorgeB Posted February 8, 2021 Share Posted February 8, 2021 8 hours ago, bombz said: I attempted to add a second cache disk to the production array (xfs) and when I added the second cache disk it stated UNMOUNTABLE: NO POOL UUID. You can't add a device to an xfs cache. Quote Link to comment
bombz Posted February 9, 2021 Share Posted February 9, 2021 15 hours ago, JorgeB said: You can't add a device to an xfs cache. OK good to know. So I will be required to convert my existing cache to btrfs in order to create a cache pool in RAID1 if that's the case. Quote Link to comment
bombz Posted February 9, 2021 Share Posted February 9, 2021 23 hours ago, jonathanm said: https://wiki.unraid.net/Replace_A_Cache_Drive Thanks Quote Link to comment
bombz Posted February 28, 2021 Share Posted February 28, 2021 (edited) Following up here as I am a little confused with the process I am attempting to do Overview/Plan: (SSD cache disks) Backup my current cache disk (XFS) Format my current cache disk (to btrfs) Format a second cache disk (to make a pool or RAID1) cache disk set which the filesystem needs to be btrfs in order to do this Right now I have (1x) cache disk in my array used for docker (I don't use VMs or Mover) https://wiki.unraid.net/Replace_A_Cache_Drive I followed up to step 5 I powered down my array and made a 1:1 block copy of my current cache drive to another SSD. (block copy takes partition data with it) Now what I want to do: Power up my array with my current cache disk Format the current cache disk to btrfs Add slot 2 (second SSD cache disk) and also format to btrfs Create a cache pool in RAID1 *which I would have 2x cache disk preset* Add my backed up cache disk (XFS) to Unassigned Devices to copy data from that UD disk, back to the pool RAID1 cache disk set start the array. With how I am looking at this or my situation will this work? Copy the root folders from the backed up cache SSD (xfs) disk using UD to the cache pool RAID1 set (unsure if UD can read XFS disk) Then start my docker (via Settings > Docker > Enable > Yes) -- which will create a new docker.img on the pool disk set Then start all my docker containers and that's it... I should be finished? I am hesitant to do this as part of me thinks the dockers will not work so I want to clarify with the community before proceeding Thanks, Edited February 28, 2021 by bombz Quote Link to comment
JorgeB Posted March 1, 2021 Share Posted March 1, 2021 14 hours ago, bombz said: I am hesitant to do this as part of me thinks the dockers will not work so I want to clarify with the community before proceeding After restoring appdata to its original location see here: https://forums.unraid.net/topic/57181-docker-faq/?do=findComment&comment=564309 Quote Link to comment
bombz Posted March 3, 2021 Share Posted March 3, 2021 On 3/1/2021 at 3:59 AM, JorgeB said: After restoring appdata to its original location see here: https://forums.unraid.net/topic/57181-docker-faq/?do=findComment&comment=564309 Based on this, it is not recommended to copy my docker.img from my current cache disk to my new cache pool? Will my templates (on flash) be OK, as in will they point to all my containers and my current container settings will be OK. Basically trying to to a straight copy of current cache to new cache pool, without many changes * Using mc or any file manager or the command line, move docker.img to the desired location (/mnt/cache/docker.img is recommended) Will my templates remain unaffected if I am moving my docker.img to another location, then creating the new cache pool, and copying this docker.img back? Or will the templates even work being the new cache pool is new disk (disk make, model, etc.)? Quote Link to comment
JorgeB Posted March 3, 2021 Share Posted March 3, 2021 1 hour ago, bombz said: Based on this, it is not recommended to copy my docker.img from my current cache disk to my new cache pool? Yes, just re-create like explained in the link. Quote Link to comment
bombz Posted March 21, 2021 Share Posted March 21, 2021 On 3/3/2021 at 9:01 AM, JorgeB said: Yes, just re-create like explained in the link. Seems I have successfully made the migration to a replacement cache disk reinstalled all containers had to recreate networks for docker (didn't know that) added a second cache disk (cache pool) updated to the latest OS Everything seems to be running OK Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.