Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 27 Jun 2005 12:27:06 -0700
From:      "Darren Pilgrim" <dmp@bitfreak.org>
To:        "'Niki Denev'" <nike_d@cytexbg.com>
Cc:        hackers@freebsd.org
Subject:   RE: How to disable at-boot configuration of a network interface but permit manual use of rc.d?
Message-ID:  <004f01c57b4e$34a289a0$0b2a15ac@SMILEY>
In-Reply-To: <42C051D3.2080709@cytexbg.com>

next in thread | previous in thread | raw e-mail | index | archive | help
From: Niki Denev [mailto:nike_d@cytexbg.com] 
> Darren Pilgrim wrote:
> > There are some conditions to the task given by the subject:
> > 
> > 1: The interface must be present at boot.
> > 2: Use of /etc/rc.d scripts to start and stop the interface
> > is desirable.
> > 
> > The first condition poses no problem, just don't include the
> > relevant ifconfig_ifn line in /etc/rc.conf and the interface won't
> > be configured. But rc.d/dhclient and rc.d/netif won't work without
> > an ifconfig line for the interface.
> > 
> > Adding the ifconfig line and then listing every interface but the
> > one I want configured in network_interfaces does prevent it from
> > being configured at boot while having an ifconfig line in rc.conf,
> > but if I try to use rc.d/netif to start the interface, rc.d/netif
> > does nothing because it tests the interface against the contents
> > of network_interfaces and cloned_interfaces, so the interface I
> > left out will be excluded.
> > 
> > Have I overlooked an option somewhere?
> 
> What happens if you configure the interface in 'down' state, like :
> 
> ifconfig_fxp0="inet 192.168.0.10 netmask 0xffffff00 down"

Then rc.d/dhclient won't work.  The "DHCP" keyword must be present in
the ifconfig line in order for dhcpif to test true.  A similar logic is
in place for wpaif based on the "WPA" keyword.




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?004f01c57b4e$34a289a0$0b2a15ac>