Local network: basics of computer networks functioning


Local area network (local area network or LAN) is an environment where several computers interact with each other. The purpose of interaction is data transfer. Local networks, as a rule, cover small spaces (home, office, enterprise) - which justifies their name. A LAN can have one or several levels. To build a multi-level local network, special network equipment is used: routers, switches. There are several ways to combine computers and network equipment into a single computer network: wired (twisted pair), optical (fiber optic cable) and wireless (Wi-Fi, Bluetooth) connections.

LAN topology

The first thing you need to start when studying the basics of the functioning of computer networks is the topology (structure) of the local network. There are three main types of topology: bus, ring and star.

Linear bus

All computers are connected to a single cable with plugs at the edges (terminators). Plugs are required to prevent signal reflection. The principle of operation of the bus is as follows: one of the computers sends a signal to all participants in the local network, while the others analyze the signal and, if it is intended for them, process it. With this interaction, each computer checks the presence of a signal on the bus before sending data, which eliminates the occurrence of collisions. The disadvantage of this topology is low performance; moreover, if the bus is damaged, the normal functioning of the local network is disrupted and some computers are not able to process or send signals.

Ring

In this topology, each computer is connected to only two network participants. The principle of operation of such a LAN is that one of the computers receives information from the previous one and sends it to the next one, acting as a signal repeater, or processes the data if it was intended for it. A local network built on a ring principle is more productive compared to a linear bus and can connect up to 1000 computers, but if a break occurs somewhere the network completely stops functioning.

Star

Star topology is the optimal structure for building a LAN. The principle of operation of such a network is the interaction of several computers with each other using a central switching device (switch or switch). The star topology allows you to create high-load scalable networks in which the central device can act as a separate unit as part of a multi-level LAN. The only disadvantage is that if the central switching device fails, the entire network or part of it collapses. The advantage is that if one of the computers stops functioning, it does not in any way affect the performance of the entire local network.

Wireless way

This refers to unification over radio waves. The most common option now is Wi-Fi. However, connection is also possible via Bluetooth and GPRS. In any case, the speed will be lower than with a wired connection. On average, over Wi-Fi it is 10 Mbit/s and higher.

To create a mesh without wires, you need a special module in your computers. In modern laptops it is usually built-in, but for PCs you can buy an external device. You also need a single network gateway (router) to which wired Internet will be connected. And network participants will receive it via radio waves.

What are MAC Address, IP Address and Subnet Mask?

Before getting acquainted with the basic principles of interaction between network devices, it is necessary to understand in detail what an IP address, MAC address and Subnet mask are.

A MAC address is a unique identifier of network equipment, which is necessary for the interaction of devices on a local network at the physical level. The MAC address is “hardwired” into the network card by the manufacturer and cannot be changed, although if necessary this can be done at the software level. An example of a MAC address entry: 00:30:48:5a:58:65.

An IP address is a unique network address of a node (host, computer) on a local network, for example: 192.168.1.16. The first three groups of digits of an IP address are used to identify the network, and the last group is used to determine the “sequence number” of a computer on that network. If we draw an analogy, the IP address can be compared with a postal address, then the entry will look like this: region.city.street.house. Initially, IP addresses version 4 (IPv4) were used, but when the number of global network devices increased to the maximum, this range became insufficient, as a result of which the TCP/IP protocol version 6 - IPv6 - was developed. For local networks, version 4 of the TCP/IP protocol is sufficient.

A subnet mask is a special entry that allows you to use an IP address to calculate the subnet address and IP address of a computer on a given network. An example of a subnet mask entry: 255.255.255.0. We will look at how IP addresses are calculated a little later.

Theoretical page

So, LAN stands for Local Area Network. This actually translates to local area network.

To put it simply, a LAN is several interconnected computers, routers and other devices that can connect to the network.

And they are connected to each other either using cables or using Wi-Fi. In Figure 1 you can see a fairly clear example of a local network.

Rice. 1. LAN example

As you can see, the main element of the network here is a router that is connected to the Internet (WAN). Remember this abbreviation, we will talk about it later.

For now, let’s look at the diagram shown above. On it, numbers indicate network segments, specifically:

1. A switch through which other devices are connected.

As you know, a switch is a device that receives a signal via a cable and, in the same way, transmits it via cable to other devices connected to it.

In fact, the switch can be compared to a Soviet tee, which was plugged into an outlet, and three more devices could be plugged into it, for example, an iron, a TV and a telephone.

Here the principle is the same, only it is not electricity that is transmitted, but information. This, again, if we speak in worker-peasant language.

Rice. 2. Soviet tee

2. A laptop that connects to the router via Wi-Fi.

3. DVD player connected to the router using a cable. For this purpose, the router has special LAN connectors, which are usually marked in yellow. In most cases there are 4 such connectors.

4. A tablet also connected via a Wi-Fi signal.

5. A personal computer that is connected in the same way as a DVD player, using a cable.

6. Another laptop, which is also connected using a wire.

7. Smartphone – uses Wi-Fi signal.

As we said above, a LAN connector is used to connect to the router via cable. We can see this in Figure 3.

Rice. 3. Router - rear view

As you can see, everything is standard in this model - 4 LAN connectors, but there is one more and it is already different in blue.

Actually, this is the WAN (remember, we said that this concept needs to be remembered?). To more accurately understand what a LAN is, you can compare it with this very WAN.

By the way: Both LAN and WAN are connected via the most common cable with an RJ45 tip, shown in Figure 4. Above we said that, for example, segment No. 3 in Figure 1, that is, a DVD player, is connected to the router with using a cable. This cable is a regular twisted pair cable with RJ45 lugs on both sides. It's that simple!

Rice. 4. RJ45 tip

What is the ARP protocol or how do LAN devices interact?

ARP is a protocol that determines the MAC address of a host by its IP address. For example, there are several computers on our local network. One must send information to the other, but at the same time only knows his IP address, and for interaction at the physical level a MAC address is needed. What's happening? One of the computers sends a broadcast request to all participants on the local network. The request itself contains the IP address of the required computer and its own MAC address. Another computer with a given IP address understands that the request has come to it and in response sends its MAC address to the one that came in the request. After which the process of transmitting information packets is actually initiated.

Network switch and router (router)

To coordinate the operation of network devices, special network equipment is used - switches and routers. Based on what was discussed above, it is important to understand a simple truth - switches work with MAC addresses, and routers (or routers) with IP addresses.

The switch contains a table of MAC addresses of local network devices directly connected to its ports. Initially, the table is empty and begins to fill when the switch starts operating; the MAC addresses of devices and the ports to which they are connected are compared. This is necessary so that the switch directly forwards information packets to those local network participants to whom they are intended, and does not poll all LAN devices.

The router also has a table in which it records the IP addresses of devices based on analysis of the local network. The router can independently distribute IP addresses to LAN devices thanks to the Dynamic Host Configuration Protocol (DHCP). The routing table allows the router to calculate the shortest routes to send information packets between different LAN nodes. These nodes (computers) can be located in any segment of a multi-level network, regardless of the architecture of a particular subnet. For example, a router connects a local network to a global network (the Internet) through the provider’s network.

Main characteristics

The local channel is associated with combining devices into one unit for work in the office or at home. There are several departments in a LAN. Thanks to one web, you can control all computers from one device, increasing the productivity of company employees. The web includes the following equipment:

  • switches, routers, which are part of the main equipment;
  • communication panels, cables and other accessories related to passive equipment;
  • printers, servers and scanners are peripheral equipment.

Regardless of the type of LVK, they have the following requirements:

  • high speed - characteristics of the web;
  • adaptation – the ability of LVK to introduce new workstations;
  • reliability - must work regardless of failed equipment elements.

Routing example

Let's say there is such an entry in the routing table:

NetMaskInterface
192.168.1.0255.255.255.0192.168.1.96

The router receives a packet destined for a host with IP address 192.168.1.96, after which it begins to traverse the routing table and discovers that when the subnet mask 255.255.255.0 is applied to the IP address 192.168.1.96, a network with IP address 192.168.1.0 is calculated. Having passed the line to the end, the router finds the IP address of interface 192.168.1.96, to which it sends the received packet.

How is the IP address of a network and computer calculated?

A subnet mask is used to calculate the network's IP address. Let's start with the fact that the IP address that is familiar to our eyes is presented in decimal format (192.168.1.96). In fact, a network device sees this IP address as a set of zeros and ones, that is, in the binary number system (11000000.10101000.00000001.01100000). The subnet mask looks the same (255.255.255.0 -> 11111111.11111111.11111111.00000000).

Destination IP address192.168.1.9611000000 10101000 00000001 01100000
Subnet mask255.255.255.011111111 11111111 11111111 00000000
Network IP address192.168.1.011000000 10101000 00000001 00000000

What happens? Whatever destination IP address we have (for example, 192.168.1.96 or 192.168.1.54), when we apply a subnet mask (255.255.255.0) to it, we will get the same result (192.168.1.0). This happens due to a bitwise comparison of records (1x1 = 1, 1x0 = 0, 0x1 = 0). In this case, the computer's IP address is taken from the last group of digits of the destination IP address. It is also worth considering that out of the total address range, within one subnet, two fewer addresses will be available, because 192.168.1.0 is the IP address of the network itself, and 192.168.1.255 is a service broadcast address for transmitting general request packets.

Wired connection

A twisted pair or optical cable is used, which is connected to the network cards on the PC. Such devices are found in any hardware that is no more than 10-15 years old - they are integrated into the motherboard.

Wired connection provides the most stable and fastest data transfer. In modern versions, the throughput is 100 Mbit/s and higher via twisted pair. From 10 Gbit/s over fiber. For such a connection, Ethernet technology is most often used.

When the collection of computers is large or it is necessary to distribute the Internet from one server, hubs (switches) can be used. They have several connectors for connecting wires. Their functions include relaying the signal entering one port over other interfaces.

What is NAT?

In the last paragraph of this article, we will consider what NAT is. As mentioned earlier, the router connects networks not only at the local level, but also interacts with the provider’s network in order to gain access to the Internet. To forward packets to an external network, the router cannot use the IP addresses of computers from the local network, since these IP addresses are “private” and are intended only for organizing the interaction of devices within the LAN. The router has two IP addresses (internal and external), one in the local network (192.168.1.0), the other (for example 95.153.133.97) is assigned to it by the provider’s network during the dynamic distribution of IP addresses. It is the second IP address that the router will use to send and receive packets over the Internet. NAT was developed to implement such substitution.

NAT (Network Address Translation) is a network address conversion mechanism that is part of the TCP/IP protocol.

The principle of NAT is as follows: when sending a packet from a LAN, the router replaces the IP address of the local machine with its own, and upon receipt, it performs the reverse replacement and sends the data to the computer for which it was intended.

Briefly about computer networks

A computer (or computer) network allows you to connect several different devices into one system, within which data can be exchanged. The main elements of such networks are computers, but they can also include printers, network equipment, servers, storage, televisions, phones and other devices. All these devices are called end nodes. But the network also contains intermediate elements - these are various routers, routers, modems, wireless access points, switches. All this is connected to each other using the so-called network environment. The network environment consists of fiber optic cables, Wi-Fi radio waves, twisted pairs, with the help of which all devices connect to the network and interact with each other.

Any computer network consists of these three types of elements

Computer networks are local (LAN) and wide area (WAN). What is the key difference between them? The former are located in a limited area (usually not going beyond the boundaries of one building), while the latter can spread over a much larger area - the distance between nodes can be hundreds and thousands of kilometers. As users, we are now more interested in local computer networks - they are the ones we deploy at home, and we use them at work or at school.

It is worth noting that the differences between local and global computer networks are slowly disappearing. This is due to the improvement of both. Perhaps in the near future there will no longer be a significant difference between them.

Additionally, we can distinguish city computer networks - MAN (Metropolitan Area Network). They differ from WAN, first of all, in their coverage area and, as you might guess, occupy one city. MAN provides cable television and telephony services, and is also a fulcrum for providers.

Mini-test: “Local network”

Time limit: 0

Navigation (job numbers only)

0 out of 5 tasks completed
Questions:

  1. 1
  2. 2
  3. 3
  4. 4
  5. 5

Information

Online test to test your knowledge of the basics of computer networks.

You have already taken the test before. You can't start it again.

The test is loading...

You must log in or register in order to begin the test.

You must complete the following tests to start this one:

results

Correct answers: 0 out of 5
Your time:

Time is over

You scored 0 out of 0 points (0)

Average result
Your result
Rating
( 2 ratings, average 5 out of 5 )
Did you like the article? Share with friends:
For any suggestions regarding the site: [email protected]
Для любых предложений по сайту: [email protected]