Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 7351

Summary: On x86 platform, given /etc/fstab is impossible
Product: [OLD] Docs-user Reporter: Evan Read <eread>
Component: Gentoo Security GuideAssignee: Sherman Boyd <meekrob>
Status: RESOLVED FIXED    
Severity: normal    
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
URL: http://www.gentoo.org/doc/gentoo-security.html#doc_chap3
Whiteboard:
Package list:
Runtime testing required: ---

Description Evan Read 2002-09-01 17:27:44 UTC
The given /etc/fstab in the security documentation is impossible to replicate on the x86 plaform (and maybe  
others)?  
  
The given /etc/fstab/:  
 
<begin fstab>  
/dev/sda1 /boot ext2 noauto,noatime 1 1 
/dev/sda2 none swap sw 0 0 
/dev/sda3 / reiserfs notail,noatime 0 0 
/dev/sda4 /tmp reiserfs notail,noatime,nodev,nosuid,noexec 0 0 
/dev/sda5 /var reiserfs notail,noatime,nodev 0 0 
/dev/sda6 /home reiserfs notail,noatime,nodev,nosuid 0 0 
/dev/sda7 /usr reiserfs notail,noatime,nodev,ro 0 0 
/dev/cdroms /cdrom0 /mnt/cdrom iso9660 noauto,ro 0 0 
proc /proc proc defaults 0 0 
</end fstab> 
 
Partitioning 7 partitions in a row is impossible on x86 (starting from 1).  One of these partitions (most likely 
4) needs to be an extended partition for the rest and therefore cannot be directly assigned like that.  A more 
likely scenario is this: 
 
<begin fstab> 
/dev/sda1 /boot ext2 noauto,noatime 1 1 
/dev/sda2 none swap sw 0 0 
/dev/sda3 / reiserfs notail,noatime 0 0 
# parition four is container for subsequent partitions 
/dev/sda5 /tmp reiserfs notail,noatime,nodev,nosuid,noexec 0 0 
/dev/sda6 /var reiserfs notail,noatime,nodev 0 0 
/dev/sda7 /home reiserfs notail,noatime,nodev,nosuid 0 0 
/dev/sda8 /usr reiserfs notail,noatime,nodev,ro 0 0 
/dev/cdroms /cdrom0 /mnt/cdrom iso9660 noauto,ro 0 0 
proc /proc proc defaults 0 0 
</end fstab> 
 
In the case where this limitation doesn't exist on other platforms, it might be worthwhile putting fstabs in for 
all platforms.  
 
This is the paritioning scheme I use and is proven to be correct (ie what fdisk will let you do). 
 
Thanks! 
 
Evan.
Comment 1 John Davis (zhen) (RETIRED) gentoo-dev 2002-09-10 17:20:43 UTC
I fixed this and commented it appropriately.

//ZhEN