User Tools

Site Tools


eg-253:networkq:670923

Network Configuration: Results

EG-253Practical Internet Technology II
Name Guo Ziwen
Student Number 670923
Date of Submission 29th November 2012

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

hostname 
 
 

Question 2

Use the command selected in Question 1 to determine your host computer's name? What is the name?

Answer: <cli>icct@carme:~$ hostname carme </cli>

I modified your answer to better reflect the actual output. No marks lost

Chris Jobling 2012/12/06 08:32

Question 3

Which configuration file would you need to edit to change your computer's name on the network?

Your answer (one of): /etc/hosts

/etc/hosts 

Question 4

Which linux command gives you information on your host's network settings?

Answer one of: ifconfig

 
ifconfig 
 

Question 5

Use the command selected in Question 4 to complete the following table:

Feature Value
My host's IP address 192.168.2.23
My network's IP address 192.168.2.255
The address used by my host to send an IP packet to all hosts on my network 192.168.2.255
The netmask of my host 255.255.255.0
The hardware address (MAC Address) of my LAN-facing network interface connection (NIC)1) fe80::219:d1ff:fe91:4ce8/64,00:19:d1:91:4c:e8
The frame-level (layer 1) protocol is used to send network messages to the network from my host? NO

Your network address is the bit-wise logical AND of your host IP address and the bitmask.

Your hardware address is 00:19:d1:91:4c:e8. The other address fe80::219:d1ff:fe91:4ce8/64 is the IPv6 address of your host.

Chris Jobling 2012/12/06 08:33

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/network/interfaces 
 

Please include a listing of the file chosen in answer to Question 8:

auto eth0
iface eth0 inet static
  address 192.168.2.23
  network 192.168.2.0
  netmask 255.255.255.0
  gateway 192.168.2.1

I had to reformat your answer. I didn't however deduct any marks

Chris Jobling 2012/12/06 08:37

Question 9

What is the IP address of the host which serves as the default gateway for your network?

Answer:

      gateway:192.168.3.1

Your answer does not agree with the answer for Q8!

Chris Jobling 2012/12/06 08:38

Question 10

What is the hostname of the gateway interface?

Answer:

       (JUPITER)

Yes but it's written jupiter

Chris Jobling 2012/12/06 08:38

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:

# /etc/hosts -- Hosts file for ICCT Private network
#
# IP          FQDN                       aliases 
#
127.0.0.1     localhost.localdomain      localhost carme
#
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.23  carme.jupiter.icct.com     guo carme
192.168.2.22  leda.jupiter.icct.com      jumana leda
#
# Saturn cluster

I had to format your answer so that it came out correctly. Ans as this was the second time (dispite isntructions been given) I deducted half a mark. The file is only half complete. Presumably because you loaded the file in nano and only copied the first page! Another mark lost for that

Chris Jobling 2012/12/06 08:40

Question 12

What is the symbolic name of your network's gateway interface?

Answer:

saturn.icct.com

No! Your host is on the jupiter network so the host would be jupiter.icct.com

Chris Jobling 2012/12/06 08:42

Question 13

What is the purpose of the Gateway interface?

Answer: “Identifies the device that allows local network computers to communicate with devices on other networks”. It is a way to pass a Web user's request to an application program and to receive data back to forward to the user and provides a consistent way for data to be passed from the user's request to the application program and back to the user.

Your first sentence gives the correct definition – but you should cite the source of the quote! Your second paragraph is a definition of the Common Gateway Interface (CGI) which is a different kind of gateway! Perhaps Google gave both definitions and you couldn't decide which was correct!

Chris Jobling 2012/12/06 08:43

Question 14

Which linux command shows the routing table for your host?

Answer: route

Run the command identified in Question 14 and reproduce its output here.

Answer

<cli prompt=“$” comment=“#”> user@host:~$ command # Copy command and its output and paste it here.

icct@carme:~$ route Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface default jupiter.icct.co 0.0.0.0 UG 100 0 0 eth0 link-local * 255.255.0.0 U 1000 0 0 eth0 jupiter-net * 255.255.255.0 U 0 0 0 eth0 </cli>

Question 15

How many interfaces (NICs) must a router have?

Answer one of:

At least 1 

No, there must be at least 2 because a router connects 2 or more networks

Chris Jobling 2012/12/06 08:46

Question 16

Which system feature must be turned on if you want a Linux host to act as a router?

Answer:

Turn on IP packet forwarding
Setting up NAT
Setting up DHCP
Setting up DNS

The first answer was correct. You were perhaps hedging your bets by mentioning the other services

Chris Jobling 2012/12/06 08:46

Question 17

Which run-time command can be used to make a Ubuntu Linux host act as a router?

Answer:

/proc/sys/net/ipv4/ip_forwarding

In Ubuntu is 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: In file /etc/network/options

Yes, but on which host? On jupiter it was actually /etc/networking/if-up/ip_forwarding! You should specify the host name of the file!

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. 

ip_forward=yes spoofprotect=yes syncookies=no

Question 19

What setting has been added to the network configuration file to define a route to icct-net from your sub-network's cluster-server?

Which of these commands define the route?

Chris Jobling 2012/12/06 09:05

Answer:

auto eth0
iface eth0 inet static
  address 192.168.1.3
  netmask 255.255.255.0
  gateway 192.168.1.1 # default for jupiter is solaris
  # route to saturn-net
  up   route add -net 192.168.3.0 netmask 255.255.255.0 gw 192.168.1.4
  down route del -net 192.168.3.0 netmask 255.255.255.0 gw 192.168.1.4

# Interface in jupiter-net is much simpler
auto eth0
iface eth1 inet static
  address 192.168.2.1
  netmask 255.255.255.0

Setting 2 should be auto eth1. Perhaps the file was in error on jupiter so benefit of the doubt given!

Chris Jobling 2012/12/06 08:50

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.

Underlined Text

Question 20

Give and explain the output of the command netstat -r.

Answer <cli prompt=“$” comment=”#“> user@host:~$ netstat -r # Paste result here…. icct@carme:~$ netstat -r Kernel IP routing table Destination Gateway Genmask Flags MSS Window irtt Iface default jupiter.icct.co 0.0.0.0 UG 0 0 0 eth0 link-local * 255.255.0.0 U 0 0 0 eth0 jupiter-net * 255.255.255.0 U 0 0 0 eth0 icct@carme:~$ </cli>

Add your explanation here.

It is use to display the information of route, the result is similar to command “route print. Not only display the route information, also display the valid link.

Question 21

Give and explain the output of the command netstat -i.

Answer <cli prompt=“$” comment=”#”> user@host:~$ netstat -i # Paste result here…. icct@carme:~$ netstat -i 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 21884 0 25 0 5780 0 0 0 BMRU lo 16436 0 58 0 0 0 58 0 0 0 LRU

</cli>

Add your explanation here.

netstat -i -i = -interface. so this command is display the information of network. such as list the network interface.

Question 22

Give and explain the output of the command netstat -ta.

Answer <cli prompt=“$” comment=“#”> user@host:~$ netstat -ta # Paste result here…. icct@carme:~$ netstat -ta Active Internet connections (servers and established) Proto Recv-Q Send-Q Local Address Foreign Address State tcp 0 0 *:http *:* LISTEN tcp 0 0 *:ssh *:* LISTEN tcp 0 0 localhost.localdoma:ipp *:* LISTEN tcp 0 0 localhost.localdo:mysql *:* LISTEN

</cli>

Add your explanation here.

It is display all socket TCP transfer protocol connection status

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:~$ traceroute # paste output here icct@carme:~$ traceroute Usage:

traceroute [ -46dFITnreAUV ] [ -f first_ttl ] [ -g gate,... ] [ -i device ] [ -m max_ttl ] [ -N squeries ] [ -p port ] [ -t tos ] [ -l flow_label ] [ -w waittime ] [ -q nqueries ] [ -s src_addr ] [ -z sendwait ] [ --fwmark=num ] host [ packetlen ]

Options:

  1. 4 Use IPv4
  2. 6 Use IPv6
  3. d –debug Enable socket level debugging
  4. F –dont-fragment Do not fragment packets
  5. f first_ttl –first=first_ttl

Start from the first_ttl hop (instead from 1)

  1. g gate,… –gateway=gate,…

Route packets through the specified gateway

                            (maximum 8 for IPv4 and 127 for IPv6)
-I  --icmp                  Use ICMP ECHO for tracerouting
-T  --tcp                   Use TCP SYN for tracerouting (default port is 80)
-i device  --interface=device
                            Specify a network interface to operate with
-m max_ttl  --max-hops=max_ttl
                            Set the max number of hops (max TTL to be
                            reached). Default is 30
-N squeries  --sim-queries=squeries
                            Set the number of probes to be tried
                            simultaneously (default is 16)
-n                          Do not resolve IP addresses to their domain names
-p port  --port=port        Set the destination port to use. It is either
                            initial udp port value for "default" method
                            (incremented by each probe, default is 33434), or
                            initial seq for "icmp" (incremented as well,
                            default from 1), or some constant destination
                            port for other methods (with default of 80 for
                            "tcp", 53 for "udp", etc.)
-t tos  --tos=tos           Set the TOS (IPv4 type of service) or TC (IPv6
                            traffic class) value for outgoing packets
-l flow_label  --flowlabel=flow_label
                            Use specified flow_label for IPv6 packets
-w waittime  --wait=waittime
                            Set the number of seconds to wait for response to
                            a probe (default is 5.0). Non-integer (float
                            point) values allowed too
-q nqueries  --queries=nqueries
                            Set the number of probes per each hop. Default is
                            3
-r                          Bypass the normal routing and send directly to a
                            host on an attached network
-s src_addr  --source=src_addr
                            Use source src_addr for outgoing packets
-z sendwait  --sendwait=sendwait
                            Minimal time interval between probes (default 0).
                            If the value is more than 10, then it specifies a
                            number in milliseconds, else it is a number of
                            seconds (float point values allowed too)
-e  --extensions            Show ICMP extensions (if present), including MPLS
-A  --as-path-lookups       Perform AS path lookups in routing registries and
                            print results directly after the corresponding
                            addresses
-M name  --module=name      Use specified module (either builtin or external)
                            for traceroute operations. Most methods have
                            their shortcuts (`-I' means `-M icmp' etc.)
-O OPTS,...  --options=OPTS,...
                            Use module-specific option OPTS for the
                            traceroute module. Several OPTS allowed,
                            separated by comma. If OPTS is "help", print info
                            about available options
--sport=num                 Use source port num for outgoing packets. Implies
                            `-N 1'
--fwmark=num                Set firewall mark for outgoing packets
-U  --udp                   Use UDP to particular port for tracerouting
                            (instead of increasing the port per each probe),
                            default port is 53
-UL                         Use UDPLITE for tracerouting (default dest port
                            is 53)
-P prot  --protocol=prot    Use raw packet of protocol prot for tracerouting
--mtu                       Discover MTU along the path being traced. Implies
                            `-F -N 1'
--back                      Guess the number of hops in the backward path and
                            print if it differs
-V  --version               Print version info and exit
--help                      Read this help and exit

Arguments: + host The host to traceroute to

    packetlen     The full packet length (default is the length of an IP
                  header plus 40). Can be ignored or increased to a minimal
                  allowed value

</cli>

You didn't actually use tracerooute to trace the route to a host on the saturn.icct.com of icct.com network.

Chris Jobling 2012/12/06 08:53

Question 24

Give the output of traceroute from your host to www.swan.ac.uk

Answer <cli prompt=“$” comment=“#”> user@host:~$ traceroute swan.ac.uk # paste output here </cli>

Explain the result.

Correct command but no results provided

Chris Jobling 2012/12/06 08:55

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

Question 26

Which other files would you need to modify to correctly set up this new router?

Answer

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

Question 27

Which other files would you need to modify to fully configure your host to recognizes the new engineering sub-network?

Answer

Signature

I hereby submit this work for marking.

Your signature here: Guo Ziwen

1)
If your host has two or more network cards, the LAN-facing card will be the NIC assigned to your host's static IP address.
eg-253/networkq/670923.txt · Last modified: 2012/12/06 15:06 by eechris