[PC-BSD Testing] PC-BSD testing - jail network interface

nr10232 at op.pl nr10232 at op.pl
Fri Nov 8 01:04:17 PST 2013


Problem is strange - in /usr/local/etc/warden.conf is correct value:

#!/bin/sh
# Configuration options for the Warden
######################################################################

# Network Interface for the jails to use
NIC: msk0

# Directory to use for compressing / decompressing files 
WTMP: /usr/jails

# Location of the jails
JDIR: /usr/jails


but jail started with warden it has IP adres on wrong network IF:

samba2# ifconfig
rl0: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=2008<VLAN_MTU,WOL_MAGIC>
        ether 00:30:4f:51:bc:3c
ifconfig: socket(AF_INET6, SOCK_DGRAM): Protocol not supported
        media: Ethernet autoselect (none)
        status: no carrier
re0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=8209b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,WOL_MAGIC,LINKSTATE>
        ether 48:5b:39:3f:b3:92
        inet xx.xxx.xxx.230 netmask 0xffffff00 broadcast xx.xxx.xxx.255
ifconfig: socket(AF_INET6, SOCK_DGRAM): Protocol not supported
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active
msk0: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=c011a<TXCSUM,VLAN_MTU,VLAN_HWTAGGING,TSO4,VLAN_HWTSO,LINKSTATE>
        ether 00:30:4f:90:7a:f3


but jail starded with service jail start samba2 work as it should:

samba2# ifconfig
rl0: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=2008<VLAN_MTU,WOL_MAGIC>
        ether 00:30:4f:51:bc:3c
ifconfig: socket(AF_INET6, SOCK_DGRAM): Protocol not supported
        media: Ethernet autoselect (none)
        status: no carrier
re0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=8209b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,WOL_MAGIC,LINKSTATE>
        ether 48:5b:39:3f:b3:92
ifconfig: socket(AF_INET6, SOCK_DGRAM): Protocol not supported
        media: Ethernet autoselect (100baseTX <full-duplex>)
        status: active
msk0: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500
        options=c011a<TXCSUM,VLAN_MTU,VLAN_HWTAGGING,TSO4,VLAN_HWTSO,LINKSTATE>
        ether 00:30:4f:90:7a:f3
        inet xx.xxx.xxx.230 netmask 0xffffffff broadcast xx.xxx.xxx.230


So error is somewere in warden source.

Regards,
Krzysiek

 On Mon, 28 Oct 2013, nr10232 at op.pl wrote:

-}
-}Hi.
-}How to change jail network interface?
-}I tried to use warden configuration options, but it didn't work (jail work only on external network interface; i changed it about 2 times, but system allways use netif used for external comunication).
-}I figured out to start jail with /etc/rc.conf (in file i specify witch netif it will use) but I suppose there should be better option.

IIRC when I did this I had to edit /usr/local/etc/warden.conf to make sure
the jail was created using the correct interface.  This was a few revs ago
though so YMMV, FWIW, etc.  ;

--
 Randy    (schulra at earlham.edu)      765.983.1283         

Hatred does not cease by hatred, but only by love; this is the eternal rule.
     - Siddhartha Gautama

 


More information about the Testing mailing list