Internet protocol version 4 tcp ipv4 rostelecom. IPv6 protocol: configuration on Windows systems

Today there was an interesting copy running win 8 OS. I had to tinker with it. Initially, when loading, there was a black screen after the logo. By manipulating the registry branches in the backup, we managed to return it to how it was. Moreover, the regular recovery and rollback to the point failed with errors. As a result, I downloaded the beast, but discovered that the Internet was not working at all. Moreover, it refuses to ping network DNS names, including even localhost. In order not to immediately use heavy artillery, I decided to try more gentle options.

reset windows routing table

I decided to start by making sure that viruses had not hijacked the routing table. In order to return everything as it was originally intended by the small-soft ones, you need to run the following command by running cmd .

And then reboot the patient. But in in this case, the problem was not that, and we moved on.

Reset WinSock

I decided to get to the heap, since nothing is plowing, to do a reset Winsock. For this action it is also necessary to command line cmd launched execute the command:

Then we reboot. We check the ping to ya.ru. In my case, there is no answer. So I had to move on.

Reinstalling the TCP/IP protocol

And then, I decided not to look for ways around the trouble, but to shoot at it from a cannon, so to speak. We will reinstall the TCP/IP protocol completely. Initially, if you go Control Panel ->Network and Internet -> -> Properties, and select Internet Protocol Version 4 (TCP/IP), we will see that this protocol cannot be deleted..

We will do what is possible. To do this, we carry out everything point by point.

1) You need to delete 2 keys in the registry. We launch the registry using the command regedit V Execute (win+R) or through Start and in the field Find programs and files we write regedit. Next, we look for and delete the following branches:

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\Winsock

HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\WinSock2\

2) Next you need to find the file Nettcpip.inf, which is located on system disk in folder Windows\inf. Open it with any editor, including Notepad, and look for the section almost at the top of the file and a line in it Characteristics = 0xa0. Changing the parameter value Characteristics = 0xa0 on 0x80. There may be problems with saving this file in the inf directory. I advise you to save as after making changes and save it to your desktop. Next, try to copy it and replace it with Windows\inf. If it doesn’t work out that way, then most likely you have a system record as the owner of the file TrustedInstaller. You must become the owner of this file. To do this, right-click on the file, Properties-> Security tab -> Additionally -> Owner tab -> Change, and select the user we want to assign as owner. Better than yourself 🙂 Well, then we set the group to Users Full Access. Now we can do everything with this file, whatever we want.

3) Let's go back to network connection. Control Panel ->Network and Internet -> Network Control Center and shared access -> Change adapter settings, right-click on the network connection Properties. Click Install -> Protocol -> Install from disk-> Using a button Review indicate the path to System drive:\Windows\inf and click OK. Select at the bottom of the list Internet Protocol Version 4 (TCP/IPv4) and click OK.

Now, returning to the Local Area Connection Properties, and selecting Internet Protocol Version 4, we should see that the button Delete became active.

4) Actually delete the protocol, reboot and do the whole step №3 again. Reboot again and check the Internet.

In my case, everything worked at the point №3 without deleting the protocol.

Every owner personal computer or laptop encountered problems accessing the Internet. It has happened that all the settings have been made, there is access to the network, Wi-Fi is configured, but there is no access to the Internet. In network connections, the status bar says the following: IPv4 without Internet access. How to fix the error and gain access to the network, read this article.

Diagnosis of the error

The first thing to do in this situation is to diagnose the networks:

  1. Press Win+R and run the command ncpa.cpl
  2. Right click on the problematic network connection and select “Status”.
  3. Open Diagnostics.
  4. Depending on the identified problem, to solve it, use the material from the links provided:
    1. This computer is missing one or more network protocols.
    2. .
    3. The computer settings are configured correctly, but the device or resource (DNS server) is not responding.
    4. .
    5. The DHCP server is not enabled on the network adapter.

It often happens that the cause of a problem with Internet access is an incorrectly configured DHCP server. This can be either on your part or on the part of the Internet provider. If this is your problem, read on.

TCP/IPv4 settings

First, let's make sure that there is no ordinary network failure that can be solved by reconnecting the connection. Right-click on the problematic network and select “Disconnect”. Then double-click to turn it back on.
If you have a router, reboot it too. Important! If there are several computers on the network, do not assign the problematic IP address of another device. If you do this, the network will not work.

Router settings

If you are using a router, enable the DHCP server in the settings:


If the suggested options do not resolve the problem, please contact technical support your provider. For their part, they will analyze possible mistakes and will indicate the reason for the lack of Internet.

Every owner of a personal computer or laptop has encountered problems accessing the Internet. It has happened that all the settings have been made, there is access to the network, Wi-Fi is configured, but there is no access to the Internet. In network connections, the status bar says the following: IPv4 without Internet access. How to fix the error and gain access to the network, read this article.

Diagnosis of the error

The first thing to do in this situation is to diagnose the networks:

  1. Press Win+R and run the command ncpa.cpl
  2. Right click on the problematic network connection and select “Status”.
  3. Open Diagnostics.
  4. Depending on the identified problem, to solve it, use the material from the links provided:
    1. .
    2. .
    3. .
    4. .
    5. The DHCP server is not enabled on the network adapter.

It often happens that the cause of a problem with Internet access is an incorrectly configured DHCP server. This can be either on your part or on the part of the Internet provider. If this is your problem, read on.

TCP/IPv4 settings

First, let's make sure that there is no ordinary network failure that can be solved by reconnecting the connection. Right-click on the problematic network and select “Disconnect”. Then double-click to turn it back on.
If you have a router, reboot it too. Important! If there are several computers on the network, do not assign the problematic IP address of another device. If you do this, the network will not work.

Router settings

If you are using a router, enable the DHCP server in the settings:


If the suggested options do not help resolve the problem, contact your provider's technical support. For their part, they will analyze possible errors and indicate the reason for the lack of Internet.

IP addresses (Internet Protocol version 4, Internet Protocol version 4) - are the main type of addresses used at the network layer of the OSI model to transmit packets between networks. IP addresses consist of four bytes, for example 192.168.100.111.

Assignment of IP addresses to hosts is carried out:

  • manually, configured system administrator while setting up a computer network;
  • automatically, using special protocols (in particular, using the DHCP protocol - Dynamic Host Configuration Protocol, dynamic settings hosts).

IPv4 protocol developed in September 1981.

IPv4 protocol operates at the internetwork (network) level of the TCP/IP protocol stack. The main task of the protocol is to transfer blocks of data (datagrams) from the sending host to the destination host, where the senders and recipients are computers uniquely identified by fixed-length addresses (IP addresses). Also, the Internet Protocol IP carries out, if necessary, fragmentation and collection of sent datagrams for data transmission through other networks with smaller packet sizes.

The disadvantage of the IP protocol is the unreliability of the protocol, that is, before the start of transmission, a connection is not established, this means that the delivery of packets is not confirmed, the correctness of the received data is not monitored (using a checksum) and the acknowledgment operation is not performed (exchange of service messages with the node -destination and its readiness to receive packages).

The IP protocol sends and processes each datagram as an independent piece of data, that is, without any other connections to other datagrams on the global Internet.

After sending a datagram via IP to the network, further actions with this datagram are in no way controlled by the sender. It turns out that if a datagram, for some reason, cannot be transmitted further over the network, it is destroyed. Although the node that destroyed the datagram has the opportunity to report the reason for the failure to the sender, via the return address (in particular, using the ICMP protocol). The guarantee of data delivery is entrusted to higher-level protocols (transport layer), which are endowed with special mechanisms for this (TCP protocol).

As you know, routers operate at the network layer of the OSI model. Therefore, one of the most basic tasks of the IP protocol is the implementation of datagram routing, in other words, determining the optimal path for datagrams (using routing algorithms) from the sending node of the network to any other node on the network based on the IP address.

On any network node receiving a datagram from the network looks like this:

IP Header Format

The structure of IP packets version 4 is shown in the figure

  • Version - for IPv4 the field value should be 4.
  • IHL - (Internet Header Length) the length of the IP packet header in 32-bit words (dword). It is this field that indicates the beginning of the data block in the packet. The minimum valid value for this field is 5.
  • Type of Service (TOS acronym) - a byte containing a set of criteria that determines the type of service for IP packets, shown in the figure.

Description of the service byte bit by bit:

    • 0-2 - priority (precedence) of this IP segment
    • 3 - requirement for delay time of IP segment transmission (0 - normal, 1 - low delay)
    • 4 - requirement for bandwidth(throughput) route along which the IP segment should be sent (0 - low, 1 - high throughput)
    • 5 - requirement for reliability (reliability) of IP segment transmission (0 - normal, 1 - high reliability)
    • 6-7 - ECN - explicit delay message (IP flow control).
  • Packet Length - The length of the packet in octets, including header and data. The minimum valid value for this field is 20, the maximum is 65535.
  • Identifier is a value assigned by the sender of the package and is intended to determine the correct sequence of fragments when assembling the package. For a fragmented packet, all fragments have the same ID.
  • 3 flag bits. The first bit must always be zero, the second bit DF (don’t fragment) determines whether the packet can be fragmented, and the third bit MF (more fragments) indicates whether this packet is the last in a chain of packets.
  • Fragment offset is a value that determines the position of the fragment in the data stream. The offset is specified by the number of eight byte blocks, so this value requires multiplication by 8 to convert to bytes.
  • Time to Live (TTL) is the number of routers this packet must pass through. As the router passes, this number will decrease by one. If the value of this field is zero, then the packet MUST be discarded and a Time Exceeded message (ICMP code 11 type 0) may be sent to the sender of the packet.
  • Protocol - The next layer Internet protocol identifier indicates which protocol data the packet contains, such as TCP or ICMP.
  • Header checksum - calculated according to RFC 1071

Intercepted IPv4 packet using Wireshark sniffer:

IP packet fragmentation

On the path of a packet from the sender to the recipient there may be local and global networks different types with different permissible sizes of data fields of link layer frames (Maximum Transfer Unit - MTU). Thus, Ethernet networks can transmit frames carrying up to 1500 bytes of data, X.25 networks are characterized by a frame data field size of 128 bytes, FDDI networks can transmit frames of 4500 bytes in size, and other networks have their own limitations. The IP protocol is able to transmit datagrams whose length is greater than the MTU of the intermediate network, due to fragmentation - breaking up a “large packet” into a number of parts (fragments), the size of each of which satisfies the intermediate network. After all the fragments have been transmitted through the intermediate network, they will be collected at the recipient node by the IP protocol module back into a “big packet”. Note that the packet is assembled from fragments only by the recipient, and not by any of the intermediate routers. Routers can only fragment packets, not reassemble them. This is because different fragments of the same packet will not necessarily pass through the same routers.

In order not to confuse fragments of different packets, the Identification field is used, the value of which must be the same for all fragments of one packet and not repeated for different packets until the lifetime of both packets has expired. When dividing packet data, the size of all fragments except the last one must be a multiple of 8 bytes. This allows you to allocate less space in the header to the Fragment offset field.

The second bit of the More fragments field, if equal to one, indicates that this fragment is not the last in the packet. If the packet is sent without fragmentation, the “More fragments” flag is set to 0, and the Fragment Offset field is filled with zero bits.

If the first bit of the Flags field (Don’t fragment) is equal to one, then fragmentation of the packet is prohibited. If this packet were to be sent over a network with an insufficient MTU, the router would be forced to discard it (and report this to the sender via ICMP). This flag is used in cases where the sender knows that the recipient does not have enough resources to reconstruct packets from fragments.

All IP addresses can be divided into two logical parts - network numbers and network node numbers (host number). To determine which part of the IP address belongs to the network number and which part belongs to the host number, it is determined by the values ​​of the first bits of the address. Also, the first bits of an IP address are used to determine which class a particular IP address belongs to.

The figure shows the structure of the IP address of different classes.

If the address starts with 0, then the network is classified as class A and the network number occupies one byte, the remaining 3 bytes are interpreted as the node number in the network. Class A networks have numbers ranging from 1 to 126. (Number 0 is not used, and number 127 is reserved for special purposes, as will be discussed below.) Class A networks are few, but the number of nodes in them can reach 2 24, that is 16,777,216 knots.

If the first two bits of the address are equal to 10, then the network belongs to class B. In class B networks, 16 bits, that is, 2 bytes, are allocated for the network number and the node number. Thus, a class B network is a medium-sized network with a maximum number of nodes of 2 16, which is 65,536 nodes.

If the address begins with the sequence 110, then this is a class C network. In this case, 24 bits are allocated for the network number, and 8 bits for the node number. Networks of this class are the most common; the number of nodes in them is limited to 2 8, that is, 256 nodes.

If the address begins with the sequence 1110, then it is a class D address and denotes a special, multicast address. If a packet contains a class D address as a destination address, then such a packet must be received by all nodes to which it is assigned given address.

If the address begins with the sequence 11110, then this means that this address belongs to class E. Addresses of this class are reserved for future use.

The table shows the ranges of network numbers and the maximum number of nodes corresponding to each network class.

Large networks receive class A addresses, medium-sized networks receive class B addresses, and small networks receive class C addresses.

Using masks in IP addressing

In order to obtain a particular range of IP addresses, enterprises were asked to fill out registration form, which listed the current number of computers and the planned increase in the number of computers, and as a result, the company was given a class of IP addresses: A, B, C, depending on the data specified in the registration form.

This mechanism for issuing IP address ranges worked normally, this was due to the fact that at first organizations had a small number of computers and, accordingly, small computer networks. But due to the further rapid growth of the Internet and network technologies, the described approach to the distribution of IP addresses began to produce failures, mainly associated with class “B” networks. Indeed, organizations in which the number of computers did not exceed several hundred (say, 500) had to register for themselves an entire class “B” network (since class “C” is only for 254 computers, and class “B” is for 65534). Because of which available networks class “B” was simply not enough, but at the same time large ranges of IP addresses were wasted.

The traditional scheme of dividing an IP address into a network number (NetID) and a host number (HostID) is based on the concept of a class, which is determined by the values ​​of the first few bits of the address. It is precisely because the first byte of the address 185.23.44.206 falls in the range 128-191 that we can say that this address belongs to class B, which means that the network number is the first two bytes, supplemented by two zero bytes - 185.23.0.0, and the number node - 0.0.44.206.

What if we used some other sign that could be used to more flexibly set the boundary between the network number and the node number? Masks are now widely used as such a sign.

Mask- this is the number that is used in conjunction with the IP address; The binary mask entry contains ones in those bits that should be interpreted as a network number in the IP address. Since the network number is an integral part of the address, the ones in the mask must also represent a continuous sequence.

For standard network classes, masks have the following meanings:

  • class A - 11111111.00000000.00000000.00000000 (255.0.0.0);
  • class B - 11111111. 11111111. 00000000. 00000000 (255.255.0.0);
  • class C - 11111111. 11111111.11111111. 00000000 (255.255.255.0).

By providing each IP address with a mask, you can abandon the concept of address classes and make the addressing system more flexible. For example, if the address 185.23.44.206 discussed above is associated with a mask 255.255.255.0, then the network number will be 185.23.44.0, and not 185.23.0.0, as defined by the class system.

Calculation of network number and node number using mask:

In masks, the number of ones in the sequence that defines the boundary of the network number does not have to be a multiple of 8 in order to repeat the division of the address into bytes. Let, for example, for the IP address 129.64.134.5 the mask 255.255.128.0 is specified, that is, in binary form:

  • IP address 129.64.134.5 - 10000001. 01000000.10000110. 00000101
  • Mask 255.255.128.0 - 11111111.11111111.10000000. 00000000

If you ignore the mask, then, in accordance with the class system, the address 129.64.134.5 belongs to class B, which means that the network number is the first 2 bytes - 129.64.0.0, and the node number is 0.0.134.5.

If you use a mask to determine the boundary of the network number, then 17 consecutive units in the mask, “superimposed” (logical multiplication) on the IP address, determine the number as the network number in binary expression:

or in decimal notation - the network number is 129.64.128.0, and the node number is 0.0.6.5.

There is also a short version of mask notation called prefix or a short mask. In particular, the network 80.255.147.32 with a mask of 255.255.255.252 can be written as 80.255.147.32/30, where “/30” indicates the number of binary units in the mask, that is, thirty binary units (counted from left to right).

For clarity, the table shows the correspondence between the prefix and the mask:

The mask mechanism is widespread in IP routing, and masks can be used for a variety of purposes. With their help, the administrator can structure his network without requiring additional network numbers from the service provider. Based on the same mechanism, service providers can combine address spaces of several networks by introducing so-called “ prefixes"in order to reduce the size of routing tables and thereby increase the performance of routers. In addition, writing a mask as a prefix is ​​much shorter.

Special IP addresses

The IP protocol has several conventions for interpreting IP addresses differently:

  • 0.0.0.0 - represents the default gateway address, i.e. the address of the computer to which information packets should be sent if they did not find a destination in the local network (routing table);
  • 255.255.255.255 – broadcast address. Messages sent to this address are received by all nodes of the local network containing the computer that is the source of the message (it is not transmitted to other local networks);
  • “Network number.” “all zeros” – network address (for example 192.168.10.0);
  • “All zeros.” “node number” – a node in this network (for example 0.0.0.23). Can be used to transmit messages to a specific node within a local network;
  • If the destination node number field contains only ones, then a packet with such an address is sent to all network nodes with the given network number. For example, a packet with the address 192.190.21.255 is delivered to all nodes on the network 192.190.21.0. This type of distribution is called a broadcast message. When addressing, it is necessary to take into account the restrictions that are introduced by the special purpose of some IP addresses. Thus, neither the network number nor the node number can consist of only binary ones or only binary zeros. It follows that maximum amount nodes given in the table for networks of each class, in practice should be reduced by 2. For example, in class C networks, 8 bits are allocated for the node number, which allows you to set 256 numbers: from 0 to 255. However, in practice, the maximum number of nodes in the network class C cannot exceed 254, since addresses 0 and 255 have a special purpose. From the same considerations, it follows that the end node cannot have an address like 98.255.255.255, since the node number in this class A address consists of only binary ones.
  • The IP address has a special meaning, the first octet of which is 127.x.x.x. It is used to test programs and process interactions within the same machine. When a program sends data to the IP address 127.0.0.1, a “loop” is formed. Data is not transmitted over the network, but is returned to upper-level modules as just received. Therefore, on an IP network, it is prohibited to assign IP addresses to machines starting with 127. This address is called loopback. You can assign the address 127.0.0.0 to the internal network of the host routing module, and the address 127.0.0.1 to the address of this module on the internal network. In fact, any network address 127.0.0.0 serves to designate its routing module, and not just 127.0.0.1, for example 127.0.0.3.

The IP protocol does not have the concept of broadcasting in the sense in which it is used in link-layer protocols of local networks, when data must be delivered to absolutely all nodes. Both the restricted broadcast IP address and the broadcast IP address have Internet propagation limits - they are limited either to the network to which the source host of the packet belongs, or to the network whose number is specified in the destination address. Therefore, dividing the network into parts using routers localizes the broadcast storm to the boundaries of one of the parts that make up the overall network, simply because there is no way to simultaneously address the packet to all nodes of all networks of the composite network.

IP addresses used in local networks

All addresses used on the Internet must be registered, which guarantees their uniqueness on a global scale. These addresses are called real or public IP addresses.

For local networks not connected to the Internet, registration of IP addresses is naturally not required, since, in principle, any possible addresses can be used here. However, in order to avoid the possibility of conflicts when such a network is subsequently connected to the Internet, it is recommended to use local networks only the following ranges of so-called private IP addresses (these addresses do not exist on the Internet and it is not possible to use them there) presented in the table.