sysml / clickos

The Click modular router: fast modular packet processing and analysis
http://www.read.cs.ucla.edu/click/
Other
136 stars 35 forks source link

clickvm can not start with vale bridge #25

Closed zhangwei1984 closed 8 years ago

zhangwei1984 commented 8 years ago

Hi,

After inserting the xen backend, if I want to use vale bridge create the vm, I met this error:

zhangwei1984@nimbnode21:~/clickos/clickvms$ sudo xl create vm1.cfg
Parsing config from vm1.cfg
libxl: error: libxl_exec.c:118:libxl_report_child_exitstatus: /etc/xen/scripts/vif-vale online [24793] exited with error status 1
libxl: error: libxl_device.c:1084:device_hotplug_child_death_cb: script: /etc/xen/scripts/vif-vale failed; error detected.
libxl: error: libxl_create.c:1381:domcreate_attach_vtpms: unable to add nic devices
libxl: error: libxl_exec.c:118:libxl_report_child_exitstatus: /etc/xen/scripts/vif-vale offline [24844] exited with error status 1
libxl: error: libxl_device.c:1084:device_hotplug_child_death_cb: script: /etc/xen/scripts/vif-vale failed; error detected.
libxl: error: libxl.c:1591:libxl__destroy_domid: non-existant domain 15
libxl: error: libxl.c:1549:domain_destroy_callback: unable to destroy guest with domid 15
libxl: error: libxl.c:1476:domain_destroy_cb: destruction of domain 15 failed

dmesg

[18584.480314] xen_netback/xen_netback:xenvif_netmap_detach: netmap_detach vif14.0
[18776.725908] 478.320403 [2259] netmap_attach             success for vif15.0
[18776.806011] IPv6: ADDRCONF(NETDEV_UP): vif15.0: link is not ready

vm configuration file

zhangwei1984@nimbnode21:~/clickos/clickvms$ cat vm1.cfg 
name   = 'vm1'
kernel = '/home/zhangwei1984/clickos/clickvms/vm1'
vcpus  = '1'
# pinning your VCPU helps performance
#cpus   = '3'
memory = '8'
vif    = ['bridge=vale0,script=vif-vale']
on_poweroff = 'destroy'
on_reboot   = 'restart'
on_crash    = 'preserve'                        
click       = 'mirror.click'

I can create vale bridge and attach a port. The following info shows that

zhangwei1984@nimbnode21:~/clickos/clickvms$ sudo /home/zhangwei1984/clickos/xennet/netmap/examples/vale-ctl -l zhangwei1984@nimbnode21:~/clickos/clickvms$ sudo /home/zhangwei1984/clickos/xennet/netmap/examples/vale-ctl -a vale0:p2p2
zhangwei1984@nimbnode21:~/clickos/clickvms$ sudo /home/zhangwei1984/clickos/xennet/netmap/examples/vale-ctl -l bdg_ctl [98] bridge:0 port:0 vale0:p2p2
zhangwei1984 commented 8 years ago

solved. By adding the path environment in bashrc, it does not work. Have to hardcoded to the script.