Answer the question
In order to leave comments, you need to log in
How is the default gateway determined?
Colleagues,
how does the computer determine the default gateway? I understand that the computer can learn this from the interface parameters, where the gateway is written. But let's say only the IP address and mask are registered on the host - how to find out in this case? Does the IP packet contain information about this?
Answer the question
In order to leave comments, you need to log in
How does a computer determine the default gateway?No way. This is a mindless piece of iron. Either this is done by manual settings, or it is assigned by the dhcp server, where they also indicate the gateway of last resort with their hands.
But let's say only the IP address and mask are registered on the host - how to find out in this case?No way. The mask indicates the subnet. IP - address in this subnet.
Does the IP packet contain information about this?There is no such field in the IP packet that indicates the default gateway.
for normal network operation on the computer, it is necessary to configure:
the address on the interface
its mask
the default gateway
dns server
these parameters can either be entered manually or received via dhcp
In the interface config. if it is not there, then the gateway is not specified.
The package has only src\dst addresses + ports
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question