Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 1 Jul 2003 16:18:02 +0100
From:      lewiz <purple@lewiz.info>
To:        Dan Pelleg <daniel+bsd@pelleg.org>
Cc:        FreeBSD-questions <freebsd-questions@freebsd.org>
Subject:   Re: Variable NFS mounts / firewall rules.
Message-ID:  <20030701151802.GA9390@lewiz.org>
In-Reply-To: <u2sptkuifel.fsf@gs166.sp.cs.cmu.edu>
References:  <20030701063248.GA904@lewiz.org> <u2sptkuifel.fsf@gs166.sp.cs.cmu.edu>

next in thread | previous in thread | raw e-mail | index | archive | help

--y0ulUmNC+osPPQO6
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Tue, Jul 01, 2003 at 08:45:54AM -0400, Dan Pelleg wrote:
> 2. Use the automounter to mount NFS volumes on-demand. This way you will
> not have to worry about mounting until you actually need to access the
> volume. See amd(8).

That's a good idea I didn't think off :)  I messed with amd(8) once
before and ran into trouble.  I can see in this case it would be ideal,
and shall have a go at getting it to play nicely.

> 3. ipfw supports the "me" keyword, to flexibly refer to your currently
> assigned IP address.

Yes, I had looked at this.  However, I was meaning trying to have a
solution where a different set of firewall rules would be started based
on the assigned IP address.

> 4. Just in case it might help you, here is my /etc/dhclient-exit-hooks:
>=20
> # nothing to do unless we're bound
> case ${reason} in
>     BOUND | RENEW | REBIND | REBOOT )
>         if [ -n "${new_domain_name_servers}" ]; then
>             if [ -z "${old_domain_name_servers}" ] || [ x${old_ip_address=
} !=3D x{$new_ip_address} ]; then
>                 [ -x /etc/refresh-named ] && /etc/refresh-named ${new_dom=
ain_name_servers}
>                 [ -x /etc/set-time ] && /etc/set-time
>             fi
>         fi
>         ;;
> esac

Yeah, I think I can see that this might even be a good place to
start/stop (stop if required, I haven't read amd(8) yet) amd from.
Also, I can set my symlinks in case the reason is not one of yours
listed.

> 5. You can further run ifconfig commands in /etc/start_if.<INTERFACE NAME>
> (for example /etc/start_if.fxp0 ).

I use start_if.ep0 to set the media for my network card.  Does this get
re sourced after dhclient has done it's magic?  I was under the
assumption that it got executed /before/ dhclient, and would therefore
be of little use to set variables based on the output of dhclient... ?

  Many thanks!  You've given me some excellent ideas.  I'll tell you how
I fare.

-lewiz.

--=20
In the long run, every program becomes rococo, and then rubble.
		-- Alan Perlis
------------------------------------------------------------------------
-| msn:purple@lewiz.net | jab:lewiz@jabber.org | url:http://lewiz.net |-

--y0ulUmNC+osPPQO6
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (FreeBSD)

iD8DBQE/AaYpItq0KFQv7T8RAj0MAJ4zS0b6FSUSCU+M6E4hvXCLe8AULQCgkc0y
NVPkH00oyrvMkDkcThVACCw=
=wwPt
-----END PGP SIGNATURE-----

--y0ulUmNC+osPPQO6--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20030701151802.GA9390>