I have a test jail that has two address aliases assigned:
When I ping without specifying a source address then I can ping another host. If I set the source IP to the 192 alias I get the error:
I just would like to know why
Code:
em0: flags=8863<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=481249b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,LRO,WOL_MAGIC,VLAN_HWFILTER,NOMAP>
ether 00:30:48:c6:96:5c
inet 216.185.71.104 netmask 0xffffffff broadcast 216.185.71.104
inet 192.168.216.104 netmask 0xffffffff broadcast 192.168.216.104
media: Ethernet autoselect (1000baseT <full-duplex>)
status: active
When I ping without specifying a source address then I can ping another host. If I set the source IP to the 192 alias I get the error:
Code:
ping -c3 -t3 192.168.216.1
PING 192.168.216.1 (192.168.216.1): 56 data bytes
64 bytes from 192.168.216.1: icmp_seq=0 ttl=64 time=0.433 ms
64 bytes from 192.168.216.1: icmp_seq=1 ttl=64 time=0.199 ms
64 bytes from 192.168.216.1: icmp_seq=2 ttl=64 time=0.231 ms
--- 192.168.216.1 ping statistics ---
3 packets transmitted, 3 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 0.199/0.288/0.433/0.103 ms
ping -c3 -t3 -S192.168.216.104 192.168.216.1
ping: -4 and -6 cannot be used simultaneously
I just would like to know why
ping reports that both IPv4 and IPv6 addresses are used.