Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 01 Apr 2003 09:39:05 -0600
From:      Kirk Strauser <kirk@strauser.com>
To:        freebsd-questions@freebsd.org
Subject:   Re: Cloning a jail
Message-ID:  <87vfxyw7l2.fsf@pooh.honeypot.net>
In-Reply-To: <20030401143251.GA4560@poecilotheria.netmails.net> (Hari Bhaskaran's message of "Tue, 1 Apr 2003 08:32:51 -0600")
References:  <20030401143251.GA4560@poecilotheria.netmails.net>

next in thread | previous in thread | raw e-mail | index | archive | help
--=-=-=
Content-Transfer-Encoding: quoted-printable

At 2003-04-01T14:32:51Z, Hari Bhaskaran <subscr@spider.netmails.net> writes:

> When I need to clone a jail, would a cp -Rp do?

I don't know about `cp' (I'm not sure how well it deals with device nodes,
symlinks, etc), but yes, making an exact copy of the file structure should
result in an identical jail.

> Also can I hardlink a tree (outside) to inside the jail?

Once you've made a hardlink, the system has no concept of the "original
location".  Both of the filesystem entries point to a structure on the disk;
that structure doesn't refer back to those entries, point to one, and say
"that's my parent!"

However, depending on what you want to do, using NFS may be a nice approach.
You can make a directory and its children read-only to the jail, but
read-write outside of the jail.  It's also a lot clearer later on that a
particular directory is used by several different systems on the same
machine.
=2D-=20
Kirk Strauser
In Googlis non est, ergo non est.

--=-=-=
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)

iD8DBQA+ibKa5sRg+Y0CpvERAvrEAKCa1/YRYq11p/qRHGFRrsWikueBsgCghwSC
CtgY16B0wy/zRKymN2ExDDQ=
=LJkY
-----END PGP SIGNATURE-----
--=-=-=--



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