1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Restore backup of mount points on the original storage

Discussion in 'Mail Gateway: Installation and configuration' started by omgs, Jul 5, 2017.

  1. omgs

    omgs New Member

    Joined:
    Aug 19, 2016
    Messages:
    13
    Likes Received:
    0
    Hi. I use Proxmox 4.4-13/7ea56165 (updated yesterday) on Debian Jessie. I have the PVE VG defined as LVM storage and a thin pool storage for the root disk of containers. I have some mount points with big data separated from the root disk, all of these on PVE. I choose to backup some of these mount points by checking the backup option in the mount point. Then, to test the behaviour in case of restore, I'm offered just one storage, and ALL the mount points are recreated on this choosen storage.
    Is there anyway to restore the mount points on the source storage?
     
  2. LnxBil

    LnxBil Well-Known Member

    Joined:
    Feb 21, 2015
    Messages:
    1,906
    Likes Received:
    110
    This was discussed on the forum before and IIRC there is currently no way to restore to different storages. You have to move the disks after the restore.

    This is due to the fact that the storage information is IMHO not stored in the backup, only the data and the metadata without the used storage. I'm not sure if this is still correct so please correct me if I'm wrong.
     
  3. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    15,224
    Likes Received:
    154
  4. LnxBil

    LnxBil Well-Known Member

    Joined:
    Feb 21, 2015
    Messages:
    1,906
    Likes Received:
    110
    Oh, I missed that he asked about the container. For KVM my answer is still correct, isn't it?
     
  5. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    15,224
    Likes Received:
    154
    Yes, VMs are different.
     
  6. omgs

    omgs New Member

    Joined:
    Aug 19, 2016
    Messages:
    13
    Likes Received:
    0
    Thanks for your reply. Anyway, I think it's perfectly possible, taking that the original mp info is kept, to provide a way to "respect" those settings. I guess that the current behaviour is parsing the settings to see the mps and restore them all, but this parsing "forgets" to watch the associated storage to even try to keep it as it was when the backup was done, falling back to the same storage as the rootfs.

    Though it's possible to define extra manual options for this in pct restore, I guess that those who do so, they just try to mimic the stored settings not taken into account (at least that's my case at the moment). Apart from the "nuisance" itself, it's error prone, so I can't think about anything that spoils to develop this idea for future feature.

    TIA
     
  7. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    15,224
    Likes Received:
    154
    If you do not specify any storage the original mp info is used, but allocate on local storage. It is planned to add further storage mapping options in future.
     
  8. omgs

    omgs New Member

    Joined:
    Aug 19, 2016
    Messages:
    13
    Likes Received:
    0
    Well, I didn't test the command line, but the Proxmox UI. If you mean that there's a simple way to get a restore taking into account the original storages, then it sounds like it's a feature/bug in the UI, by not allowing the mentioned behavior and forcing everything to go into a specific storage. Is this last is right, what is the way to request this behaviour?
     
  9. dietmar

    dietmar Proxmox Staff Member
    Staff Member

    Joined:
    Apr 28, 2005
    Messages:
    15,224
    Likes Received:
    154
    Fastest way is that you implement it and send a patch ...
     
  10. omgs

    omgs New Member

    Joined:
    Aug 19, 2016
    Messages:
    13
    Likes Received:
    0
    I've been playing for a while with the command line "pct restore ..." with a test container having a root disk and just one mount point on different storages and I haven't been able to restore the way that I wanted, on a specific storage different from local storage. A command line "pct restore VMID backup.tar.gz" means "--storage local", and just changing the storage just reproduces the initial post conditions. Trying things in mps seem to require the volume to exist previously, which means that pct restore by itself, at this moment, can't just restore to the original storages, and that's not just an UI bug, but something not implemented in the code.

    The reason why I asked is I wasn't sure of the status and the features of restoring, together with there was some work in progress and/or demand about this issue. About doing the work myself, I don't have the knowledge to dive into the code, so I'm afraid you can't expect help from me about that. So, I hope someone with the proper knowledge in this forum finds this issue interesting and dedicates the necessary time to implement a solution.

    Regards.
     

Share This Page