Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 1 Feb 2010 12:56:37 -0600
From:      Dan Nelson <dnelson@allantgroup.com>
To:        Nerius Landys <nlandys@gmail.com>
Cc:        Lowell Gilbert <freebsd-questions-local@be-well.ilk.org>, FreeBSD Mailing List <freebsd-questions@freebsd.org>
Subject:   Re: /root permission reset on boot
Message-ID:  <20100201185637.GE50360@dan.emsphone.com>
In-Reply-To: <560f92641002011041x484518bdqc9828eff404254fb@mail.gmail.com>
References:  <560f92641001312208r1af8a8a2j2be83fe231ad8d74@mail.gmail.com> <44ljfc2a2w.fsf@be-well.ilk.org> <560f92641002011041x484518bdqc9828eff404254fb@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
In the last episode (Feb 01), Nerius Landys said:
> >> I'm running FreeBSD 7.1 i386, and even after I "chmod 700 /root", after
> >> a reboot it goes back to permission 755.  1.  What's the reason for
> >> this?  There must be a good reason and I would like to know it. 
> >> Everything in FreeBSD just makes sense and is well designed (honestly,
> >> no sarcasm here).
> >
> > It's something local to your machine; this doesn't happen on any machine
> > I've used, and I can't find anything that could be configured for that.
> 
> Perhaps I was mistaken about this happening after every reboot.  Perhaps
> it only happens when I upgrade my world (make buildworld, make
> installworld, etc.).  I do this often (every time a release patch is
> released).
> 
> So, perhaps this only happens during these upgrades?

I was going to point blame at mtree, but the file for the root filesystem
( /etc/mtree/BSD.root.dist ) just lists /root without forcing a mode value.

You could probably use either dtrace or the audit system to log exactly when
the permissions get changed.

-- 
	Dan Nelson
	dnelson@allantgroup.com



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