Hi,
I also have some problems related to serial consoles. When I try to create
a virtual machine (virsh create test.xml) with a serial port connected to
a unix socket in the host by using:
<serial type="unix">
<source mode="bind"
path="/tmp/.vnx/simple_ubuntu/ubuntu_socket"/>
<target port="1"/>
</serial>
(see the complete XML below)
I get this error:
error: Failed to create domain from test.xml
error: internal error Process exited while reading console log output:
char device redirected to /dev/pts/3
bind(unix:/tmp/.vnx/simple_ubuntu/ubuntu_socket): Permission denied
chardev: opening backend "socket" failed: Permission denied
(I've executed libvirt in debug mode, but I've not seen any relevant
traces related to the problem)
This problem arises only when I try over an Ubuntu system with libvirt
installed as a package. When I try it over the same system with libvirt
manually installed, it works.
Latest tests have been made over a Ubuntu 12.04 system with apparmor
disabled using libvirt 0.9.8 as package or manually compiled with standard
configure options. But, I also made tests with other Ubuntu and libvirt
versions and the result is similar.
Any idea about how to solve the problem or a workaround will be highly
appretiated.
Best regards,
David Fernández
Universidad Politécnica de Madrid
Virtual Networks over linuX (VNX)
http://www.dit.upm.es/vnx
---------------------------------------------------------------------
test.xml file:
<?xml version="1.0" encoding="UTF-8"?>
<domain type="kvm"
xmlns:qemu="http://libvirt.org/schemas/domain/qemu/1.0">
<name>Ubuntu</name>
<memory>524288</memory>
<vcpu>1</vcpu>
<os>
<type arch="i686" machine="pc">hvm</type>
<boot dev='hd'/>
</os>
<features>
<pae/>
<acpi/>
<apic/>
</features>
<clock sync="localtime"/>
<devices>
<emulator>/usr/bin/kvm</emulator>
<disk type='file' device='disk'>
<source file='/usr/share/vnx/filesystems/rootfs_ubuntu'/>
<target dev='hda'/>
<driver name="qemu" type="qcow2"/>
</disk>
<serial type="unix">
<source mode="bind"
path="/tmp/.vnx/simple_ubuntu/ubuntu_socket"/>
<target port="1"/>
</serial>
<graphics type='vnc'/>
</devices>
</domain>