Switch and mac address table
I thought that a switch learnt the mac addresses by the computers sending out packets. However when I configured 2 switches, and 2 pc's, 1 pc connected to 1 switch, the other pc connected to the other switch, and then both switches connected to each other, there were mac addresses in the mac address table without there being any packets being sent. Why/How does this happen?
switch mac-address
|
show 2 more comments
I thought that a switch learnt the mac addresses by the computers sending out packets. However when I configured 2 switches, and 2 pc's, 1 pc connected to 1 switch, the other pc connected to the other switch, and then both switches connected to each other, there were mac addresses in the mac address table without there being any packets being sent. Why/How does this happen?
switch mac-address
4
PCs are actually pretty chatty. They do a lot of things in the background.
– Ron Trunk
Feb 13 at 11:56
1
Are you sure there were no packet sent? How? Modern OSes have a lot of background network activity. This can also be due to gratuitous ARP. See this answer for example
– JFL
Feb 13 at 11:57
Definitely no packets sent when it was first viewed, packets were sent afterwards and the table was view again.
– The_Bear
Feb 13 at 11:58
4
Then you have magic switches.
– JFL
Feb 13 at 13:02
6
Clearly the PCs sent frames. That’s how the switch learned the MACs.
– Ron Trunk
Feb 13 at 13:11
|
show 2 more comments
I thought that a switch learnt the mac addresses by the computers sending out packets. However when I configured 2 switches, and 2 pc's, 1 pc connected to 1 switch, the other pc connected to the other switch, and then both switches connected to each other, there were mac addresses in the mac address table without there being any packets being sent. Why/How does this happen?
switch mac-address
I thought that a switch learnt the mac addresses by the computers sending out packets. However when I configured 2 switches, and 2 pc's, 1 pc connected to 1 switch, the other pc connected to the other switch, and then both switches connected to each other, there were mac addresses in the mac address table without there being any packets being sent. Why/How does this happen?
switch mac-address
switch mac-address
asked Feb 13 at 11:54
The_BearThe_Bear
714
714
4
PCs are actually pretty chatty. They do a lot of things in the background.
– Ron Trunk
Feb 13 at 11:56
1
Are you sure there were no packet sent? How? Modern OSes have a lot of background network activity. This can also be due to gratuitous ARP. See this answer for example
– JFL
Feb 13 at 11:57
Definitely no packets sent when it was first viewed, packets were sent afterwards and the table was view again.
– The_Bear
Feb 13 at 11:58
4
Then you have magic switches.
– JFL
Feb 13 at 13:02
6
Clearly the PCs sent frames. That’s how the switch learned the MACs.
– Ron Trunk
Feb 13 at 13:11
|
show 2 more comments
4
PCs are actually pretty chatty. They do a lot of things in the background.
– Ron Trunk
Feb 13 at 11:56
1
Are you sure there were no packet sent? How? Modern OSes have a lot of background network activity. This can also be due to gratuitous ARP. See this answer for example
– JFL
Feb 13 at 11:57
Definitely no packets sent when it was first viewed, packets were sent afterwards and the table was view again.
– The_Bear
Feb 13 at 11:58
4
Then you have magic switches.
– JFL
Feb 13 at 13:02
6
Clearly the PCs sent frames. That’s how the switch learned the MACs.
– Ron Trunk
Feb 13 at 13:11
4
4
PCs are actually pretty chatty. They do a lot of things in the background.
– Ron Trunk
Feb 13 at 11:56
PCs are actually pretty chatty. They do a lot of things in the background.
– Ron Trunk
Feb 13 at 11:56
1
1
Are you sure there were no packet sent? How? Modern OSes have a lot of background network activity. This can also be due to gratuitous ARP. See this answer for example
– JFL
Feb 13 at 11:57
Are you sure there were no packet sent? How? Modern OSes have a lot of background network activity. This can also be due to gratuitous ARP. See this answer for example
– JFL
Feb 13 at 11:57
Definitely no packets sent when it was first viewed, packets were sent afterwards and the table was view again.
– The_Bear
Feb 13 at 11:58
Definitely no packets sent when it was first viewed, packets were sent afterwards and the table was view again.
– The_Bear
Feb 13 at 11:58
4
4
Then you have magic switches.
– JFL
Feb 13 at 13:02
Then you have magic switches.
– JFL
Feb 13 at 13:02
6
6
Clearly the PCs sent frames. That’s how the switch learned the MACs.
– Ron Trunk
Feb 13 at 13:11
Clearly the PCs sent frames. That’s how the switch learned the MACs.
– Ron Trunk
Feb 13 at 13:11
|
show 2 more comments
3 Answers
3
active
oldest
votes
When you connect a PC to a network switch ("link up"), the PC performs at least one of these procedures (assuming IPv4 use):
- (most commonly) request an IP address lease from a DHCP server
- (when DHCP fails or is deactivated) automatically configure a link-local IP address (aka zero-config or APIPA)
- (when a static IP address is configured) send an ARP probe to detect an address collision
All of these methods send out broadcast frames from the PC which populate the MAC table in all the switches in the network (broadcast domain / VLAN).
Also, gratuitous ARP, as mentioned in the comments to the question.
– Jörg W Mittag
Feb 13 at 20:17
And an ARP for the default gateway and DNS servers if defined either locally or by DHCP plus UPNP discovery, etc.
– grahamj42
Feb 13 at 20:20
Strictly speaking this depend on OS and network configuration. If you were to disable IPv4 none of the packets you mention would be sent. For another example look at IPv6, it doesn't use broadcast only multicast. There are switches which will treat them the same, but a switch does not have to forward multicast packets onto all ports.
– kasperd
Feb 13 at 22:20
@kasperd Absolutely. However, 99.x% of users are using IPv4 and the question didn't call for a too thorough/complicated answer.
– Zac67
Feb 14 at 7:21
@Zac67 Your 99% number sounds like one you made up rather than anything based on actual data. One would need telemetry implemented in native code deployed to a very large user base to give a number with that amount of accuracy. I most certainly don't have access to a large enough number of client machines to say how widespread the use of IPv6-only networks with NAT64 is. But given that more than 20% of users have IPv6 access I would guess the number of such IPv6-only networks to amount for more than 1%.
– kasperd
Feb 14 at 21:20
|
show 2 more comments
PCs have many background tasks that send data all the time, even when you’re “not doing anything.” These frames will populate the MAC table.
add a comment |
You might think no packets have been sent, but Computers do a lot of talking in the background, given all the services functioning in the background.
add a comment |
protected by Ron Maupin♦ Feb 13 at 21:16
Thank you for your interest in this question.
Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).
Would you like to answer one of these unanswered questions instead?
3 Answers
3
active
oldest
votes
3 Answers
3
active
oldest
votes
active
oldest
votes
active
oldest
votes
When you connect a PC to a network switch ("link up"), the PC performs at least one of these procedures (assuming IPv4 use):
- (most commonly) request an IP address lease from a DHCP server
- (when DHCP fails or is deactivated) automatically configure a link-local IP address (aka zero-config or APIPA)
- (when a static IP address is configured) send an ARP probe to detect an address collision
All of these methods send out broadcast frames from the PC which populate the MAC table in all the switches in the network (broadcast domain / VLAN).
Also, gratuitous ARP, as mentioned in the comments to the question.
– Jörg W Mittag
Feb 13 at 20:17
And an ARP for the default gateway and DNS servers if defined either locally or by DHCP plus UPNP discovery, etc.
– grahamj42
Feb 13 at 20:20
Strictly speaking this depend on OS and network configuration. If you were to disable IPv4 none of the packets you mention would be sent. For another example look at IPv6, it doesn't use broadcast only multicast. There are switches which will treat them the same, but a switch does not have to forward multicast packets onto all ports.
– kasperd
Feb 13 at 22:20
@kasperd Absolutely. However, 99.x% of users are using IPv4 and the question didn't call for a too thorough/complicated answer.
– Zac67
Feb 14 at 7:21
@Zac67 Your 99% number sounds like one you made up rather than anything based on actual data. One would need telemetry implemented in native code deployed to a very large user base to give a number with that amount of accuracy. I most certainly don't have access to a large enough number of client machines to say how widespread the use of IPv6-only networks with NAT64 is. But given that more than 20% of users have IPv6 access I would guess the number of such IPv6-only networks to amount for more than 1%.
– kasperd
Feb 14 at 21:20
|
show 2 more comments
When you connect a PC to a network switch ("link up"), the PC performs at least one of these procedures (assuming IPv4 use):
- (most commonly) request an IP address lease from a DHCP server
- (when DHCP fails or is deactivated) automatically configure a link-local IP address (aka zero-config or APIPA)
- (when a static IP address is configured) send an ARP probe to detect an address collision
All of these methods send out broadcast frames from the PC which populate the MAC table in all the switches in the network (broadcast domain / VLAN).
Also, gratuitous ARP, as mentioned in the comments to the question.
– Jörg W Mittag
Feb 13 at 20:17
And an ARP for the default gateway and DNS servers if defined either locally or by DHCP plus UPNP discovery, etc.
– grahamj42
Feb 13 at 20:20
Strictly speaking this depend on OS and network configuration. If you were to disable IPv4 none of the packets you mention would be sent. For another example look at IPv6, it doesn't use broadcast only multicast. There are switches which will treat them the same, but a switch does not have to forward multicast packets onto all ports.
– kasperd
Feb 13 at 22:20
@kasperd Absolutely. However, 99.x% of users are using IPv4 and the question didn't call for a too thorough/complicated answer.
– Zac67
Feb 14 at 7:21
@Zac67 Your 99% number sounds like one you made up rather than anything based on actual data. One would need telemetry implemented in native code deployed to a very large user base to give a number with that amount of accuracy. I most certainly don't have access to a large enough number of client machines to say how widespread the use of IPv6-only networks with NAT64 is. But given that more than 20% of users have IPv6 access I would guess the number of such IPv6-only networks to amount for more than 1%.
– kasperd
Feb 14 at 21:20
|
show 2 more comments
When you connect a PC to a network switch ("link up"), the PC performs at least one of these procedures (assuming IPv4 use):
- (most commonly) request an IP address lease from a DHCP server
- (when DHCP fails or is deactivated) automatically configure a link-local IP address (aka zero-config or APIPA)
- (when a static IP address is configured) send an ARP probe to detect an address collision
All of these methods send out broadcast frames from the PC which populate the MAC table in all the switches in the network (broadcast domain / VLAN).
When you connect a PC to a network switch ("link up"), the PC performs at least one of these procedures (assuming IPv4 use):
- (most commonly) request an IP address lease from a DHCP server
- (when DHCP fails or is deactivated) automatically configure a link-local IP address (aka zero-config or APIPA)
- (when a static IP address is configured) send an ARP probe to detect an address collision
All of these methods send out broadcast frames from the PC which populate the MAC table in all the switches in the network (broadcast domain / VLAN).
edited Feb 14 at 7:21
answered Feb 13 at 13:45
Zac67Zac67
29.6k21859
29.6k21859
Also, gratuitous ARP, as mentioned in the comments to the question.
– Jörg W Mittag
Feb 13 at 20:17
And an ARP for the default gateway and DNS servers if defined either locally or by DHCP plus UPNP discovery, etc.
– grahamj42
Feb 13 at 20:20
Strictly speaking this depend on OS and network configuration. If you were to disable IPv4 none of the packets you mention would be sent. For another example look at IPv6, it doesn't use broadcast only multicast. There are switches which will treat them the same, but a switch does not have to forward multicast packets onto all ports.
– kasperd
Feb 13 at 22:20
@kasperd Absolutely. However, 99.x% of users are using IPv4 and the question didn't call for a too thorough/complicated answer.
– Zac67
Feb 14 at 7:21
@Zac67 Your 99% number sounds like one you made up rather than anything based on actual data. One would need telemetry implemented in native code deployed to a very large user base to give a number with that amount of accuracy. I most certainly don't have access to a large enough number of client machines to say how widespread the use of IPv6-only networks with NAT64 is. But given that more than 20% of users have IPv6 access I would guess the number of such IPv6-only networks to amount for more than 1%.
– kasperd
Feb 14 at 21:20
|
show 2 more comments
Also, gratuitous ARP, as mentioned in the comments to the question.
– Jörg W Mittag
Feb 13 at 20:17
And an ARP for the default gateway and DNS servers if defined either locally or by DHCP plus UPNP discovery, etc.
– grahamj42
Feb 13 at 20:20
Strictly speaking this depend on OS and network configuration. If you were to disable IPv4 none of the packets you mention would be sent. For another example look at IPv6, it doesn't use broadcast only multicast. There are switches which will treat them the same, but a switch does not have to forward multicast packets onto all ports.
– kasperd
Feb 13 at 22:20
@kasperd Absolutely. However, 99.x% of users are using IPv4 and the question didn't call for a too thorough/complicated answer.
– Zac67
Feb 14 at 7:21
@Zac67 Your 99% number sounds like one you made up rather than anything based on actual data. One would need telemetry implemented in native code deployed to a very large user base to give a number with that amount of accuracy. I most certainly don't have access to a large enough number of client machines to say how widespread the use of IPv6-only networks with NAT64 is. But given that more than 20% of users have IPv6 access I would guess the number of such IPv6-only networks to amount for more than 1%.
– kasperd
Feb 14 at 21:20
Also, gratuitous ARP, as mentioned in the comments to the question.
– Jörg W Mittag
Feb 13 at 20:17
Also, gratuitous ARP, as mentioned in the comments to the question.
– Jörg W Mittag
Feb 13 at 20:17
And an ARP for the default gateway and DNS servers if defined either locally or by DHCP plus UPNP discovery, etc.
– grahamj42
Feb 13 at 20:20
And an ARP for the default gateway and DNS servers if defined either locally or by DHCP plus UPNP discovery, etc.
– grahamj42
Feb 13 at 20:20
Strictly speaking this depend on OS and network configuration. If you were to disable IPv4 none of the packets you mention would be sent. For another example look at IPv6, it doesn't use broadcast only multicast. There are switches which will treat them the same, but a switch does not have to forward multicast packets onto all ports.
– kasperd
Feb 13 at 22:20
Strictly speaking this depend on OS and network configuration. If you were to disable IPv4 none of the packets you mention would be sent. For another example look at IPv6, it doesn't use broadcast only multicast. There are switches which will treat them the same, but a switch does not have to forward multicast packets onto all ports.
– kasperd
Feb 13 at 22:20
@kasperd Absolutely. However, 99.x% of users are using IPv4 and the question didn't call for a too thorough/complicated answer.
– Zac67
Feb 14 at 7:21
@kasperd Absolutely. However, 99.x% of users are using IPv4 and the question didn't call for a too thorough/complicated answer.
– Zac67
Feb 14 at 7:21
@Zac67 Your 99% number sounds like one you made up rather than anything based on actual data. One would need telemetry implemented in native code deployed to a very large user base to give a number with that amount of accuracy. I most certainly don't have access to a large enough number of client machines to say how widespread the use of IPv6-only networks with NAT64 is. But given that more than 20% of users have IPv6 access I would guess the number of such IPv6-only networks to amount for more than 1%.
– kasperd
Feb 14 at 21:20
@Zac67 Your 99% number sounds like one you made up rather than anything based on actual data. One would need telemetry implemented in native code deployed to a very large user base to give a number with that amount of accuracy. I most certainly don't have access to a large enough number of client machines to say how widespread the use of IPv6-only networks with NAT64 is. But given that more than 20% of users have IPv6 access I would guess the number of such IPv6-only networks to amount for more than 1%.
– kasperd
Feb 14 at 21:20
|
show 2 more comments
PCs have many background tasks that send data all the time, even when you’re “not doing anything.” These frames will populate the MAC table.
add a comment |
PCs have many background tasks that send data all the time, even when you’re “not doing anything.” These frames will populate the MAC table.
add a comment |
PCs have many background tasks that send data all the time, even when you’re “not doing anything.” These frames will populate the MAC table.
PCs have many background tasks that send data all the time, even when you’re “not doing anything.” These frames will populate the MAC table.
answered Feb 13 at 13:22
Ron TrunkRon Trunk
36.7k33475
36.7k33475
add a comment |
add a comment |
You might think no packets have been sent, but Computers do a lot of talking in the background, given all the services functioning in the background.
add a comment |
You might think no packets have been sent, but Computers do a lot of talking in the background, given all the services functioning in the background.
add a comment |
You might think no packets have been sent, but Computers do a lot of talking in the background, given all the services functioning in the background.
You might think no packets have been sent, but Computers do a lot of talking in the background, given all the services functioning in the background.
edited Feb 13 at 17:57
Cown
6,26131030
6,26131030
answered Feb 13 at 17:16
PantheraPanthera
111
111
add a comment |
add a comment |
protected by Ron Maupin♦ Feb 13 at 21:16
Thank you for your interest in this question.
Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).
Would you like to answer one of these unanswered questions instead?
4
PCs are actually pretty chatty. They do a lot of things in the background.
– Ron Trunk
Feb 13 at 11:56
1
Are you sure there were no packet sent? How? Modern OSes have a lot of background network activity. This can also be due to gratuitous ARP. See this answer for example
– JFL
Feb 13 at 11:57
Definitely no packets sent when it was first viewed, packets were sent afterwards and the table was view again.
– The_Bear
Feb 13 at 11:58
4
Then you have magic switches.
– JFL
Feb 13 at 13:02
6
Clearly the PCs sent frames. That’s how the switch learned the MACs.
– Ron Trunk
Feb 13 at 13:11