/etc/rc.conf 에서 IP 변경한후 sh /etc/netstart 하면 IP가 변경됩니다.
한개 인터페이스에 여러 IP를 할당시에는 alias 로 추가 하시면됩니다.
ifconfig em0 alias 10.0.0.1 netmask 255.0.0.0
제거는 -alias
ifconfig em0 -alias 10.0.0.1
## /etc/netstart 스크립트 내용
. /etc/rc.subr
load_rc_config 'XXX'
/etc/rc.d/pccard start
/etc/rc.d/devd start
/etc/rc.d/hostname start
/etc/rc.d/ipmon start
/etc/rc.d/ipfilter start
/etc/rc.d/ipnat start
/etc/rc.d/ipfs start
/etc/rc.d/sppp start
# /etc/rc.d/atm1 start
# . /etc/rc.d/atm2.sh start
# . /etc/rc.d/atm3.sh start
/etc/rc.d/netif start
/etc/rc.d/ipsec start
/etc/rc.d/dhclient start
/etc/rc.d/isdnd start
/etc/rc.d/ppp start
/etc/rc.d/ipfw start
/etc/rc.d/ip6fw start
/etc/rc.d/network_ipv6 start
/etc/rc.d/routing start
/etc/rc.d/mroute6d start
/etc/rc.d/route6d start
/etc/rc.d/mrouted start
/etc/rc.d/routed start
/etc/rc.d/nisdomain start
exit 0
IP 변경하기