Вы находитесь на странице: 1из 38
SEVEN Computer Networks Introduction to Networks Computer network isa system (collection and connection of computers) which allows two or more computers a com ‘municate Elements of computer network are intermediate message processors such as bridges, routers and gateways in addition to computers. 1 11{ Classification of Networks Networks can be classified based on © Range of communication + Relationship betiveen components ‘Physical design structure (lopology) * Communication techniques (protoce) 7.1.1.1 Networks by Range (LANs, MANs and WANs) Local Area Network (LAN) This isa network typically set up ina home, office or small troup of buildings. The range of this type of network is limited, confined to an area of 1000 square metres, The ef- fect of this small range is that no computer on this netseork will be further than 30-50 metres from its nearest neigh- bour. The number of computers/devices on an individual LAN will normally not excced50, Note that multiple LANs can be linked together to provide greater network access! coverage. Metropolitan Area Network (MAN) ‘This is a network that spans a city or extended group of buildings as in a college campus, To enhance speed MANS often use fibre optic cables to connect segments ofthe net- work. The optical cables allow for extremely high rates of data transfer, A number of LANs may be joined together to form part of a MAN. It is expected that several hundred ‘computers may be present on a MAN. Wide Area Network (WAN) This type of network spans a wide geographical area. Dueto the dispersed nature ofthe computers, WANs must handle and support multiple networking technologies. In contrast toa typical LAN, users may not be using the same types of hhardate/software. The need forthe constant availability of the WAN means that dedicated personnel, equipment and lines must be used. The internet is an extreme example of 8 WAN, Large orgtnisstions may also maintain their own private WANs with the use of leased lines. The existence of these networks provide global reach, Many private WANs are aso connected tothe internet but outsiders cannot en ‘er without providing the relevant usernames/passwords or other security information & [Note Internets global and refers to WAN. Intrant eters to LAN. 7.1.1.2 Networks by Relationships between Components Client/Server This isa relationship primarily between two computers in Which one machine makes requests (called the client) and the other machine (called the server) satisfies the requests For example, when a user downloads a web page they are actually making a request for information from another imachine (called the web server) ‘Typically the server is @ powerful machine which uses special hardovare to improve performance, The server may be connected to thousands of clients at @ time. The client typically will bea PC or machine with reduced computing. ability when compared to the server. Computer Networks | 78) and below is via a well defined interface. Layer N is said to request service from layer N-| (below) and provide a service to the layer Nel (above). Layer Nin one protocol stack communications with the same layer in a remote protacol stack via the layers helow. This is known as virtual br peer-to-peer communication. OSI Model: TCP/IP Model: Application Layer Transport Layer Application Layer Presentation Layer Session Layer Network Layer Teansport Layer Data Link Layer Network Layer Physical Layer Data Link Layer Physical Layer 7.4.2.1 Comparison of TCP/IP and OS! Reference Models oth Models have similarities and ditferences. Similarities 1, Both use the concept ofa protocol architecture, where there area number of independent layers each carry- sng outa specific task. 2, The functionality is very similar for most of the ay- cs in each reference model, Fr example, bth have a \ransport layer which operates end-to-end. Differences 1, OSI reference model makes clear the distinetion be ‘swoon services, interfaces and protocols, The service efines what services the layer offers, the interface de- fines how they are accessed and the protocols are the actual implementation ofthe services. This adheres to standard software engineering practice. In contrast, the TCP/IP Reference Model does not use this a proach and hence the protocols (implementations) are not always transparent, 2. TCP/IP has no presentation or session layer. 3, OSI supports connection-oriented and connection- less communication in the network layer, but only connection-oriented communication in the transport layer. In contrast, TCP/IP allows only connectionloss communication ia the network layer but a choice of connection-oriented and connectionless inthe trans port layer 4, The OST defines very precisely the physical and data link layers. TCP/IP ignores this approach and instead the Host-to-network layer merely defines the interface to the underlying network, Some Important Points To be critical, data communication deals with aspects re lated to data link layer and physical layer and computer networks deals with remaining layers. Moreover, PL and DLL aspects are realised in HW ia, in formware. For exam- ple, network cards or ethernet cards are the ones which car- ries the activites of DLL and PL. Whereas, NL, Thy and AL. ace implemented in SW. CISCO people have implemented NL TL related services in thelr routers Protocols means rules and regulations but they will not tell anything about how they are implemented or realised. Physical hyer protocol specifies physical, electrical, me chanical, procedutal, functional interface between a data terminating equipment (computer) and data communicat- {ng equipment such as modem, Nall Modem is used to connect two computers via their RS 232 ports cither COMI or COM2 First popular serial com- ‘munication software was Kermit developed by Cambridge University, UK. Data units are normally divided into smaller units while communicating, ‘© To utilise the bandwidth in a better manner ‘© Not to allow one application to monopolise the lines ‘© Because of the protocol constraints, s/w constraints such as butler sizes ete ‘Because of the error characteristics of the practical channels. (Cor example, if a channel is identified as having error rate as I in 100000 bits and the size ofthe communication data unit is more than 100000 bits than every communica tion data unit is bound to face an error. Even if we trans- mit, the retransmitted one also going to face error. Thus, there will not be any effective data transfer. Thus, frames data communication units < 100000 bits are used. That to preferable their sizes should be less than 1/2*100000). Data Link layer main responsibility is successfully de- livery of frame from one side ofa link to another side of a link inthe ease of point to point networks. Its responsibilty also includes acknowledge management, flow control, slow receiver problem Flow control elated to one particular link and is done by data link layer whereas congestion control is @ global phenomenon carried out by many mic’ in the subnet and this isthe responsibility of the network layer. “Main responsibilty of network layer is delivery of packet from source m/c to destination mic (peer communication). Its responsibility also includes route finding, congestion control, deadlock avoidance, extending connection orient- ced and connectionless services. ‘Transport Layer responsiblity is connection establish ‘ment, management, multiplexing of services, et, Computer Science & Information Technology for GATE 7.1Four receiving and transmitting devices can distinguish among four diferent voltage levels ina given signal instead of just two, how many bits can be transmitted. in a single signal element? Ifthe baud rate is 1200 what isthe data rate we can achieve? Answe No ofits a signal element ean carry = log, Data Rate = 2"1200=2400bps 8, Given a channel with intended capacity of 20Mbps, the bandwidth ofthe channel is 3Mz, What SNR is needed in order to achieve this capacity? Answer: 20Mbps = 3MHzlogy(1+SIN) siN= 2 SNR = 10 log 2° =17 &B 9. A five-bit startstop asynchronous transmission with start and data pulses of each 13.5min duration plus a stop pulse of 19min giving a total character duration of 100min isused? What isthe signalling speed? What isthe data rate? Answer: Signalling speed = baud rate= 1/13.5ms=74 Data rate = Sbite/100ms= 50 bps 10.11 is desired to send a sequence of computer sereen im- ‘ges over an optical cable. The sereen images are 640480 pixels each and each pixel requires 24bits. It is required to send 60 frames per second?. What is the minimum band- width needed for the channel which is supposed to carry this data? Answer: D: 442.368 Bandiwidthroguiredforthechannel=442.368/2=221.184MHz 11. A Modem to be used with a PSTN (public switched telephone network) which used amplitude and phase shift keying with eight levels per signalling clement. If the band Width of the PSTN is 310012, deduce the Nyquist maxi- mum data rate Answer: Nyguist data rate= 2X 3100 X log, 8 = 18600bps 12, Deduce maximum data rate ofa tele networking with bandwidth of 500 Hz and a SNR of 54B, Answer: 5 = 10 logy SIN. Therefore, S/N=3.16 Max data rate = 599 X log, (143.16) =1000bps 13, Assume thatthe TV picture i sent over a channel with 45 Mhz bandwidth and 354B SNR value. Find the capacity, ofthe channel Answer: 35=10logye S/N ‘Therfore,S/N=3162.3 Data Rate= 4.8 X 10°x log (1431623) =S2Mbps 14, What isthe channel capacity fora tleprinter channel with 30012 bandwidth and S/N value of 32 Answer: Date Rate = 300 X logs(1+3) =600bps 15. For a video conferencing system a LOMHz channel is tien. Video camera outputs 30 frames fora second with ata Required to be sent = 60 X 640 X 480 X 24 512x512, §-bit pixels. At the same rate images are required to be transferred due to some technical reasons ( real time video communication). Will he given channel is adequate? If tis not possible, itis proposed to compress and send, If 0, how mich compression rati fs needed for the compres- sion algorithm selected? 0 X 512 X S12X 8= 62.9Mbps we can achieve on the channel = 2X 10, Mbps (As nothing is given about voltage levels we assume binary signal itself) ‘Channel s not sulficent. (Compression ratio required for the compression algorithm 52.8/20=3.195 EEA Physical Layer These describe the electrical and mechanical interface nec essary to establish a communications path. Layer 1 protocols are concerned with the physical and clectrical interfaces. It defines for example: ‘© Connection types and allocation of signals to pins ‘© Electrical characteristics of signals which includes bit synchronisation and identifying a signal clement asaor | Hence, layer IIs responsible for transmitting and receiv ing the signals RS232/V.24 Signal voltage levels + -3V to -25V binary 1 for data, OFP for a control signal ‘© +3V to 425V binary 0 for data, On fora control sig- nal 25 Volts isthe maximum rating for a line without a load. In practice RS232/V24 signals are set to typically be + ~12V Use of RS232/V.24 as DTE/DCE interface standard Ground Signals ‘© Pin 1 (SHG) Protective Ground /Shield Ground to reduce external interference + Pin 7 (SIG) Signal Ground provides a reference for other signal ‘Transmit and Re ‘Pin 2 (TxD) Transmit Data + Pin 3 (RxD) Receive Data Maintaining a Connection j ‘Hardware Handshaking’ ‘Pin 6 (DSR) DataSet Ready, Modem indicates to DTE. that ts ready, fe, connected to a telephone wire in 20 (DTR) Data Terminal Ready, DTE uses this to prepare the modem to be connected tothe telephone line. Its placed in an OFF condition it causes the TAY) Computer Science & Information Technology fr GATE “The total number of signalling clement changes is kknovn as the BAUD RATE, and this is bandwidth limited by the transmission medium. However if each signalling element represents N bits then the actual data rate is N* BAUD RATE, 124.4 ferential Phase Shift Keying (DPSK) In order to design electronic circuitry that detects phase shi, it is advantageous to ensure that lots of phase shifis occur even ifthe line is idle. A PSK system would just trans- rita contintos tone in these circumstances, so the receiver clock will tnd to drift. One solution isto use DPSK, which defines each pair of data bits (or dibits) as the phase change between two signalling clements.For example V22 defines the following coding system DIBIT VALUE PHASE CHANGE 0 90 Degrees o 0 Degrees u 270 Degrees 10 180 Degrees, ‘The carrier frequencies are again 1200 Hz and 2400 Hi, with a baud rate of 600. This means that the data rate is 1200 bite per second (BPS), 7.2.1.5 Quadrature Amplitude Modulation QAM Higher data rates are achieved by a combination of PSK with ASK, So as well as changing the phase of the transmit- ted signal we can also alter its amplitude, The V22bis MO- DEM standard isthe simplest example of this technique, ‘V2bis defines 16 diferent types of signalling element, so cach element represents 4 binary bits, The baud rate i stl (600 baud, so the data rate achieved by V22bis i 2400 BPS, Another examples is V32 which defines 16 states, trans- ‘mitted as 2400 baud = 9600 BPS, Higher data rates are now achievable (up to 56.6 KBPS) by increasing the number of discrete signalling elements available to the MODEM 7.2.1.6 Modems Sending Computer Data over Telephone Channels © Computers produce digital data (pulses) © Telephone channels are designed for analogue signals + So digital data must be converted into a suitable for mat (analogue signals) if telephone channels are to be sed # Device which does ths is called a MODEM Modulator Demodulator A MODEM can set up a switched path through the tele phone network, or use a leased line, ane JW an Bais ‘age fasenue Dl 7.2.2) Transmission Modes There are two transmission modes to name Asynchronous and Synchronous transmission. Fundamental diference between the two modes is Asynchronous Transmission ~ "The receiver clock is not synchronised with respect tothe received signal Synchronous Transmission ~ The receiver lock operates in synchronisation with the received signal For both types of transmission the receiver must be able toachieve bit synchronisation. For Asynch transmission byte synchronisation must also be achieved. For Synch transmission, synchronisation of a block of bits (or bytes) must also be achieved. Asynchronous Transmission Bit Synchronisation ‘Transmitter must oper ‘© Receiver clocks runs asynchronously with respect to the incoming signal ‘© Problem is to ensure the incoming signal (bit) is sampled as near centre as possible + Local receiver clack rans at N times transmitted bit rate (typically x16 or x64) ‘© Each new signal is sampled after N ticks ofthe lock + The higher the receiver clock rate, the closer to the entre the signal will be sampled (Character Synchronisation ‘© Each characteris enveloped in start and stop bits ‘© Transmitter and receiver must be programmed to ‘operate with the same number of start and stop bits ‘Transmitter and recsiver must be programmed to operate with the same number of bits for the transmitted character. This is typically 7 for ASCII, 5 for TELEX, of § for CEPT display profiles (eg teletext). ‘© When the line is idl, 15 are normally transmitted and the stop bits are also 1. ‘© Start bit is usually @ zero, thus there Is always a 1-0 teansition at the stat or every characte, ‘© Note the star hit is sample at N/2 clock ticks. e with the same characteris Computer Science & Information Technology for GATE USB employs device polling. USB controllers are Further classified as UHCI (universal Host controller interface), HCI (open host controler interface). Communication overhead is more on host CPU in UHCI “The USI standard specifies Four types of packets such as token, data, handshake, and special The token packet is used to initiate data transfers. It specifies address (ADDR), direction specifier (packet iden- Uiier PID), end of packet (ENDP), and CRC checksum. ere, data packets contains no addresses, Data field val- tue can be upto 8192 bits. Handshake packets ae to either send ACK or NACK (negative ACK). Example A computer sends 0.5KB (614 bits) of data to one ofits USB peripherals. 1, Show the packets sent by the computer to perform this transfer. What is the total no ofbits transferred? +b, What percentage of the bits transmitted is overhead? ‘How many bits would be required to send the same data using an RS232C serial ort with no parity, 8 data bits and I stop biti used? Answer: According to the above discussion, a data pack- ct in a USB standard can have at most 8192 bits. Our data is only 6144 bits. Thus, no of overhead bits =8 + 16 =24 Percentage of overhead = 24/(6144 + 24) = 0.38% In the case of RS232C for every 1 byte I start bit and 1 stop bit has to be sent. Thus overhead bits 2°051024 =L024bits Percentage of overhead = 1024/(6144 + 1024 ‘A communication line can be shared using the multi-point configuration. For instance, terminals. that wish to com- ‘municate with the master computer. In practice multiplex- {ng is used to achieve this. Various Multiplexing methods ‘+ Time division multiplexing ~ mainly in circuit switeh- ing. «Statist 3 multiplexing - mainly on packet switching « Frequency Division Multiplexing ~ mainly on un- {guided transmissions « Space division 7.2.4.1 Time Division Multiplexing (TDM) Each TE has a separate connection to the TDM (Fig. 7.2). TDM samples each TE, in turn and puts aggregate onto high speed link. Each cycle (of servicingall TEs) has a fixed time period, and data from cycle is called frame (time frame). This is similar to time-slicing in operating systems. Thus, the bandwidth allocated to a TE is fixed. tes res Mult Tine Frome DDetttpixing st Ro se Lr [so] [s2|si[sn] — [s2] sv High speed Link Ro Tow Figure 7.2. Time Dwvsion Multiplexer In USA, TDM carriers are used to support PSTN lines as shown in Table7.1,Forexample, Tl carriersupports 4 voice grade channels and a control channel of 8000bits(Framing, bits). Table 7.1 illustrates the carrier hierarchy. In Europe uses 31B4D is used (2.048Mbps) called as El lines there allow for 32 64k channels where 31 are voice and one D channel (64Kbps) is for signalling or framing. Also, ISDN carriers are also made available in the mean time, The 2B+D Basic Rate Interface uses 64k for each B-channel plus 16k for the D-channl, the 23B+D Primary Rate Interface uses (4k for each B-channel plus 6k for the D-channel, which ‘equals 544 Mbps, T1 bandwidth, Table 7.4 vier | Signal | #ofT1 | #ofVoice 7 Carlee | “Level | signals | Channels | SP**4 ni | psa 1 24 | saa Kipe tie | se | 2 a8 | 152 kps m[ ps2 4 96 | 63zkbps | pss |e | M736Kbpe ‘ 271760 tHe | ps4 | ios 1032 ee 7.2.4.2 Statistical Multiplexing (Stat MUX) Figure 7.3 shows a number of TEs connected 10 a Stat MUX. Note that typically there will be another Stat MUX connected to other end ofthe synchronous link, which also terminates a number of TEs. Before data can be accepted fom a TE, the TE must inform the Stat MUX of the des- tination TE it wishes to communicate with. Ths informa- tion ie conveyed to the Stat MUX at the other end of the synchronous link. Thus, at the destination, when a frame arrives from TE SI (this is stored in the frame header) the Stat MUX routes i to the appropriate destination, ‘The Stat MUX collects data (characters ~ asynchronous transmission) from the TEs and builds variable length frames. The end of a frame will be recognised for instance TH) computer Science & Intrmation Technology foe GATE components which process the datagram apply the same format, The latest version is 4, but version 6 is currently be- Ing defined HILEN (4 bits) ~ Defines the length of the header in 32 bit words, SERVICE TYPE = Defines how the datagram should be processed. This comprises a number of subfields which are shown below. PRECEDENCE (or priority) (3 bits) ~ Defines the prior- Aty of the datagram, from 0 (normal) through to 7 (highest). Generally, ths is ignored, but it will become more impor- tant in the provision of QoS. = Isaonebit lagiwhich when set requests low delay. ‘T ~ Is a one bit flag which when set specifies high throughput, R Isa one it flag which when set specifies high reli ability [Note that it is not possible for the network to guaran- tee the service requests that have been made, however its clearly important for the network to atleast know the user requirements. “The last two bits ofthe service type field are unused, TOTAL LENGTH (16 bits) - Defines the total length of the datagram measured in octets. IDENTIFICATION, FLAGS and FRAGMENT felds (Cotal 32 bits) control the fragmentation and reassembly of datagrams. This is discussed later inthis section. TIME TO LIVE (8 bits) ~ This Is measured in seconds, and defines how long the datagram is allowed to remain in the Internet. This field is decremented as the datagram is ‘moves through the network. When the field reaches zero the datagram is discarded and a message sent back to the source. PROTOCOL (8 bits) ~ Defines the high-level protocol that was used to create the message being carried in the data, This essentially defines the format ofthe data portion ofthe datagram. HEADER CHECKSUM (16 bits) ~ This is a checking field used to check the integrity of the header. SOURCE IP ADDRESS and DESTINATION IP AD- DRESS (32 bits each) ~ Define the source and destination address IP OPTIONS ~ The length of ths feld is variable, de pending on which options are chosen. Options are stored contiguous in the OPTIONS field, and each option com- prises an OPTION CODE field followed by an optional LENGTH (8 bits) and DATA field (variable integral nam- ber of 8 bits). Options relate to network management and control For instance, if the record route option is specified then each network clement which processes the datagram ‘must add their IP address tothe record route option fel. A detailed description of all options is beyond the scope of these notes ‘The major functions carried out by IP are Fragments tion/Reassembly, Routing and Error Reporting Fragmentation/Reassembly Datagrams may be transported across many physical nel works. Thete may be various maximum physical fe es associated with these physical networks. Consequently if a datagram is longer that the maximum physical frame site defined by the network st must be fragmented into a ‘number of smaller fragments accordingly. Each of the frag- iments becomes a new datagram and most (not all) of the Ineader fields will be copied from the original datagram to cach new fragment, ‘Of great importance in the fragmentation process is the IDENTIFICATION field. This must be copied into cach fiagment because this identifies the original datagram to Which the fragment belongs. The FRAGMENT OFFSET field specifies where (the offset) this fragment was posi- tioned in the original datagram. The last fragment resets the MORE FRAGMENTS bits, From the FRAGMENT OFFSET and TOTAL LENGTH fields in the lst fragment the destination ean caleulate the length of the original data- gram, It is a simple task to reassemble the datagram, Routing Iefore routing can be discussed, addressing must be un- derstood. An IP address is 32 bits long, and comprises a netid (network identifier) field and a hostid (host identi- fier) fold. Each network must be allocated a unique netid within the domain of the Internet, while each host must be allocated a unique hostid within the domain ofthe net- work to which it fs attached. In this way a (netid, hostid) pair can uniquely identify @ host, and thus itis possible to route a datagram from a source host to a destination host without any ambiguity. Note that the hostid is typi- cally divided into subnetid and hostid, This subdivision allows the network identified by the neti to be considered asa local internet’ comprising networks identified by the subnetid and hosts attached to the subnetwork identified by host, ‘There are three different address classes, Class A, B and . These differ only in the number of bits allocated to the netid and the hostid, For instance, Chass A addresses allo cate 7 bits for the netid and 24 bits for the host, while Cass C allocates 21 bits for the neti and 8 bis for the hos- tid, Clearly Class A addresses allow fewer networks but a greater number of hosts on each of the networks compared o Class C. The format of these address classes are shown n Fig. 7.6, To make it easier to read the address, the 32 bits are broken down into 4 bytes, the byte values converted to decimal and separated by dots (periods). Also, in quoting network addresses the hostid fel is set to zero. For exam ple, the netid for DMU is 146.227.0.0, 1.26) computer Science & Information Technlogy for GATE host is expected to respond to the message by reducing, the trafic rate, ‘here are other functions carried out by the ICMP which are outside the scope of these notes. 1. 1. Some Points about TCP/IP and UDP IP packet is normally called as Datagram For connection oriented service ~ TCP is uscd For connection less service ~ UDP is used Network address length depends on the class type ‘whereas network card address is independent of the class ofthe network and is always 48-bit long ‘+ Port aumber, IP number can be combinedly called as socket. But however itis not too vali. © Its more appropriate to call socket as file rather than an addeess. In UNIX OS itis visualized asa file ‘Thus, some of the Unix system calls such as read (). ‘Write () can be used on the sockets, Proxy ARP : An m/e will be responding on behalf of a group of IP addresses i, this me will respond to ARP ‘message by sending its N/W card addres for a group of imjc’s. Thus, the router will be delivering the IP packets to this ARP which may take further action to deliver the packets tothe real host. # DHCP ( Dynamic Host Configuration Protocol) DHCP protocol is a variant of bootp protacol, With the help of which A host which is physically moved from one LAN ina clusters automatically Idi. IP Packet Format a4 8 is bite ‘Ver_| THL | Type of Service| Total length dentifcation Ht | DEIME| Fragment Offset Timeto Live [Protocol _| Header check sum Source Address Destination Address Options 0 or more In the packet structure shown, we have the MF bit. Tai is usually to indicate whether this packet isthe last frag- ment or not, All fragments except the last one will have this bit set. DE bit is used to indicate whether this IP packet can be fagmented or not all m/c’ ate required to accept this pack- ct a8 a Whole if this bit is set. However, if it is not possible then an ICMP error message is sent tothe host. THIL denote the Internet header length in multiples of 82-bit words. “The version field indicates the the IP protocol version is 4 or not, ‘The Header total size thus should be in betwoen 20 and 60 bytes, The type of service specifies, what type of service \we wanted, whether we want service with lowest ercor rate or with min delay or max packet size ‘The total length includes the total length of the packet, including the header size and data size. As of today, themax allowable packet size is 65535 bytes. “The identification field contains the details about packet seq, fragment no, et, Fragment offset indicates the affet of the fragment wrt original packet in multiples of 8 bytes. Time to Live field is used to indicate how long the packet can lve inthe internet. Typically is value is 255 see. When. ever it reaches router then it gets reduced and when this becomes 0 this packet is recognized as Stalled Packet ‘CheckSum is 16 bit and is calculated only forthe header of the IP packet. Ente header value is taken as 16 bit and by doing 1's complement of each 16-bit word first each half word of the header are added together using 1 comple- ‘ment arithmetic and then 1's complement is taken for the result. Initially the header checksum is assumed tobe al 05 while calculating ‘The Options Field is used whenever we wanted cither of the following services: (i) Strict source routing (ii) Loose souree routing (i) Record route routing (iv) Time stamp routing 7.4.1.2. Distance Vector Routing Protocols “Most routing protocols fll into one of two classes distance: vector of link state. The name distance vector is derived from the fact that routes are advertised as vectors of (dis- tance, direction), where distance is defined in terms of a metric and direction is defined in terms of the nexthop router. For example, “Destination A is a distance of five hhops away, in the direction of next-hop Router X” As that statement implies, each router learns routes from its neigh- boring routers’ perspectives and then advertises the routes from its own perspective. Because each router depends on its neighbors for information, which the neighbors in turn ‘might have learned from thelr neighbors, and so on, dis- tance vector routing is sometimes facetious seferred to as “routingby rumor” A typical distance vector routing protocol uses a routing algorithm in which routers periodically send routing updates toall neighbors by broadcasting their entire route tables. Periodic updates means that atthe end ofa certain time period, updates will be transmitted. This period typically ranges from 10 seconds for AppleTalk’ RTMP to 90 sec- fonds forthe Cisco IGRP. Computer Netwerks | 727 ‘When a router frst becomes active on a network, how does it find other routers and how does it announce it ov presence? Several methods are availabe. The simplest isto send the updates tothe broadeast addres (in the case of IP 255.285.255.285). Neighbouring routers speaking the same routing protocol will hear the broadcasts and take appro- priate action. Hasts and other devices uninterested in the outing updates will simply drop the packets. ‘Most distance vector routing protocols take the very simple approach of telling their neighbours everything they know by broadcasting their entire route table, with some exceptions that are covered in following sections. Neigh bours receiving these updates glean the information they need and discard everything else, Figure 7.8 shows a distance vector algorithm in action. In this example, the metric is hop count, At time t, Routers {A through D have just become active. Looking a the route tables across the top row att, the only information any of the four routers has is its own directly connected networks. “The tables identify these networks and indicate that they are directly connected by having no next-hop router and by having « hop count of 0, Each of the four routers will broadcast this information on al links. A time t, the first updates have beon received and pro- cessed by the routers. Look at Router AS table att, Router Bs update to Router A said that Router B can reach net \Works 10.1.2.0 and 10.1.3, both zero hops away. Ifthe net works are zero hops from B, they must be one hop from ‘A. Router A incremented the hop count by one and then examined its route table. It already recognised 10.1.2. and the hop count (zera) was ess than the hop count B adver- tised, (one), so A disregarded that information. 0110 10120 wra0 tor40 10180 Sun wx Su wx Router Router Router NET VIA HoPs|[NeT iA HoPs |[Ner A HOPS [NET » [torso $0120 @ 10130 fo14o 10120 wo130 == 0 |jtora0 10180 l= NET VIA Hoes [NET er 10110 f120 -- 0 ||t0130 10140 101.20 worso "0 ||to1a0 jorso 4 10130 wouto wo322 4 [10120 i130 torso 10432 1 |jto4s0 l= wos |/NET ~via HOPS |/NET NEL WA Hoe 10110 o|\or20 -- 8 W140 ~ o 10120 ° |Ito130. 6 io1so o [10130 torz2 1 |lt0110 wor2a 1 W130 mrss 1 | Wide 10122 2 [todo 10132 2 W120 frat 2 40180 1132 NET NET VIA HOPS. NET 10110 0 ||w120 -- oo © |fior40 0 10120 0 |[ois0 —- oo © |Jiorso. 0 4 [18188 setae ft |fianio sras 4 $ fioi30 soras 4 foiso 10.122 5 ||fors0 tors2 2 toro trai 2 |lioi10 worar 5 Figur 7.8 Distance vector algorithm in stion Network 10.1.3. was new information, however, 60 A. centered this in the route table, The source address of the update packet was Router B's interface (101.22) so that in- formation is entered along with the calculated hop count. [Notice that the other routers performed similar opera tions atthe same time ,. Router C, for instance, disregard: ced the information about 10.1.3.0 from B and 10.1.40 from CC but entered information about 10.1.20, reachable via Bs Interface address 1041.31, and 10.1.5.0, eachable via Cs in terface 10.1.42, Both networks were calculated as one hop way. {At time tthe update period has again expired and another set of updates has been broadcast. Router B sent fits latest tables Router A again incremented BS advertised hhop counts by one and compared. The information about 10.1.2.0 fs again discarded for the same reason as before. 1.28) computer Science & Intrmation Technlogy foe GATE 10.1.3. is already known, and the hop count hasn't changed, s0 that information is also discarded. 10.1.4.0 is ‘new information and is entered into the route table. ‘The network is converged at time ty. Every router ree~ lognizes every network, the address of the next-hop router for every network, and the distance in hops to every net- work Route Invalidation Timers How will handle re-convergence when some part of the topology changes? If'a network goes down, the answer is simple enough other neighbouring router, in its next scheduled update, lags the network as unreachable and passes the information along. Split Horizon A route pointing back tothe router from which packets were received is called a reverse route. Splithorizon isa technique for preventing reverse routes between two routers, "Example Consider a subnet with routers A,B,CD.E. Distance vector routing is used, and the following vectors have just come in to router C: from B: (50,8,12,6,2) from D:(16,12,60,9,10);, and from E:(7,6,3,9,0,4). The measured delays from router C to B,D, and E, ae 6, 3, and 5, respectively, What is Cb new routing table? Give both the outgoing line to use and the expected delay “The new routing table would be listed as follows: To OntgoingLine Expected Delay A B u B B 6 c c ° D D 3 E E 5 F B 8 0 m— Router © Spanning Tree Original Suber Suppose that node B in above has just rebooted and has no routing information in its tables, It suddenly needs a route to H. Itsends out broadcasts with TTL set to 1,2, 3, and so fon, How many rounds does it take to find a route? Answer: It will take 3 rounds of broadcasts to locate a route to H Ey Transport Layer Main responsibilities ofthe transport layer i to extend se vices to the Application layer from which Byte stream is available to the Transport layer. Socket can be considered as Transport Layer Service Ac- cess Point. () Connection establishment, management, closing ete Js also the responsiblity ofthe transport layer (i) Extending the Quality of service (i) Multiplexing of data coming from different applica- ons (iv) Error control also ‘Transport Layer extends connection oriented, reliable full duplex service to the application layer, Binder is a kernel component which registers Process id no's and the Port which itis using. When a packet at- ives with a given port no, based upon this port no Binder decides to which process this packet has ta be hando- vered. Daemon Programs when they are initiated, they will he first creating a socket with a port (well known port ) and then they will be waiting for the connection request to this port adress. Thus, this port is called as listening port. Ev- cry well known service sich as Telnet, fip etc will be ex- tending their services at fixed port only. ‘When a Client request arrives to the port at which the server is listening then the server creates a new process In that process, a new socket is created with different Port no, whose value is more than 1023 and that socket and the el- ent side socket are binded together. In TCP connection establishment, Client can send con nection request and server replies with a special packet called SYN packet and then the Client replies again with an acknowledgment for the same. Since then, both sides knows connection i established Sliding Window Protocol is employed while data trans- fer takes place between two TCP entities. The sender side will be sending a packet with its sequence number. The r- ceiver side TCP entity replies along with acknowledgement, amount of free buifer space available with it, Both Nagas algorithm and Silly window syndrome are ‘complementary to each other. Connection can be closed by anyone, however otherskle connection may be sil active thus, the one which did not close ean continue to use its socket to send the data Computer Netwerks | 7.81 Example An audio streaming server has a one-way dis- tance of 50 mace with a media player. Ie outputs at | Mbps. If the media player has a 1-MB butfer, what can you say about the position of the low-water mark and the high- water mark? Answer: The low water mark must be higher than the amount of data that can be played in 50 msec so tha butfer tunderrun does not accur and the igh water mark must be ata point that is more than the amount of data that can be played in 50 msec below the 1 MB mark so that buffer over- run does not occur. Example | What isthe bit rate for transmitting wncom- pressed 800x600 pixel color frames with & bits/pixe st 40 framesisec? 1 Answer: The bit rate for this transmission would be 154 Mbps. Example Consider 2 100,000-customer video server, where each customer watches twa movies per month, Half the movies are served at 8 PM. How many movies does the server have to transmit at once during this time period? I each movie requires 4 Mbps, how many OC-12 connec- tions does the server need to the network. 1 Answer: This server would need 336,456 OC-12 connec: tions to supply the needed bandwidth, Example A client sends a 128-byte request to a server located 100 km away over a I-gigablt optical fiber, What is the efficiency ofthe line during the remote procedure call? Answer: The line will be in use.02% ofthe time, Example RTP is ased to transmit CD-quality audio, which makes a pair of 16-bit samples 44,100 times/sec, one sample for each ofthe stereo channels. How many packets peer second must RTP transmit? Answer: 176,400 packets must be sent every second, Consider the effect of using slow start on alline with a 10- msec round-trip thme and no congestion, The receive win. dow is 24 KB and the maximum segment size is2 KB. How long does it take before the fist fll window can be sent? m Answer: It will take 120-msee before the ist fll window will be send, Example To get around the problem of sequence num- bers wrapping around while old packets still exist, one could use 64-bit sequence numbers. However, theoreti- cally, an optical fiber can run at 75 Tops. What maximum packet lifetime is required to make sure that future 75 Thps networks do not have wraparound problems even with 64 bit sequcnce numbers? Assume that cach byte has its oven sequence number, as TCP docs. Answer: The maximum packet lifetime should be just shy ofthe total time it takes t issue al f the available 4- bit sequence numbers, Example What is the bandwidth-delay product for a 50-Mbps channel on a geostationary satellite? If the pack ets are all 1500 bytes (including overhead), how big should the window be in packets? 1 Answer: The bandwidth-delay product for this would be 50-Mbps * the delay. Not knowing the exact location of the geostationary satelite makes the delay dificult to deter rine, Assuming the packets are all 1500 bytes the window size should be equal tothe bandwidth-delay product. Example Give three examples of protocol parameters that might be negotiated when a connection is setup. Answer: The protocol parameters that may be negotiated during the setup ofa connection could be maximum packet size, maximum transmission/reception speed, and quality of service standards Example Assuming that all routers and hosts are work- Ing properly and thatll software in both is ree ofall errors, is there any chance, however smal, that a packet will be delivered to the wrong destination? Answer: There is lays a chance that a packet will be delivered incorrectly or even tally lost. Interference and noise on the transmission lines can interfere with and ere- ate corruption that interrupts the delivery of packets on a network. Example To what docs the word node (host refer? Answer: A node oF host Is any addressable device at tached toa network, [Name and describe two key fstues related to computer net- works. Data teansfer rate: ‘The speed with which data is moved across the network. Protocol: The set of rules that define how data is formatted and processed across a network Example Describe the client/server model and discuss how bas it has changed how we think about computing. 1 Answer: The client/server is a model in which resources tare spread across the web, The client makes a request for {information or an action from a server and the server re- sponds, For example, a file server, a computer dedicated to storing and managing files for network users, esponds to requests for fle, A web server, computer dedicated tore- sponding to requests for web pages, produces the requested page. Before the client/server model was developed, a user ‘thought of computing within the boundaries ofthe comput: erin feont ofhim of her. Now the functions that were pro- vided within one computer ae distributed across a network, with separate computers in charge of different functions. Example 1 Answer: A local-area network connects a relatively stall ‘number of machines ina relatively close geographical arca, Just how local is a loca-area network? Computer Netwerks | 7.89 networks that da not use the same system. Networks using, ‘open eystems can all communica Example | What isthe seven-layer logical breakdown of netivork interaction called? Answer: Open Systems Interconnection (OSI) Reference Model Example What isa protocol stack and why is it ayered? Answer: A protocol sack i layers of protocols that build and rely on each other. Protocols are layered so that new protocols can be developed without abandoning funda- ‘mental aspects of lower levels, Example What is a firewall, what does it accomplish, and how does it accomplish i? Answer: A firewall is a computer system that protects a network from inappropriate access. A firewall filters in- coming teatlc, checking the validity of incoming messages, and perhaps denying access to messages, For example a LAN might deay any remote access by refusing all talfic that comes in on port 23 (the port fr telnet) Example | What is» hostname and how ist composed? Answer: A hostname isa unique identification fora spe- cific computer on the Internet made up of words separated by dots "Example posed? Answer: An IP address is made up of four numeric ¥ tues separated by dots that uniquely identifies a computer on the Internet. Example What is the relationship between a hostname and an IP address? Answer: Hostnames are for people and IP addresses are for computers, Each hostname is translated into a unique IP adéress. People refer to the machine by its hostname; computers refer to the machine by its IP address. "Example Answer: An IP addeess can be split into a network ad dress, which specifies the network, and a host numbes, which specifies a particular machine on the network, Example How mony hosts are possible in Class C net works, in Class B networks, and in Class A networks? What is an IP adress, and how is it com- Into what parts can an IP address be split? Answer: Class C networks use three bytes for the net= work number and only one byte for the host number, so they can identify 256 hosts. Class B networks use two bytes for the network number and two bytes forthe host number, so they can identify 32768 hosts. Class A network use one byte for the network number and three bytes forthe host ‘number, so they can identify 224 host, Example What is a domain name? Answer: A domain name is that part of the hostname that spocities the organisation or group to which the host belongs. Example Answer: The last part of a domain name that specifies the ype of organisation or its country of origin Example How does the current domain name system try to resolve a hostname? 1 Answer: First a requests sent to a nearby domain name server (a computer that attempts to translate a hostname into an IP address). IF that server cannot resolve the host name it sends a request to another domain name server, If the second server can't resolve the hostname, the request continues to propagate until the hostname is resolved or the request expires because it took too much time, Example Frames are generated at node A and sent to node C through an intermediate nade B. Distance between ‘Aaand B is 4000Km while B and C is 1000Kna. Determine the minimum transmission rate required between nodes ‘nd C so thatthe butfers at node B are not flooded, based on the following: ‘©The data rate between A and B is 100 kbps ‘© The propagation delay is 5 msec/km for both the lines ‘© There are full duplex, error free lines between the nodes. ‘©All data frames are 1000 bits longs ACK frames are separate frames of negligible length + Betwoen A and B «sliding window protocol is use, with a window size of 3 (three). ‘Between Band C, stop and wait is used. Answer: In order not to ood the butfers of B, the average number of frames entering and leaving Bk must be the same over a long interval ‘Ato B: Propagation time = 4000" 5 msce = 20 msec ‘Transmission time per frame = 1000/(100"103) = 10 msec B to C: Propagation time = 1000" 5 msec = 5 msec ‘Transmission time per frame = x = 1000/R Fame time in between A to B=1000bits/100Kbps Rw data rate between B and C (unknown) ‘Acan transmit three frames to B and then must wait for the acknowledgement of the ist frame before transmitting additional frames, The first frame takes 10 msee to transmit between A to B (frame time); the last bit ofthe first frame arrives at B 20 msec afer it was transmitted and therefore 530) msec afer the frame transmission began. Itwill tke an additional 20 msec for B's ack to retuen to A. Thus A can Uwansmit three frames in 50 msec. What isa top-level domain name? lomsec Computer Netwerks | 7.87 o Transmission ofPackat (Osea) Transmission (seo) ofPackat? (02600) ofPacket? (ose) Example When using virtual-circuit transport, the virtual-citcuit setup time is 400ms. Packets travel over a path that goes through 10 links and each kink i 9 56 kbps line, Each packet contains a 7-byte header and 400 bits of data, When using a datagram transport, cach packet containsa 12-byte header and 400-bit data. However, there sno circuit setup delay. In the following parts, ignore the processing delay, propagation delay and queuing delay (@) How long docs it take to transmit N packets using virtual-circuit transport? (b) How long does it take to transmit N packets using da- lagram transport? () For what values of Nis the transfer by virtual-circuit transport faster? For what value of N is datagram Uwansport faster? Answer: (a) The packet size isthe size of data + the size of header = (400 + 56) bits = 456 bits. ‘Time to transmit 456 bits = 456/55k = LAs. “The transmission of N packets over 10 links takes, N°8.14ms + 9°8.44ms. Adding the setup-up time, the total delay i 400ms + N°8.L4ms + 9°8,L4ms = 473ms-4-N°8.Lime, (b) The packet size i the sizeof data + the sie of header (400 + 96) bits= 496 bits snsmit 496 bits = 496/56k = 8.86ms. ‘The transmission of N packets over 10 links takes, N*S.6ms + 9*8.86ms, “There is no setup time. As result, the total delay N*8.6ms + 79.74, (6) The two are almost equal when N = 548. ‘Therefore, for messages that are shorter than 548 packets, use datagram transport, Otherwise, use virtal-citcut ser vce, Example Suppose a 100-Mbps point-to-point link is being set up between the earth and e new lunar station which is approximately 385000km from earth, and data travels over the link at the speed of light (3 x 108 m/s). The transmission i reliable and sliding window. based (a) Calculate the minimum Round Trip Time (RTT) for the link, (b) Using the RTT asthe delay, calculate the delay x band ‘width product for this link, (c) What is the maximom number of bits that can be in transit at any one point? (2) A camera on the Innar base takes pictures of the earth and saves them in digital format to disk. Sup- pose Mission Control on earth wishes to download the most current image, which is SMB. What is the ‘minimum amount of time that will elapse between when the request for the data goes out and the trans- fer is finished? mAnsw (a) The minimum RTT is two times of the propagation delay on the link = (2*385000000)/3*10" = 2.57s (b) Thedelay-bandwidth product =(2.57)*(100 Mbits/s) :STMbits = 32M bytes. (6) Same asthe delay bandwidth product (@) It would then take (1/2) RUT for the earth to make the download request and another (1/2) RTT for the propagation delay for sending the data from the ‘moon to the earth. The total time isthe sum of the transmission time and the two (1/2) RTT. :SMB/IOOMbps + (1/2) Minimum amount of time’ RIT + (1/2) RTT 00M /100Mbps + 2.57 s 254257 =4578 Example Suppose the ength of a 10BaseS cable is 2500 metres, IF the speed of propagation in a thick coaxial cable {is 200,000,000 m/s how long docs it take for abit to travel from the beginning to the end of the network? Assume that there isa 10s delay inthe equipment Answer: A typical 10BaseS network will be having a maximums length of 500 metres, so repeaters should be in- serted into the cable in order to ensure transmission is pos- sible over the fall length ofthe 2500m cable. Four repeaters fare required as shown below: “Thus, time noeded for 1 bit to transfer from one end to the other is=4 x 10ys + 2500/200,000,000 = 52.5ys 138) computer Science & Intonation Technlogy for GATE seuee —Repantor Repent; —-Rapener———Repater Destin X Example The data rate of 10BaseS is 10Mbps, How av) foe long does it take to create the smallest frame? Answer: The smallest frame is 64 bytes or 512 bits, With a data rate of 10 Mbps, we have Ty, = (S12 bits) J (10 Mbps) = 51.2 Hs “This means that the time required to send the smallest frame isthe same at the maximum time requited to detect the collision. Example Given the dataword 1010011110 aad the divi sor 10111 (a) Show the generation of the codeword atthe send- er site using binary division (6) Show the checking of the cadeword atthe receiv= crsite assuming no error has oecurted. (o) What isthe syndrome atthe resever end ifthe H dataword has an error in the 5” bit position + counting from the right? Namely: dataword of 1010001110 is received. ototo s Answer: (a ney svn ene (© Suppose that we received the corrupted dafaword with ey onsen the old CRC value as follows: 1O100011101010, We ean eens boss tio1010 determine the syndrome in ths case a-0010 we [rfetrtetetepeps po c + Spe a TOL La]—] "Example What isthe use of subnet mask? ‘Re Gheeksum| “| w answer: The subnet mask enables us to subdivide a¢- dresses to achieve more useful mixes of host and subnets (b) At the receiver, result of division operation Is given be- fora given range of addresses, low. We find checksum as 0000 rina eso Computer Netwerks | 7.98 Example Given IP address 136.27.32.104 and subnet task of FFFFFE00, thich class network isi, how many: subnets are there, and what isthe host address MAnswer: Binary squivalent of given IP address: 13627.32.104 = 10001000 0001 1011 00100000 01101000 est two bits ate 10, thus it i class B type of network. “Thus, most significant 16 bits indicates the network ad- ress. Now consider the net mask’s binary equivalent 1111111111111111111000000000, As we have seven Is af ter first sixtoon 1's, we willbe having.2” subnets. Also, least 9 bits are for host from last nine zeros in net mask). Host ‘number is 001101000=104, Example Consider the quewing delay in a router buffer With infinite size. Assume that each packet consists of L. bits, Let R denote the rate at which packets are pushed out of the queue (bits/sec) (2) Suppose that the packets arrive periodically every L=R seconds. What isthe average router queuing delay? Answer: Zero, (6) (0.5) Suppose that N packets arrive simultancously ev- ery (LIR)N seconds. What is the average router queving, delay? Answer L/RY(N-1/2 second Example Differentiate Non- HTTP connections, ctsistent and persistent Answer: Non-persistent © HTTP/LO © server parses request, responds and closes TCP con- nection # 2RTTs to fetch each object ‘Each object transfer sulfers from slow start Persistent © default for HTTP # on same TCP connection: server, parses request, re sponds, parses new request. # Client sends requests for all referenced objects as soon asi receives base HTML. Fewer RT'Tsand less slow stat. Example A uscrin Delhi, connected tothe internet via 8.2 Mb/s connection retriever a 25 KB (B=bytes) web page from a web server in Mumbai, where the page references 3 ‘mages of 200 KB each, Assume thatthe one way propaga: tion delay is 20 ms. Approximately how long does it take for the page (including images) to appear on the user's sercen, assuming non-persistent HTTP using a single connection atatime? Answer: In non-persistent HTTP connection, every ob- Jct request is dealt separately by establishing separate con- nection for each, For every request, we need 4 RTT which includes two RTTs for fetching object in addition to re- {quests and responses. Thus, time needed to Toad the page = 4°(80 ms) + (8°(25+3"200) Kbits)(2 Mb/s) = 320 ms + 2.5 see = 2.82 see m= Example Suppose within your web browser you click ona link to ob- taina web page, Suppose that the IP address forthe associ sted URL fs cached in your local host, so that a DNS look up isnot necessary. Further suppose that web page associ- sted with the link contains a small amount of HTML text 3s well asN very small objects. Let RTT denote the round trip delay betwecen the local host and the server containing the objects. Assuming zero transmission time ofthe objects, (a) With non-persistent HTTP with no parallel TCP connections, how much time elapses from when the client clicks on the link tntil the client receives the objects? Answer: T=RIT (TCP establishment) + RTT (for HTML base file) Total Time elapsed is (N+1)*T (b) Repeat (a) for non-persistent HTTP with parallel connections, Answer: T=RIT(TCP establishment) +RTT (for HTML base file) Total Time clapsed is 2"T. This is hecause the client will parse the HTML base file and he should find the referenced objects. Then it established a separate TCP connection in parallel for each object, (c) Repeat (b) for persistent HITTP with pipelining. Answer: {TT (TCP establishment) + RTT (for HTML base file) Total Time elapsed is T+ RTT. This is because the cli cent will parse the HTML base file and he should find the referenced objects. Then it sends requests to all referenced objects using pipelining method. The as- ‘sumption here is that all these N objects are on the Example A user i Lucknow, connected to the inter net via a 20 Mbs (b=bits) connection retrieves a 250 KB nes) web page from a server in Chennai, where the page references 4 images of | MBeach, Assume that the one way propagation delay is 25 ms. Approximately, how long. does it take for the page (Including images) to appear on the user’ screen, assuming non-persistent HTTP using a single connection ata time (fr this part, you should ignore {queueing delay and transmission delays at other links in the network)? Computer Netwerks | Tat re ‘The following iguee illustrates pecrshelpingin distributing, the fle among the multiple clients, Important point in this approach of distributing file Start witha singe copy of large file Large file with Fbits and server upload rate u, ~ Peer with download rated, and upload rat + Two components of eistibution latency ~ Server must send each bit min time Fa, ~ Slowest peer receives each bit: min time Fd, + Total upload time using ll upload resourees ~ Total number of bits: NF ~ Total upload bandwidth u, + sum () Total: maxfflty Fldyig NEMucsuni(u))) Example (2) Considers situation in which 1000 clients are trying to download a 10 MB file from a server. Ifthe server hasa 100 Mb/s access link and the clients have access links with a downstream rate of 2 Mb/s, how long, does it take to download the fle to allelients, under ideal eon tions (you may ignore the time to establish a TCP connee- tion tothe server) WaAnswer: The total download bandwidth is 2 Gb/ (1000x2Mb/s),s0 the server’ access Bandwidth is the limiting factor. The namber of bits that the server must send i 80 gigabits (1000x10MB=1000s10x10°x8bits), s© under ideal conditions, it would take about 800 seconds(S0gigabits/100Mb/s-80x10"/100x10°) to deliver the file to al clients. (b) Now, consider the peer-to-peer situation, in which there is no server and one peer holds the file to be distrib- tuted. Assuming that the upstream rate from each peer is | bis and the downstream rate is 2 Mb/s, how long, dacs i take to distribute the file to all peers? "Answer: In this case, the limiting factor isthe upstream rate from the peers, so the time is 80 Mb/(1 Mb/s), so 80 seconds, That i, ile size divided by upload speed of peer ts explained in the previous question Example The diagram at below shows the state of the sending side of a sliding window protocol with a window size of 4 and the selective repeat feature, The array repre- sents the send buffer and each pair inthe butfer represents 1 packet and its sequence number, together with th time at Which itis scheduled to be retransmitted. (60, for example, the pair (93,14) denotes a packet with sequence number 3, Which is to be retransmitted at rime 14). Assume that the timeout used for retransmitting packets is 20 time units. ren 00) (et72) 4 Suppose that at time 7, the application passes us a new payload to be sent, at time 8, we receive an ack with ‘sequence number 3, and that a time 9, we receive an ack with sequence number 2. Show the state of the sonder at time 10, in a diagram. », Ifno addtional payload ot ack is received before time 25, whats the next thing that should happen and how oes it affect the sender’ state? Answer: (a) Ifwe observe the given figure, we may find that there are 3 packets under transmission and window see is 4, Thus, when new payload arrives at 7, st will be sent by making it retransmission time as 27 (7+timeout for retransmission=7+20). Do remember that its sequence ‘number Is taken a 5 and nextSeqNum is made as 6, The following figure illustrates the state of the sender at time 10, roxsoghun6 3 [eazy s | wszn TAB) computer Science & ntrmation Tecnlogy foe GATE Origin Servers Eiiy ac nanet mu es & 10.Mbps LAN Answer: 1, Response time T can be calculated as follows: objectsize 0.910" Sx BIS access linespeed BLS requestss = 044.1506 requestsis A,=065 0.095 1, Bada Finally we can calculate response time as: “1,4 0 * T; = 2sec( App) Response time for HITTP requests in this institutional network can be reduced by around 75% if proxy is intro- duced, provided that the hitrate equals to 0.4 Example Consider an overlay network with N active peers, with each pair of peers having an active TCP connec- tion. Additionally, suppose that the TCP connections pass through a total of K routers, How many nodes and edges are there inthe corresponding overlay network? Why? Answer: N nodes and N(N-1)/2 edges. The edges of the overlay network are formed by the individual TCP connee- tions. Routers are not part of the overlay network since they operate atthe lower network layer. =0.0951 mM Example Consider a reliable data transfer protocol th tases only negative acknowledgments (NAKs). Suppose the sender sends data only infrequently. Would an NAK only protocol be preferable to a protocol that uses aeknowledg- ments (ACKs) only? Why? Now suppose the sender has a lot of data to send and the end-to-end connection experi- ences few losses. In this case, would a NAK-only protocol be preferable to a protocol that uses ACKs? Why? Ansyrer: In an NAK only protocol, the loss of packet x is only detected by the receiver when packet x+1 is eccived, That is the receivers receives x-1 and then x#1, only when x+l is received docs the receiver realise that x was missed. If there isa long delay between the transmission of x and the transmission of x+1, then it will be long time until x can be recovered, under an NAK only protocol. On the other hand, if datas being sent often, then recovery under an NAK: only scheme could happen quickly. Moreover, if errors are Infrequent, then NAKs are only occasionally sent (when rneoded), and ACK are never sent ~a significant reduction n feedback in the NAK-only case over the ACKonly case m Example What isthe destination MAC address of the frame when it eaves the sender host? Whats the destination MAC address ofthe frame when it leaves the router?Which protocols used to determine the destination MAC address? Answer: ARP protocol is used. ‘A router implements both link and network layers. A datagram (a network layer packet) Keeps its destination ad- des sit travels through routers. Ifa router were to change the destination IP address eg to the IP address of the next hop router link interface, it would be impossible for the next router to forward the datagram to its original destina tion, On the other hand, the link layer destination address can be (and is) changed across different subnets. Nodes in different subnets nood to make an ARP lookup to find the destination MAC address Example Consider the given network, The nodes in this network run the distance-vector algorithm synchro- rnously using time slots, In given time slot, all nodes re- ceive distance vectors of thelr neighbours, update their own distance vectors, and signal the changes in their distance vectors to their neighbours. Using the distance-vector algo- rithm, calculate the distance vectors at node D at each time slot until there are no more distance-vector updates ex- changed among routers, Assume that the nodes only know their distances to their direct neighbours initially. TAB) computer Science & Intrmation Technclogy for GATE (6) No packet will be missing. All will be available for playing. Packets Packets arved wo Al pla instances ar blow ° (exon) the packe aval pot 8 ‘A packets can be played out 1 ‘nme 6 5 3 2 ' fq GB Wt tw to ty ba ty te ta he ty he fy to Example In modem packet-switched networks, the b, Nowsuppose thatthe message sogmented into 4,000 souree host segments long, application-layer messages (for «example, an image or a music fils) into smaller packers and. sends the packets into the network. The receiver then re- assembles the packets back into the original message, We refer to this process as message segmemuation. Figure il lustrates the end-to-end transport of # message with and without message segmentation, Consider a message that is 8:10" bits long that i to be sent from source to destination in the figure. Suppose each link in the figure is 2 Mbps. Ignore propagation, queuing, and processing delays, Messoae Packet teh Destination ‘Source Figure Enéto-End message transpr: a) without message segmentation; (b) with message segmentation, Peketowien Packet ewich Destnaton 8, Consider sending the message from source to desti- nation without message segmentation. How long does it take to move the message from the source host to the first packet switch? Keeping in mind that each switch uses store-and-forward packet switching, what fsthe total time to move the message from source host to destination host? Answer: Time from source hos to first packet switch = 8*10°/2* 10° =4 see, Totaltime=4* hops = 12.ees packets, with each packet being 2,000 bits long. How Tong does it take to move the ist packet from source host tothe first switch? When the first packet is be {ng sent from the first switch tothe second switch, the second packet is being sent from the source host to the first switch. At what time will the second packet be fully received at the fist switch? Answer: Time to send first packet [rom source host to first packet switch =2* 10° /2* 10° = 1 msec. Time at which second packet is received atthe first switch ame at which fist packet is received atthe second switch =2* L msce = 2msee How long does it take to move the file from source host to destination host when message segmentation 4s used? Compare this result with your answer in part (@) and comment. Answer: Time at which first packet is received atthe destination host = msec* 3 hops = 3msec. After this, every 1_msee one packet will be received; thus time at which last (4000) packet is received = 3 msec + 3999"Imsee = 4,002sec. It can be seen that delay in using message segmentation is significantly Tess (al most 1/3). 4. Discuss the drawbacks of message segmentation. “Answer: Packets have to be put in sequence at the destination, 2. the total amount of header bytes is more Example Consider the Go-Back-N protocol. Suppose thatthe size of the sequence number space (number of ‘unique sequence numbers) is N, and the window size is Show (give a timeline trace showing the sender, receiver and the messages they exchange over time) that the Go- Back-N protocol will not work cosrectly inthis case SO) computer Science & Information Tecinlogy foe GATE MExample Supposeall of the network sources send data st constant bit rate. Would packet-switching or circuit switching be more desirable in this case? Why? 1 Answer: Circuit-switchingis more desirable here as there no statistical multiplexing gains to be had, and by us- ing circuits, each conneetion will get a constant amount of bandwidth that matched its CBR rate, On the other hand, circuit-switching has more overhead in terms of signaling, so there i an argument that packetswitching is beter here since there is no call setup overhead. One can say ether ofthem is OK. MExample Suppose fll the network sources are bursty = that they only occasionally have data to send. Would packet-switching or clgcuit switching be more desirable in this case? Explain, Answer: Packet-switching is better here because there ate statistical multiplexing gains ~ when a source does not hhave data to send, it will not be allocated bandwith (that Would be idle). Hence this bandwidth is available for use by other sources Example Describe the use of the “If Modified-Since’ header im the HTTP protocol Answer: When a web client or web cache has a copy of previously requested document, its GET request to the server includes an I-madified-Since line that gives the time at which the browser/cache received the copy of the docu- ment. If the document has not been modilied at the web server since this time, the web server neod not (and will not) send a duplicate copy of the document. Example What does it mean when we say that conteol ‘messages are “in-band”? Answer: It means that control message and data mes- sages may be interleaved with each other on the same con- rection, Indeed a single message may contain both contral information and dat. Example What does it mean when we say that conteol messages are “out-of-band”? Answer It means that control and data messages are cavried on separate connections. One example ofa protocol that has out-of-band control messages (Answer: PTP). Example Give example protocols that has in-band con- teol messages. 1 Answer: Examples includes HTTP, DNS, TCR, SMTP). Example Consider @ TCP connection between hosts A and B. Suppose that the TCP segments from A to B have source port number x and destination port number y. ‘What are the source and destination port numbers for the segments traveling from B to A? Answer: Source port isy, destination port is x. Example What is the purpose of the connection-ori- ented welcoming socket, which the server uses to perform an aecept(J? Once the aecept() is done, does the server use the weleoming socket to communicate back to the client? Explain. Answer A connection oriented server waits on the wel coming socket for an incoming connection request. When that connection request arrives a new socket is created the server for communication back to that clint MExample Suppose a web server has 1000 ongoing TCP connections, How many server-side sockets are used? How ‘many server-side port numbers are used? Explain 1 Answer: lithere are 1000 ongoingconnections, and noth- {ng clse happening on the server, there will 1001 sockets in tuse~ the single welcoming socket and the 1000 sockets in tse for server-to-cient communication. The ONLY server- sideport number In use at the server willbe the single port ‘number associated withthe welcoming socket, eg. port 80 fon a web server Example Consider the networks shown in the figure below. There are two user machines www.ritch.com and wwvwaarada.com in the network a.com. Suppose the user at wwwaritch.com types in the URL wwwappu.convbigfile, bhtm into a browser to retrieve a 1Gbit (1000 Mbit file from \wwwappu.com. TM bps Intrnot in ach crecton) ~ Rt ‘ OG; = lee a List the sequence of DNS and HTTTP messages sentire- ceived from/by wwweritch.com as well as any other messag- that leave/enter the a.com network that are not directly sent/received by wwwisiteh.com from the point that the URL is entered into the brovser until the il is completely 2) _ computer Science & ntrmation Technclogy foc GATE ‘retransmission, To handle losses in the channel timers are used. If the ACK for a transmitted packet is not received within the duration of the timer for the packet, the packet (or its ACK or NACK) is assumed to have been lost. lence, the packet i retransmitted, Example Consider a datagram network using 8-bit host addresses. Suppose a router uses longest prefix mateh- {ng and has the following forwarding teble: Prefix Match Interface 0 u t un 2 otherwise 3 For each of the four interfaces, give the associated range of destination host addresses and the number of addresses inthe range. Answer: Destination Address Range 0000000 ‘through (64 addresses) o ro1itiit 11000000 throwgh(32 addresses) 1 HOI 11100000 ‘through (32 addresses) 2 unt ‘0000000 ‘through (128 addresses) 3 out Example Do the routers in both datagram network and virtual-cicuit networks use forwarding tables? IF 0, escribe the forwarding tables for both lasses of notworks. Link Interface Answer: Yes, both use forwarding tables. For a VC for- warding table, the columns are : Incoming Interface, In- coming VC Number, Outgoing Interface, Outgoing VC ‘Number. Fora datagram forwarding table, the columns are: Destination Address, Outgoing Interface. Example Why is an ARP query sent with a broadeast frame? Why isan ARP response sent within a frame with a specific destination MAC address? Answer: An ARP query is sent in @ broadcast frame be- cause the querying host does not which adapter address corresponds tothe IP address in question. For the response, the sending node knows the adapter address co which the response should be sent, so there is no need to send a broadcast frame (which would have to be processed by all the other nodes on the LAN). mExample Define switches and routers and explain pros (at last two items) of switches comparing with routers. Answer: A router is a layer-3 switeh and a switel is a layer-2 packet switch. The pros are switchs plageand-play, high filtering and forwarding, Example Why are acknowledgements used! in 802.11 bout not in wired Ethernet? 1 Answer: The adapter would not beable to tes al ol sions due to hidden terminal problem and fading. "Example Define terminologies such as streaming, packet jitter, policing and realtime. ™ Answer: Streaming: playing’ out while downloading file Packet iter: the variation of packet delay. Policing: the regulation of the rate at which a class or low isallowed to inject packets into the network Real-time: response tims wil be wry less Example What are the dilleences between message confidentiality and message integrity? Can you have one wwthout the other Justify your answer. " Answer: Considentaity is the property that the orig nal plaintext message cannot be determined by an attacker who intercepts the ciphertex-encryption of the original plaintext message. Message inteprity i the property that the ceceiver ean detect whether the message sen (whether cnerypted or nat) sa altered in transit. The two are thos diferent concepts, and one can have one without the other ‘An encrypted message that i altered in transmit may stil be confidential (the attacker cannot determine the original plaintext) but wil not have message integrity ifthe error ds undetected. Similary, a message that i altered in tans (and detected) could have been sent in plaintext and thus would not be confidential Example What i the purpose of a nonce in an end- point authentication protocol? Answer: A none is used to ensure that the person be- ing authenticated is "live® Nonces thus are used to combs playback attacks Example Compare and contrast between Connection: Oriented communication service and Cannectionless com- ‘munication service? 1 Answer: Some ofthe principle characteristics of the con- nection-oriented service are ‘© Two end-systems first “handshake” before either starts to send application data tothe other + Provides reliable data transfer, i. all aplication data sent by one side ofthe connection arrives atthe other side ofthe connection in order and without any gaps. ‘© Provides flow control, i, it makes sure that nei- ther end of a connection overwhelms the buifers in TA computer Science & Information Tecnlogy foe GATE Example State the four fanctions ofthe Answer: a, Framing b. Reliable data transfer «, Flow control link layer. 4. Channel access control MExample MAC Protocols can be classified into three broad classes. State these classes and give an example for each one, Answer: 8, Channel partitioning (eg. CDMA, FDMA, TDMA) b, Random access (eg. ALOHA, CSMA, ete) Token turns (eg. token ring, polling) Example What is the access methodology used in Ethernet technology? (please note abbreviation alone isnot accepted) Answer CSMA/CD (Carrier Sense Multiple Access (Collision De- tection) Example In order to have efficiency of 0.6, what should be the distance between hub and a node in a 100baseT Ethernet LAN. Assume propagation delay is 200m/usee and frame size is 64 bytes. op =A/200%10" ‘oabytes/100Mbps = 64°8/100°10°= effleency = 1/1458) = 0.6 “Therefore, A=0.133 = tyop!oan 0.133 =€/200x10°/ 5.1248 Therefore, distance d = 184m Example Distinguish from the operational point of view between CSMA/CA and CSMA/CD protocols. Also, explain why CSMA/CD is difficult to apply in wireless en- vironment, CSMAICA is cartier sense multiple aecess/colision avoidance ‘CSMA/CD is cartier sense multiple access collision de- tection. Then CSMA/CA is based on avoiding the collision and detection the collision. Therefore, the protocol takes several measures to assure avoiding collision. ‘Using CSMA (by sensing before transmission) Answer 12ps ‘Using reservation theough special requests, namely “ready-to-send” (RT'S) and “clear-to-send” (CTS) Where the first one is sent by the sending mobile While the other is a response from the receiving mobile ‘Using diferent inter frame gaps (DIPS, SIFS) Random backoff when collision occurs Also CSMA/CS requests the receiver to send ACK frame to acknowledging the reception of the frame. This ACK is rot part of COMAICD (On the other hand, CSMA/CD is design such that colli son can be detected therefore, there ar restrictions om the length ofthe Frame, network segment length and s0 on CSMA/CD is very dfcult to implement is wireless net- work because ofthe following Very noisy channel ‘© Receptionytransmission should be carried out on the same channel to be able to detect the collision and this is very difficult to implement is wireless network Example Illustcate with figure where multiplexing and de-multiplexing takes place in the internet layers = Answer — — ee pos umber (FG) (uBR) YOR om There ‘Multiplexing/demultiplexing in the layers. Example Explain how multiplexing is done at 1P layer? Answer In the IP case, cach protocol using IP is as- signed a unigue protocol number, which is earried in the Protocol IP header field in every packet generated by the protocol. By examining the value ofthis field of an incom: ing IP datagram, the type of payload can be determined. Example Explain how multiplexing is done at DLL? Answer Example 1 Answer: In order to provide the flexibility administration and operation, the subnetting technique was introduced, where an IP address is further divide into three levels:a network ID, a subnet [D, anda host ID. With subnetting, IP addresses can be assigned using a finer gran- ularity, eg.a small organisation can be assigned a subnet address that just satisfies its requirement. In addition, with suibnetting, an organisation can divide its assigned network Prame Type What isthe use of subnetting? in network TSB) computer Science & Intrmation Technlogy foc GATE following settings? Assume thatthe round trip times domi- nate all other times. a. HTTP 1.0 with no parallel connections Answer: 2 RIT per file fora total of 62 b, HTTP 1.0 with up to 10 parallel connections 1 Answer: 2 RTT for the base file, plus 6 RTT for the em- bedded images, for a total of 8 HTTP 11. with no pipelining Answer: 2 RIT for the base file, plus L RTT for each of the remaining files, fora total of 32. 4. HTP 1.1, with pipelining Answer: 2RTT for the base fle, and | RT'T for the re- maining files, for a total of | RTT. Example Assume that a TCP process A frst measuces the actual round trip time to another TCP process to be 30 rms, and A thus sets its estimated round trip time to be 30 ims. The next actual round trip time that A sees is 60 ms. In response A increases its estimated round trp to 50 ms. The ‘next actual round trp time that A secs is 40 ms. What is the next estimated round trip computed by A? Justify your Answer: TCP uses an exponential weighted moving av erage, that i, ‘New EstimatedRT'T=x OldEstimatedRTT + (1-x) Ne- wObservedRT'T. ‘So when the estimated RTT of 50 calculated, we know that 50 = x 30 + (L-x) 60, so x=1/3. Plugging into this for- ‘mula to compute the new estimated RTT gives 1/3 50+2/3 40 = 13003 = 40 173 Example Assume server A creates sockets by supply: ing it P address 1.2.3.8 and port number as 1 tothe Socket system call Then it calls bind, listen system calls. Another hhostereates socket and calls connect system call By supply- ing 1.23.5 and 81 as parameters. One more host also does the same. Assume on A, connection oriented service is ex- tended, How many sockets are in total crested on A, and hhow many ports are in use on A? Answer: 3 and 1 Example Consider a packet with a total length of 250 bytes (including IPv4 header, with no options) and an id field equal to 17, sent from a host A to a host B, passing, through routers X and Y. Assume that the subnet where host is connected has an MTU of 500 bytes, the subnet where host Bis connected has an MTU of 80 bytes and the subnet between Xand Yas an MTU of 120 bytes. Assur ing thatthe “dont fragment” flags not set, how many frag- iments docs router X divide the packet into? What is the length of each fragment? Answer: The payload has 230 bytes and each packet in the subnet joining X and Y has room for a 100 byte payload, but since 100 is not divisible by 8, well have 96 bytes in the initial fragments, So, there are 3 fragments with payload sizes of 96, 96 and 38 giving packet sizes of 116, 116 and 58 1 Complete the diagram below so that it represents the first two fragments forwarded by router ¥ (nor X). Fill in all the blanks, ofc oifset= ayload Tength payload Tength Answer: First two fragments are the one which can be formed by dividing first fragment having payload length ‘of 96 and coming out from X. As, MTU in the network in Which host B is available is 80, this 96 onehas to be divided, Do remember that payload. sizes has to be multiples of 8 bytes. Thus, 96 is divided into 56 and 40, According two fragments are created with the following field values. MP=1 [officio Mi=1 [otfsei=7 ‘payload ‘payload Tength=s6 Tength=40 b. Suppose host 4 sends a 50 byte packet withthe “don"t fragment” flag set. Explain what happens to this packet at each ofthe two routers Answer: This packet is shorter than the MTU of all sub- nets, so it wll be delivered to B without any fragmentation. Example Suppose a TCP message that contains 2048 bytes of data and 20 bytes of TCP header is passed to LP for delivery across two networks ofthe Internet. The first net work uses 14 byte headers and has an MTU of 1024 bytes: the second uses &-byte headers with an MTU of S12 bytes. Bach networks MTU gives the size of the largest IP data igram that can be carried in a link-layer frame, Give the sizes and offeete of the sequence of fragments delivered to the network layer at the destination host. Assume all IP hheaders are 20 bytes. Note, the IP requites that fragmenta- tion should always happen on 8-byte boundaries, 1 Answer: Consider the first network. Packets have room for 1024 ~ 20 = 1004 bytes of IP-Level data; because 1004 Is not a multiple of 8 each fragment ean contain at most 8x foor{(1004/8)) = 1000 bytes. We need to transfer 2048 + 20= 2068 bytes of such data, This would be fragmented into fragments of size 1000, 1000, and 68. Computer Netwerks | 7.59) Fragment Sine Offest 1 1000 0 2 1000 1000 3 os 2000 Over the sevond network, the 68-byte packet would be un- fragmented but the 1000-data-byte packet would be frag- mented as follows, The IP header is 20 bytes, leaving $12- 20 = 492 bytes for IP-level data. Again rounding down to the nearest multiple of 8, each fragment could contain 488 bytes of IP-level data. 1000 bytes of such data would be- come fragments with data sizes 488, 488, and 24, Fragment Size Offest 1 48 0 2 “488 88 3 2 376) 4 a8 1000 5 488 mz 6 2 1976 7 my 2000 Example Host A son LAN | and host Bis on LAN 2. ‘The two LANs are interconnected by a router. The MTU of the two LANs are 1000B and S0OB, respectively. Suppose an application on host A executes $000 writes to an appl cation on host B. Each write results in one MTU sized IPv4 packet on LAN 1. Each packet consists of an IP header (20B) and the data. The IP headers do not carry any op- tions. How many packets from hest A to host B uaverse LAN 2? What are the sizes of the packets? Answer: Each IP packet has 20B of header and 9808 of payload. The first fragment will be S008 long, with 208 of header and 4808 of payload. The second fragment will have the same header/payload sizes. Tis leaves 208 of payload left ‘which will go into the final fragment, making the fragment size 408, In ll, there will be 15,000 packets on LAN 2. Example Suppose that a TCP message that contains 1964 bytes of data and 20 bytes of TCP header is passed to IP for delivery across three networks of the Internet (i. from the source host toa frst router to a second router tothe des- tination host). The first network uses H4-byte headers and hhas an MTU (maximum transmission unit) of 1024 bytes; the second uses 8-bytos headers with an MTU of $12 bytes; the third uses 16-bytes headers with an MTU of 4500 bytes. Each network’ MTU gives the total packet size that may be sent including the network header, Give the sizes an offsets ofthe sequences of fragments delivered to the network layer at the destination host, Assume all IP headers are 20 bytes, Answer: ‘TCP message = payload + TCP header = 1964 + 20= 1984 bytes First network: MTU = 1024 = link header + IP header + payload = 14 bytes + 20 bytes + TCP data TCP data = 990 bytes but 990 snot in multiples of 8. TCP data fragment must be 984 Which is in multiples of 8. Therefore the first network gen- erates three fragments (size offset) = (984, 0), (984, 123) Second network: MTU =512= link header + IP header + payload = 8 bytes + 2 bytes + TCP data TCP data = 484 bytes but 990 is not in multiples of 8. TCP data fragment must be 480 that isin multiples of 8. ‘Therefore the second network generates 6 fragments (size, offset) = (480, 0), (480, 60), (24, 120), (480, 123), (480, 183), (24, 243) “Third network: ‘The third network only forwards 6 fragments (size, offset) = (480, 0), (480, 60), (24, 120), (480, 123), (480, 183), (24, 243) 10 te destination host heeause is MTU is 4500 bytes, that is lager than the size of ineoming packets. Example The diagram below shows a network with 3 routers (shown as hexagons) connected by an Fthernet switch. The routing table for the left-hand router is shown, ymplete the routing table for the right-hand router, so that packets wil be delivered appropriately (use no more than 5 route table entries) Answer: Right hand sie routers, routing table looks ike: ‘ext hop pein ‘tpt ie 122028 L 1252 123024 1 1254 125024 t 12.1029 3 = 121189 2 - Computer Science & Information Technology for GATE a. Ifa switch was inserted between the host with IP address 1.23.2 and its router, how many hosts could be added to that switch, without having to change the routing table en- tries? What IP addresses would those hosts use? W Answer: A /29 profs contains 8 addresses. Since 2 are al- ready in use, so this leaves addresses 1.23.0,12.33, 123.4, 1.235, 1.2.36 and 1.237. So 6 hosts eould be added. This fs actually not quite right, since there i a special rule for subnets. The first address in any subnet range (the address efined by all eros) is generally interpreted as the “subnet address” and isnot supposed to be used by any host. In ad- ition, the last address in any subnet range (the address de fined by all ones) isthe "broadcast address” for the subnet and should not be assigned to a host. This rule effectively sliminates hosts 1.2.30 and 1.2.37, so technically; only 4 hosts can be added. "Example indo rang¢ 2 » Bb & ® 3 Consider the scenario shown in the figure above in which the lines at the top ofthe figure show the radio range (eg s0 A is heard by B only, and B is heard by A and C but not ), Node D sends an RTS to node C at 0. Node C sends a CTS (whieh is heard by nodes B and D) in accordance with 802.11 protocol, and nade D begins the transmission of is ‘message at 2. [n the meantime, node A sends an RTS m. sage to Bat time t1 (@) Ifnode A were to begin transmitting to node B at some point after (3, would As transmission interfere with the on: going DATA transmission from D-to-C? Answer: No, sinee A can not reach C. (6) At 3, can B respond to As RTS message with a CTS ‘message? Why or why not? Answer: No, since B has received a CTS and will have to defer all transmission until after data is sent and ACK isheard, (©) In the 801.11 protocol, what will node C do att a the end of the receipt of data from node D2 Answer: C will send an ACK (actually after deferring a bit, but that not important) (@) IA were to begin transmitting to node B at some point after 3, would A's transmission be suecessfully received at [B? Justifyidiscuss your answer ina few sentences. Answer: It could interfere with the later ACK teansmis- son from C. Example In modern packet-switelied networks the source hosts segments long application-Iayer messages (for example, an image or a music file) into smaller packets and sends the packets into the network. The receiver then reas- semblesthe packet hack into the original message. We refer to this process as message segmentation the given figure i lustrates the end-to-end transport of a message with and without message segmentation, Consider a message that is 810° bits long that isto be sent from source to destination. Suppose each link has a maximum capacity of 2Mbps. Ig- ‘nore propagation, queuing, and processing delays. 4, Consider sending the message from source to dest nation without message segmentation. How long does ft take to move the message from the source host to the first packet stitch? Keeping in mind that each ‘switch uses store-and-forwaed packet switching what fs the total time to move the message from source host to destination host? b, Now suppose that the message is segmented into 4,000, packets, with each packet being 2,000 bits long. How long docs it take to move the first packet from source host to the firs switch? When the first packet is be {ng sen from the fest switch to the second switeh, the second packet is being sent from the source to the first switeh, At what time will the secand packet be fully received at the first switch? «, How log does it take to move the file from source host {o destination host when message segmentation is cused? Compare this result with your answer in part (@) and comment. 4 Discus the drawbacks of message segmentation. Source Packet Sith Packet wich estnaon oe ee Answer: a, Time to send packet from source A to frst packet switeh=8x10°%2x10"4see. As the packet needs to take 3 hops to reach destination and all links are of same capacity and_ length, it needs 3x4=12sec for packet 10 reach destination. '. Time needed to send small 2000 bit packet from source to fist packet switch = 2000/2510"=Ims, While first 2000 bit packet is sent from_ packet ‘switch 110 2, packet switch I will be receiving next packet from source. At the end of 2ms, this gets completed, Computer Netwerks | 7.61 «, Small packet of 2000bits needs 3m to reach destin tion, After that for every Im one 2000bit packet will be arriving. As the file size is 4000 packets in total, we ‘willbe needing 3999ms + 3ms = 4002ms = 4.002ms 4, Packets need to arranged at destination and control overhead is more Example Suppose within your Web browser you click fn a link to obtain a Web page. The IP address forthe as- sociated URL is not cached in your local host, so a DNS lookup is necessary to obtain the IP address. Suppose that in DNS servers are visited before your host receives the IP address from DNS; the successive visits incur an RET of ITI, ..« RPT, Further suppose that the Web page asso- ciated with the link contains exactly one object, consisting. tf small amount of HTML text, Let RTTO denote the RTT between the local host and the server containing the ob- jects. Assuming zero transmission time of the object how ruch time clapses from when the client clicks on the link until the client receives the object? Now suppose the HTML fle references eight very small objects on the same server. Neglecting transmission times, how much time clapses with b, Non-persistent HTTD with no parallel TCP con- nections? c, Non-persistent HTTP with browser configured for 5 parallel connections? d. Persistent HTTP? Answer a, The total amount of time to get the IP address is RITISRTT2+....ATTA, Once the IP address is known, RTO elapses to set up the TCP connec- tion and another clapses to request and receive the small object. The total response time is=2RTTO+ RITISRTT2+...¢RTTO, b, RPTL....t RPT +2RTTO¢8.2RTTO=ISRTTOVRTT. 1+RTT2+...RTTA 66 RPTL soot RTTn}2RTT042,2RTTO=ORTTOFRITI 4RTT26.RTTA 4, RETH4 ot RT Tn 2RTTO+RTTO=3RTTOFRTTIAR TTD RTT MExample Consider sending a large file from a host to another over a TCP connection that has no loss. a. Sup- pose TCP uses AIMD for its congestion control without slow start. Assuming congestion window increases by MSS every time a batch of ACKS is received and assuming. approximately constant round-trip times, how long does it take for congestion window to increase from 5 MSS ta 11 MSS (assuming no loss events)? b. What is the average throughput (in terms of MSS and RTT) for this connection ‘up through time = 6 RTT? W Answer: a, It takes 1 RTT to increase CongWin to 6 MSS; 2 RTTs to increase to 7 MSS; 3 RTTs to increase to 8 MSS; 4 RTT to increase to 9 MSS:5 RTTS to increase to 10 (MSS; and 6 RT'Ts to increase to 11 MSS. b. In the fist RTT 5 MSS was sent; in the second RTT 6 [MSS wa sents in the third RT'T 7 MSS was sent in the forth RUT 8 MSS was sent; inthe fith RTT, 9 MSS was sent; and {nthe sixth RTT, 10. MSS was sent, Thus, up to time 6 RTT, 5464748496 10 = 45 MSS were sent (and acknowledged). “Thus, we can say that the average throughput up to time 6 RYT eas (45 MSS)/(6 RTT) =7.5 MSSIRTT. Example Suppose Client A initiates an HTTP session with web server §. At about the same time, Client B also Initiates an HTTD session with web server S. Provide pos- sible source and destination port numbers for a, The segments sent from A to S. . The segments sent from B to S. «The segments sent frou Sto A. 4 The segments sent from S to B. eI A and B are diferent hosts, i it possible that the source port number inthe segments from A to Sis the same as that from B to S? Answer: source port numbers destination port numbers (asasr 3 ()B5513 2 (sar 467 (5982 513 Example Consider the scenario in the given shown in Which a server is connected to a router by a 100Mbps link with a S0ms propagation delay. Initially this roster is also connected to two routers, each over a 25Mbps link with a 200mas propagation delay. A 1Gbps link connects a host and 8 cache (if present to each ofthese routers and we assume that this link has 0 propagation delay, All packets in the net- work are 20,000 bits long. Ome 1.62) _ computer Science & Information Tecinclogy foe GATE 8. What is the end-to-end delay from when a packet is transmitted by the server to when itis received by the eli- ent? In this case, we assume there are no caches, there’ no {queuing delay at the routers, and the packet processing de- lays at routers and nodes are all Answer: If all packets are 20,000 bits long it takes 200 usec to send the packet aver the 100Mbps link, 800 usee to send over the 25MBps link, and 20 usee to send over the IGbps link. Sum ofthe three-link transmission is 1020 usec. Thus, the total end-to-end delay is 251.02 msc. b, Here we assume that client hosts send requests for files irecly to the server (caches are not used oF olf én this ase). What is the maximum rate at which the server can n, and a large number of small abjects, Assume the client request the objects inthe order it finds them in the page. What problem docs the ahove persistent connections scheme pose in this situation? 1 Answer: Since the large objects will take a lat of time to download, the user will not sce any content fora long time and get an impression thatthe server is nat responding, So hae wil rofresh the page and the same thing will start over again Deseribe a simple client side (ie. im the browser) solu- tion to address this problem and improve the overall re- sponse time for the Web page “The client can reserve one connection for large objects and use the rest lor small objects. The cient ean use the HEAD method of http and request the meta-data ofthe ob- jects (here images) including the sizeof the object. Then it can use the GET method to retrieve the large-sized images fon one connection and the smaller objects on the other Example Suppose you are designing a sliding window protocol for a IMbps point-to-point link to the Moon, Which has a one way latency of 1.256. Assuming that each frame carries IKB of data, what isthe minimum number of bits you need forthe sequence number? fm Answer: RTT=Round Trip Time = 1.2572 Total packet out = 2.5* IM bps/ 1KB + 1 = 308 “Therefore, we need logs(305)+1= 9 bits m Example Assume that two hosts ate trying to com- rmunicate over a 100Mbps Ethernet segment. Many other hhosts also connected to this segment, The hosts wish to exchange a 40B IP packet (Including IP, TCP and applica tion headers and payload), What is the minimum number of padding bytes that the sending hosts Ethernet adaptor will add? Assume that electromagnetic signals travel at the speed of 108 m/s over 100Mbps Ethernet cable. Also as- sume that the maximum allowed segment size 1s 1000m, Suppose nodes A and B are on the same LOMbps Ethernet segment. Say the propagation delay between them is 250 bi times. Answer: Fora collision to be effectively detected, in this case, the sending packet should be able to last for at least 1900/ 10"* 2=2"10% 5 “Thus, itshould be at least 100° 10° * 210° = 1000 bits = 250 byte => Need to pad 250-40 = 210 bytes TH2)_ computer Science & ntrmation Tecinclogy foc GATE 0100 a0 0100 1100 ‘We found that the given address is having largest num= ber of prefix bits matching, with 172.21.10.66, Thus, this is selected, MExample The following table isa routing table using CIDR. Address bytes are in hexadecimal. 0100 172.21.10.68 mol 172.21.10.237 oo 172.21.10.68 10 172.21.10.66 0100 172.21.10.68 001 172.21.10.193 (©) €3.1.80.02 (©) C46B31.28 Answer: “The following table lustrates the interfaces and their pre- fix bits (D) CAsD31.28 ‘NetiMaskLength Next hop Nel/MaskLengih [Next hop | Binary Address jcasonona a casonon2 a Too 1000107 (e45b.10020 B Cxst.10020 |B 00.0100.0101.1170.0001 e40000112 © (Cxso.00/12 € Ton 01000110 ‘chosnoita D Cxss00/14 D 110001000110.10 ‘so0n0i © wo0.001 E T suunas : ‘soonorr r on 2 000.002 © o ooona 6 “The following are the binary versions of given addresses. State to what next hop the following will be delivered, We choose the address with longest match in the addresses (a) C4SE2087, (B) CASE.1A.09 of routing table Binary Address Next Hop No.of Bits Match ‘CASE.2087 = 11000100,01011110,00100000, 10000111 => A, BR (CASE.1A.09 = 11000100.01011110.00011010.00001001 => 8 20 (€3.41.80.02 = 11000011.01009001.19000000.00000010 => E, 11000160.01101101.001 10001.00101010 => €; {€4.68.3.28 ~ 11000100,1101011.00110001.00101011 => Ds 4sD31.24 Example An organisation has @ class C network 2196.10.10 and wants to form subnets for five departments, which host as follows: n 4 ‘There are 195 hosts in all. Design a possible arrange ment of subnets to make each department in a different subnet. For each subnet, give subnet mask and range of IP (A) 55 hosts addresses. (8) 50 hosts Answer: Class C network: 196.1010 indicates, we ean (045 hosts have at most 254 hosts only in total. Our total, 195 is less (D) 25 hosts than 254, we can easily achieve the required subnetting. In (£) 20 hosts principle, we can have many solutions. The following is one of them. Department | Subnet Mask Swbnet ID Range of Address ‘A:S5 Hosts [255.255.285.192 196, 10.100, 196.1010 ~196.10.1063 B50 Hosts | 255.255.255.192 196.1010. 196.10.10.54 —196.10-10,37 (GAS Hoss | 255.255.255.192 196.1040.128 | 196.10.10,.28 —196.10,10.197 D:25Honts | 255.255.255.224 19610,10192| 196,100,192 196101023 E20 Hows | 255.255.255.204 1961010224 | 196.10.10224 ~196.10.10.255 Computer Netwerks | B. 4 15. A. Both are the techniques used for network routing purposes B, The max number of network flow is adjustable and resizable . The dataflow for these two techniques are subject to under utilization D. STDM is used for circuit switching and FDM is used in VC networking E, STDM and FDMs data flow i transferring on de- mand, Which option below about digital encoding could be «potential problem? A. Encode makes 0 as low signal and 1 as high signal B, Encode isto madulate electromagnetic waves . Signals propagate over a physical medium D. Low signal (0) may be interpreted as no signal EE, There could be alternative encoding methods Which option below about representing network as ‘graph is wrong? ‘A. Nodes are part of the components ofthe graph B. Node costs is used to represent values related to physical distance, capacity delay, ete . Routers is used to support the protocols and algo- rithm in the dynamie approach D. The assumption of edge cost in dynamic 9 proach is known, E. ‘The distance vector algorithm maintaining the next hop value for every destination. Which ofthe following option about ATM is wrong? A. ATM §s a connection-orlented packet-switched netwvork BB The Cells in ATM network are variable length C. ATM used in both WAN and LAN settings D. Different ATM AAL (ATM Adaptation Layer) providesditferen services for networkapplications EE, Segmentation and Reassembly (SAR) are neces- sary processes in ATM 16, Which one below about limitation of a Learning Bridge is wrong? A, Learning Bridge uses Spanning Tree Algorithm to remove loops ‘There is limited scalability capability for Learning. Bridge . There could bes transparency problem for Learn ing Bridge D. Learning Bridge use VLAN to support scalability E. Its casy for different types of network structures «an be interconnected using Learning Bridge. 17, Which one below shout Datagram Switching Nel work is wrong? A. Connection setup phase is needed B, Every packet contains the complete destination address C. ‘This is sometimes called connectionless model D. Bach Switch maintains a routing table for packets EE, Source host has no way of knowing ithe network is capable of delivering a packet or if the destina- tion host is even up 18 Which one below about VC (Virtual Circuit) Net ‘work is wrong? A. Typlcally wat fll RTT for connection setup be- fore sealing frst data packet B. Ifa switch of a link in a connection fails, the connection is broken and a new one needs to be established. C. Bach data packet contains only a small identifier D. Include only Outgoing Interface for packets transfer EE. It contains connection setup and data transfer phases 19, Which one below about Network Channels is wrong? ‘A. Request/reply (client/server) channel used by the file transfer and digital library application 'B. Message Stream channel could be used by both video-on-demand and videoconferencing appli- . Roquestireply (clientiserver) channel has no need to guarantee all messages are delivered D. Message Stream channel support both one or two-way trafic and delay properties IE, Message Stream channel needs to ensure that ‘messages are delivered arrives in the same order in which they were sent. 20, Which one below is NOT a network function? A. Provide Connectivity B. Addressing . Resource Sharing . Switching and Data Forwarding E, Server Application Supports 21, Four hosts (Hl, H2, H3 and H4) are connected to fone hub. HI's TP address is 192.168:733/24; H28 IP address 1s 192.168.120.7/16; H3% IP address is 192.168.7.43/16; IIHS IP address is 1921.168.7/28, Mark all pairs that can ping each other, AC HI-H2 B.HI-HS c.HNa D. W213 BDH RBH Computer Science & Information Technology for GATE 2. 23. 4 25. 26. 2. 28. 2», 30, ah. ‘A bub that enables us to gather network performance information is A. Hub B, Intelligent hub C. Bridge D. Gracious hub Correct point about spanning tree algorithm is A. Calculates shortest distance between links BB, Ensure frames are not transmitted in an endless loop, CC. Forward frames along the most efficient route D. None is used for compressed audio and video ‘where the data rate depends on the level of compres sion that can be achieved. ‘A. Constant Bit Rate (CBR) service B. Variable Bit Rate (VBR) service C. Available Bit Rate (ABR) service D. None of the given A form of addressing: in which a set of computers is assigned one address A. Broadcast B, Multicast . Packet Switch D. cRE E, Bandwidth rogram sends a message tos remote comput. er and reports whether the computer responds. A. Ping B, Traceroute c. IcMP D. None of the above A Bridge can A. Bilter frame 1, Forward frame ©. Extend aLAN ——_D, Doll theabove A network with throughput T and delay D has a total of bit in transit at any time. ATID BTxD cT+D D. None of the given is used for audio and video, since these have predefined maximum data rates, A. Constant Bit Rate (CBR) service BB. Variable Bit Rate (VBR) service C. Available Bit Rate (ABR) service D. None of the given Most NICs contain cireuitey that allows the NIC to operate independent ofthe CPU. ‘A. DMA(Direct Memory Access) B. Multiplexer ©. Transceiver D. None of the given I the ASCII character G is sent and the character Dis received, what type of error is this? A. Single-bit 1B, Maltiple-bit ©. Burst D. Recoverable 32, Computers attached to an ether use __in which a computer waits for the ether to be idle Before trans- aframe, A. CSMA/CD C. TOKEN PASSING “Themaximum sizeof an Ethernet segmentis. A, 250 meters B. 500 meters . 700 meters D. None of the given In Direct point to point communication adding the Nth computer requires. new connections. ANZ BONA Cc. (N2-NV2 . None of the given ‘The number of connections needed for N computer in direct point to point communication is equal to A. (NY BLN (N-1) c.ND D. None of the given Hardware that calculates & CRC uses two simple com- ponents A. AND unit and XOR unit 1, Shift register and XOR unit . Shift register and AND unit D. None of the given One repeater two repeaters ‘maximum cable length limitation. A. Doubles, cancel B. Doubles, triple C, Square roots, eude roots D. And, triple A Bridge forwards or filters a frame by comparing the Snformation in its address table to the frame's BL CSMA/CA D. None of the given es 3. the A. Layer 2 source address BB. Source node’ physical address . Layer 2 destination address D. Layer 3 destination address ATM assigns each VC a identifier that is divided two parts to produce a hierarchy. A. 21-bit B. 22-bit ©. 23-bit D. 24-bit Basic LAN technologies such as Ethernet, Token Ring, and FDDI use a ‘A. Connectionless service paradigm B. Connection-oriented service paradigm . Both Connectionless and Connection-oriented service paradigm D. None of the given Computer Netwerks | 78) APL B. vel cp D. GFC 122, Find odd one out A. Bridge B. Transceiver ©. Router D. Repeater 123. Gateway A. Protocol conversion B, Packet resizing . Data rate adjustment D. All 124. Gateways function in which OST layer? A. Lower 3 B. Upper 3 c aly D. None 125, A bridge has access to the __ address ofa station on the same nenwork A. Physical B, Network ©. SAP D. All 126, A packet from an Ethernet requires a__before tcan be routed to an EDI network, A. Repeater B, Bridge . Router D. Gateway 127, Piggybacking A. Physical layer B, Data link layer ©. Networklayer ——_D, Transport layer 128, Find odd-one out A. Network layer 1B, Physical C. Datalink D, Transport 129, Flow control isin ‘A, Transport B, Datalink . Physical D. Application 130, Why framing has to be done at a DLL connected to a link? ‘A. Such that no user service monopolizes the link BB, Bulfer requirements reduces . To have data transfer even on the ctroneous channel with some error rate D. all IBL, Repeaters are A. SW entities 1B. FW entities In physical ayer, Both B &C 132, Baud and bitrates ofa channel are same ifthe number of symbols used are equal to Al Ba Ba D. None 133. Find odd one out A, Data link B, Transport C. Network ©. None 134. Parity bit stufing is 135. 136. as. 138. 139. 140, 4. A. Error detection B. Error correction ©. Both A&B D. None “Application ayer A. Frame B, Packet C. Message D. None ‘A 10V 2kh user sine signal is modulating « 30V 200 Kz carrie sine signal. The esultant fourier spectrum ‘under a Double Side Band with Transmitted Carriee (DsBTC) is ‘A. 10V 2khz, 40V 200 khz 'B. 10V 198 kh, 30V 200 kh, 10V 202 kha. . 8¥ 198 kh, (OV) nothing at 200 khz, 5V 202 khz D. SV 198 khz, 30V 200 kh SV 202 Khe The above data (in Q51) under a DSB SC (suppressed Carrier) is ‘A. 10V 2khz, 40V 200 kz B. 10V 198 khz, 30V 200 khz, 10V 202 kha. C. 5¥ 198 khz, (OV) nothing at 200 khz, SV 202 khe D. SV 198 khz, 30V 200 khz SV 202 khe The data in Q51, using Single Sideband (SSB) Trans. mitted Carrier, Upper Sideband is A. SY 198 kha, 1B. SV 198 khz, 30V 200 khz ©. 30V 200 kha, SV 202 kh D. SV 202 kh The data in QS1, using Single Sideband (SSB) Sup- pressed Carries, Lower Sideband is ‘A. SV 108 kh, B, SV 198 khz, 30V 200 kha CC. 30V 200 kha, SV 202 kh D. 8V 202 kh Data in QL with minor modification (user signal = cosine) 10V 2khz user cosine signal is modulat- ing a 30V 200 khz carrier sine signal, The resultant fourier spectrum under a Double Side Band with Transmitted Carrier (DSBTC) is ‘A, -5V198 khz, 30V 200 khz, SV 202 kh BB, SV 198 khz, 30V 200 khz,-5V 202 khe C. -SV 198 kh, 30V 200 khzs SV 202 kha. D. SV 108 kl, 30V 200 khz, 5V 202 khe A QPSK 16 levels modem is currently at +90 degrees 2V. The next group of data is O111 (SY, + 135 degrees). The output is Computer Science & Information Technology for GATE 12. 143. 144, The encoding scheme forthe bits LIL] 4s. A. TN,4225 degrees —B. SV, +225 degrees . SV 4135 degrees —D. 7, +135degrees ‘The encoding scheme forthe bits 00000 under NRZL. A. Low0V 1B. A transition atthe beginning of interval foreach 0 ©. High, 5V D. For each bit 0, alternates between high +5V, and Tow -3Y, returning to OV after each bit 0. ‘The encoding scheme forthe bits 00000 under NRZ-1, intially at high SV A. Low0V B.A transition atthe beginning of interval for each 0 High, sv D. For each bit 0 alternates between high +5V, and Tow -3Y, returning to OV after each bit 0. nder NRZ, Sntially at high SV is ‘A. High, high, low; low —B. Low, high, low, high C. Low low, high, high D. High, low, high, low Manchester encoding is used in disks over NRZ-I oF NRZ-L due to A. Manchester code has less transitions rate than NRZS B. Manchester code has transition in the middle for cach 0 oF 1, hence this makes it sef-clocking C. Manchester cade has transition in the mile for each 0 or I, hence this allows colison detection, ‘oa voltage threshold D. ‘The transitions in Manchester encoding alternate for 0 and 1's hence this makes it suitable for al= ternating current (AC) 146, Bi-polar AMI signals have ww. ‘A. More transitions. than NRZ-L, NRZ-I, more power than Manchester B. Less transitions than NRZ-1, NRZ-I, more power than Manchester . Less transitions than NRZ-L, NRZ-T, ess power than Manchester . Least average power, due to each bit 1 alternating between +5, -SV (cancellation effect in average amplitude) Traditional LANs such as Token Ring, Ethernet Bus A. Circuit Switching B, Packet Switching. C. Radio Frequency (RF) wireless D. Packet Broadcasting 148, 14. 150. 151. 182 153. 154. Traditional LANs such as Token Ring (IEEE 802.5), Ethernet Bus (IEEE 802.3) use A. NRZ-L B. Bi-polar AMI . Manchester D. Difrential Manchester Ethernet Bus is based on A. Reservation bus B. Collision bus--collision detect, random backotf, LWT C. Collision avoidance (CA) bus-using tokens D. Collision avoidance (CA) bus-allocated (fixed) timeslots Collision detection in IEEE 8023 (CSMA/CD) is based on A. Prequency--bus detects 2 different frequencies of BB. Clocking ~ bus detects clock transitions for 2sta tions C. Logic ~ bus uses logic to detect to detect 2 sta- tions are active D. Amplitude-voltage level exceeds a threhold Coding method in IEEE 802.3 (CSMA/CD) Ethernet Bus is based on A. NRZ-L B. Bi-polar AMI . Manchester D. Dilerential Manchester Manchester encoding in IEEE 802.5 Token Ring is based on A. Minimum transitions B. Clocking -- stations are kept in synchronisation ddue to self-clock CC. Logic--stations use the scf-clocking info to de- cide who has token D. Amplitude-each 0 or Lhasa high, hence voltage threshold can be used for collision detection WDM is based on A. Time Division Multiplexing(TDM) B, Space Division Multiplexing (SDM) C. Wavelength Division Multiplexing--prineiple same as FDM, diferent colours (optical-easier to represent as wavelengths, than frequency) D. Frequency Division Multiplexing (FDM)-in the Radio Frequency Frequency Modulation eg: 101.1 Miz range Collision Avoidance is NOT done in 7.90) computer Science & Intrmation Tecnlogy foc GATE 215, 28800 bps is A. V34 B. v2 ©. Vaabis D, None 216. _is prone to noise very much, ‘A. Frequency B, Amplitude C. Wavelength D. Phase E. None 217, Current day modems employs A. Ascii coding B, Ebedie coding . Trelis coding D. Differential pulse code E, None 248, Null modem will have__ circuit. Ad Ba 3 D. None 219. Codecis A. Used in end office B. Coder-decoder CC. Works on multiple channels D. Does A/D and D/A conversion E. All 220. Overhead in TY carrier is A. 193 bits B, 25 bits ©. 1bit D. None 221, Out-of-band signaling bits in TE carrier are A193 B25 cl D. 24 B. None 222, Why frame time in T] carrier is 125 micro seconds? A. Itis standard B, Users interest, C. For realtime digital voice communication EL carriee data rate is A. LSAMbps ©. 6.468Mbps 224, Circuit switching ‘A. Charging is based on connection time 1B Every packet traverse in the same route C. No need of packet buffering & congestion contral 23, 1B, 2.048Mbps D, None D. All 225, For realtime performance ___is prefered. A. Circuit switching —_B. Packet switching ©. Both D. Message switching 226, Physical copper path is created in A. Circuit switching B. Packet switching C. Message switching D, Both A&C E. None 7. Store-and-forward network uses ‘A, Circuit switching B. Packet switching . Messageswitching D. None Telegrams uses (in olden days) ‘A. Circuit switching —B, Message switching . Packet switching. None suitable for interactive traffic. B, Packet switching C. Message switching. None >. Packets reach in same order in A, Circuit switching B, Message switching . Packet switching C. None ‘Bandwidth utilisation is better in 1B, Message switching, C. Packet switching. None 232, For real time trafic __ is suitable, A, Circuit switching B, Message switching. . Packet switching. None 233, Main drawback of message switching is A. Cost B, Delays because of monopolisation of channel by cone application . Complexity D. None 234, A TSI switch is used which is equipped with RAM ‘of L00 nano seconds. Frame period is 125 micro sec- fonds. Then no. of lines which it ean support is A. Circuit switching 21, A. Circuit switching A. 100 B 500 c. «5 D. None 235, ATM uses ‘A, Circuit switching B, Message switching . Packet switching, None 236, PSTN and N-ISDN uses ‘A. Circuit switehing C. Packet switching Virtual circuits A. Actual service is offered through packet switching 'B. Actual service is offered through circutt switching, C. Arecither permanent or switched D. None 238, Setup is not needed in ‘A, Circuit switehing 1. Permanent virtual circuit B. Message switching D. None 237, . Switched virtual cireuit D. None 239. In ATM cells 338, 339, 340, aan, 3a, 343. 34, 343, 346, 347. 348, 4s, 350, Subnet address in IPVE is A. 4B bits B, bits C. Is bits D. 32 bits Internet provider address in actual address part of IPV4 occupies ‘A. 48 bits B, a bits ©. Ibis D. S2 bits E, None Loopback addresses in IPV6 A. Not supported 1B AllO' followed by 1 atthe end . Starts with 127 D. None Find odd one out A. INTERNIC 3B, RIPNIC. c. NIC D. APNIC Reserved addresses in IPVo stars with AL Bo . 00000000 D, None In IPV6, link local addresses starts with, ‘A. 00000000 B. LULL cc. mmi9 In IPV6 hop limit is used. tes equavalent in 1PV4 is A. TTL filed 2B, Priority C. Flow label D. None Does header checksum is needed in IPV6? ‘AL Yes B. No Record rout option is A, Supported in IPV4 —B, Supported in IPV6 ©. Both A&C D. None Which of the following is a necessary part of IPV6 datagram? A. Base header B. Extension header . Data packet from the upper layer D. Both A&C ‘The ___field in the base header of IPV6 restricts the Lifetime ofa datagram, A. Version B, Priority . Next header D. Hop limit In IPV6 When a datagram needs to be discarded in a congested network the decision is based on the —_ field of base header. A. Version B, Priority C. Nest header D. Hop limit In IPV6, the___ field inthe base header and sender IP address combine to indicate a unique path identifier fora specific flow of data Computer Netwerks | 7.95) A. Version 2B. Priority C. Next header D. Hop limit 351. The source address in the hase header always contains theaddress ofthe. A, Last router B. Next router . Original sender. Any of the above 352. For IPV6, for a maximum number of hops, set the hop limit field to decimal__. A 16 B.S ca D.o 1353, For IPV6 for time sensitive data, assign the priority field a value of decimal __. Ao BT 81015 D. 16 ‘354, A datagram in IPV6 witha priority of __will be di carded before a datagram with a priority of 12. All BT co D. Any of theabove 355, A 6000-byte packet needs to routed through an Eth- crnet LAN, what extension header must be used in Iver A. Source routing ——_-B. Fragmentation C. Authentication, Destination option 356. An IP datagram in [PV6 is 80000bytes. What exten- sion header must be used? A. Hop-by-hop Authentication B. Fragmentation D. Destination option 1357, The maximum size for an IPVG datagram is _ bytes A, 65535 B. 63575, a” D. 2440 ‘358, When the hop count field reaches zero and the des- tination has not been reached, a _ error message is sent ‘A. Destination unreachable B, Time exceeded . Parameter problem D. Packet too-big 359, When all fragments of a message have not been re- ceived with the designated amount oftime, a__ error message is sent. A. Destination unreachable B. Time exceeded . Parameter problem D. Packet too-big ‘360, The _ fcld in the socket structure is usually set to 0 fora process using the services of TCP or UDP. A. Family B. Type Computer Networks [answer KEY 4c 8B 12.€ 16.E 20. oe 28. 32. 36. 40, wm 48. 52. 56. 60. ot 68 E B B A B A A B B © A D 8 .D BA D A © D D © _D LA 5.c 9.8 13D IA 2. BD 25.4 29. 33.8 a7.0 128, D(Peer to Peor) 131. D 135.€ 139. 143.€ 147. 151.¢ 155. D 159. 8 163. D 167.¢ 28 6.6 0.c 4.8 18D 2.8 26. 30.4 348 38. 2D 46. 50. 8 54.D 38. 2.4 66. 70.8 4.8 78.4 22.5 86. 90, 8 94D 98. 102.¢ 106. A 110. 8 14. 118.8 122.5 126. 132.8 136. D 40. D 144.5) 148..c 152.8 156.8 160.8 164. 168.¢ BOwoeS 1. 2. 2, 31 35, 3, 8 47, 51 55, 59, 67. n 75, 7”, 83, 87, 91 95, 99, 103, 17. a, us, Lis. 123, v7. 128, 133, 137. Mi. 145, 4s, 153, 157. 161. 165. 168. POUT E> OF eB OOS eee ee OBeraYG 6 Zee Oeeennes 12, 154.4 158. D 162.¢ 166. D 170.4 D720 TRA 175.4 176.8 ATA. 179.8180, BL. A 183.8 LC 85. 187. 188A 189, 5 IB 192.0 198 195. 196, Al 197, E 199. 200.8201. B 208.C 204.205. C 207.\ 208.209, 2D UAC KA 2A 6B 217. 219.E 2208221. 23.8 24D 25,8 27.6 28.B 9.8 BC BACB 235.6 236. 237. A 239.D 40.8 DAL A 2B. A MA 245. A 27. BC 48. 251A 252C 25%. 255, 010011100011110101, 257.8 258. 259, 261.C 262.4 263. D 264, 160bits(refer Page 7.17) 265, 77Tbits(refer Page 7.17) 266, 1/501 267. 268 B 269A 270,58 DLA 273.0 WALA WBA 27.8 RA 29.8 281.C —282.D 283. 285. 286,D 287. 289.8 290,291. 293.E 294.C 295.4. 297A 298.5299, BOLE 302.C 303. 305.A 306.8307. A 309.8 1H SIL 3I.B SLD 315.D BIG 31 BIB B2.C RE RC 325.6 326.0 327.8 329.5 330.8331. BRC MD 338. A 33RD 33, MC MBC Ac 178, 182, 186. 190, 194. 198, 202. D 206. 210. 2 218, 22, 26, 230. 24, 238, 22, 246, 250, 254, 256, 260, Aneore SORSa sabe anemS 272, 276, 280, 284. 288, 292, 296, 300, 304, 308, 3h, 316, 320, 324, 328, 332, 336, 340, aa, SS eOGoeaea ee aueG be Computer Netwerks 7408) 2, Using public key encryption, X adds a digital sige nature to amessage M, encrypts , and sends 5tto ¥, where itis decrypted. Which one the following sequence of Keys re used for the operations? (GATE 2013) ‘A. Encryption: X% private key followed by Y's pr vate key; Decryption: X's public key followed Y's public key B. Encryption: X' private key followed by Y's pub> lic key; Decryption: X's public key followed Y's private key . Eneryption: X's public key followed by Y's pri- vate key; Decryption: Ys public key followed X's private key D. Encryption: X°s private key followed by Y's pub- lic keys Decryption: Ys private key followed Y's public key 43. Assume that source S and destination D are connect- ed through two intermediate routers labeled R. De- termine how many times each packet has to visit the network layer and data link layer during a transmis- sion from S to D. (GATE 2013) [=] A. Network Layer-4 times and Data link layerst times s R R 1. Nenork Lape nes and Dats Tink lyer3 . Nemork Layer nes and Dts ink yes time D. Network Layer? mss and Dat nk yer planation Sette allowing gram which ex pment ow nthe gen near +©—_O£ CT CI AL: Application Layer TL Transport Layer NL Netrenk Layer DLLs Lin Layer PL Physial ayer 4A, Determine the maximum length of the cable (in Kea) for transmitting data at a rate of S00Mbps in an Eth- exnet LAN with frames of size 10,000bits. Assume the signal speed in the cable to be 2,00,000Km/s, (GATE 2013) Ad Ba cs Ds Explanation: In Ethernet, minimum frame time is two times of propagation delay. Consider x be the Tength of the cable. Frame time=10000/500x106, Therefore, 0000/S00x10°=2*x/200000 1/50000=3/100000 Therefore, x= 100000/50000=2KM 5, Inan Plvi datagram, the M bits, the value of TLEN 5s 10, the value of total length is 400 and the fragment offset value i 300, ‘The position of the datagram, the ‘sequence numbers ofthe frst and the last bytes of the payload, respectively are (GATE 2013) ‘A. Last sogment, 2400, and 2789 B, First segment, 2000 and 2759 . Last fragment, 2400 and 2759 D. Middle fragment, 300 and 689 6. The protocol data unit (PDU) forthe application layer inthe Internet stack is (GATE 2012) A. Segment BB. Datagram C. Message D. Frame 7. Which of the following transport layer protocols is tused to support electronic mail? (GATE 2012) A. SMTP BP c. TeP p. upp, In the IPv4 addressing format, the number of net works allowed under Class C addresses is (Gare 2012) Aa Ba ce pr 9. An Internet Service Provider (ISP) has the following, chunk of CIDR based IP addresses available with it 248.248.128,0/20. The ISP wants to give half of this chunk of addresses to Organisation A, and a quarter to Organisation B, while retaining the remaining with dtself, Which of the following isa valid allocation of addresses to A and BP (GATE 2012) ‘A. 245.248.136.0/21 and 245.248.128.0/22 B. 245.248.128.0/21 and 248.248.128.0/22 GC. 245.248.132.0/22 and 245.248.132.0/21 D. 245.248.136.0/24 and 245.248.132.0/21 Introduction to HTML, XML and Client Server Programming EXD introductic Internet and browsing the World Wide Web (WWW) have become common in everyones daily life Internet is a col lection of computers, connected through various interconnecting devices such as bridges, routers, gateways; whereas WWW is a collection of web pages or hyper documents, Hyper documents are ones which may contain text in ditferent size, colours, audio, video, pictures and hyperlinks. We can create hyper documents using many Janguages such as HTML, DHTML, XML, JSP, ASP, Java, Pet], PHP, etc. Out of them, HTML based pages are very simple to create. 8.1.4 | What is HTML? * HTMLisa HTML stands for Hyper Text Markup Language. + HITML is nota programming language, itis a markup language. © A.markup language is collection of markup tags. + TITML uses markup tags to describe web page content. language for describing web pages. 8.1.2/ HTML Tags HTML markup tags are uswally called HTML tags and are surrounded by angle brackets like , HTML tags nor: mally come in pairs like and . The fist tag in a pair isthe start tag, the second tag isthe end tag. Start and end tage are also called opening tags and closing tags. HTML. tags are not case sensitive:

means the same as

. Plenty of web sites use uppercase HTML tags in their pages. W3Schools use lowercase tags because the World Wide Web Consor tum (WSC) recommends lowercase in HTML 4, and demands lowercase tags in future versions of ((X)HTML). A web browser (like Internet Explorer, Netscape Navigator, Chrome, or Firefox) is used to read HTML documents and display them as web pages. The browser does not display the HITML tags, but ss the tags to interpret the content ofthe page. 8.1.3 My First Web Page Suppose that we want to create a simple html page. Write the following statements in a file with the name “irst.htm" oF “first.html” using any editor such as notepad. Now, open Internet Explorer (or any other browser) and open this “irst.htm” file through OPEN (and browse) option under File menu item,

Вам также может понравиться