LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 04-01-2017, 01:07 PM   #31
AB49K
LQ Newbie
 
Registered: Mar 2017
Location: Australia
Distribution: CentOS, OpenSuse, Ubuntu, Debian.
Posts: 26

Rep: Reputation: Disabled

Quote:
Originally Posted by Jay1969 View Post
Thanks for your reply, AB49K.

I have found where the VMs are installed. See attachment.

I just came back from the office to try to extract the files from the server. I shutdown the server, plugged in a 2TB USB and booted on latest Knoppix live. I see the datapool partition, but I get an error message when clicking on it. I believe it had something to do with ***/usr.

I tried mounting the USB in order to create a stop backup and saving it directly on the USB and it did not work (cannot find the thread I used for now--will post the link later).

Can I use a command line I can run asking PM to take file vzdump-qemu-100-2016_11_11-09_30_41.vma.lzo and ship it on the USB device? We also have a NAS connected to the server. I assume I would have to mount it before being able to save anything?

I will work on the static IP in the meantime.
Because the backup is not a live disk and nicely compressed for you, just run good ol "rsync -avzc vzdump-qemu-100-2016_11_11-09_30_41.vma.lzo /path/to/externalhdd --progress" and then you'll have a nice backup ready to go. I don't know if proxmox supports a direct backup like that without adding the disk as a datastore and then running the backup targeting it.
 
Old 04-01-2017, 01:13 PM   #32
Jay1969
Member
 
Registered: Mar 2017
Posts: 35

Original Poster
Rep: Reputation: Disabled
Quote:
Because the backup is not a live disk and nicely compressed for you, just run good ol "rsync -avzc vzdump-qemu-100-2016_11_11-09_30_41.vma.lzo /path/to/externalhdd --progress" and then you'll have a nice backup ready to go. I don't know if proxmox supports a direct backup like that without adding the disk as a datastore and then running the backup targeting it.
Great! I just need some more info. I should run this exact, generic command?

rsync -avzc vzdump-qemu-100-2016_11_11-09_30_41.vma.lzo /path/to/externalhdd --progress

I do not need to identify the device (i.e. dev/sda1) or the container on the HDD to get this to work? (I feel kind of dumb asking.)
 
Old 04-01-2017, 01:24 PM   #33
AB49K
LQ Newbie
 
Registered: Mar 2017
Location: Australia
Distribution: CentOS, OpenSuse, Ubuntu, Debian.
Posts: 26

Rep: Reputation: Disabled
Quote:
Originally Posted by Jay1969 View Post
Great!
rsync -avzc vzdump-qemu-100-2016_11_11-09_30_41.vma.lzo /path/to/externalhdd --progress
Identify the device, then do

"sudo mkdir /externalhdd"
"sudo mount /dev/sdX /externalhdd"
then
"sudo rsync -avzc /datapool/backups-compressed/vzdump-qemu-100-2016_11_11-09_30_41.vma.lzo /externalhdd --progress"

I *think* I'm in the right directory here, if you get an error saying something along the lines as no such file, do
"cd /datapool/backups-compressed" then do "ls" and see what's in that folder. the lzo may just be in a subfolder depending on how the backups are set up.
 
1 members found this post helpful.
Old 04-03-2017, 04:51 PM   #34
Jay1969
Member
 
Registered: Mar 2017
Posts: 35

Original Poster
Rep: Reputation: Disabled
AB49K, you rock!

By following your instructions, I was able to complete the process, and I am ecstatic to see—at this very moment—that the backup is being copied to the XHDD. What a terrific relief!

Next step: I need to get this backup on the Clonezilla'd HD, more specifically in the folder that PM uses to boot the virtual machine. You mentioned: /var/lib/vz/images/<VM ID>. Correct?

May I please ask you to provide the sequence of commands I should input in order to copy this backup from my XHDD onto the Proxmox-powered HDD. Will I need to partition the HDD in any ways?

Can't believe I made it this far! It would have been impossible without your help, AB49K & Rickkkk!

Thanks again!
 
Old 04-03-2017, 06:23 PM   #35
AB49K
LQ Newbie
 
Registered: Mar 2017
Location: Australia
Distribution: CentOS, OpenSuse, Ubuntu, Debian.
Posts: 26

Rep: Reputation: Disabled
Quote:
Originally Posted by Jay1969 View Post
AB49K, you rock!

Next step: I need to get this backup on the Clonezilla'd HD, more specifically in the folder that PM uses to boot the virtual machine. You mentioned: /var/lib/vz/images/<VM ID>. Correct?

May I please ask you to provide the sequence of commands I should input in order to copy this backup from my XHDD onto the Proxmox-powered HDD. Will I need to partition the HDD in any ways?

Can't believe I made it this far! It would have been impossible without your help, AB49K & Rickkkk!

Thanks again!
Are you using an different RAID set for your containers like on the old server?

If you are, the commands will be different - you may have to re-set up the storage devices to point to a local folder rather than the ZFS pool that it was on the original server.
 
Old 04-03-2017, 06:25 PM   #36
Jay1969
Member
 
Registered: Mar 2017
Posts: 35

Original Poster
Rep: Reputation: Disabled
No, I have one 2TB HDD in the box — that's it! I formatted the HDD, then cloned Proxmox on it using Clonezilla. That's all I did.
 
Old 04-03-2017, 07:03 PM   #37
AB49K
LQ Newbie
 
Registered: Mar 2017
Location: Australia
Distribution: CentOS, OpenSuse, Ubuntu, Debian.
Posts: 26

Rep: Reputation: Disabled
Quote:
Originally Posted by Jay1969 View Post
No, I have one 2TB HDD in the box — that's it! I formatted the HDD, then cloned Proxmox on it using Clonezilla. That's all I did.
Alright!
So there is a few things we might need to do.

First make a directory
"sudo mkdir /var/lib/vzbackup"
Then mount the external disk the same way as before.
then do
"sudo rsync -avzc /externalhdd/vzdump-qemu-100-2016_11_11-09_30_41.vma.lzo /var/lib/vzbackup --progress"

Once that's done, you'll have to add the new storage locations to the server.

in the Proxmox panel, go to datacentre -> storage
There should be a storage called "local" there. Double click on that and make sure "Disk Image, ISO Image, Container Template and Container" are highlighted.

Then, go to Add -> directory

For the ID, just put 'backups' or something
directory is "/var/lib/vzbackup"
and for content, set it as "VZDump backup file"

Now under your server list, you should see a new storage location with the ID of the new backup location. Click on that, it should list all the backups copied to /var/lib/vzbackup. And then just highlight the backup and choose "restore"

That should be it.
 
1 members found this post helpful.
Old 04-04-2017, 11:16 AM   #38
Rickkkk
Senior Member
 
Registered: Dec 2014
Location: Montreal, Quebec and Dartmouth, Nova Scotia CANADA
Distribution: Arch, AntiX, ArtiX
Posts: 1,364

Rep: Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511
Glad to see you're progressing with AB49K's help. At this point, I have nothing in particular to add since AB49K has much more pertinent experience for your particular situation.

I'll still follow this until the end, mind you :-)

Cheers.
 
Old 04-04-2017, 12:26 PM   #39
Jay1969
Member
 
Registered: Mar 2017
Posts: 35

Original Poster
Rep: Reputation: Disabled
OK, backups all have been transferred to my XHDD. Happy camper! Before I go on and proceed to next step, I am sure I need to unmount the XHDD before unplugging the device. I tried to reverse the steps AB49K indicated to mount the XHDD and transfer the files with rsync. It does not work.

What is the command to unmount the external HDD? I tried "unmount /dev/sdXX /externalhdd" without luck.
 
Old 04-04-2017, 02:34 PM   #40
wpeckham
LQ Guru
 
Registered: Apr 2010
Location: Continental USA
Distribution: Debian, Ubuntu, RedHat, DSL, Puppy, CentOS, Knoppix, Mint-DE, Sparky, VSIDO, tinycore, Q4OS,Manjaro
Posts: 5,597

Rep: Reputation: 2690Reputation: 2690Reputation: 2690Reputation: 2690Reputation: 2690Reputation: 2690Reputation: 2690Reputation: 2690Reputation: 2690Reputation: 2690Reputation: 2690
Quote:
Originally Posted by Jay1969 View Post
OK, backups all have been transferred to my XHDD. Happy camper! Before I go on and proceed to next step, I am sure I need to unmount the XHDD before unplugging the device. I tried to reverse the steps AB49K indicated to mount the XHDD and transfer the files with rsync. It does not work.

What is the command to unmount the external HDD? I tried "unmount /dev/sdXX /externalhdd" without luck.
The command is not
Code:
unmount
. The command is
Code:
umount
.
I hope that helps.
 
Old 04-04-2017, 04:14 PM   #41
Jay1969
Member
 
Registered: Mar 2017
Posts: 35

Original Poster
Rep: Reputation: Disabled
Thanks wpeckham!

The backups were not copied the XHDD. I got an error message at the very end, something to do with read-only. I have a WD 2TB Elements, factory formatted. SHould we create a distinct Linux partition on this drive? Or create a folder through Windows (e.g. root/dump) and copy the files in that folder instead of at the disk's root?
 
Old 04-04-2017, 06:22 PM   #42
Rickkkk
Senior Member
 
Registered: Dec 2014
Location: Montreal, Quebec and Dartmouth, Nova Scotia CANADA
Distribution: Arch, AntiX, ArtiX
Posts: 1,364

Rep: Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511Reputation: 511
Quote:
Originally Posted by Jay1969 View Post
Thanks wpeckham!

The backups were not copied the XHDD. I got an error message at the very end, something to do with read-only. I have a WD 2TB Elements, factory formatted. SHould we create a distinct Linux partition on this drive? Or create a folder through Windows (e.g. root/dump) and copy the files in that folder instead of at the disk's root?
That's odd. If there was a read-only flag on the file-system, I think you would have gotten a message immediately - not near the end of the copy cycle. Could you run a command on the machine your 2TB drive is plugged into :

Code:
lsblk -fs
Thx.
 
Old 04-05-2017, 10:30 AM   #43
Jay1969
Member
 
Registered: Mar 2017
Posts: 35

Original Poster
Rep: Reputation: Disabled
Retried — does not work. See snapshots.
Attached Thumbnails
Click image for larger version

Name:	IMG_20170405_1122392.jpg
Views:	17
Size:	244.5 KB
ID:	24681   Click image for larger version

Name:	IMG_20170405_1128220.jpg
Views:	12
Size:	191.9 KB
ID:	24682  
 
Old 04-05-2017, 10:38 AM   #44
AB49K
LQ Newbie
 
Registered: Mar 2017
Location: Australia
Distribution: CentOS, OpenSuse, Ubuntu, Debian.
Posts: 26

Rep: Reputation: Disabled
Hi Jay,

Try moving it into a different directory in the external HDD?
I can't really see what the rest of the error is due to the flash.
Did the .lzo get moved to the HDD anyway? do "ls -l /externalhdd/"
 
Old 04-05-2017, 10:47 AM   #45
Jay1969
Member
 
Registered: Mar 2017
Posts: 35

Original Poster
Rep: Reputation: Disabled
No, it did not. See screenshots. I created the 'dump' folder yesterday through Windows. What would the command to try to copy in that folder?

I would guess:

sudo rsync -avzc dump/externalhdd/vzdump-qemu-100-2016_11_11-09_30_41.vma.lzo /var/lib/vzbackup --progress

Please confirm.
Attached Thumbnails
Click image for larger version

Name:	IMG_20170405_1143099.jpg
Views:	9
Size:	247.0 KB
ID:	24683   Click image for larger version

Name:	IMG_20170405_1143169.jpg
Views:	13
Size:	231.0 KB
ID:	24684  
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Why are user credentials not being passed to server at time of login? rajevar Linux - Newbie 2 09-24-2009 03:57 PM
Using C API; first query passed passed by program to MySQL is successful, second quer weibullguy Programming 2 06-12-2007 10:45 PM
vpn passed from RH9 firewall to OS X server - not quite MadTurki Linux - Networking 4 02-25-2004 03:55 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 04:24 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration