diff options
author | Ilias Apalodimas <ilias.apalodimas@linaro.org> | 2017-08-28 11:04:40 +0300 |
---|---|---|
committer | Ilias Apalodimas <ilias.apalodimas@linaro.org> | 2017-08-28 11:04:40 +0300 |
commit | 729241e96b67e4a1f02ecc7bb12b525823edcdae (patch) | |
tree | 99d56758f1ec29ca566d8ffd7f968cb97d73b3f0 | |
parent | 14b9fa3da83462070647869638db28de805efb84 (diff) |
Added README examples
-rw-r--r-- | README.md | 16 | ||||
-rwxr-xr-x | netmap/scripts/netmap.sh | 2 |
2 files changed, 14 insertions, 4 deletions
@@ -4,8 +4,18 @@ Create VM images using packer.io ## Installation 1. Install packer <https://www.packer.io/> -2. Got to the selected directory and run build.sh some-file.json. cd netmap ./build.sh debian-9.0.0.json +2. Go to the selected directory and run build.sh some-file.json. +Example: cd netmap ./build.sh debian-9.0.0.json ## Generated images boot examples -1. `qemu-system-x86_64 -m 4G -smp 4 -drive file="replace-generated-image",if=virtio -enable-kvm -cpu host` -2. `qemu-system-x86_64 -m 4G -smp 8 -device e1000,netdev=net0 -netdev tap,id=net0 -drive file=tester,if=virtio -enable-kvm -cpu host` +1. Launch guest in simple mode(guess will access the internet) +`qemu-system-x86_64 -m 4G -smp 4 -drive file=GENERATED_IMAGE,if=virtio -enable-kvm -cpu host` +2. Launch guest TAP/TUN mode(tap0 will appear on host OS) +`qemu-system-x86_64 -m 4G -smp 8 -device e1000,netdev=net0 -netdev tap,id=net0 +-drive file=GENERATED_IMAGE,if=virtio -enable-kvm -cpu host` +3. Launch guest netmap/VALE mode(requires custom QEMU with netmap support) +Replace VALE-X with 0,1,2... for multiple VALE-connected guests +`qemu-system-x86_64 -m 4G -smp 8 -device e1000,netdev=net0 +-netdev netmap,id=net0,ifname=vale0:VALE-X -drive +file=/home/apalos/work/packer.io-images/netmap/output-tester/tester2,if=virtio +-enable-kvm -cpu host` diff --git a/netmap/scripts/netmap.sh b/netmap/scripts/netmap.sh index ef21537..d681593 100755 --- a/netmap/scripts/netmap.sh +++ b/netmap/scripts/netmap.sh @@ -3,6 +3,6 @@ tar xf /usr/src/linux-source-*.tar.xz git clone https://github.com/luigirizzo/netmap cd netmap -./configure --kernel-sources=/home/packer/linux-source-4.9 +./configure --kernel-sources=$HOME/linux-source-4.9 make -j 16 sudo make install |