[prev in list] [next in list] [prev in thread] [next in thread] 

List:       crux
Subject:    Re: Pre interface dameons
From:       Florian Weber <Florian.Weber () pfaffenhofen ! de>
Date:       2002-08-01 3:02:17
[Download RAW message or body]

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Wednesday 31 July 2002 21:21, Erlend Bergsås Mikkelsen wrote:
> It should be possible to run daemons before the interfaces are initiated,
> and close them after the interfaces are shut down.
>
> This would be very nice for people getting dynamic IPs, and for
> people using the pcmciatools

Nice: perhaps. Neccessary: not at all.
Consider that pcmcia has it's own config files e.g. for network in 
/etc/pcmcia/network.opts. My setup (pcmcia, dhcp), which boots just like 
you'd expect, is as follows:

- - Laptop with only a pcmcia ethernet card (no onboard stuff)
- - Port for dhcpcd is installed.

/etc/rc.conf:
IFCONFIG_UP=("lo 127.0.0.1")
IFCONFIG_DOWN=("lo down")
ROUTE=("")
DAEMONS=(pcmcia OTHER CRUX DAEMONS)

/etc/pcmcia/network.opts:
case "$ADDRESS" in
*,*,*,*)          # <--- select different pcmcia cards / network channels here
    INFO="Generic DHCP base setup"
    DHCP="y"
    # all other options empty or off
    # you might also set hardcoded IP parameters here
   ;;
esac

With the last file, pcmcia-cs will call either /sbin/dhcpcd, /sbin/dhclient or 
/sbin/pump. For me, this automagically translates into a call to 
"/sbin/dhcpcd -h HOSTNAME eth0" that will even update dynamic DNS with the 
correct hostname :-)

The only thing it won't do is stop the dhcp daemon on card ejection. But it 
won't start it twice either upon reinsertion, so that's fine.

> [pcmcia]
> (which by the way should be added to the
> opt repository considering it's a pain transfering these tools to the
> laptop if one don't have network).

Plus: pcmcia is a basic item for just about every laptop out there.

I second this motion once a solution to the "changing files" problem 
(discussed elsewhere on this list) has been agreed on.

- -- 
With best regards,
Florian Weber

PGP key ID: 3C4E74DC
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE9SKS5m8fasDxOdNwRAs6fAKDUO/dHuurvC4L+pX9HQZxdq+maIACdGztI
ShSB8Xbzhen3+fYKS72A+z0=
=+evw
-----END PGP SIGNATURE-----

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic