[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#78834: marked as done (Support for mounting /usr readonly)



Your message dated Mon, 11 Dec 2000 19:58:33 +0100
with message-id <20001211195833.N4346@cistron.nl>
and subject line Bug#78834: Support for mounting /usr readonly
has caused the attached Bug report to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what I am
talking about this indicates a serious mail system misconfiguration
somewhere.  Please contact me immediately.)

Darren Benham
(administrator, Debian Bugs database)

--------------------------------------
Received: (at submit) by bugs.debian.org; 5 Dec 2000 14:23:48 +0000
>From Simon.Richter@phobos.fs.tum.de Tue Dec 05 08:23:48 2000
Return-path: <Simon.Richter@phobos.fs.tum.de>
Received: from phobos.fachschaften.tu-muenchen.de [129.187.176.43] (mail)
	by master.debian.org with esmtp (Exim 3.12 1 (Debian))
	id 143J0S-000299-00; Tue, 05 Dec 2000 08:23:44 -0600
Received: from geier (helo=localhost)
	by phobos.fachschaften.tu-muenchen.de with local-esmtp (Exim 3.12 #1 (Debian))
	id 143J07-0005fA-00
	for <submit@bugs.debian.org>; Tue, 05 Dec 2000 15:23:23 +0100
Date: Tue, 5 Dec 2000 15:23:23 +0100 (CET)
From: Simon Richter <Simon.Richter@phobos.fs.tum.de>
To: submit@bugs.debian.org
Subject: Support for mounting /usr readonly
Message-ID: <[🔎] Pine.LNX.4.21.0012051514210.20290-100000@phobos.fachschaften.tu-muenchen.de>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
Delivered-To: submit@bugs.debian.org

Package: general
Severity: wishlist

Hi,

My usual setup is to have /usr mounted readonly and have apt remount it
r/w when it calls dpkg. This saves me about 20 minutes of fsck time, as
/usr has many small files on it.

However, this approach only works as long as no postinst script starts a
daemon on /usr. After that, the filesystem is marked busy and cannot be
properly remounted read-only.

As postinst scripts need r/w access to /usr currently, there is no easy
solution (like unpacking first, remounting, then configuring). An option
would be to split the postinst process. Since not many packages should
need to modify files on /usr in the postinst, this would be actually
doable, however I'm not sure about whether this is actually wanted.

   Simon

-- 
GPG public key available from http://phobos.fs.tum.de/pgp/Simon.Richter.asc
 Fingerprint: DC26 EB8D 1F35 4F44 2934  7583 DBB6 F98D 9198 3292
Hi! I'm a .signature virus! Copy me into your ~/.signature to help me spread!


---------------------------------------
Received: (at 78834-done) by bugs.debian.org; 13 Dec 2000 14:58:42 +0000
>From wichert@cistron.nl Wed Dec 13 08:58:41 2000
Return-path: <wichert@cistron.nl>
Received: from cabal.wiggy.net (fog.mors.wiggy.net) [195.64.66.141] 
	by master.debian.org with esmtp (Exim 3.12 1 (Debian))
	id 146DMb-0001DQ-00; Wed, 13 Dec 2000 08:58:41 -0600
Received: (from wichert@localhost)
	by fog.mors.wiggy.net (8.11.1/8.11.1/Debian 8.11.0-6) id eBBIwX104901;
	Mon, 11 Dec 2000 19:58:33 +0100
Date: Mon, 11 Dec 2000 19:58:33 +0100
From: Wichert Akkerman <wichert@valinux.com>
To: Simon Richter <Simon.Richter@phobos.fachschaften.tu-muenchen.de>,
   78834-done@bugs.debian.org
Subject: Re: Bug#78834: Support for mounting /usr readonly
Message-ID: <20001211195833.N4346@cistron.nl>
References: <[🔎] Pine.LNX.4.21.0012051514210.20290-100000@phobos.fachschaften.tu-muenchen.de>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
User-Agent: Mutt/1.2.5i
In-Reply-To: <[🔎] Pine.LNX.4.21.0012051514210.20290-100000@phobos.fachschaften.tu-muenchen.de>; from Simon.Richter@phobos.fachschaften.tu-muenchen.de on Tue, Dec 05, 2000 at 03:23:23PM +0100
Delivered-To: 78834-done@bugs.debian.org

Previously Simon Richter wrote:
> However, this approach only works as long as no postinst script starts a
> daemon on /usr. After that, the filesystem is marked busy and cannot be
> properly remounted read-only.

Any daemon that doesn't do the following is basically broken:
1. chdir to /
2. close stdin/stdout/stderr and if needed reopen then to /dev/null
3. start a new session group (setsid)

If you find a daemon that doesn't do that feel free to submit a
bugreport.

> As postinst scripts need r/w access to /usr currently, there is no easy
> solution (like unpacking first, remounting, then configuring). An option
> would be to split the postinst process. Since not many packages should
> need to modify files on /usr in the postinst, this would be actually
> doable, however I'm not sure about whether this is actually wanted.

The postinst might need a writeable /usr, there is no way around that.
Remount /usr after running all the postinsts.

Wichert.

-- 
  _________________________________________________________________
 /       Nothing is fool-proof to a sufficiently talented fool     \
| wichert@cistron.nl                  http://www.liacs.nl/~wichert/ |
| 1024D/2FA3BC2D 576E 100B 518D 2F16 36B0  2805 3CB8 9250 2FA3 BC2D |



Reply to: