InstiLAN

From Iitmlug

Jump to: navigation, search

Contents

Introduction

This article primarily intends to introduce the institute's LAN (Local Area Network). It will hopefully help the reader understand the basics of TCP/IP Networking and will also describe some of the fundamental network configuration that is required to use Linux in the institute. century 21 broker properti jual beli sewa rumah Indonesia

This article will mostly talk about the hostel network, and can be easily modified to work for the other networks in the institute.

IP Addresses

Any computer on a (TCP/IP) network is identified by an IP Address. This is a wierd looking number with dots in-between. You may have heard of people talking about IP Addresses like 10.94.0.11 or 10.94.0.31 - it's not some really geekish lingo. It's just the identity number of a computer on a network or on the internet.

In any network, there are subnetworks and computers. One could probably consider the Hostel Network, the Academic Network etc. as subnetworks in our institute, and there are many computers connected to each of these subnetworks. An IP version 4 address typically consists of 4 numbers in the range 0 - 254 separated by periods. In our institute, the first two numbers indicate which subnetwork a computer belongs to, and the second two numbers uniquely specify the identity of a computer on that subnetwork.For example 10.94.0.31 identifies as a computer / network interface in the Hostel Zone, while 10.65.0.42 identifies as a computer / network interface in the Academic Zone. Thus, all computers in hostels / hostel zone must have an IP address of the form 10.94.*.* where the *s represent numbers in the range 0 - 254. Century 21 Broker Properti Jual Beli Sewa Rumah Indonesia

The IP address 10.94.0.0 is special, because it denotes not a particular computer on the network, but the whole network itself. 10.94.255.255 is also special and has a similar meaning.

To find out your IP address, you may use the command /sbin/ifconfig under Linux. Your IP address will appear somewhere in the output.

127.0.0.1 is a special IP address that denotes 'localhost', meaning the same system. Thus, all 'packets' of information addressed to 127.0.0.1 reach the same computer / network interface which sent them. You could think of 127.0.0.1 as some sort of a synonym to 'me'. You will most probably see an interface called 'lo' with an IP address 127.0.0.1 in the output of /sbin/ifconfig.

(On windows, use ipconfig in the command prompt to find your IP address)

In the absence of a domain name (a 'common name' for a system, in some sense - like ftp.iitm.ac.in), you will have to rely on IP addresses for addressing systems on your network. Thus, it is important to know your own IP Address and useful to write down a few friends', so that you can exchange files etc much much faster than through GTalk and other protocols relying on the internet.

Static vs. Dynamic IP Addresses

A server called a DHCP server on the network is capable of assigning IP addresses and other network parameters to computers connected on the network automatically using a protocol called DHCP (Dynamic Host Configuration Protocol). This is why you sometimes need not set an IP address for your computer, or you may find that the IP address of your computer varies. Most (user-friendly) operating systems use DHCP by default.

Using DHCP is not a very good idea because your IP address keeps changing from time to time, from reboot to reboot. Besides, if the DHCP server is down, your LAN connection might not work because you are not assigned an IP address / other network parameters. It is best to configure a static IP address and you can read about it in the later sections of this article.

We will assume that you have a static IP address for further discussions.

Ping

The command 'ping' may be used to check if a computer is 'alive' (up and running). It is also a useful diagnostic to see which parts of a network are failing, or whether you are connected to the LAN.

To check if you are connected to the insti LAN, you may execute 'ping 10.94.0.254' (no quotes) in a terminal to see if the 'gateway' to the LAN (we'll see what's a gateway later) is up. If the LAN is working, you should typically see output like this:

PING 10.94.0.254 (10.94.0.254) 56(84) bytes of data.
64 bytes from 10.94.0.254: icmp_seq=1 ttl=255 time=0.300 ms
64 bytes from 10.94.0.254: icmp_seq=2 ttl=255 time=0.358 ms
64 bytes from 10.94.0.254: icmp_seq=3 ttl=255 time=0.299 ms

--- 10.94.0.254 ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 1998ms
rtt min/avg/max/mdev = 0.299/0.319/0.358/0.027 ms

Of course, some of the numbers may vary. Ping will go into an infinite "pinging" process - to stop it, use Ctrl+C. (I hit Ctrl+C after 3 pings in the above example)

In the case of (partial or complete) LAN failure, it should show something like:

PING 10.94.0.254 (10.94.0.254) 56(84) bytes of data.
From 10.94.*.* icmp_seq=1 Destination Host Unreachable
From 10.94.*.* icmp_seq=2 Destination Host Unreachable
From 10.94.*.* icmp_seq=3 Destination Host Unreachable

--- 10.94.0.254 ping statistics ---
4 packets transmitted, 0 received, +3 errors, 100% packet loss, time 3008ms
, pipe 3

Where 10.94.*.* represents the IP address of your system. Thus ping is a useful diagnostic tool to check networks.

Sometimes when the LAN works but internet doesn't, it may be because of the proxy server being down. You can check that by doing a 'ping 10.93.0.35' and seeing if the proxy is alive.

You can also try pinging your friends' computers to see if they are on.

NOTE: Some computers can block ping and pretend to be dead, as a security measure.

/sbin/ifconfig

/sbin/ifconfig tells you the status of your network interfaces. A so-called 'network interface' may be a piece of network hardware (like a LAN card, a router etc) or can be a virtual interface like 'lo' (loopback, 127.0.0.1)

Typically, if you execute /sbin/ifconfig you should see something like this:

eth0      Link encap:Ethernet  HWaddr __:__:__:__:__:__ 
          inet addr:10.94.___.___  Bcast:10.94.0.255  Mask:255.255.0.0
          inet6 addr: ________________________4 Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:934014698 errors:5 dropped:0 overruns:0 frame:5
          TX packets:2613644 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000 
          RX bytes:3264766306 (3.0 GiB)  TX bytes:1296474581 (1.2 GiB)
          Interrupt:16 Base address:0x6000 

lo        Link encap:Local Loopback  
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:586792 errors:0 dropped:0 overruns:0 frame:0
          TX packets:586792 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0 
          RX bytes:181752006 (173.3 MiB)  TX bytes:181752006 (173.3 MiB)

The only details we are probably going to be worried about are inet addr (which gives your IP address) and Mask (which gives what is called your subnet mask) - which should be 255.255.0.0 for the insti LAN. You may also be interested in the Received and Transmitted bytes.

/sbin/ifconfig shows only configured interfaces, i.e. interfaces which are up and enabled. If your LAN network interface (usu. called 'eth0') is disabled, you will not see 'eth0' in the output of ifconfig. You may try to re-enable it by invoking sudo /sbin/ifup eth0

You may also additionally see wireless LAN interfaces if you have wireless LAN support or interfaces like eth1 if you have more than one network card.

The output of /sbin/ifconfig is generally helpful in debugging network problems.

Gateways

A gateway 'connects' one network to another (usu. the internet). The hostel zone gateway is at 10.94.0.254. All connections to computers outside the hostel zone must go through the gateway.

You may sometimes experience a problem where you can ping any computer within your hostel, but not outside. This happens if there is no connection to the gateway, or the gateway is not configured correctly. If your gateway is configured correctly, the output of /sbin/route should look like this:

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
10.94.0.0       *               255.255.0.0     U     0      0        0 eth0
default         10.94.0.254     0.0.0.0         UG    0      0        0 eth0

If the line for destination 'default' is missing or is different, you may be able to solve the problem by invoking

sudo /sbin/route add default gw 10.94.0.254

If the line for default takes too long to appear, try pinging 10.94.0.254 to check if it is alive / you have network connectivity with it.

DNS Servers

DNS (Domain Name System) Servers keep a list of common names for IP addresses. When you type www.google.com, the system does a query looking for the IP address corresponding to google.com and establishes a connection with it.

Configuring Static IP Address in Hostel Zone

In most cases you should be able to use a graphical tool like network-admin (for GNOME) or system-config-network (for Fedora) for configuring static IP smoothly. The following details will be required: IP Address: 10.94.*.* Replace the *s by some numbers that are easy to remember for you. Note that the IP address must be unique on the network, or you'll get an error. Subnet Mask: 255.255.0.0 The program may suggest 255.255.255.0, but change it to 255.255.0.0 Default Gateway: 10.94.0.254 Primary DNS Server: 10.91.2.11 Secondary DNS Server: 10.91.2.12

If you want to do it the harder way, in Debian (or Ubuntu) you edit the files /etc/network/interfaces and /etc/resolv.conf A typical static IP address configuration in /etc/network/interfaces would look like this:

# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
allow-hotplug eth0
iface eth0 inet static
        address 10.94.*.*          # Replace *.* by your preferred numbers.
        netmask 255.255.0.0
        network 10.94.0.0
        broadcast 10.94.0.255
        gateway 10.94.0.254
        # dns-* options are implemented by the resolvconf package, if installed
        dns-nameservers 10.91.2.11 10.91.2.12

Once you edit this file and save it, you may want to edit resolv.conf to contain the following two lines:

nameserver 10.91.2.11
nameserver 10.91.2.12

Then, you will have to invoke

sudo /etc/init.d/networking restart

to restart network interfaces and networking services. You may then want to check the outputs of /sbin/ifconfig and /sbin/route to see if things are configured fine.

NOTE: You may have to troubleshoot duplicate IP Addresses at this stage.

Proxy Server

All connections to the internet go via the proxy server. The proxy server acts proxies connection requests from the intranet to the outside world, retrieves the data, and returns it to the computer that requested it from the local intranet.

Our proxy servers lie at 10.93.0.35 and 10.93.0.36 (Hostel Zone), but you may want to configure the NTLMAPS proxy server or CNTLM to run on localhost (127.0.0.1). Please refer the appropriate articles on this Wiki for those details.

Exploring the Insti LAN

This section lists out various interesting servers on our network.

10.65.0.42 This server, known to the outside world as ftp.iitm.ac.in, is maintained by Prof. P. Sriram from the Aerospace Engg. Department. This FTP (File Transfer Protocol) server has a lot of free software and acts as the local Linux repository.

To configure the Debian / Ubuntu APT (Advanced Packaging Tool) to use the Debian / Ubuntu repository at ftp.iitm.ac.in, you will have to comment out all lines in your /etc/apt/sources.list file, leaving / adding only the following:

deb ftp://10.65.0.42/debian testing main contrib non-free
deb-src ftp://10.65.0.42/debian testing main contrib non-free

for Debian and:

deb ftp://10.65.0.42/ubuntu hardy main universe multiverse
deb-src ftp://10.65.0.42/ubuntu hardy main universe multiverse

for Ubuntu.

While Debian / Ubuntu are the currently well-supported distributions, we may want to have a Fedora mirror as well. People who are interested in maintaining a Fedora mirror are requested to post on the LUG Google Group.

10.65.0.11 Also known as smail.iitm.ac.in, this is the IMAP mail server around. To configure mutt to use this server, please see the article on Configuring a Mail Client.


Personal tools

sl
דומיין בעברית  דומיין  דומין  תוכנה לניהול  קשרי לקוחות  CRM, ניהול קשרי לקוחות  דומין בעברית  פורומים  ספרדית  גיבוי