LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Virtualization and Cloud
User Name
Password
Linux - Virtualization and Cloud This forum is for the discussion of all topics relating to Linux Virtualization and Linux Cloud platforms. Xen, KVM, OpenVZ, VirtualBox, VMware, Linux-VServer and all other Linux Virtualization platforms are welcome. OpenStack, CloudStack, ownCloud, Cloud Foundry, Eucalyptus, Nimbus, OpenNebula and all other Linux Cloud platforms are welcome. Note that questions relating solely to non-Linux OS's should be asked in the General forum.

Notices


Reply
  Search this Thread
Old 12-08-2020, 01:30 PM   #1
Goodlinux
Member
 
Registered: Jan 2020
Posts: 63

Rep: Reputation: Disabled
qemu-kvm virtualization


Hello,

I have two redundant servers with qemu-kvm type 1 hypervisor, each server houses three Redhat linux5 VMs.
The problem that arises is that I want to restore a lost VM.
Normally the system contains a global backup of all the server configuration with which we can recover this VM.

Thanks
 
Old 12-08-2020, 02:33 PM   #2
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,987

Rep: Reputation: 3627Reputation: 3627Reputation: 3627Reputation: 3627Reputation: 3627Reputation: 3627Reputation: 3627Reputation: 3627Reputation: 3627Reputation: 3627Reputation: 3627
Not sure what way to go here.

You shouldn't have "lost" a vm would be my starting point.

If you have a virtual hard drive copy then move it??
 
Old 12-08-2020, 04:11 PM   #3
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Quote:
Originally Posted by Goodlinux View Post
Hello,

I have two redundant servers with qemu-kvm type 1 hypervisor, each server houses three Redhat linux5 VMs.
The problem that arises is that I want to restore a lost VM.
How did you lose it?
Quote:
Normally the system contains a global backup of all the server configuration with which we can recover this VM.
I am not aware of such a backup. If the VM's configuration exists, it is not lost. Can you elaborate?

Most people use libvirt to manage KVM VMs. Is that what you do? How do you start and stop them, and how do you know one of them was lost?
 
Old 12-09-2020, 01:59 AM   #4
Goodlinux
Member
 
Registered: Jan 2020
Posts: 63

Original Poster
Rep: Reputation: Disabled
Hello;

From the Virtual-Machine-Manager, I tried to make a clone of this VM machine in running state.
Also I found that the .xml file does not exist et le ping ne marche plus.

Pour votre information cette VM est responsable de la gestion d'une application de supervision graphique d'un réseau de système Telecom.

Thanks
 
Old 12-09-2020, 02:00 AM   #5
Goodlinux
Member
 
Registered: Jan 2020
Posts: 63

Original Poster
Rep: Reputation: Disabled
Hello;

From the Virtual-Machine-Manager, I tried to make a clone of this VM machine in running state.
Also I found that the .xml file does not exist et le ping ne marche plus.

For your information, this VM is responsible for managing a graphical supervision application for a Telecom system network.

Thanks[/QUOTE]
 
Old 12-09-2020, 02:11 AM   #6
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Quote:
Originally Posted by Goodlinux View Post
Hello;

From the Virtual-Machine-Manager, I tried to make a clone of this VM machine in running state.
What happened when you tried cloning it?
Quote:
Also I found that the .xml file does not exist et le ping ne marche plus.
ping not getting a response can have other causes: The VM is stopped, something is broken at the network level, or networking or firewall are not correctly configured in the VM.

Where did you look for the XML file? If you can access the command line, share the result of virsh list --all. Is the lost VM in that list? If yes, it is not lost.

You can also search the host's filesystem for the file that contains the VM's root disk, for example find / -name \*.qcow2.

If you find neither XML file nor the root disk, the VM is indeed lost. If you haven't created a backup, there is no backup.

I think you had this problem early this year. Is it the same VM or a different one?
 
1 members found this post helpful.
Old 12-09-2020, 03:26 AM   #7
Goodlinux
Member
 
Registered: Jan 2020
Posts: 63

Original Poster
Rep: Reputation: Disabled
Hello

Yes this is the same problem.

When i tried cloning it, i lost it and this problem appears.

Also after using virsh list -all commande i didn't find my VM.

And cd /var/lib/libvirt/qemu didn't contain the .xml file for this VM.

Thanks
 
Old 12-09-2020, 03:32 AM   #8
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Quote:
Originally Posted by Goodlinux View Post
And cd /var/lib/libvirt/qemu didn't contain the .xml file for this VM.
On my hypervisor host, XML files are under /etc/libvirt. But perhaps it's elsewhere in your case. I would search the entire filesystem, just in case.

And I am sorry to say it again, if the XML file is not on that host, it's gone. There is no built-in backup. Backups are set up by system administrators.

Last edited by berndbausch; 12-09-2020 at 03:36 AM.
 
1 members found this post helpful.
Old 12-09-2020, 04:40 AM   #9
Goodlinux
Member
 
Registered: Jan 2020
Posts: 63

Original Poster
Rep: Reputation: Disabled
Hello



you are right i was wrong xml file it is in / etc / libvirt.

How could I check if there is a backup which has been made somewhere of the VM or of all the configuration of my linux servers.

Thank you
 
Old 12-09-2020, 04:48 AM   #10
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Quote:
Originally Posted by Goodlinux View Post
How could I check if there is a backup which has been made somewhere of the VM or of all the configuration of my linux servers.
You ask the system administrators.

EDIT: Backups are usually done on a regular basis, so if your system is backed up, you should find something in the cron tables or anacron configuration.

Last edited by berndbausch; 12-09-2020 at 04:55 AM.
 
1 members found this post helpful.
Old 12-09-2020, 04:53 AM   #11
Goodlinux
Member
 
Registered: Jan 2020
Posts: 63

Original Poster
Rep: Reputation: Disabled
OK Thank you for reply
 
Old 12-09-2020, 05:00 AM   #12
Goodlinux
Member
 
Registered: Jan 2020
Posts: 63

Original Poster
Rep: Reputation: Disabled
Hello

just one last question.
We have another server from another system which hosts the same VM and which performs the same role.
Can we backup this VM and use it in our server instead of the lost one, and how can we do it?

Thanks
 
Old 12-09-2020, 08:25 AM   #13
Goodlinux
Member
 
Registered: Jan 2020
Posts: 63

Original Poster
Rep: Reputation: Disabled
Hello

I want to make a backup and copy a VM from one server to another.?????

Thanks
 
Old 12-09-2020, 09:50 AM   #14
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
Shut the VM down. Copy its root disk to the new host. Copy its XML file as well.

Remove things like MAC address and UUID from the XML file, which uniquely identify the VM. Then create a new VM from the XML file.

Depending on your situation, you may also have to fix the network configuration in the VM copy. I can't say if your application requires some adjustment.
 
Old 12-09-2020, 02:34 PM   #15
Goodlinux
Member
 
Registered: Jan 2020
Posts: 63

Original Poster
Rep: Reputation: Disabled
Hello

How can do it ? ( Copy its root disk to the new host. Copy its XML file as well )

Remove only UUID but change the MAC ADDR with a new MAC, is it right ?

Thanks
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] "No KVM, No qemu-kvm" Available error while trying to install KVM on CentOS 6.3 sriramdas Linux - Virtualization and Cloud 5 01-01-2013 10:46 AM
LXer: Set up qemu-kvm-1.0+noroms as spice enabled qemu server vs qemu-kvm-spice on Ubuntu Precise LXer Syndicated Linux News 0 05-26-2012 07:41 AM
[Debian/Qemu/KVM] Why qemu --enable-kvm works but not kvm directly? gb2312 Linux - Virtualization and Cloud 2 03-21-2011 02:05 PM
LXer: Attempt of qemu-kvm-0.14 patching via Gerd’s Hoffmann “spice/qxl: locking fix for qemu-kvm” on LXer Syndicated Linux News 0 03-14-2011 01:20 PM
On qemu-kvm, qemu-ifup script not found on Slackware 13 AndrewGaven Linux - Virtualization and Cloud 14 01-29-2010 03:36 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Virtualization and Cloud

All times are GMT -5. The time now is 12:46 AM.

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