picoserver and qemu
Hi, I am trying to test picoserver app in qemu, but I am not able to connect to the echo component on port 1234. These are the steps I am following, please, let me know if I am doing something wrong. Thanks in advance: $ repo init -u https://github.com/seL4/camkes-manifest.git $ repo sync # use docker container to compile $ container @in-container:/host$ mkdir build @in-container:/host$ cd build @in-container:/host$ ../init_build.sh -DCAMKES_APP=picoserver -DPICOSERVER_IP_ADDR=127.0.0.1 -DSIMULATION=1 @in-container:/host$ ninja Everything seems to be ok, but when I tried to execute in qemu: $ sudo ./simulate --machine q35,accel=kvm,kernel-irqchip=split --mem-size 2G --extra-cpu-opts "+vmx" --extra-qemu-args="--enable-kvm -device intel-iommu,intremap=on,caching-mode=on -netdev user,id=network0,hostfwd=tcp::1234-:1234 -device e1000e,netdev=network0" It seems the echo component is listening on port 1234, but if I try to send data with "netcat 127.0.0.1 1234" I can't reach the echo component ...... IOMMU 0x0: enabling... enabled Booting all finished, dropped to user space Protocol ethernet registered (layer: 2). Protocol ipv4 registered (layer: 3). Protocol ipv6 registered (layer: 3). Protocol icmp4 registered (layer: 4). Protocol icmp6 registered (layer: 4). Protocol igmp registered (layer: 4). Protocol udp registered (layer: 4). Protocol tcp registered (layer: 4). listener instance starting up, going to be listening on 192.168.0.21:4321 echo instance starting up, going to be listening on 192.168.0.21:1234
"lfern70" == lfern70
writes:
lfern70> Everything seems to be ok, but when I tried to execute in lfern70> qemu: lfern70> $ sudo ./simulate ... -netdev user,id=network0,hostfwd=tcp::1234-:1234 I think you need to say what address range QEMU thinks the network is on. So add net=192.168.0.21/24 into the -netdev arg. Peter C -- Dr Peter Chubb https://trustworthy.systems/ Trustworthy Systems Group CSE, UNSW
Thanks, Peter, but it still doesn't work. It must be something really easy, but I am not able to find it: sudo ./simulate --machine q35,accel=kvm,kernel-irqchip=split --mem-size 2G --extra-cpu-opts "+vmx" --extra-qemu-args="--enable-kvm -device intel-iommu,intremap=on,caching-mode=on -netdev user,id=network0,net=192.168.0.21/24,hostfwd=tcp::1234-:1234 -device e1000e,netdev=network0"
If I enable log I get these last lines (but I don't think they are related to de ethernet driver): start_threads@main.c:1887 Starting threads... start_threads@main.c:1890 Starting echo_echo_0_control_tcb... start_threads@main.c:1890 Starting echo_echo_0_fault_handler_tcb... start_threads@main.c:1890 Starting ethdriver_ethdriver_0_control_tcb... start_threads@main.c:1890 Starting ethdriver_ethdriver_0_fault_handler_tcb... start_threads@main.c:1890 Starting ethdriver_ethdriver_client_0000_tcb... start_threads@main.c:1890 Starting ethdriver_ethdriver_irq_0000_tcb... start_threads@main.c:1890 Starting listener_listener_0_control_tcb... start_threads@main.c:1890 Starting listener_listener_0_fault_handler_tcb... start_threads@main.c:1890 Starting picoserver_picoserver_0_control_tcb... start_threads@main.c:1890 Starting picoserver_picoserver_0_fault_handler_tcb... start_threads@main.c:1890 Starting time_server_time_server_0_control_tcb... start_threads@main.c:1890 Starting time_server_time_server_0_fault_handler_tcb... start_threads@main.c:1890 Starting time_server_time_server_irq_0000_tcb... start_threads@main.c:1890 Starting time_server_time_server_the_timer_0000_tcb... init_system@main.c:2097 6629 of 131072 CSlots used (5.06%) main@main.c:2127 CapDL Loader done, suspending... Protocol ethernet registered (layer: 2). Protocol ipv4 registered (layer: 3). Protocol ipv6 registered (layer: 3). Protocol icmp4 registered (layer: 4). Protocol icmp6 registered (layer: 4). Protocol igmp registered (layer: 4). Protocol udp registered (layer: 4). Protocol tcp registered (layer: 4). listener instance starting up, going to be listening on :4321 sel4platsupport_get_num_pmem_regions@pmem.c:17 Could not find info echo instance starting up, going to be listening on :1234 acpi_sig_search@walker.c:87 Failed to map physical page 0xe0000 acpi_init@acpi.c:380 Failed to find rsdp
participants (2)
-
lfern70@gmail.com
-
Peter Chubb