cnplab / xennet

Xen optimizations for fast packet I/O
Other
11 stars 7 forks source link

Please help me with installing xennet #8

Closed pengminjiong closed 9 years ago

pengminjiong commented 9 years ago

I wanna to install xennet. after I finished "Getting Started"in cnp.neclab.eu/getting-started。 I follow your suggestion in other issue by using "xenstore-ls | grep feature-netmap" but got "feature-netmap='0' ".(you said it means patches did not be compiled well ) I used "lsmod | grep xen_netback " I got "module / size / used by " xen_netback /408430/ /0 netmap_lin / ... / /1 xen_netback

my kernel version is 3.13 (you mentioned it is ok to compile xennet)

Problem 2 cannot insmod xen-netfront.ko Error: Driver 'vif ' us already registered, aborting...... Then I tried "modprobe -r xen_netfront" FATAL: Module xen_netfront is builtin. I do wrote "blacklist netfront" into the right file.

Please help me

skuenzer commented 9 years ago

Hi,

as far as I can see from your lsmod output, I can see that your xen_netback is compiled with netmap support enabled.

What I don't understand is your setup and what you are trying to do (e.g., ClickOS guest). Where do you run xen_netfront? On Dom0? How do you instantiate the guest? How does your network topology looks like? ... Can you give me more details (inclusive guest Domain config) so that I can understand your issue?

Thanks!

pengminjiong commented 9 years ago

Thank you for your reply. In a nutshell , I have two problems , please help me.
Problem 1: I want to test clickos with high performance. I installed clickos and compiled xennet. cannot insmod xen-netfront. I want to insmod netback and netfront that can be used by Clickos. What should I do ? I tried to run xen_netfront and xen_netback in Dom0 because I think it could be used by clickos if I installed them in Dom0.
(use clickos as a transmit router) 1.click FromDevice(0)->ToDevice(1)

vale-ctl -a vale0:eth1 vale-ctl -a vale1:eth2

1.cfg name ='clickos' kernel=/root/clickos_x86_64 click ='mirror.click' vif =['mac= ,bridge=vale0, script=/etc/xen/script/vif-vale', 'mac= ,bridge=vale1,scripts=/etc/xen/script/vif-vale']

xenstore-ls | grep feature-netmap

feature-netmap='1' feature-netmap-tx-desc = '1024' feature-netmap-rx-desc='1024' feature-netmap='1' feature-netmap-tx-desc = '1024' feature-netmap-rx-desc='1024' it is the right output?

Problem 2: how to do port forwarding in VALE(I followed the process in"getting started ,VALE Extensions" )but failed in "Attaching a module to a switch". after make bdgfnctl , I tried "./bdgfnctl ips regfn --bridge=0 --port=257" I got : bgdfn: No such file or directory /dev/ips:bdgfn_do [97] cannot register vale32734 noterror unkonw command --bridge=0 . Then I thought I forget to "ismod ip_static.ko" but after insmoded it . I got "ERROR unknown symbol in module. I thought the possible reason was I did not compile kernel from source(only apt-get source). In the end , I compiled linux-3.14 but the same output " ERROR unknown symbol in module" when I want to insert ip_static.ko.

Please help me.

skuenzer commented 9 years ago

Your output looks good, as far as I can see. Be aware that - according to your Click configuration - you can now only send traffic in a single direction. You can try using pkt-gen (in netmap examples direction) to generate and retrieve packets. Can you send me your output of vale-ctl after you created your guest VM and attach your physical interface to vale? For standard packet forwording between switch ports, you do not need to do anything with bdgfnctl. Per default, vale is working as a L2 learning bridge. Btw, you also do not need xen-netfront for Dom0. You use this only for a Linux guest on Xen.

pengminjiong commented 9 years ago

Thank you a lot for your replying. I really appreciate for your time. sorry for the late , here is the output of vale-ctl after created clickos. bdg_ctl [98] bridge:0 port:0 vale0:p2p1 bdg_ctl [98] bridge:0 port:1 vale0:vif12.0 bdg_ctl [98] bridge:1 port:0 vale1:p3p1 bdg_ctl [98] bridge:1 port:1 vale1:vif12.1

I tested the" Wire (WR): A simple “middlebox” which sends pack- ets from its input to its output interface. This configura- tion serves to give a performance baseline."(from your paper " ClickOS and the Art of Network Function Virtualization" ) , I almost get the same result .(click configuration file of this test "FromDevice(0)->ToDevice(1)) The output of console is as follows: Xen Minimal OS! start_info: 0x1cb000(VA) nr_pages: 0x2000 shared_inf: 0xcb0aa000(MA) pt_base: 0x1ce000(VA) nr_pt_frames: 0x5 mfn_list: 0x1bb000(VA) mod_start: 0x0(VA) mod_len: 0 flags: 0x0 cmd_line: stack: 0x178040-0x198040 MM: Init _text: 0x0(VA) _etext: 0xe163d(VA) _erodata: 0x15e000(VA) _edata: 0x15fbb8(VA) stack start: 0x178040(VA) _end: 0x1ba010(VA) start_pfn: 1d6 max_pfn: 2000 Mapping memory range 0x400000 - 0x2000000 setting 0x0-0x15e000 readonly skipped 0x1000 MM: Initialise page allocator for 1e4000(1e4000)-2000000(2000000) MM: done Demand map pfns at 2001000-2002001000. Heap resides at 2002002000-4002002000. Initialising timer interface Initialising console ... done. gnttab_table mapped at 0x2001000. Initialising scheduler Thread "Idle": pointer: 0x2002002050, stack: 0x1f0000 Thread "xenstore": pointer: 0x2002002800, stack: 0x200000 xenbus initialised on irq 1 mfn 0x431325 Thread "shutdown": pointer: 0x2002002fb0, stack: 0x210000 Dummy main: start_info=0x198040 Thread "main": pointer: 0x2002003760, stack: 0x220000 sparsing 0MB at 177000 "main" [on_status:205] router id 0 [on_status:206] status change to Running Thread "click": pointer: 0x2002010a00, stack: 0x240000 backend dom 0 Mapping TX rings 0 map errors Mapping RX rings 0 map errors Mapping TX buffers 0 map errors Mapping RX buffers 0 map errors init_netfront_netmap device/vif/0 Waiting for /local/domain/0/backend/vif/13/0/state change to connected unmasking event-channel-tx 4 unmasking event-channel-rx 5 backend dom 0 Mapping TX rings 0 map errors Mapping RX rings 0 map errors Mapping TX buffers 0 map errors Mapping RX buffers 0 map errors init_netfront_netmap device/vif/1 Waiting for /local/domain/0/backend/vif/13/1/state change to connected unmasking event-channel-tx 6 unmasking event-channel-rx 7 [router_thread:157] Starting driver...

but my problem this time is I got a very low performance when I tried ether mirror test (click configuration file of that test "FromDevice(0)->EtherMirror-> ToDevice(1)") In all tests , clickos configuration file is the same as mentioned above. Hope you can help me.