[libvirt-users] serial console with virt-install

Cole Robinson crobinso at redhat.com
Wed Feb 8 13:59:53 UTC 2012


On 02/08/2012 03:52 AM, Felix Blanke wrote:
> On 2/8/12 9:46 AM, Osier Yang wrote:
>> On 2012幎02月08日 05:08, Felix Blanke wrote:
>>> Hello,
>>>
>>> sorry for bother you again. I'm new to kvm and libvirt, that's why my
>>> next question is maybe some sort of noob question :)
>>>
>>> I have a headless server (no X at all, just ssh) and want to run some
>>> virtual machines on it. I have kvm etc. all set up.
>>>
>>> When doing something like
>>>
>>> virt-install --connect qemu:///system -n template -r 1024 --disk
>>> path=/data/vm/template.qcow2,format=qcow2 -c
>>> /data/vm/livedvd-amd64-multilib-2012.iso --os-type linux -v
>>> --network=bridge:br0 --virt-type kvm --arch x86_64 --graphics none
>>>
>>>
>>> the vm starts
>>>
>>> Starting install...
>>> Creating domain...
>>>
>>> Connected to domain template
>>> Escape character is ^]
>>>
>>>
>>> That's it, no more output. I see two threads running, each takes up 100%
>>> cpu.
>>> I tried to help myself via google and read a lot hints like "you need to
>>> setup your guest to get a serial console...", but that's not possible
>>> when running a fresh vm. All I want to do is getting some sort of
>>> console from the vm to start the installation with the given .iso file.
>>>
>>> Could someone lead me into the right direct? A link to an explanation
>>> would be more then enough :)
>>
>> Try "--extra-args" to see if it works for you. e.g.
>>
>> --extra-args="console=ttyS0,115200"
>>
> 
> This doesn't work:
> 
> <snip>
> ERROR    --extra-args only work if specified with --location.
> </snip>
> 
> But I don't know what to tell for --location for a gentoo, because you compile
> your own kernel, etc.
> 

If you are booting from CD, the only way to get serial output is to either
connect graphically and specify custom kernel args if the ISO has a splash
screen, or edit the files on the ISO to manually change the boot args.

- Cole




More information about the libvirt-users mailing list