I'm not able to wrap my head around what's going on with the networking in a jail.
I created a new jail 'jail1' and configured it with an IP in the same subnet as the bare metal OS.
The trouble I'm having is that the same IP also shows up in the bare metal OS, and if I SSH to it I end up in the bare metal OS.
How can I configure the jail so that it has its own IP that is unrelated to the bare metal OS?
I created a new jail 'jail1' and configured it with an IP in the same subnet as the bare metal OS.
Code:
root@jail1:~ # ifconfig
em0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=9b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM>
ether 00:50:56:9a:6d:19
inet 10.0.75.201 netmask 0xffffffff broadcast 10.0.75.201
media: Ethernet autoselect (1000baseT <full-duplex>)
status: active
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
The trouble I'm having is that the same IP also shows up in the bare metal OS, and if I SSH to it I end up in the bare metal OS.
Code:
[root@freebsd-root1 /home/someone]# ifconfig
em0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
options=9b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM>
ether 00:50:56:9a:6d:19
inet 10.0.75.102 netmask 0xffffff00 broadcast 10.0.75.255
inet 10.0.75.201 netmask 0xffffffff broadcast 10.0.75.201
nd6 options=29<PERFORMNUD,IFDISABLED,AUTO_LINKLOCAL>
media: Ethernet autoselect (1000baseT <full-duplex>)
status: active
lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> metric 0 mtu 16384
options=600003<RXCSUM,TXCSUM,RXCSUM_IPV6,TXCSUM_IPV6>
inet6 ::1 prefixlen 128
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x2
inet 127.0.0.1 netmask 0xff000000
nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL>
How can I configure the jail so that it has its own IP that is unrelated to the bare metal OS?