Date: Wed, 12 May 2004 18:52:43 +0100 From: Matthew Seaman <m.seaman@infracaninophile.co.uk> To: carvin5string <carvin5string@yahoo.com> Cc: freebsd-questions@freebsd.org Subject: Re: moving /var & symlink to /usr/var isn't working, now broke mysql Message-ID: <20040512175243.GF28587@happy-idiot-talk.infracaninophile.co.uk> In-Reply-To: <20040512155408.67902.qmail@web40411.mail.yahoo.com> References: <20040512155408.67902.qmail@web40411.mail.yahoo.com>
next in thread | previous in thread | raw e-mail | index | archive | help
--JSkcQAAxhB1h8DcT
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
On Wed, May 12, 2004 at 08:54:08AM -0700, carvin5string wrote:
> rm -rf /var
> I am using FreeBSD-5.2. Everything works except the rm -rf /var, I get
> a=20
> message that it is not empty. I look in /var and see a subdirectory
> called empty, which is empty. But I cannot delete it.=20
See chflags(1) -- /var/empty has had the 'schg' flag applied to it to
make it immutable. You can see that by:
% ls -ldo /var/empty
dr-xr-xr-x 2 root wheel schg 512 Jun 25 2002 /var/empty/
Now, to get rid of the schg (or any other) flag you need to run:
# chflags -R 0 /var/empty
however that will only work at a low securelevel. If you have raised
the securelevel -- ie if:
# sysctl kern.securelevel
tells you securelevel is anything other than '-1' or '0' then you will
need to reboot the system into single user mode in order to do that.
http://www.freebsd.org/doc/en_US.ISO8859-1/books/faq/security.html#SECU=
RELEVEL
Also see init(8) where the details of securelevel settings are
described.
Cheers,
Matthew
--=20
Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks
Savill Way
PGP: http://www.infracaninophile.co.uk/pgpkey Marlow
Tel: +44 1628 476614 Bucks., SL7 1TH UK
--JSkcQAAxhB1h8DcT
Content-Type: application/pgp-signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (FreeBSD)
iD8DBQFAomRriD657aJF7eIRAqv8AJ9eHYzM1Iq5UXvldseSmt/L6IpGvgCeKZCz
WASIW5rA28fZnL5cGlF3+rE=
=tOsG
-----END PGP SIGNATURE-----
--JSkcQAAxhB1h8DcT--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040512175243.GF28587>
