[libvirt-users] Objective: run commands in the domain. Trouble: setting up a console

Guilherme Santos guisgb13 at gmail.com
Fri May 6 14:39:37 UTC 2011


I've installed libvirt and also Virtual Box OSE hypervisor, in order to see
if I could properly manage it through virsh.
I could easily set up, start, pause, resume, shutdown and destroy the newly
created domains, from a XML file.

Then I was wondering how could I be able to spawn commands in the domain
through virsh, and the command 'console' gave me a the thought that I should
connect to the domain's console, so that, once connected, I would be able to
"do anything". Am I right?

I need to be able to run commands in the virtual machine. If the only way is
by accessing the domain's console, how can I properly set up one? I tried
several ways, following the examples in the documentation.

Problem is that no matter what I wrote in the xml file about serial or
console devices, it aways get overriden by null configuration when I start
the domain (I can see it by using command 'edit' <domain> ).

So then I tried to edit the XML through virsh and insert specifications
about console or serial devices, but I never was able to sucessfully edit
the file. I always got the same error message: "could not define a domain,
rc=80bb0004", although the domain is in fact defined! I tried editing the
XML both with the domain running and stopped.

My final alternative was using command 'attach-device' passing a xml
containing only the specifications of serial or console devices. I aways
received an error message saying that memory limit was exceeded, although I
strongly suppose that's not the real problem.

I am sure that I am configuring something (or many things) wrongly, so that
I am getting all those errors... My initial problem is just to be able to
run commands in the newly created domain. Anybody can tell me an easier way
to do this? If setting up consoles is the only way, what is going on wrongly
for me?

Sorry if an answer for this issue is already somewhere in the documentation,
I tried to find it hard before emailing you guys!

Thanks anyway!!

-- 
Guilherme Santos G. Baptista
Graduando em Ciência da Computação pela UFCG
LSD - Laboratório de Sistemas Distribuídos
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/libvirt-users/attachments/20110506/2acee1ed/attachment.htm>


More information about the libvirt-users mailing list