how to copy one block storage data to another block storage?

July 19, 2017 551 views
Block Storage Nginx Ubuntu

Can i copy one block storage data to another block storage?

4 Answers

Hi @DhavalPadshala

You can attach multiple Block Storage volumes to the same droplet (up to 5 volumes).
Then you could attach another volume to your current droplet, and configure it as another device in Ubuntu, and then copy data with the regular cp command.

thnx @hansen
Actually i have an 2 droplet and both have an different different block storage so i want to copy one droplet block storage data to second droplet block storage.

or else how to access one droplet block storage to second droplet.

  • @DhavalPadshala

    Ahhh, then it's much more simple. Keep everything as it is now. I would recommend that you go to the control panel and take a snapshot before copying data around.

    You can use the command scp, which creates a SSH tunnel and then copies data.
    Login to the droplet you want to copy data from.

    scp -pr /path/from user@droplet-ip-address:/path/to/
    #Example
    #scp -pr /volume-old/photos root@12.34.56.78:/volume-keep/media/
    

@hansen
Actually i can't able to login this droplet because it is under Ddos attack. But i have an snapshot of the block storage.

  • @DhavalPadshala

    Uhm, okay, then detach the volume from the DDoS-droplet and then attach it to the working droplet, mount the volume in your OS, and then just use the cp command.

Have another answer? Share your knowledge.