Table of Contents
Network Configuration: Results
EG-253 | Practical Internet Technology II |
---|---|
Name | Craig Menzies |
Student Number | 366938 |
Date of Submission |
Instructions
This wiki page allows you to record the results of your network configuration exercise. You may need to refer to the configuration handout to complete this document.
Answer all questions based on the host that you are configuring in the lab. Edit this wiki page directly to insert your answers. You will probably find this most convenient to do at the same time as you perform the configuration. Where requested, please include listings of the actual configuration files and command outputs directly in the document. Placeholders have been provided for this purpose. Please follow the formatting hints given in the text.
When the exercise is complete you should sign and submit it in for marking. Deadline for completion is the start of the lab on the last week of this term.
This exercise is worth 20% of the module marks.
Host Configuration
Question 1
Which Linux command gives you information about your computer's name on the network?
Answer (delete as appropriate):
hostname
Question 2
Use the command selected in Question 1 to determine your host computer's name? What is the name?
Answer:
titan
Question 3
Which configuration file would you need to edit to change your computer's name on the network?
Your answer (one of):
/etc/hostname
Question 4
Which linux command gives you information on your host's network settings?
Answer one of:
ifconfig
Question 5
Use the command selected in Question 4 to complete the following table:
Feature | Value |
---|---|
My host's IP address | 192.168.3.4 |
My network's IP address | 192.168.2.0 (wrong!) |
The address used by my host to send an IP packet to all hosts on my network | 192.168.3.255 |
The netmask of my host | 255.255.255.0 |
The hardware address (MAC Address) of my LAN-facing network interface connection (NIC)1) | 00:10:5A:39:82:B4 |
The frame-level (layer 1) protocol is used to send network messages to the network from my host? | Ethernet |
Question 6
How many hosts can the sub-net defined by your host's netmask support?
Answer one of:
254
Question 7
What class of network is the sub-net to which your host has been assigned?
Answer one of:
Class C
Network Configuration
Answer the following questions about your network configuration. Please copy and paste the contents of the files identified in Questions 8 and 11 to your submission.
Question 8
In which file is the configuration of your Network Interface Controller (NIC) configured?
Answer one of:
/etc/hosts
Please include a listing of the file chosen in answer to Question 8:
# /etc/hosts -- Hosts file for ICCT Private network # # IP FQDN aliases # 127.0.0.1 localhost.localdomain localhost myhost # 192.168.1.1 solaris.icct.co solaris inet-gateway 192.168.1.2 venus.icct.com venus www # Jupiter cluster # 192.168.1.3 gw-jupiter.icct.com gw-planets jupiter-if1 192.168.2.1 jupiter.icct.com jupiter jupiter-if2 192.168.2.2 callisto.jupiter.icct.com callisto 192.168.2.3 europa.jupiter.icct.com europa 192.168.2.4 ganymede.jupiter.icct.com ganymede # # Saturn cluster # 192.168.1.4 gw-saturn.icct.com gw-saturn saturn-if1 192.168.3.1 saturn.icct.com saturn saturn-if2 192.168.3.2 dione.saturn.icct.com dione 192.168.3.3 tethys.saturn.icct.com tethys 192.168.3.4 titan.saturn.icct.com titan # # Add other hosts/clusters below here # (we'll use this to add virtual hosts to the web-server in a later # lab exercise) 127.0.0.1 localhost 127.0.1.1 titan
# The following lines are desirable for IPv6 capable hosts ::1 ip6-localhost ip6-loopback fe00::0 ip6-localnet ff00::0 ip6-mcastprefix ff02::1 ip6-allnodes ff02::2 ip6-allrouters ff02::3 ip6-allhosts
Question 9
What is the IP address of the host which serves as the default gateway for your network?
Answer: 192.168.1.4 no must be on 192.168.3.0 network!)
Question 10
What is the hostname of the gateway interface?
Answer: gw-saturn saturn-if1 no saturn is the default gateway!
Question 11
In which file is the symbolic names of the networks, hosts and interfaces available on the network defined?
Answer one of:
/etc/hosts
Please include a listing of the file chosen in answer to Question 11:
Copy contents of file and paste it as a listing here. Include a minumum indent of two spaces per line. Like this.
# /etc/hosts -- Hosts file for ICCT Private network # # IP FQDN aliases # 127.0.0.1 localhost.localdomain localhost myhost # 192.168.1.1 solaris.icct.co solaris inet-gateway 192.168.1.2 venus.icct.com venus www # # Jupiter cluster # 192.168.1.3 gw-jupiter.icct.com gw-planets jupiter-if1 192.168.2.1 jupiter.icct.com jupiter jupiter-if2 192.168.2.2 callisto.jupiter.icct.com callisto 192.168.2.3 europa.jupiter.icct.com europa 192.168.2.4 ganymede.jupiter.icct.com ganymede # # Saturn cluster # 192.168.1.4 gw-saturn.icct.com gw-saturn saturn-if1 192.168.3.1 saturn.icct.com saturn saturn-if2 192.168.3.2 dione.saturn.icct.com dione 192.168.3.3 tethys.saturn.icct.com tethys 192.168.3.4 titan.saturn.icct.com titan # # Add other hosts/clusters below here # (we'll use this to add virtual hosts to the web-server in a later # lab exercise) 127.0.0.1 localhost 127.0.1.1 titan
# The following lines are desirable for IPv6 capable hosts ::1 ip6-localhost ip6-loopback fe00::0 ip6-localnet ff00::0 ip6-mcastprefix ff02::1 ip6-allnodes ff02::2 ip6-allrouters ff02::3 ip6-allhosts
Question 12
What is the symbolic name of your network's gateway interface?
Answer: gw-saturn.icct.com
Question 13
What is the purpose of the Gateway interface?
Answer: To link my network to other networks
Question 14
Which linux command shows the routing table for your host?
Answer: route -n
Run the command identified in Question 14 and reproduce its output here.
Answer Kernel IP routeing table
Destination Gateway Genmask Flags Metric Ref Use Iface 192.168.3.0 0.0.0.0 255.255.255.0 U 0 0 0 eth0 169.254.0.0 0.0.0.0 255.255.0.0 U 1000 0 0 eth0 0.0.0.0 192.168.3.1 0.0.0.0 UG 0 0 0 eth0
<cli prompt=“$” comment=“#”> user@host:~$ command # Copy command and its output and paste it here. </cli>
Question 15
How many interfaces (NICs) must a router have?
Answer one of:
3 or more (no 2 or more! ! in and 1 out)
Question 16
Which system feature must be turned on if you want a Linux host to act as a router?
Answer: ip forwarding
Question 17
Which run-time command can be used to make a Ubuntu Linux host act as a router?
Answer: sudo sh -c “echo 1 > /proc/sys/net/ipv4/ip_forward”
Question 18
In which file is the setting defined in Question 17 set if you want a Ubuntu host to be configured as a router at boot-time?
Answer: /etc/network/if-up.d/router
Reproduce the contents of the file defined in Question 17 to make a Ubuntu host into a router?
Answer
Copy contents of file and paste it as a listing here. Include a minumum indent of two spaces per line. Like this.
#!/bin/sh
#enable ip forwarding
echo 1 > /proc/sys/net/ipv4/ip_forward
Question 19
No – need the file that has if up route an if down route!
What setting has been added to the network configuration file to define a route to icct-net
from your sub-network's cluster-server?
Answer:
Copy contents of file and paste it as a listing here. Include a minumum indent of two spaces per line. Like this.
auto lo iface lo inet loopback
auto eth0 iface eth0 inet static address 192.168.3.4 network 192.168.3.0 netmask 255.255.255.0 gateway 192.168.3.1
auto eth1 iface eth1 inet dhcp
auto eth2 iface eth2 inet dhcp
auto ath0 iface ath0 inet dhcp
auto wlan0 iface wlan0 inet dhcp
Checking Your Network
The Linux command netstat
gives a lot of useful information on your network. In the following 3 questions, reproduce the output of various usages of netstat. You should annotate your results with a brief explanation of what they mean. You may need to print the output and attach to the submission.
Question 20
Give and explain the output of the command netstat -r
.
Answer <cli prompt=“$” comment=“#”> user@host:~$ netstat -r # Paste result here….
Kernel IP routeing table Destination Gateway Genmask Flags MSS Window irtt Iface saturn-net * 255.255.255.0 U 0 0 0 eth0 link-local * 255.255.0.0 U 0 0 0 eth0 default saturn.icct.com 0.0.0.0 UG 0 0 0 eth0
</cli>
Add your explanation here:
Question 21
Give and explain the output of the command netstat -i
.
Answer <cli prompt=“$” comment=“#”> user@host:~$ netstat -r # Paste result here….
Kernel Interface table Iface MTU Met RX-OK RX-ERR RX-DRP RX-OVR TX-OK TX-ERR TX-DRP TX-OVR Flg eth0 1500 0 4310 718 0 2 4515 0 0 0 BMRU lo 16436 0 2 0 0 0 2 0 0 0 LRU
</cli>
Add your explanation here.
Question 22
Give and explain the output of the command netstat -ta
.
Answer <cli prompt=“$” comment=“#”> user@host:~$ netstat -r # Paste result here….
Active Internet connections (servers and established) Proto Recv-Q Send-Q Local Address Foreign Address State tcp 0 0 localhost.localdom:2208 *:* LISTEN tcp 0 0 localhost.localdoma:ipp *:* LISTEN tcp 0 0 localhost.localdom:2207 *:* LISTEN
</cli>
Add your explanation here.
Testing the Connectivity of your network
Install, if necessary, the traceroute command then answer the following two questions.
Question 23
Give the output of traceroute from your host to any host on one of the other ICCT networks.
Answer <cli prompt=“$” comment=“#”> user@host:~$ command # paste output here
traceroute to europa.jupiter.icct.com (192.168.2.3), 30 hops max, 40 byte packets 1 saturn.icct.com (192.168.3.1) 1.332 ms 0.135 ms 1.198 ms 2 gw-jupiter.icct.com (192.168.1.3) 7.015 ms 2.383 ms 0.230 ms 3 europa.jupiter.icct.com (192.168.2.3) 2.553 ms 0.339 ms 2.493 ms
</cli>
Question 24
Give the output of traceroute
from your host to www.swan.ac.uk
Answer <cli prompt=“$” comment=“#”> user@host:~$ command # paste output here
traceroute to www.swan.ac.uk (137.44.1.7), 30 hops max, 40 byte packets 1 saturn.icct.com (192.168.3.1) 1.287 ms 0.180 ms 1.194 ms 2 * * * 3 * * * 4 * * *
</cli>
Explain the result.
There are no packets coming back as they are not accepted!
Extension Questions
Question 25
A new sub-network engineering-net (192.168.10.0/24
) is to be added to the ICCT network. Host engineering (192.168.10.1/32
) is a cluster server for this new network. Give the settings needed to set up this host as a router to icct-net
, jupiter-net
, and saturn-net
and a gateway for engineering-net
.
Answer
# Server venus is a host on icct-net. It needs to know about # the rest of the network so that it can return messages to the # saturn and jupiter subnets. auto eth0 iface eth0 inet static address 192.168.10.1 network 192.168.10.0 # member of icct-net netmask 255.255.255.0 gateway 192.168.10.15 # default gateway is solaris # Route to jupiter-net up route add -net 192.168.2.0 netmask 255.255.255.0 gw 192.168.1.3 down route add -net 192.168.2.0 netmask 255.255.255.0 gw 192.168.1.3 # Route to saturn-net up route add -net 192.168.3.0 netmask 255.255.255.0 gw 192.168.1.4 down route add -net 192.168.3.0 netmask 255.255.255.0 gw 192.168.1.4
# Interface fpr engineering auto eth0 iface eth1 inet static address 192.168.10.1 network 255.255.255.0
Question 26
Which other files would you need to modify to correctly set up this new router?
Answer /etc/network/interfaces in saturn jupiter and venus
Question 27
Summarize the changes that you would you need to make to your host's network configuration to have the new engineering sub-network recognized?
Answer We need an engineering-net file in etc/networks and we need to list the hosts and gateway in the host file.
Signature
I hereby submit this work for marking.
Your signature here: C.Menzies - 366938