| 24 | |
| 25 | ==== Setting up Network Interfaces ==== |
| 26 | |
| 27 | - Select the !NetMon VM from left panel on Virtual box, right click and open '''Settings''' |
| 28 | - Click on the '''Network''' title |
| 29 | - On '''Adapter 1''' check the '''Enable Network Adapter''' . Then change '''Attached to be''' to the '''Bridged Adapter''' and make sure the '''name''' of the interface is the same interface which you use to connect to the outside (Either Wi-Fi or Ethernet). This virtual interface will work as the WAN port of the of your virtual campus network that can be used to connect from out side. |
| 30 | - Click on '''Advanced''' drop down list and change the '''promiscuous mode''' to '''Allow All''' |
| 31 | - Click '''OK''' |
| 32 | |
| 33 | ==== CampusLAN VM ==== |
| 34 | |
| 35 | Before running Dynagen you have to start your VMs and assign IP address to the VM's network interfaces. |
| 36 | |
| 37 | - Select the '''CampusLAN''' VM from left panel on Virtual box, right click '''Start''' and wait till the VM starts |
| 38 | - login to the machine using the following user credentials |
| 39 | {{{ |
| 40 | usrname : learn |
| 41 | password : <classpassword> |
| 42 | }}} |
| 43 | - Then change the '''interfaces''' file. Root password is the same as class password |
| 44 | {{{ |
| 45 | sudo vi /etc/network/interfaces |
| 46 | }}} |
| 47 | - locate the following lines |
| 48 | {{{ |
| 49 | iface enp0s3 inet static |
| 50 | address 192.168.56.2 |
| 51 | netmask 255.255.255.0 |
| 52 | network 192.168.56.0 |
| 53 | broadcast 192.168.56.255 |
| 54 | gateway 192.168.56.1 |
| 55 | dns-nameservers 192.248.1.161 |
| 56 | }}} |
| 57 | - Change it to the following lines. You can find your IP Address from this [wiki:2017netmonipallocation table] |
| 58 | {{{ |
| 59 | iface enp0s3 inet static |
| 60 | address <Your IP Address > |
| 61 | netmask 255.255.255.0 |
| 62 | network 192.248.6.0 |
| 63 | broadcast 192.248.6.255 |
| 64 | gateway 192.248.6.254 |
| 65 | dns-nameservers 192.248.1.161 |
| 66 | }}} |
| 67 | - Save and Exit the editor (type ''':wq''') |
| 68 | - When you completed the IP settings , reboot the machine |
| 69 | {{{ |
| 70 | sudo reboot |
| 71 | }}} |
| 72 | - Confirm the correct IP settings by '''ifconfig''' command. Your result should be something like the following. Check the IP address of enp0s3 Interface and see whether the other interfaces are up |
| 73 | {{{ |
| 74 | enp0s3 Link encap:Ethernet HWaddr 08:00:27:8c:e0:26 |
| 75 | inet addr:<your IP address> Bcast:192.248.6.255 Mask:255.255.255.0 |
| 76 | inet6 addr: fe80::a00:27ff:fe8c:e026/64 Scope:Link |
| 77 | UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 |
| 78 | RX packets:1120 errors:0 dropped:0 overruns:0 frame:0 |
| 79 | TX packets:7550 errors:0 dropped:0 overruns:0 carrier:0 |
| 80 | collisions:0 txqueuelen:1000 |
| 81 | RX bytes:99387 (99.3 KB) TX bytes:567441 (567.4 KB) |
| 82 | |
| 83 | enp0s8 Link encap:Ethernet HWaddr 08:00:27:f0:f7:66 |
| 84 | inet6 addr: fe80::a00:27ff:fef0:f766/64 Scope:Link |
| 85 | UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 |
| 86 | RX packets:0 errors:0 dropped:0 overruns:0 frame:0 |
| 87 | TX packets:8 errors:0 dropped:0 overruns:0 carrier:0 |
| 88 | collisions:0 txqueuelen:1000 |
| 89 | RX bytes:0 (0.0 B) TX bytes:648 (648.0 B) |
| 90 | |
| 91 | enp0s9 Link encap:Ethernet HWaddr 08:00:27:51:68:d3 |
| 92 | inet6 addr: fe80::a00:27ff:fe51:68d3/64 Scope:Link |
| 93 | UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 |
| 94 | RX packets:0 errors:0 dropped:0 overruns:0 frame:0 |
| 95 | TX packets:8 errors:0 dropped:0 overruns:0 carrier:0 |
| 96 | collisions:0 txqueuelen:1000 |
| 97 | RX bytes:0 (0.0 B) TX bytes:648 (648.0 B) |
| 98 | |
| 99 | lo Link encap:Local Loopback |
| 100 | inet addr:127.0.0.1 Mask:255.0.0.0 |
| 101 | inet6 addr: ::1/128 Scope:Host |
| 102 | UP LOOPBACK RUNNING MTU:65536 Metric:1 |
| 103 | RX packets:160 errors:0 dropped:0 overruns:0 frame:0 |
| 104 | TX packets:160 errors:0 dropped:0 overruns:0 carrier:0 |
| 105 | collisions:0 txqueuelen:1 |
| 106 | RX bytes:11840 (11.8 KB) TX bytes:11840 (11.8 KB) |
| 107 | }}} |
| 108 | - Try ping to some known hosts and see the results. |
| 109 | {{{ |
| 110 | ping 192.248.6.254 |
| 111 | ping 192.248.1.161 |
| 112 | ping www.google.com |
| 113 | }}} |