Restoring a currupted docker image


lankanmon

Recommended Posts

My cache drive became full due to an unexpected set of data baing added to cache only. I only nocied when some of my docker apps started misbehaving. I turned off docker (in settings) to prevent further damage and ran the mover to get the cache back to normal. When turning on docker again, I saw that "Docker Service failed to start.". I know that I can delete the docker image, but IIRC, last time I deleted the image, I had to setup each app all over again. Since then, I have a lot more apps. Is there a way to backup each of the apps configs (all of the settings) before deleting the image, so I can add them easily after deleting the image?

 

Since the docker image is not starting, I can't go through each of then like I would normaly to take screenshots of the settings.

Your help will be much apprciated. I really hope that I don't need to figure out the configs for each app all over again...

 

I have also attached my diagnostics in case that will help with resolvign the issue...

 

lknserver-diagnostics-20200920-0710.zip

Edited by lankanmon
Link to comment
23 minutes ago, itimpi said:

Any time you set install a container via the Apps tab then the settings you used are saved in a template on the flash dtive.    If you restore the containers using the Previous Apps section of the Apps tab then these will be used so that they will be put back with their previous settings intact.

Okay, thanks! So, if I delete the image and restart docker, I should be able to see the application templates?

13 minutes ago, ChatNoir said:

The custom dockers network might have to be reapplied/reconfigured though if I am not mistaking.

Is there anyway to see the custom docker networks before I delete the image? Just so I can re-make it. I think I had one setup... Thanks!

Link to comment

Since the docker service failed to start you can't ask docker what custom networks you had.

 

If you were following SpaceInvader videos for letsencrypt for example, then you probably had

docker network create proxynet

Go to Settings - Docker, disable and delete docker.img

 

But, your system share, where docker.img is configured to live, is on the array and it is set to cache-yes instead of prefer as it should be. Are you sure filling cache is what corrupted it? Doesn't seem likely since it isn't on cache or configured to be on cache. Possibly you filled docker.img instead. Have you had problems filling it? I see you have allocated 30G but 20G is often much more than enough unless you have some app misconfigured so it is writing into the image.

 

You should get system share all on cache and set to stay on cache before recreating docker.img, recreating custom docker networks, and reinstalling your dockers from Apps - Previous Apps.

 

Do you actually run any VMs? Those would be using libvirt.img which is also in system and on the array. You need to set system to cache-prefer so mover can move it to cache, but since mover can't move open files you will have to disable VM Manager in addition to disabling Docker to get system share moved.

 

appdata is all on cache so that much is good. You can decide if you want domains share on array like you have it now, but be aware that VMs accessing that share (vdisks) will have performance impacted by parity and will keep array disks spunup. Often domains can also live completely on cache, since the VM OS vdisks may be all you need and VMs can access additional Unraid storage over the virtual network. Looks like cache has plenty of capacity for all this while also caching user share writes.

 

Link to comment

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.