FreeBSD equivalent of ifup/ifdown

freebsduk at alexdyas.com freebsduk at alexdyas.com
Tue Mar 13 16:08:54 GMT 2007


On Tue, 13 Mar 2007, Simon Dick wrote:

> On Tue, 2007-03-13 at 16:54 +0100, freebsduk at alexdyas.com wrote:
>> Hi,
>>
>> Does anyone know of an equivalent under FreeBSD of the Linux ifup / ifdown
>> scripts to stop and start network interfaces?  I know of /etc/rc.d/netif,
>> but that's a bit brutal if you only want to stop/start one interface
>> (especially if you're connected on the other).
>>
>> I am of course aware that I can do it 'by hand' with ifconfig, but I feel
>> safer if I use scripts that refer to the config, that way I know what the
>> machine will use when it reboots.
>
> Try /etc/rc.d/netif restart dc0
> or whatever interface you use. No, I didn't know that was there until I
> browsed the source just now :)

Bah, and I'd looked through the source myself but hadn't seen it.  Thanks, 
this works a treat.

Alex..




More information about the Ukfreebsd mailing list