how to add an aliased nic at boot time

Sergio Tam tam.sergio at gmail.com
Tue Feb 18 14:28:30 UTC 2014


 Hello

2014-02-18 7:44 GMT-06:00 Aryeh Friedman <aryeh.friedman at gmail.com>:
> I need to create two virtual nics and make them get assigned at boot
> time... the exact command line I need to transfer to rc.conf is:
>
> ifconfig re0 alias 192.168.0.1 up


 RC.CONF(5)

 http://www.freebsd.org/cgi/man.cgi?query=rc.conf&sektion=5


See

network_interfaces

It is possible to add IP alias entries using ifconfig(8) syn-
tax with the address family keyword such as inet.  Assuming
that the interface in question was ed0, it might look some-
thing like this:

ifconfig_ed0_alias0="inet 127.0.0.253 netmask 0xffffffff"
ifconfig_ed0_alias1="inet 127.0.0.254 netmask 0xffffffff"


or

Google search: ifconfig add alias to rc.conf freebsd
http://www.cyberciti.biz/tips/freebsd-how-to-setup-2-ip-address-on-one-nic.html



Regards.



>
> --
> Aryeh M. Friedman, Lead Developer, http://www.PetiteCloud.org


More information about the freebsd-questions mailing list