lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 8 Feb 2012 18:25:51 +0100
From:	Kay Sievers <kay.sievers@...y.org>
To:	"H. Peter Anvin" <hpa@...or.com>
Cc:	Paul Parsons <lost.distance@...oo.com>,
	Kirill Smelkov <kirr@....spb.ru>, linux-kernel@...r.kernel.org
Subject: Re: No /dev/root with devtmpfs?

On Wed, Feb 8, 2012 at 18:20, H. Peter Anvin <hpa@...or.com> wrote:
> On 02/08/2012 08:44 AM, Paul Parsons wrote:
>>
>> Could you simply use /etc/fstab to identify the root partition?
>>
>
> That's not a very good thing, as it is much more likely to be wrong.
>
> It would be a good thing to have the /dev/root symlink *IF* a valid root
> device exists (defined as a device node appearing which has the same
> device number as reported by stat on the root directory), if nothing
> else because we have had one available for a very long time and this is
> needless breakage.
>
> Obviously, if such a device doesn't exist (btrfs, NFS, tmpfs) then don't.

Tools should just do the equivalent of:
  $ ls -l /sys/dev/block/$(mountpoint -d /)
  /sys/dev/block/8:1 ->
../../devices/pci0000:00/0000:00:1f.2/host0/target0:0:0/0:0:0:0/block/sda/sda1

and all is fine. I'm convinced, that determining the root device is a
job for *running code* not to expect a symlink to be around.

Kay
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ