Mailing List Archive

[Bug] Error when running network-attach
Hi,
When I try to add a network with xl network-attach command,
the log show some errors:
root@RK3588:/mnt# xl network-attach 0
libxl: error: libxl_xshelp.c:201:libxl__xs_read_mandatory: xenstore read failed: `/libxl/0/type': No such file or directory
libxl: warning: libxl_dom.c:52:libxl__domain_type: unable to get domain type for domid=0, assuming HVM
[ 50.081420] rockchip-thermal fec00000.tsadc: Missing rockchip,grf property
[ 50.081631] rockchip-thermal fec00000.tsadc: failed to register sensor 0: -517
[ 50.081667] rockchip-thermal fec00000.tsadc: failed to register sensor[0] : error = -517
[ 50.104335] rockchip-thermal fec00000.tsadc: Missing rockchip,grf property
[ 50.104507] rockchip-thermal fec00000.tsadc: failed to register sensor 0: -517
[ 50.104544] rockchip-thermal fec00000.tsadc: failed to register sensor[0] : error = -517
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 1 to 2 frames
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 2 to 3 frames
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 3 to 4 frames
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 4 to 5 frames
[ 50.155613] xen_netfront: backend supports XDP headroom
[ 50.189706] vif vif-0-0 vif0.0: Guest Rx ready
libxl: error: libxl_exec.c:117:libxl_report_child_exitstatus: /etc/xen/scripts/vif-bridge online [1044] exited with error status 1
libxl: error: libxl_device.c:1259:device_hotplug_child_death_cb: script: Could not find bridge device xenbr0
libxl: error: libxl_device.c:1402:device_addrm_aocomplete: Unable to add vif with id 0
libxl_device_nic_add failed.
root@RK3588:/mnt# (XEN) gnttab_mark_dirty not implemented yet
what does vif-bridge exited with error status 1 mean?
"Could not find bridge device xenbr0", is that means I have to create a xenbr0?How to create?
I create a domu with the config below:
kernel = "/media/sdcard0/domu-Image"
memory = 1024
name = "guest1"
vcpus = 2
serial="pty"
vif = ['']
disk = [ 'phy:/dev/mmcblk2p2,xvda,w' ]
extra = 'console=hvc0 root=/dev/xvda rw clk_ignore_unused'
There also has the same error log above, although the network can work.
dom0 and domu can ping each other successfully.
But the network type seems is NAT, How can I set up a bridged networking ?
Best regards
Cailigang
Re: [Bug] Error when running network-attach [ In reply to ]
Hi, 

you probably need to set up the bridge xenbr0 (default name) manually in Dom0. Please have a look at

https://xenbits.xen.org/docs/unstable/man/xl-network-configuration.5.html#bridge

and

https://wiki.xenproject.org/wiki/Network_Configuration_Examples_(Xen_4.1%2B) 

There seem to be other errors in your log which I can't diagnose.

Paul



 

________________________________
Von: ??? <cai_ligang@gmechina.com.cn>
Gesendet: Montag, 6. Februar 2023 09:53
An: xen-users
Betreff: [Bug] Error when running network-attach

Hi,

When I try to add a network with xl network-attach command,
the log show some errors:

root@RK3588:/mnt# xl network-attach 0
libxl: error: libxl_xshelp.c:201:libxl__xs_read_mandatory: xenstore read failed: `/libxl/0/type': No such file or directory
libxl: warning: libxl_dom.c:52:libxl__domain_type: unable to get domain type for domid=0, assuming HVM
[   50.081420] rockchip-thermal fec00000.tsadc: Missing rockchip,grf property
[   50.081631] rockchip-thermal fec00000.tsadc: failed to register sensor 0: -517
[   50.081667] rockchip-thermal fec00000.tsadc: failed to register sensor[0] : error = -517
[   50.104335] rockchip-thermal fec00000.tsadc: Missing rockchip,grf property
[   50.104507] rockchip-thermal fec00000.tsadc: failed to register sensor 0: -517
[   50.104544] rockchip-thermal fec00000.tsadc: failed to register sensor[0] : error = -517
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 1 to 2 frames
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 2 to 3 frames
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 3 to 4 frames
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 4 to 5 frames
[   50.155613] xen_netfront: backend supports XDP headroom
[   50.189706] vif vif-0-0 vif0.0: Guest Rx ready
libxl: error: libxl_exec.c:117:libxl_report_child_exitstatus: /etc/xen/scripts/vif-bridge online [1044] exited with error status 1
libxl: error: libxl_device.c:1259:device_hotplug_child_death_cb: script: Could not find bridge device xenbr0
libxl: error: libxl_device.c:1402:device_addrm_aocomplete: Unable to add vif with id 0
libxl_device_nic_add failed.
root@RK3588:/mnt# (XEN) gnttab_mark_dirty not implemented yet

what does vif-bridge exited with error status 1 mean?
"Could not find bridge device xenbr0", is that means I have to create a xenbr0?How to create?

I create a domu with the config below:
kernel = "/media/sdcard0/domu-Image"
memory = 1024
name = "guest1"
vcpus = 2
serial="pty"
vif = ['']
disk = [ 'phy:/dev/mmcblk2p2,xvda,w' ]
extra = 'console=hvc0 root=/dev/xvda rw clk_ignore_unused'

There also has the same error log above, and domu bring up failed.
If delete vif option. domu can bring up. and using network-attach create a network.
The network can work, dom0 and domu can ping each other successfully.
But the network type seems is NAT, How can I set up a bridged networking ?

Best regards
Cailigang

________________________________
Von: ??? <cai_ligang@gmechina.com.cn>
Gesendet: Montag, 6. Februar 2023 09:53
An: xen-users
Betreff: [Bug] Error when running network-attach

Hi,
When I try to add a network with xl network-attach command,
the log show some errors:
root@RK3588:/mnt# xl network-attach 0
libxl: error: libxl_xshelp.c:201:libxl__xs_read_mandatory: xenstore read failed: `/libxl/0/type': No such file or directory
libxl: warning: libxl_dom.c:52:libxl__domain_type: unable to get domain type for domid=0, assuming HVM
[ 50.081420] rockchip-thermal fec00000.tsadc: Missing rockchip,grf property
[ 50.081631] rockchip-thermal fec00000.tsadc: failed to register sensor 0: -517
[ 50.081667] rockchip-thermal fec00000.tsadc: failed to register sensor[0] : error = -517
[ 50.104335] rockchip-thermal fec00000.tsadc: Missing rockchip,grf property
[ 50.104507] rockchip-thermal fec00000.tsadc: failed to register sensor 0: -517
[ 50.104544] rockchip-thermal fec00000.tsadc: failed to register sensor[0] : error = -517
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 1 to 2 frames
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 2 to 3 frames
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 3 to 4 frames
(XEN) grant_table.c:1869:d0v1 Expanding d0 grant table from 4 to 5 frames
[ 50.155613] xen_netfront: backend supports XDP headroom
[ 50.189706] vif vif-0-0 vif0.0: Guest Rx ready
libxl: error: libxl_exec.c:117:libxl_report_child_exitstatus: /etc/xen/scripts/vif-bridge online [1044] exited with error status 1
libxl: error: libxl_device.c:1259:device_hotplug_child_death_cb: script: Could not find bridge device xenbr0
libxl: error: libxl_device.c:1402:device_addrm_aocomplete: Unable to add vif with id 0
libxl_device_nic_add failed.
root@RK3588:/mnt# (XEN) gnttab_mark_dirty not implemented yet
what does vif-bridge exited with error status 1 mean?
"Could not find bridge device xenbr0", is that means I have to create a xenbr0?How to create?
I create a domu with the config below:
kernel = "/media/sdcard0/domu-Image"
memory = 1024
name = "guest1"
vcpus = 2
serial="pty"
vif = ['']
disk = [ 'phy:/dev/mmcblk2p2,xvda,w' ]
extra = 'console=hvc0 root=/dev/xvda rw clk_ignore_unused'
There also has the same error log above, and domu bring up failed.
If delete vif option. domu can bring up. and using network-attach create a network.
The network can work, dom0 and domu can ping each other successfully.
But the network type seems is NAT, How can I set up a bridged networking ?
Best regards
Cailigang
Re: [Bug] Error when running network-attach [ In reply to ]
Hi Paul,
Sorry, I did not receive your email. I found the mail through https://xen.markmail.org/.
I sloved the network-attach error problem.
You posted some offical manuals that I have been seen before, But not work for me.
So I write down my solution, that might help others.
The solution work on arm platform(rk3588).
1. config kernel menuconfig to support ethernet bridging.
[*] Networking support --->
Networking options --->
<*> 802.1d Ethernet Bridging
[*] IGMP/MLD snooping (NEW)
2. manul create bridge xenbr0
#ip link add xenbr0 type bridge
#ip link set eth0 master xenbr0
#ip link set xenbr0 up
#ip addr add dev xenbr0 172.16.1.100/24
3. domu.conf add config vif
vif = ['']
or
vif = [ 'bridge=xenbr0' ]
4. use xl create -c domu.conf to bring up.
Best regards
Cailigang