Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 7 Dec 2001 19:40:44 -0600
From:      Mike Meyer <mwm@mired.org>
To:        Gabriel Ambuehl <gabriel_ambuehl@buz.ch>
Cc:        questions@freebsd.org
Subject:   Re: What happens on a system with LOTs of mount points (say >1500)?
Message-ID:  <15377.28572.149380.851720@guru.mired.org>
In-Reply-To: <3854501@toto.iv>

next in thread | previous in thread | raw e-mail | index | archive | help
Gabriel Ambuehl <gabriel_ambuehl@buz.ch> types:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hello,
> I'm wondering how FreeBSD would behave if I did the following for eac
> of about 400 directories (domains) per server:
> 
> 
> cd /home/web/user_dom/
> mkdir bin
> mkdir sbin
> mkdir etc
> mkdir usr
> mkdir temp
> mount_null -o rdonly /bin bin
> mount_null -o rdonly /sbin sbin
> mount_null -o rdonly /etc etc
> mount_null -o rdonly /usr usr
> 
> i.e. have about 1600 mount points on a single machine. The purpose of
> the exercise is to create chroot() environments that get updated
> automatically when the base system is updated...

Assuming the warning in the mount_null man page doesn't scare you,
you're going to chew up memory in the mount table and elsewhere, and
getpwd will probably be slow. If you manage to get them all mounted,
you're probably OK.

You might consider creating empty directory trees full of hard links
back to the thing you want them to get instead. That should achieve
roughly the same results, and won't be near the burden on the sytem.

--
Mike Meyer <mwm@mired.org>			http://www.mired.org/home/mwm/
Independent WWW/Perforce/FreeBSD/Unix consultant, email for more information.

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




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