V
V
valeraisrock2021-03-30 05:12:27
linux
valeraisrock, 2021-03-30 05:12:27

How to migrate/clone CentOS from vps to local machine?

I want to migrate CentOS on vps to my hardware from vps server. For now, just move it to run. I know how to administer, I can fix the bootloader. The question is, I didn’t understand the file system on the vps

File system Size Used Dost Used% Mounted in
devtmpfs 5.8G 0 5.8G 0% /dev
tmpfs 5.8G 8.0K 5.8G 1% /dev/shm
tmpfs 5.8G 613M 5.2G 11% /run
tmpfs 5.8G 0 5.8G 0% /sys/fs/cgroup
/dev/mapper/vg0-vol--root 20G 17G 2.1G 90% /
/dev/mapper /vg0-vol_home 9.8G 1.4G 7.9G 15% /home
/dev/mapper/vg0-vol_opt 50G 9.0G 38G 20% /opt
/dev/md1 990M 253M 687M 27% /boot
tmpfs 1.2G 0 1.2G 0% /run/user/1007

how do I cut a disk on a local machine, specifically, I don’t understand now why / opt 50G if there is only 20G at the root? (i.e. I intuitively understand that this is only a mount point and they have a huge disk on the VPS and they cut it and mounted it like that) And what can I face? How to do it right? How to transfer all this to me in a LAN?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
S
Sanes, 2021-03-30
@valeraisrock

Take a virtual disk from the host and convert it to your /dev/sdX.

D
Dmitry, 2021-03-30
@q2digger

>> specifically, I don't understand now why /opt 50G if there is only 20G at the root?
Because the VPS uses an LVM
Root partition - one LVM volume (/dev/mapper/vg0-vol--root 20G)
and /opt is another LVM volume (/dev/mapper/vg0-vol_opt 50G)

A
Alexey Dmitriev, 2021-03-30
@SignFinder

1. Install any hypervisor, even Hyper-V on Windows 10.
2. Deploy Veeam Backup and Replication Free. Perhaps he needs a server OS, so pick up a virtual machine with it and install it there.
3. Make a full backup of the VPS to it using Veeam Agent for Linux Free.
4. Restore the copy as a virtual machine.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question