I have a PC connected to a switch which connects to a router. I can ping the router from the PC and vice versa. I cannot ping to or from the switch. I have checked mac addresses and they are correct. What on earth is going on?
make sure your IP addressing looks something like below (addresses are arbitrary):
interface Vlan 1
ip address 192.168.1.2 255.255.255.0
ip default-gateway 192.168.1.1
ip address 192.168.1.1 255.255.255.0
I agree that we do not know enough about this situation to be able to give a really good solution. What is described sounds like there is a vlan configured on the switch with at least 2 access ports in that vlan, and that both the router and the PC are connected to access ports in that vlan. Is that correct?
Things we do not know and need to know include:
- does the switch have a vlan interface for the vlan that connects the router and the PC?
- if there is a vlan interface then does that interface have an IP address that is in the same subnet as the router and the PC?
If the answer to either of these is no then we have identified the problem.
If the answer to both of these is yes then we need to continue to look further and posting the config of the switch would be a good next step.