![]() |
ubuntu.com - launchpad.net - ubuntu help
|
|
|||||||
|
Tutorials & Tips The place to find Ubuntu related Tips & Tricks. |
Thread Tools
|
Display Modes
|
October 23rd, 2006
|
#1 | ||||||||||||||||||||||||
|
Ubuntu Guru
![]() |
![]() Understanding fstab Sorry this is such a long post. I added much of this information to the Ubuntu wiki. update May 2009 : tbuss kindly converted this post to a pdf which is available here. The pdf can be downloaded if you log into scribd. You may use openid to log in, so should be easy if you also have an account at launchpad. Ubuntu Wiki : fstab There are essentially 5 sections:
Scroll down to the section you need. Introduction If you simply want a gui tool to manage your partitions (/etc/fstab) try Pysdm. ![]() /etc/fstab is a system configuration file and is used to tell the Linux kernel which partitions (file systems) to mount and where on the file system tree.pysdm Screen Shot /etc/mtab is an index of all mounted partitions/file systems. Note: See references section at the end of this how to for useful links. How to mount The mount command and fstab go hand in hand:
How to mount Mount Partitions Automatically (At BOOT). Filesystems and Mounting Thanks Hermanzone mount has a multitude of options. Manpage: man mount pmount: Pmount allows a user to mount removable media. pmount uses /media/<NAME> as the mount point. Syntax: Quote:
Code:
pmount /dev/dsa1 data To unmount: Code:
pumount <NAME>
Configure pmount for internal drives To show your partitions/usb devices, first plug in your usb card. To list your mounted partitions: Code:
mount Code:
sudo fdisk -l First connect all your devices, then: Code:
ls /dev/disk/by-uuid -alh fstab Syntax Quote:
/dev/hdxy or /dev/sdxy. x will be a letter starting with a, then b,c,.... y will be a number starting with 1, then 2,3,.... Thus hda1 = First partition on the master HD. See Basic partitioning for more informationNote: zip discs are always numbered "4". Example: USB Zip = /dev/sda4. Note: You can also identify a device by udev, volume label (AKA LABEL), or uuid. These fstab techniques are helpful for removable media because the device (/dev/sdxy) may change. For example, sometimes the USB device will be assigned /dev/sda1, other times /dev/sdb1. This depends on what order you connect USB devices, and where (which USB slot) you use to connect. This can be a major aggravation as you must identify the device before you can mount it. fstab does not work well if the device name keeps changing. To list your devices, first put connect your USB device (it does not need to be mounted). By volume label: Code:
ls /dev/disk/by-label -lah Code:
ls /dev/disk/by-id -lah Code:
ls /dev/disk/by-uuid -lah The format to use instead of the device name in the fstab file is: LABEL=<label> (Where <label> is the volume label name, ex. "data"). UUID=<uuid> (Where <uuid> is some alphanumeric (hex) like fab05680-eb08-4420-959a-ff915cdfcb44). Again, IMO, using a label has a strong advantage with removable media (flash drives). See How to use Labels below. For udev: udev does the same thing as LABEL, but I find it more complicated. See How to udev for a very nice how to on udev. Mount point. This is where the partition is mounted or accessed within the "tree" (ie /mnt/hda1). You can use any name you like. In general
Examples:
To make a mount point: Code:
sudo mkdir /media/usb auto: The file system type (ext3, iso9660, etc) it detected automatically. Usually works. Used for removable devices (CD/DVD, Floppy drives, or USB/Flash drives) as the file system may vary on these devices. Linux file systems: ext2, ext3, jfs, reiserfs, reiser4, xfs, swap. Windows: vfat = FAT 32, FAT 16 ntfs= NTFS Note: For NTFS rw ntfs-3g CD/DVD/iso: iso9660 To mount an iso image (*.iso NOT CD/DVD device):Network file systems: This section assumes the server and client are already setup. nfs Example: Quote:
More detailed information on nfssmb (samba) : Samba mounts can be performed very easily via gui tools (See Ubuntu Wiki Setting up Samba). If you mount a samba share with the gui tools it will be placed in ~/.gvfs , a hidden directory in your home directory. This section is limited to fstab and you will need a fstab entry to mount samba shares at boot. smbfs is now depreciated for cifs : http://linux-cifs.samba.org/ cifs still uses a credentials file to avoid the need to enter a password. If you do not use a credentials file, you will mount a samba share with sudo and enter your username and password in a terminal. Quote:
samba_user = samba user (on server).samba_user_password = samba user password (on server).
smbfs : depreciated, but similar. Quote:
More detailed information on see : The Official Samba 3.2.x HOWTO and Reference Guidesshfs : Network shares over ssh http://ubuntu.wordpress.com/2005/10/...m-using-sshfs/ Code:
sshfs#user@server:/share fuse user,allow_other 0 0
Options: Ubuntu 8.04 now defaults to "relatime". For a discussion of this option see : http://lwn.net/Articles/244829/ defaults = rw, suid, dev, exec, auto, nouser, and async. Options for a separate /home : nodev,nosuid,relatime My recommended options for removable (USB) drives are in green. auto= mounted at boot noauto= not mounted at boot user= when mounted the mount point is owned by the user who mounted the partition users= when mounted the mount point is owned by the user who mounted the partition and the group users ro= read only rw= read/write VFAT/NTFS: Ownership and permissios of vfat / ntfs are set at the time of mounting. This is often a source of confusion. uid= Sets owner. Syntax: may use user_name or user ID #. gid= sets group ownership of mount point. Again may use group_name or GID #. umask can be used to set permissions if you wish to change the default. Syntax is "odd" at first. To set a permissions of 777, umask=000 To set permissions of 700, umask=077 Best is to set directories with executable permissions and file with read write. To do this, use fmask and dmask (rather then umask): dmask=027 fmask=137 With these options files are not executable (all colored green in a terminal w/ ls) Linux native file systems: Use defaults or users. To change ownership and permissions, mount the partition, then use chown and chmod. Note: Warning re: sync and flash devices: Warning Additional Options: (From wiki.linuxquestions.org/wiki/Fstab):
Dump Dump: Dump field sets whether the backup utility dump will backup file system. If set to "0" file system ignored, "1" file system is backed up. Fsck order Fsck: Fsck order is to tell fsck what order to check the file systems, if set to "0" file system is ignored. See also: Tuning the Filesystem Check at Bootup Fstab Examples Quote:
How to Label Linux: How the label and the UUID are set depends on the file system type used. It can normally be set when creating/formatting the file system and the file system type usually has some tool to change it later on (e.g. e2tunefs,xfs_admin,reiserfstune,etc.) Labels Mke2fs/e2label/tune2fs: Note: For either ext2 or ext3 file systems. WARNING: mke2fs will reformat your partition and set a label at the same time. This will delete any data on the target partition. To set a label without reformatting use e2label or tune2fs
ReiserFS: Use reiserfstune: Code:
reiserfstune --l <Label> <device> Note:That is a small "L" and not the number 1.JFS: Use jfs_tune: Code:
jfs_tune -L <Label> <device> Code:
jfs_tune -l <device> Note:That is a small "L" and not the number 1.XFS: Use xfs_admin: Code:
sudo xfs_admin -L <Label> <device> Code:
xfs_admin -l <device> Note:That is a small "L" and not the number 1.FAT (Windows partitions): Use mtools to label a FAT partition:
NTFS (Windows partitions): Thanks to rudyj for pointing out the oversight.Use ntfsprogs: First install ntfsprogs: Code:
sudo aptitude install ntfsprogs Then:
============== END OF LABEL =============== Examples of fstab options ********* FAT ********** FAT partitions are easy to share between Linux and Windows as both OS will read FAT "out of the box" without additional installation or configuration. In this example I will use /mnt/data as my mount point. Code:
sudo mkdir /mnt/data Quote:
Quote:
********* Linux Native File Systems ********** In this example I will use ext3, but this holds true for ext2, reiserfs, jfs, and xfs. Code:
sudo mkdir /mnt/ext3 Quote:
============== END OF EXAMPLES =============== References Partitioning: Basic partitioning Mount: How to mount filesystems in Linux Ubuntu Automatically Mount Partitions man mount Mount Other Filesystems Fstab: fstab wiki How to edit and understand /etc/fstab Tuning the Filesystem Check at Bootup Labels: How to use Labels udev: How to udev NTFS: ntfs-3g Zip dirve how-to: How to Zip Drive nfs: How to set up NFS How to NFS v4 Debian/Ubuntu NFS Guide Short but sweeeet ! Mount Windows Sares: Mount Windows shares permanently Samba: Setting up Samba How to mount smbfs shares permanently
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() Last edited by bodhi.zazen; October 22nd, 2009 at 02:32 PM.. Reason: Updated cifs and info on behavior with mount points |
||||||||||||||||||||||||
|
|
October 24th, 2006
|
#2 |
|
Dark Roasted Ubuntu
![]() Join Date: Aug 2005
Location: Canada
Beans: 1,082
|
Re: How to fstab
Thanks for the detailed walkthrough!
I'm sure the UUID info will come in handy once Edgy hits. |
|
|
October 24th, 2006
|
#3 |
|
May the Ubuntu Be With You!
![]() Join Date: Apr 2006
Beans: 1,252
|
Re: How to fstab
Great works man, this is a must
__________________
WARNING : Post with explicit contents
Join to "STOP monolithic all-in-one unmanageable application" The wiki is your friend |
|
|
October 24th, 2006
|
#4 |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Thanks for the comprehensive guide. I'll be pointing people here.
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
October 27th, 2006
|
#5 |
|
Way Too Much Ubuntu
![]() |
Re: How to fstab
swell bodhi.zazen,
Thats grand detailing there, Thank You.
__________________
Love Abhinya (\_./) (O.-) (> <) |
|
|
November 6th, 2006
|
#6 |
|
Chocolate-Covered Ubuntu Beans
![]() Join Date: Oct 2005
Location: Fribourg,Switzerland
Beans: 2,202
|
Re: How to fstab
Great job! Thanks a lot,bodhi.zazen!
__________________
my JAMENDO * The XY sex-determination system is the sex-determination system found in humans and Z was my donor! * Tarot and Poya Sutra | * # 12755 |
|
|
December 2nd, 2006
|
#7 | ||
|
Dark Roasted Ubuntu
![]() Join Date: Nov 2006
Location: There and back again
Beans: 1,043
|
Re: How to fstab
I learned howto mount my hfsplus at startup.
Quote:
Quote:
Last edited by Gen2ly; December 4th, 2006 at 10:27 PM.. |
||
|
|
December 2nd, 2006
|
#8 | |||
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
Try: Code:
ls /dev/disk/by-label -lh If so... try this fstab entry: Quote:
If not... try this fstab entry: Quote:
Gentoo wiki How to hfsplus Gentoo wiki how to IPOD Ubuntu Forums hfsplus If you would be so kind as to post the solution I will update this "how-long" as xpod calls it
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|||
|
|
December 2nd, 2006
|
#9 |
|
Ubuntu addict and loving it
![]() Join Date: Jun 2006
Location: The Netherlands
My beans are hidden!
Ubuntu 9.10 Karmic Koala
|
Re: How to fstab
Well bodhi,you're a busy man.
I definitely bookmark this one,it should come handy some day. Thank you very much for this howto.
__________________
Resistance is futile.....you will be assimilated! Registered Linux User 418427. #Ubuntu User 3226# |
|
|
December 11th, 2006
|
#10 |
|
First Cup of Ubuntu
![]() Join Date: Dec 2006
My beans are hidden!
|
Re: How to fstab
great guide, helped me a lot
there is also options not mentioned in guide but i found them in some examples: nls, iocharset for correct encodeing file names. I don't know anything more about them. Anyway when i tryed to use a cd where filenames had special characters (Polish), but instead of them there were non-alphabetical signs. So i used this entry in fstab and it helped Code:
/dev/hdd /media/cdrom0 udf,iso9660 utf8,user,noauto 0 0 |
|
|

October 23rd, 2006
|
#1 | ||||||||||||||||||||||||
|
Ubuntu Guru
![]() |
![]() Understanding fstab Sorry this is such a long post. I added much of this information to the Ubuntu wiki. update May 2009 : tbuss kindly converted this post to a pdf which is available here. The pdf can be downloaded if you log into scribd. You may use openid to log in, so should be easy if you also have an account at launchpad. Ubuntu Wiki : fstab There are essentially 5 sections:
Scroll down to the section you need. Introduction If you simply want a gui tool to manage your partitions (/etc/fstab) try Pysdm. ![]() /etc/fstab is a system configuration file and is used to tell the Linux kernel which partitions (file systems) to mount and where on the file system tree.pysdm Screen Shot /etc/mtab is an index of all mounted partitions/file systems. Note: See references section at the end of this how to for useful links. How to mount The mount command and fstab go hand in hand:
How to mount Mount Partitions Automatically (At BOOT). Filesystems and Mounting Thanks Hermanzone mount has a multitude of options. Manpage: man mount pmount: Pmount allows a user to mount removable media. pmount uses /media/<NAME> as the mount point. Syntax: Quote:
Code:
pmount /dev/dsa1 data To unmount: Code:
pumount <NAME>
Configure pmount for internal drives To show your partitions/usb devices, first plug in your usb card. To list your mounted partitions: Code:
mount Code:
sudo fdisk -l First connect all your devices, then: Code:
ls /dev/disk/by-uuid -alh fstab Syntax Quote:
/dev/hdxy or /dev/sdxy. x will be a letter starting with a, then b,c,.... y will be a number starting with 1, then 2,3,.... Thus hda1 = First partition on the master HD. See Basic partitioning for more informationNote: zip discs are always numbered "4". Example: USB Zip = /dev/sda4. Note: You can also identify a device by udev, volume label (AKA LABEL), or uuid. These fstab techniques are helpful for removable media because the device (/dev/sdxy) may change. For example, sometimes the USB device will be assigned /dev/sda1, other times /dev/sdb1. This depends on what order you connect USB devices, and where (which USB slot) you use to connect. This can be a major aggravation as you must identify the device before you can mount it. fstab does not work well if the device name keeps changing. To list your devices, first put connect your USB device (it does not need to be mounted). By volume label: Code:
ls /dev/disk/by-label -lah Code:
ls /dev/disk/by-id -lah Code:
ls /dev/disk/by-uuid -lah The format to use instead of the device name in the fstab file is: LABEL=<label> (Where <label> is the volume label name, ex. "data"). UUID=<uuid> (Where <uuid> is some alphanumeric (hex) like fab05680-eb08-4420-959a-ff915cdfcb44). Again, IMO, using a label has a strong advantage with removable media (flash drives). See How to use Labels below. For udev: udev does the same thing as LABEL, but I find it more complicated. See How to udev for a very nice how to on udev. Mount point. This is where the partition is mounted or accessed within the "tree" (ie /mnt/hda1). You can use any name you like. In general
Examples:
To make a mount point: Code:
sudo mkdir /media/usb auto: The file system type (ext3, iso9660, etc) it detected automatically. Usually works. Used for removable devices (CD/DVD, Floppy drives, or USB/Flash drives) as the file system may vary on these devices. Linux file systems: ext2, ext3, jfs, reiserfs, reiser4, xfs, swap. Windows: vfat = FAT 32, FAT 16 ntfs= NTFS Note: For NTFS rw ntfs-3g CD/DVD/iso: iso9660 To mount an iso image (*.iso NOT CD/DVD device):Network file systems: This section assumes the server and client are already setup. nfs Example: Quote:
More detailed information on nfssmb (samba) : Samba mounts can be performed very easily via gui tools (See Ubuntu Wiki Setting up Samba). If you mount a samba share with the gui tools it will be placed in ~/.gvfs , a hidden directory in your home directory. This section is limited to fstab and you will need a fstab entry to mount samba shares at boot. smbfs is now depreciated for cifs : http://linux-cifs.samba.org/ cifs still uses a credentials file to avoid the need to enter a password. If you do not use a credentials file, you will mount a samba share with sudo and enter your username and password in a terminal. Quote:
samba_user = samba user (on server).samba_user_password = samba user password (on server).
smbfs : depreciated, but similar. Quote:
More detailed information on see : The Official Samba 3.2.x HOWTO and Reference Guidesshfs : Network shares over ssh http://ubuntu.wordpress.com/2005/10/...m-using-sshfs/ Code:
sshfs#user@server:/share fuse user,allow_other 0 0
Options: Ubuntu 8.04 now defaults to "relatime". For a discussion of this option see : http://lwn.net/Articles/244829/ defaults = rw, suid, dev, exec, auto, nouser, and async. Options for a separate /home : nodev,nosuid,relatime My recommended options for removable (USB) drives are in green. auto= mounted at boot noauto= not mounted at boot user= when mounted the mount point is owned by the user who mounted the partition users= when mounted the mount point is owned by the user who mounted the partition and the group users ro= read only rw= read/write VFAT/NTFS: Ownership and permissios of vfat / ntfs are set at the time of mounting. This is often a source of confusion. uid= Sets owner. Syntax: may use user_name or user ID #. gid= sets group ownership of mount point. Again may use group_name or GID #. umask can be used to set permissions if you wish to change the default. Syntax is "odd" at first. To set a permissions of 777, umask=000 To set permissions of 700, umask=077 Best is to set directories with executable permissions and file with read write. To do this, use fmask and dmask (rather then umask): dmask=027 fmask=137 With these options files are not executable (all colored green in a terminal w/ ls) Linux native file systems: Use defaults or users. To change ownership and permissions, mount the partition, then use chown and chmod. Note: Warning re: sync and flash devices: Warning Additional Options: (From wiki.linuxquestions.org/wiki/Fstab):
Dump Dump: Dump field sets whether the backup utility dump will backup file system. If set to "0" file system ignored, "1" file system is backed up. Fsck order Fsck: Fsck order is to tell fsck what order to check the file systems, if set to "0" file system is ignored. See also: Tuning the Filesystem Check at Bootup Fstab Examples Quote:
How to Label Linux: How the label and the UUID are set depends on the file system type used. It can normally be set when creating/formatting the file system and the file system type usually has some tool to change it later on (e.g. e2tunefs,xfs_admin,reiserfstune,etc.) Labels Mke2fs/e2label/tune2fs: Note: For either ext2 or ext3 file systems. WARNING: mke2fs will reformat your partition and set a label at the same time. This will delete any data on the target partition. To set a label without reformatting use e2label or tune2fs
ReiserFS: Use reiserfstune: Code:
reiserfstune --l <Label> <device> Note:That is a small "L" and not the number 1.JFS: Use jfs_tune: Code:
jfs_tune -L <Label> <device> Code:
jfs_tune -l <device> Note:That is a small "L" and not the number 1.XFS: Use xfs_admin: Code:
sudo xfs_admin -L <Label> <device> Code:
xfs_admin -l <device> Note:That is a small "L" and not the number 1.FAT (Windows partitions): Use mtools to label a FAT partition:
NTFS (Windows partitions): Thanks to rudyj for pointing out the oversight.Use ntfsprogs: First install ntfsprogs: Code:
sudo aptitude install ntfsprogs Then:
============== END OF LABEL =============== Examples of fstab options ********* FAT ********** FAT partitions are easy to share between Linux and Windows as both OS will read FAT "out of the box" without additional installation or configuration. In this example I will use /mnt/data as my mount point. Code:
sudo mkdir /mnt/data Quote:
Quote:
********* Linux Native File Systems ********** In this example I will use ext3, but this holds true for ext2, reiserfs, jfs, and xfs. Code:
sudo mkdir /mnt/ext3 Quote:
============== END OF EXAMPLES =============== References Partitioning: Basic partitioning Mount: How to mount filesystems in Linux Ubuntu Automatically Mount Partitions man mount Mount Other Filesystems Fstab: fstab wiki How to edit and understand /etc/fstab Tuning the Filesystem Check at Bootup Labels: How to use Labels udev: How to udev NTFS: ntfs-3g Zip dirve how-to: How to Zip Drive nfs: How to set up NFS How to NFS v4 Debian/Ubuntu NFS Guide Short but sweeeet ! Mount Windows Sares: Mount Windows shares permanently Samba: Setting up Samba How to mount smbfs shares permanently
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() Last edited by bodhi.zazen; October 22nd, 2009 at 02:32 PM.. Reason: Updated cifs and info on behavior with mount points |
||||||||||||||||||||||||
|
|
October 24th, 2006
|
#2 |
|
Dark Roasted Ubuntu
![]() Join Date: Aug 2005
Location: Canada
Beans: 1,082
|
Re: How to fstab
Thanks for the detailed walkthrough!
I'm sure the UUID info will come in handy once Edgy hits. |
|
|
October 24th, 2006
|
#3 |
|
May the Ubuntu Be With You!
![]() Join Date: Apr 2006
Beans: 1,252
|
Re: How to fstab
Great works man, this is a must
__________________
WARNING : Post with explicit contents
Join to "STOP monolithic all-in-one unmanageable application" The wiki is your friend |
|
|
October 24th, 2006
|
#4 |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Thanks for the comprehensive guide. I'll be pointing people here.
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
October 27th, 2006
|
#5 |
|
Way Too Much Ubuntu
![]() |
Re: How to fstab
swell bodhi.zazen,
Thats grand detailing there, Thank You.
__________________
Love Abhinya (\_./) (O.-) (> <) |
|
|
November 6th, 2006
|
#6 |
|
Chocolate-Covered Ubuntu Beans
![]() Join Date: Oct 2005
Location: Fribourg,Switzerland
Beans: 2,202
|
Re: How to fstab
Great job! Thanks a lot,bodhi.zazen!
__________________
my JAMENDO * The XY sex-determination system is the sex-determination system found in humans and Z was my donor! * Tarot and Poya Sutra | * # 12755 |
|
|
December 2nd, 2006
|
#7 | ||
|
Dark Roasted Ubuntu
![]() Join Date: Nov 2006
Location: There and back again
Beans: 1,043
|
Re: How to fstab
I learned howto mount my hfsplus at startup.
Quote:
Quote:
Last edited by Gen2ly; December 4th, 2006 at 10:27 PM.. |
||
|
|
December 2nd, 2006
|
#8 | |||
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
Try: Code:
ls /dev/disk/by-label -lh If so... try this fstab entry: Quote:
If not... try this fstab entry: Quote:
Gentoo wiki How to hfsplus Gentoo wiki how to IPOD Ubuntu Forums hfsplus If you would be so kind as to post the solution I will update this "how-long" as xpod calls it
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|||
|
|
December 2nd, 2006
|
#9 |
|
Ubuntu addict and loving it
![]() Join Date: Jun 2006
Location: The Netherlands
My beans are hidden!
Ubuntu 9.10 Karmic Koala
|
Re: How to fstab
Well bodhi,you're a busy man.
I definitely bookmark this one,it should come handy some day. Thank you very much for this howto.
__________________
Resistance is futile.....you will be assimilated! Registered Linux User 418427. #Ubuntu User 3226# |
|
|
December 11th, 2006
|
#10 |
|
First Cup of Ubuntu
![]() Join Date: Dec 2006
My beans are hidden!
|
Re: How to fstab
great guide, helped me a lot
there is also options not mentioned in guide but i found them in some examples: nls, iocharset for correct encodeing file names. I don't know anything more about them. Anyway when i tryed to use a cd where filenames had special characters (Polish), but instead of them there were non-alphabetical signs. So i used this entry in fstab and it helped Code:
/dev/hdd /media/cdrom0 udf,iso9660 utf8,user,noauto 0 0 |
|
|

January 8th, 2007
|
#11 | |
|
Way Too Much Ubuntu
![]() Join Date: Nov 2006
Location: Peru, Indiana
Beans: 285
Ubuntu 6.10 Edgy
|
Re: How to fstab
Excellent how-to--it helped me a lot, and I haven't nearly finished studying it.
One question and one observation: Quote:
I could not automount at boot my smbfs shares until I found the this fix in the Forums. I hope it will help someone else. I think the problem was related to the fact that I don't use a username and password in the Windows systems. All I had to do was add Code:
username=share,password= Thanks again for a great article. Buck |
|
|
|
January 8th, 2007
|
#12 |
|
Chocolate Ubuntu Mocha Blend
![]() |
Re: How to fstab
Nice work; very thorough!
|
|
|
January 17th, 2007
|
#13 | ||
|
Just Give Me the Beans!
![]() Join Date: Nov 2006
Beans: 63
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
Hi,
Changing the label for a vfat drive doesn't take the '-s' option. So the line Quote:
Quote:
Last edited by pieroxy; January 17th, 2007 at 05:48 AM.. |
||
|
|
January 21st, 2007
|
#14 |
|
5 Cups of Ubuntu
![]() Join Date: Jun 2006
Location: California
Beans: 16
Ubuntu 7.04 Feisty Fawn
|
Re: How to fstab
deleted
Last edited by aretei; January 22nd, 2007 at 04:20 PM.. Reason: moved to general help section |
|
|
January 28th, 2007
|
#15 |
|
Just Give Me the Beans!
![]() Join Date: Jun 2006
Beans: 58
|
Re: How to fstab
I had problems putting the uuid like you had in your example of fstab
however I did find a way that worked for me. # /dev/sdb /dev/disk/by-uuid/c4e0ea4c-1806-468e-85fa-1730632e4ee5 /mountpoint ext3 defaults 0 1 if I format the uuid line like this instead it works for me. |
|
|
February 8th, 2007
|
#16 |
|
First Cup of Ubuntu
![]() Join Date: Jan 2007
Beans: 7
|
Re: How to fstab
How can I mount a windows share that has a space? eg: //server/stupid share name
Ugly, I know, but changing the share name is not an option |
|
|
February 8th, 2007
|
#17 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
You have to "escape" the spaces with a \
Like this : Quote:
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
February 13th, 2007
|
#18 | |
|
Spilled the Beans
![]() Join Date: Sep 2005
Beans: 13
Xubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
Quote:
I know I should be more responsible and figure out what I'm doing first because I interpreted this section and this code in particular as only making a label on my partition, not as it erasing everything. I lost a few scores of GB, but I think it was all replaceable. After that I found out there is no way at all to undo a mke2fs command. Pointing people to tune2fs -L might be helpful. I found that afterwards. |
|
|
|
February 14th, 2007
|
#19 | ||
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
![]() Quote:
If you do not feel this is obvious enough, please let me know and I will make further modifications.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
||
|
|
February 18th, 2007
|
#20 |
|
Way Too Much Ubuntu
![]() |
Re: How to fstab
hi there! i'm having some troubles with the cds not mounting. this is a previous thread i wrote but since no one answered i asked you too.
i know it's not nice to ask in two places but i really want this problem solved. thank you!
__________________
⠴ open thinker | ★ full-circle magazine ★ | great links ⠦
☯ We are aspiring for harmony in the inner life and in the outer life. ☯ |
|
|

July 7th, 2007
|
#21 |
|
5 Cups of Ubuntu
![]() Join Date: Jul 2007
Location: Halifax, Nova Scotia
Beans: 18
|
Re: How to fstab
I
just discovered that the default fstab line for /cdrom isn't good when
you have a dvd with a file >4GB on it, which requires UDF. It should
be iso9660,udf, not udf,iso9660. mount seems to try filesystems in
reverse order, so putting it last makes it get tried first. edit: mount
only tries the last one. reversing the order makes it fail to mount
normal discs without UDF filesystems. I'll file a bug report.
I'm posting here because it took me a while to figure this out, but I don't know if it should be considered a bug, and if so what package is responsible for the default /etc/fstab anyway. You make such a disk by using the latest version of growisofs/genisoimage (in Gutsy testing, but not Feisty.) The -allow-limited-size option makes an iso9660 filesystem with the file sizes truncated to 32 (or 31) bits, and a UDF filesystem with the proper sizes. http://geekpit.blogspot.com/2007/02/...ups-under.html (This option is supported by the latest k3b, but k3b doesn't work in my gutsy chroot. Anyway, so if you write the image to a file (genisoimage -o), and mount -o loop, Linux will use the UDF filesystem structures because /proc/filesystems lists udf before iso9660. This means the directory listing shows a 4.3GB file, in my case. Burning to a disk and doing mount /cdrom makes Linux use the iso9660 (+Rock Ridge) filesystem, which means my directory listing shows a 300MB file. With sudo mount -t udf ... I can mount the optical disc and see the 4.3GB file. The only problem anywhere with this is that Ubuntu defaults to trying iso9660 first. BTW, it's only a problem if you have a disc with a bogus iso9660 filesystem, like genisoimage creates with -allow-limited-size. Otherwise I don't know of a reason why you'd rather have UDF instead of RR. genisoimage can't currently create images with no iso9660 filesystem, apparently because they don't trust their UDF code enough. BTW, I like to use these options for growisofs to master+burn large files all in one go: growisofs -volid 'disc name' /dev/dvd -speed=6 \ -use-the-force-luke=notray -dvd-compat \ -use-the-force-luke=bufsize:32m \ -allow-limited-size -udf -rational-rock \ -allow-leading-dots -full-iso9660-filenames -relaxed-filenames -allow-lowercase \ -no-iso-translate -allow-multidot -omit-period -iso-level 3 \ -graft-points -f \ foo.vol000....par2 foo foo.vol128...par2 (par2 is forward error correction data to make the data recoverable in case of scratches. Not putting all the recovery files next to each other on disc should give you a better chance of not losing them all. growisofs orders files in the image in the order they appear on the command line.) Usually I use k3b to set up and burn. I even have some perl scripts that I can run on a k3b project file to create par2 files for the set of files that will be on the CD. (I should publish those somewhere... email me if you want them.) Last edited by Peter Cordes; July 7th, 2007 at 09:31 PM.. |
|
|
August 23rd, 2007
|
#22 |
|
A Carafe of Ubuntu
![]() Join Date: Aug 2005
Location: Belgium
Beans: 102
Ubuntu 7.10 Gutsy Gibbon
|
Re: How to fstab
Hi, i found this thread through search. I have a problem with fstab. I like this guide but it's not completely clear.
I have made an entry for my removable usb hard disk, it mounts ok (but I have to do mound manually) is there a way so that it would mount the hard disk as soon as I plug it in (hotplug)? It was like that when installing ubuntu but ntfs-config broke that so I'm trying to remake my fstab. Also, I want to use an external usb stick and put it in fstab but when I do this command to list uuid and label it doesn't show my stick! So I don't know the label/uuid to put it in fstab! WHen I list the 'id' then it shows the usb stick. I can also mount the usb stick fine as root but i want it to automount (hotplug) and be usable as user. Any ideas? |
|
|
August 23rd, 2007
|
#23 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
gnome auto mounts removable devices with gnome-volume-manager (which has always been hard form me to configure). I find that gnome-volume-manager does NOT like it if you have an entry in fstab for flash/usb drivers, so I would remove the fstab entry, unmount the device, remove the device, delete the mount point in /media, and reboot. The re-try the device. I do not user ntfs at all, I use FAT to windows share, so I do not know if it will work or not, but set a label on your ntfs partition and see if that help.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
August 23rd, 2007
|
#24 | ||
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Quote:
I believe that pmount is responsible for automounting. Quote:
Code:
uid=1000,gid=1000,umask=077 I have no issues with my ntfs-3g partition, so if that's the one you're having issues with, I don't know how to help you. ================== By the way, if you still can't manage to get anything that's mentioned in fatab to be automounted, you might be able to hack the pmount source code to force pmount to use the options you want (which, last I checked were hard-coded), then re-compile pmount. This process, however, isn't for the faint of heart.
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
||
|
|
August 25th, 2007
|
#25 |
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
Hello All.
Great info in here and I have read with some interest - I think it may have solved an issue I had with a partition not being accessible by my "almost never used" Vista partition (but then who would want to use it!?). OK so my problems / solutions. I think I had my share partition set to the wrong type untill I read this howto I mistakenly thought vfat and fat32 were "simlar" and readable by Windoze - I have now changed my fstab to set it as NTFS-3g. More alarmingly I am confused about how I set a label?? probably me just being dopey / sleepy / snoozey and waiting for snow white to show up and help out.... - maybe Bodhi is SnowWhite in disguite?? ![]() Anyway onto my main problem. I have an issue with the UUID of my linux swap partition changing on a "Semi regular basis" - this means that each time I boot up I have to check that I have my swap in place - or else my system does a serious go-slow. A serious go slow is tantamount to the old MS blue screen of death, so I use the power switch to turn off then reboot. this seems to bugger up the uuid of my swap partition, oddly enough it has no effect on any of the others!? Personally I am not too bothered with the loss of the swap, it s a nuisance more than anything and it keeps me on my toes what solutions can I use?? if I set a "label" will this work or does it map to the uuid?? Any thoughts would be greatly appreciated and more than welcome. hope to hear from you soon. Dave |
|
|
August 25th, 2007
|
#26 | |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Quote:
I really don't know what could be causing the swap partition to change UUIDs, though. Before I increased the amount of swap I have, I experienced numerous serious slow downs, like you do. Normally with a lot of patience I could eventually log in via SSH and kill off the memory-hogging program. Of course, sometimes there's just nothing you can do but Code:
<Alt><SysRq>E <Alt><SysRq>I <Alt><SysRq>S <Alt><SysRq>U <Alt><SysRq>B
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
|
August 26th, 2007
|
#27 | ||
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
mssever
I had forgotten about the <alt><sysrq>.... trick, In fact I though that there was an even quicker one that that?? couple of silly questions though, which key is the <SysRq>, is it synonomous with the <ctrl> key or is it the <windows> button that is on keyboards these days? query on the line of code I need for my fstab, currently the offending part reads ( I have included the notes that I have commented out in the file as well, in case is helps! Quote:
In fact I will try this and report back in a few minutes. Dave OK I had a play and it doesn't seem to have worked the line in the fstab now reads Quote:
Dave ps. I've rebooted and it all seems to work, oh what joy. Thanks Bodi, Thanks mssever now I just need to try breaking it by using the power button!!! hmmm, maybee later.... Last edited by theDaveTheRave; August 26th, 2007 at 04:07 PM.. Reason: playing with my fstab! and now it works - yipee |
||
|
|
August 26th, 2007
|
#28 | |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Quote:
Code:
/dev/hda6 none swap sw 0 0
__________________
What's a blub programmer? Registered Linux user #419974 My projects: Last edited by mssever; August 26th, 2007 at 07:51 PM.. |
|
|
|
September 30th, 2007
|
#29 |
|
Gee! These Aren't Roasted!
![]() Join Date: Oct 2006
Location: Flanders, Belgium
Beans: 189
|
Re: How to fstab
I
read somewhere that from Edgy upwards, one needs to replace the device
name (e.g. /dev/sda1) with its UUID in the fstab. Under Feisty, this
only applies to scsi or scsi-emulated drives!
When adding two drives (an IDE and an SATA drive) to one of my PC's, I noticed that the IDE drive I added (/dev/hdb1) went unnoticed when mentioned by its UUID in fstab! It took me a long time to find that out, messing around with countless option alternatives before it dawned to me that the UUID just did not work. I'm actually using Linux Mint, which is Feisty plus multimedia support out of the box. |
|
|
September 30th, 2007
|
#30 | |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Quote:
Also, in Feisty, all disks are now sd*. There is no such thing anymore as /dev/hda1. I think that this was actually a kernel change, but I'm not positive about that.
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
|

October 11th, 2007
|
#31 |
|
Way Too Much Ubuntu
![]() |
Re: How to fstab
Hy guys!
This will be easy for you!! My newly formatted drive has 1GB of swap, but it doesn't automount. I just need a line to put in fstab, so it would automount for now on. HTML Code:
Device Boot Start End Blocks Id System /dev/sda1 1 5005 40202631 5 Extended /dev/sda5 1 2943 23639584+ 83 Linux /dev/sda6 2944 5005 16562983+ 83 Linux Disk /dev/sdb: 41.1 GB, 41110142976 bytes 255 heads, 63 sectors/track, 4998 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Device Boot Start End Blocks Id System /dev/sdb1 1 131 1052226 82 Linux swap / Solaris /dev/sdb2 132 4998 39094177+ 83 Linux Thank you! |
|
|
October 11th, 2007
|
#32 | ||
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
Quote:
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() Last edited by bodhi.zazen; October 11th, 2007 at 07:15 PM.. |
||
|
|
November 13th, 2007
|
#33 |
|
First Cup of Ubuntu
![]() Join Date: Nov 2007
Beans: 1
|
Re: How to fstab
I'm
running Ubuntu 7.04 and am fairly new to Linux. I have a spare ext3
partition that I would like r/w access, but have only -ro access at the
moment. Any Ideas?
Fstab: # /dev/sda5 UUID=a01a59b8-052e-4c3b-8832-d689d99dfc68 /media/sda5 ext3 rw,user,sync 0 2 Mount Command: /dev/sda5 on /media/sda5 type ext3 (rw,noexec,nosuid,nodev,sync) Also, I can't edit my fstab using sudo. I have to use a livecd to edit my fstab. |
|
|
November 13th, 2007
|
#34 | ||
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Quote:
Quote:
Code:
-rw-r--r-- 1 root root 1.7K 2007-06-16 19:32 /etc/fstab
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
||
|
|
November 14th, 2007
|
#35 |
|
5 Cups of Ubuntu
![]() Join Date: Jul 2007
Beans: 37
|
Re: How to fstab
I have a problem, deleted a partition but didn't unmounted it before...now every time i boot a get this error (# /dev/hdb2
UUID=24c6deb0-d9cd-42a9-974c-a401c4db74d2 / ext3 defaults,errors=remount-ro 0 1)...and can't get into my graphical interface.. I know i have to comment the line with "noauto" to solve this (at least that's what i guess)...my problem is that i don't know how to comment that line thru the command line (i mean without thru the root@desktop:$)...can anybody help me with it? Thanks! (sorry for my lousy english) |
|
|
November 14th, 2007
|
#36 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
Open a terminal and mount your root partition, if needed. for the rest of this post I will assume you have mounted you ubuntu root partition in /media/ubuntu ... Now, again in a terminal, Code:
sudo nano /media/ubuntu/etc/fstab Control -X to exit nano, type Y to save the changes. Reboot to hard drive.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
November 27th, 2007
|
#37 |
|
First Cup of Ubuntu
![]() Join Date: Nov 2007
Beans: 1
|
Re: How to fstab
bodhi-zazen, thanks a lot for your awesome post! Mounted a VFAT volume with no trouble with the name fixed!
|
|
|
November 30th, 2007
|
#38 |
|
Just Give Me the Beans!
![]() Join Date: Nov 2006
Beans: 67
|
Re: How to fstab
tnx man
|
|
|
December 9th, 2007
|
#39 |
|
5 Cups of Ubuntu
![]() Join Date: Jul 2007
Beans: 43
|
Re: How to fstab
Thanks for the post taught me alot.
However I have a situation. Im using KTorrent and fails to see my other mounted hardrives. Ive been told its probably because my hard drives are owned by root. I used ntfs-3g to set up these hard drives because they are an existing partition in NTFS and Im not about to move 100Gigs of data over into my Ubuntu partition. So anyway Ive read all the links for ntfs-3g and seems all the suggestion for gonfiguration is through the auto config. Grant it they mount but when I bring up the fstab it looks like this. Code:
proc /proc proc defaults 0 0 # Entry for /dev/sdc2 : UUID=8e8cf5f3-cedb-45dc-a98e-d71bf3575e33 / ext3 defaults,errors=remount-ro 0 1 # Entry for /dev/sdc5 : UUID=f91cdd5d-1a8b-47fe-8574-3e1d97714f46 none swap sw 0 0 /dev/hdb /media/cdrom0 udf,iso9660 user,noauto,exec 0 0 /dev/scd0 /media/cdrom1 udf,iso9660 user,noauto,exec 0 0 /dev/fd0 /media/floppy0 auto rw,user,noauto,exec 0 0 /dev/sdd1 /media/Storage ntfs-3g defaults,locale=en_US.UTF-8 0 0 /dev/sdc1 /media/BigBob ntfs-3g defaults,locale=en_US.UTF-8 0 0 I know Im doing something wrong here just cant figure it out. EDIT: Figure that about 5 minutes after writing this I went in and unmounted from root and the remounted in root and everything worked. Last edited by Sicundercover; December 9th, 2007 at 06:32 PM.. |
|
|
March 2nd, 2008
|
#40 |
|
Way Too Much Ubuntu
![]() Join Date: Jun 2007
Location: Essex ,U.K.
Beans: 229
Hardy Heron (Ubuntu Development)
|
Re: How to fstab
Nice one Bodhi , great article 10/10
__________________
Arch 2.6.28 on X86_64 Hardy 2.6.24 on X86_64 AMD Athlon(tm) 64 Processor 3200+ Maxtor 6L160M0 (SATA) 160G ,NVIDIA G6200 |
|
|

April 2nd, 2008
|
#41 |
|
First Cup of Ubuntu
![]() Join Date: Apr 2008
Beans: 1
|
Re: How to fstab
Hi all,
I have ubuntu installed on a 120GB IDE HDD, with 2x 200GB Sata drives spare that i wish to mount. I've gone ahead and created/formatted the partitions as you can see below: Code:
Disk /dev/sdb: 200.0 GB, 200049647616 bytes 255 heads, 63 sectors/track, 24321 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdb1 1 24321 195358401 83 Linux Disk /dev/sdc: 200.0 GB, 200049647616 bytes 255 heads, 63 sectors/track, 24321 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x00000000 Device Boot Start End Blocks Id System /dev/sdc1 1 24321 195358401 83 Linux Code:
mount -t ext3 /dev/sdb1 /mnt/files Code:
mount: wrong fs type, bad option, bad superblock on /dev/sdb1,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
Any suggestions? Please forgive me if I'm a moron, new to linux |
|
|
April 2nd, 2008
|
#42 |
|
Ubuntu Guru
![]() |
Re: How to fstab
I do not see any obvious problem.
If you do not have an entry in fstab, you need to mount with sudo. Make a mount point first. Are your partitions formatted ? Code:
sudo mkdir /mnt/files sudo mount /dev/sdb1 /mnt/files Code:
dmesg | tail
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
April 19th, 2008
|
#43 |
|
5 Cups of Ubuntu
![]() |
Re: How to fstab
Thanks for this post, I'm gonna bookmark it. I'm pretty sure it'll come in handy
__________________
Luke - 14 year old technology enthusiast My Specs: Ubuntu Gutsy ECS GeForce 6100SM-M - AMD Athlon64 X2 Dual Core 5,000+ (2.6GHz) - 2GB DDR2 RAM - 400GB Hitachi DeskStar - 700W X-Power Productivity Zero - My games arcade and currently only project. |
|
|
April 25th, 2008
|
#44 |
|
Gee! These Aren't Roasted!
![]() Join Date: Aug 2007
Location: London, England
Beans: 163
Ubuntu 7.10 Gutsy Gibbon
|
Re: How to fstab
I
want to change the default label for my mounts as they are being
displayed as 10.7gb media, and I would like more meaningful names.
Tried using tune2fs and e2label but I get a "Couldn't find valid
filesystem superblock" error.
Seeing as they are already mounted, could I just edit fstab and add some labels? EDIT: Okay got the ext3 partition sorted, now ntfslabel can't access my windows partition as it 's already mounted. I sudo nautilus unmounted it, but then ntfslabel is denied access to it. Anyway to change an unmounted NTFS partition's label? EDIT 2: No matter, managed to unmount it from terminal, and then used PYSDM to create a label for it. Job done.
__________________
We are building the future, and the future is called Ubuntu
Last edited by A$h X; April 25th, 2008 at 10:11 AM.. |
|
|
April 28th, 2008
|
#45 |
|
5 Cups of Ubuntu
![]() Join Date: Feb 2008
Location: Portugal
Beans: 44
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
Could you tell me how you did it?
Because I have similar problems: http://ubuntuforums.org/showthread.php?t=771496 |
|
|
April 28th, 2008
|
#46 | ||
|
Gee! These Aren't Roasted!
![]() Join Date: Aug 2007
Location: London, England
Beans: 163
Ubuntu 7.10 Gutsy Gibbon
|
Re: How to fstab
Pretty sure it was simply:
Quote:
If it's still giving you problems after entering the command and rebooting, then try installing PYSDM, a nice little app which allows you to to mount and label drives/partitions. It basically edits fstab on your behalf, and it seems to work for me. Get it from synaptic, or type: Quote:
__________________
We are building the future, and the future is called Ubuntu
|
||
|
|
April 28th, 2008
|
#47 |
|
5 Cups of Ubuntu
![]() Join Date: Feb 2008
Location: Portugal
Beans: 44
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
Thanks A$h X, but I guess my problem is different.
I just wanted my ext3 partition mounted as a unremovable drive (without the desktop icon). |
|
|
April 28th, 2008
|
#48 | |
|
Gee! These Aren't Roasted!
![]() Join Date: Oct 2005
Location: Nice, France
Beans: 160
Ubuntu 8.04 Hardy Heron
|
Re: How to fstab
Hi, this post is great, thanks a lot!
I'm a bit stuck on one thing though. I have a FAT32 partition I've managed to get automounting, however it's not letting me write data to it because the owner is root. This is the fstab entry for it: Quote:
Thanks a bunch
__________________
Google is my friend. Saves my butt every time (well most times). |
|
|
|
April 28th, 2008
|
#49 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
Code:
#/dev/sda2 UUID=4812-2CE3 /media/SHARED vfat auto,users,uid=1000,gid=100,dmask=007,fmask=137 0 0
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() Last edited by bodhi.zazen; April 28th, 2008 at 10:42 AM.. |
|
|
|
April 28th, 2008
|
#50 |
|
Gee! These Aren't Roasted!
![]() Join Date: Oct 2005
Location: Nice, France
Beans: 160
Ubuntu 8.04 Hardy Heron
|
Re: How to fstab
@bodhi.zazen - thanks a lot! That seems to have fixed it (after I rebooted).
__________________
Google is my friend. Saves my butt every time (well most times). |
|
|

April 28th, 2008
|
#51 | |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Quote:
If not, then you'll probably have to look into configuring Nautilus (which is the program that displays desktop icons). If you don't find anything through the normal methods, don't forget about gconf-editor. I don't know whether such configuration is possible.
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
|
April 28th, 2008
|
#52 |
|
Gee! These Aren't Roasted!
![]() Join Date: Oct 2005
Location: Nice, France
Beans: 160
Ubuntu 8.04 Hardy Heron
|
Re: How to fstab
Actually, is it possible to give full permissions to all? (Owner,
group, others.) I want to use a folder on this partition as the Apache
DocumentRoot, but I can't yet because permission is denied (it's just a
development environment not a live one).
__________________
Google is my friend. Saves my butt every time (well most times). |
|
|
April 28th, 2008
|
#53 |
|
Ubuntu Guru
![]() |
Re: How to fstab
yes
Code:
UUID=4812-2CE3 /media/SHARED vfat auto,users,uid=1000,gid=100,umask=000 0 0
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
April 29th, 2008
|
#54 | |
|
5 Cups of Ubuntu
![]() Join Date: Feb 2008
Location: Portugal
Beans: 44
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
Quote:
Thanks, anyway. |
|
|
|
April 29th, 2008
|
#55 |
|
First Cup of Ubuntu
![]() Join Date: Apr 2008
Beans: 2
|
Re: How to fstab
if
you use the user option in /etc/fstab and want to override noexec,
nosuid or nodev, you have to place the options in the right order:
exec,user does not work, it must be user,exec |
|
|
April 30th, 2008
|
#56 |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
I never knew that. Any idea why that is?
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
April 30th, 2008
|
#57 |
|
5 Cups of Ubuntu
![]() Join Date: Jul 2006
Beans: 43
|
Re: How to fstab
Hey folks, I'm having a problem mounting a freshly partitioned ext3 partition on a fresh 8.04 install.
Here is my fstab: Code:
# /etc/fstab: static file system information. # # <file system> <mount point> <type> <options> <dump> <pass> proc /proc proc defaults 0 0 # /dev/sda1 UUID=a30a6512-da7c-42e9-be90-5939d61d90f4 / ext3 relatime,errors=remount-ro 0 1 # /dev/sdb1 UUID=4522-FC6F /media/sdb1 vfat utf8,umask=007,gid=46 0 1 # /dev/sdc5 UUID=BDB4-6E5F /media/sdc5 vfat utf8,umask=007,gid=46 0 1 # /dev/sdc6 UUID=829ff193-0787-4b80-abed-8b479d638eee /media/sdc6 ext3 defaults 0 2 # /dev/sda5 UUID=cd49cb69-19df-4690-bd9a-5e733a71efb4 none swap sw 0 0 /dev/scd0 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0 /dev/fd0 /media/floppy0 auto rw,user,noauto,exec,utf8 0 0 Thanks |
|
|
April 30th, 2008
|
#58 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
Code:
sudo chown user.users /media/sdc6 sudo chmod 770 /media/sdc6 http://www.zzee.com/solutions/linux-permissions.shtml
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
May 2nd, 2008
|
#59 | |
|
A Carafe of Ubuntu
![]() Join Date: Dec 2007
My beans are hidden!
|
Re: How to fstab
Quote:
Hi Just curious, has anyting changed when it comes to mount points? Because as fare as I can tell ubuntu 8.04 mounts all and anything to /media? |
|
|
|
May 3rd, 2008
|
#60 |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Ubuntu tends to put everything in /media (and has done so at
least since Dapper--6.06--when I started using it). I don't know the
official reason for putting non-removable media in /media instead of
/mnt, but I'd guess that it's more consistent to keep everything in one
place. Plus, /mnt is kept free for manually mounting stuff when you
want to do so. Of course, there's absolutely no reason why you can't
change fstab to mount stuff wherever you want. The only requirement for
a mount point is that it must exist and be an empty directory.
Technically, it doesn't even have to be empty, but whatever's in the
directory would be inaccessible while the partition was mounted there.
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|

May 10th, 2008
|
#61 |
|
Just Give Me the Beans!
![]() Join Date: Sep 2007
Location: Missouri, USA
Beans: 65
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
Hi guys. Found a typo in your options list.
The correct line should read: Code:
|
|
|
May 19th, 2008
|
#62 |
|
Just Give Me the Beans!
![]() Join Date: Jul 2006
Location: France
Beans: 74
Ubuntu 8.04 Hardy Heron
|
Hello,
I use ubuntu 8.04, and I have two nfts partition witch are detected and functionnal with read/write support, but they are not mounted at boot. I suppose that they use ntfs-3g to have write support. To acces those partitions, I have to clic on the partition's name in the menu "Shortcut" near "System" menu. Then, the partition is mounted, and can be accessed through the desktop or the file navigator. I want to mount automaticaly at boot one of these partition. She mounted in /media/STOCKAGE Here the fstab : Code:
# /etc/fstab: static file system information. # # <file system> <mount point> <type> <options> <dump> <pass> proc /proc proc defaults 0 0 # /dev/sda6 UUID=6523d9ef-e07a-48bf-86cb-a8328e2fcaa5 / ext3 relatime,errors=remount-ro 0 1 # /dev/sda8 UUID=f59fedf2-decb-4622-be68-2e73e88a0f64 /home ext3 relatime 0 2 # /dev/sda7 UUID=dc8a3772-1364-46b6-b19b-121bab521a27 none swap sw 0 0 /dev/scd0 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0 ## usbfs is the USB group in fstab file: none /proc/bus/usb usbfs devgid=125,devmode=664 0 0 Code:
/dev/sda6 / ext3 rw,relatime,errors=remount-ro 0 0 proc /proc proc rw,noexec,nosuid,nodev 0 0 /sys /sys sysfs rw,noexec,nosuid,nodev 0 0 varrun /var/run tmpfs rw,noexec,nosuid,nodev,mode=0755 0 0 varlock /var/lock tmpfs rw,noexec,nosuid,nodev,mode=1777 0 0 procbususb /proc/bus/usb usbfs rw 0 0 udev /dev tmpfs rw,mode=0755 0 0 devshm /dev/shm tmpfs rw 0 0 devpts /dev/pts devpts rw,gid=5,mode=620 0 0 lrm /lib/modules/2.6.24-16-generic/volatile tmpfs rw 0 0 /dev/sda8 /home ext3 rw,relatime 0 0 none /proc/bus/usb usbfs rw,devgid=125,devmode=664 0 0 securityfs /sys/kernel/security securityfs rw 0 0 binfmt_misc /proc/sys/fs/binfmt_misc binfmt_misc rw,noexec,nosuid,nodev 0 0 gvfs-fuse-daemon /home/pierrick/.gvfs fuse.gvfs-fuse-daemon rw,nosuid,nodev,user=pierrick 0 0 /dev/sda5 /media/STOCKAGE fuseblk rw,nosuid,nodev,noatime,allow_other,blksize=4096 0 0 /dev/sda1 /media/SYSTEME-HP fuseblk rw,nosuid,nodev,noatime,allow_other,blksize=4096 0 0 gvfs-fuse-daemon /root/.gvfs fuse.gvfs-fuse-daemon rw,nosuid,nodev 0 0 Can someone help me ? Thanks Miles
__________________
Nous avons trop tendance à devenir pareils aux pires de nos ennemis. Coda Bene Gesserit |
|
|
May 19th, 2008
|
#63 | |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Quote:
Code:
/dev/sda5 /media/STOCKAGE ntfs-3g defaults,locale=en_US.UTF-8 0 1
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
|
May 30th, 2008
|
#64 |
|
5 Cups of Ubuntu
![]() Join Date: May 2008
Beans: 32
|
Re: How to fstab
Thanks OP, finding disk ID's was exactly what I needed
|
|
|
May 31st, 2008
|
#65 |
|
First Cup of Ubuntu
![]() Join Date: May 2008
Beans: 12
Kubuntu 8.04 Hardy Heron
|
Re: How to fstab
Hi there!
exactly what is the effect of turning the pass column in vfat partitions from 1 to 0 ? the last time I did it boot time improved but windows keeps running the check utility as if the machine was improperly shut down |
|
|
August 23rd, 2008
|
#66 |
|
Spilled the Beans
![]() Join Date: Jul 2008
Beans: 13
|
Congratulations,
It's a very thorough tutorial. Very useful. Thanks in advance. |
|
|
August 29th, 2008
|
#67 |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
I've
read through this post a few times aznd still can't figure out why my
usb drive doesn't show in xubuntu 7.10. It reads it:
Code:
lsusb Bus 001 Device 002: ID 067b:2506 Prolific Technology, Inc. Bus 001 Device 001: ID 0000:0000 Code:
sudo fdisk -l [sudo] password for flor: Disk /dev/hda: 20.0 GB, 20003880960 bytes 255 heads, 63 sectors/track, 2432 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0xe21ae21a Device Boot Start End Blocks Id System /dev/hda1 * 1 2037 16362171 7 HPFS/NTFS /dev/hda2 2038 2407 2972025 83 Linux /dev/hda3 2408 2432 200812+ 5 Extended /dev/hda5 2408 2432 200781 82 Linux swap / Solaris Disk /dev/sda: 320.0 GB, 320072933376 bytes 255 heads, 63 sectors/track, 38913 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x00000000 Disk /dev/sda doesn't contain a valid partition table |
|
|
August 29th, 2008
|
#68 |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
It appears that your drive is corrupt. Does it work on another system?
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
August 29th, 2008
|
#69 |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
I'll check on another computer.
|
|
|
August 29th, 2008
|
#70 |
|
Ubuntu Guru
![]() |
Re: How to fstab
you can write a partition table with fdisk
sudo fdisk /dev/sda just go ahead an manually add in the partitions, just use your post for start and end of partitions. Alternately try testdisk.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|

August 29th, 2008
|
#71 |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
okay but not sure what you mean about manually creating the partitions ... any guidance on that?
|
|
|
August 29th, 2008
|
#72 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
http://tldp.org/HOWTO/Partition/fdisk_partitioning.html
hit n for new partition. Use the numbers from the output you posted earlier : Quote:
add in all your partitions ... When you are done, use w to write your partition table and exit. Then re-boot (you should, IMO, reboot after writing your partition table). If you make a mistake, do not worry about it, fdisk DOES NOT change (write or erase) data to the partitions. Just re-run fdisk and fix your mistake.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
August 29th, 2008
|
#73 |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
sorry
for being such a dolt but that device is my existing 20 g hard drive -
should I use the same numbers for the usb drive which is labelled as
/sda?
a bit confused on that point basically I just want the usb drive to dump images, videos and files for back up Last edited by Daverobb; August 29th, 2008 at 08:03 PM.. |
|
|
August 29th, 2008
|
#74 |
|
Ubuntu Guru
![]() |
Re: How to fstab
Oh, I mis read sda for hda, lol
If you had one large partition, make one large partition with fdisk. If you have more then one partition, try testdisk http://www.cgsecurity.org/wiki/TestDisk_Step_By_Step
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
August 29th, 2008
|
#75 |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
okay -- here's where I'm at:
I used fdisk and created on big linux partition which was super easy -- after that though it still wasn't showing as a drive. It's actually my girlfriend's drive and I'm trying to help her out with an old laptop so I brought it back to my desktop - it seems to recognize the new partition now but doesn't show up as a drive yet- I'm thinking that now I have to mount it and have gone through the post but still am having problems. on this computer it shows up as /dev/sdd1 |
|
|
August 29th, 2008
|
#76 | |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Quote:
Code:
sudo mount -t ntfs /dev/sdd1 /mnt
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
|
August 30th, 2008
|
#77 |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
How about if it's a FAT drive?
This is the output: Code:
sudo mount -t ntfs /dev/sdd1 /mnt [sudo] password for dave: NTFS signature is missing. Failed to mount '/dev/sdd1': Invalid argument The device '/dev/sdd1' doesn't have a valid NTFS. Maybe you selected the wrong device? Or the whole disk instead of a partition (e.g. /dev/hda, not /dev/hda1)? Or the other way around? Last edited by Daverobb; August 30th, 2008 at 12:10 AM.. |
|
|
August 30th, 2008
|
#78 |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Code:
sudo mount -t vfat /dev/sdd1 /mnt
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
August 30th, 2008
|
#79 |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
This is what results:
Code:
$ sudo mount -t vfat /dev/sdd1 /mnt
[sudo] password for dave:
mount: wrong fs type, bad option, bad superblock on /dev/sdd1,
missing codepage or helper program, or other error
In some cases useful info is found in syslog - try
dmesg | tail or so
|
|
|
August 30th, 2008
|
#80 | |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Quote:
If it's some other type, replace the argument to the -t option with the proper one for your filesystem. See man mount for a (partial) list.
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
|

August 30th, 2008
|
#81 |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
I
assumed it was a FAT32 drive because I have another identical drive
that shows up on my ubuntu as such. Is there a command that I can use
to check the file system used?
|
|
|
August 30th, 2008
|
#82 |
|
Ubuntu Guru
![]() |
Re: How to fstab
Most likely it is a fat (vfat) partition.
go into fdisk again, delete the Linux partition, make a new fat partition. then re-try. If that fails, go into fdisk and again delete the partition. Then use testdisk. testdisk is easy to use as well and is in the Ubuntu repositories.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
August 30th, 2008
|
#83 |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
I
tried both but could not do as you suggested -- maybe I wasn't doing it
correctly - here are the options in fdisk - deleteing the partition
iseems easy enough but how do I create a FAT partition?
Code:
sudo fdisk /dev/sdc1 The number of cylinders for this disk is set to 38912. There is nothing wrong with that, but this is larger than 1024, and could in certain setups cause problems with: 1) software that runs at boot time (e.g., old versions of LILO) 2) booting and partitioning software from other OSs (e.g., DOS FDISK, OS/2 FDISK) Command (m for help): m Command action a toggle a bootable flag b edit bsd disklabel c toggle the dos compatibility flag d delete a partition l list known partition types m print this menu n add a new partition o create a new empty DOS partition table p print the partition table q quit without saving changes s create a new empty Sun disklabel t change a partition's system id u change display/entry units v verify the partition table w write table to disk and exit x extra functionality (experts only) Command (m for help): |
|
|
August 30th, 2008
|
#84 |
|
Ubuntu Guru
![]() |
Re: How to fstab
At
the fdisk prompt, use l (that is a small "L") to list the types of
partitions. Partition types are identified by numbers (I do not recall
the number for FAT).
then use the t to change the type of partition. 82 = linux, change it to fat.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
September 3rd, 2008
|
#85 |
|
5 Cups of Ubuntu
![]() Join Date: May 2008
Location: Thessaloniki, Greece
Beans: 37
Ubuntu 8.04 Hardy Heron
|
Re: How to fstab
thank you guys, really helpful thread... now my ntfs data partition is mounted automatically
__________________
And I only get my rocks off while I'm dreaming, I only get my rocks off while I'm sleeping. |
|
|
September 6th, 2008
|
#86 |
|
5 Cups of Ubuntu
![]() Join Date: Mar 2005
Beans: 23
Xubuntu 7.10 Gutsy Gibbon
|
Re: How to fstab
Hi,
Have been trying to get a ext3 partition to mount (using Thunar, in Xubuntu 8.04), using your guide. Keep getting "permission denied". Here is my saga: From your guide (page 1) on mounting native linux file systems: fstab options: users,noauto mount /mnt/ext3 mounts the partition. Permissions: Quote: bodhi@Arch:~$mount /mnt/ext3/ bodhi@Arch:~$ls -l /mnt | grep ext3 drwxr-xr-x 3 bodhi users 1024 2006-11-07 17:26 ext3 Note: The user can mount the device and has rw permissions. Note: Ownership remains bodhi:users My settings, in /etc/fstab: # Entry for /dev/sda5 : /dev/sda5 /media/ubuntu8 ext3 users,noauto 0 0 Following a post of yours elsewhere: http://ubuntuforums.org/archive/index.php/t-482796.html June 26, 2007 I entered the following command (first one is just to show the partition was not mounted): geoff@geoff-eeepc:~$ umount /media/ubuntu8 umount: /media/ubuntu8 is not mounted (according to mtab) geoff@geoff-eeepc:~$ ls -l /media | grep ubuntu8 drwxr----- 2 root root 4096 2008-09-05 21:32 ubuntu8 geoff@geoff-eeepc:~$ mount /media/ubuntu8 geoff@geoff-eeepc:~$ ls -l /media | grep ubuntu8 drwxr-xr-x 21 root root 4096 2008-09-06 10:00 ubuntu8 So, the mount point still has 'root' ownership, not what should have happened, according to the mentioned post. Appreciate your comments, thanks. |
|
|
September 6th, 2008
|
#87 |
|
Ubuntu Guru
![]() |
Re: How to fstab
with the partition mounted, just do a chown :
sudo chown goeff.goeff /media/ubuntu8
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
September 7th, 2008
|
#88 |
|
5 Cups of Ubuntu
![]() Join Date: Mar 2005
Beans: 23
Xubuntu 7.10 Gutsy Gibbon
|
Re: How to fstab
Hi,
Thanks for your quick reply. This other partition is my ubuntu 8.04 installation. If I "chown" the whole partition, will this change the permissions for when I boot to this partition - which I am guessing would not be a good thing? Thanks, Geoff |
|
|
September 7th, 2008
|
#89 |
|
Ubuntu Guru
![]() |
Re: How to fstab
Ah, yes, do not chown the entire partition.
What are the permissions of the rest of the directories (such as the user directories in /home) ? Depending on what you are wanting, for simple access to files use sudo or gksu (gksu nautilus) If you want a shared data partition, make a shared directory in ubuntu at say /mnt/data then set ownershiip and permission on /mnt/data then mount the ubuntu partition and use mount --bind mount --bind /media/ubuntu8/mnt/data /mnt/data
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
September 7th, 2008
|
#90 |
|
5 Cups of Ubuntu
![]() Join Date: Mar 2005
Beans: 23
Xubuntu 7.10 Gutsy Gibbon
|
Re: How to fstab
Hi,
Once again, thanks for the quick reply! Perhaps I should clarify the problem: - am currently using ubuntu 8, the nautilus file browser will mount partitions that do not appear in /etc/fstab, in such a way that files can be edited on such partitions. - I wanted to try using xubuntu (as I have an eeepc and disk space is an issue), the included thunar file browser would not mount the partitions, whether they were in /etc/fstab or not - even with 'users' in the fstab entry. - so, for xubuntu, I set up the /etc/fstab as follows: /dev/sda2 /media/sda2 ntfs-3g defaults,locale=en_AU.UTF-8 0 0 /dev/sda1 /media/sda1 ntfs-3g defaults,locale=en_AU.UTF-8 0 0 /dev/sda5 /media/ubuntu8 ext3 defaults, 0 0 now the partitions are auto-mounted at boot and thunar can access them, with editing possible on these partitions. So, I guess the problem is the way that nautilus mounts the partitions is not available either in xubuntu and/or by thunar. Anyway, problem solved - though not how I would have liked. Thanks very much for your assistance, Geoff. |
|
|

September 12th, 2008
|
#91 | |
|
5 Cups of Ubuntu
![]() Join Date: Aug 2007
Beans: 25
|
How to gain full permission on 2nd drive?
Fantastic
guide, by the way. Some of it is far above my tiny dinosaur brain, but
learning and experimenting is fun. Here's my deal.
(1) New HD (2nd drive used as a backup device); (2) Got it mounted (I think); it shows up in Nautilus; however, (3a) If I do a sudo mount -a command, it returns, "mount point /media/bak/ does not exist"; also, (3b) I do not have permission to create folders, copy files to it, etc. Here's my current fstab file, which is ugly, I know: Quote:
|
|
|
|
September 12th, 2008
|
#92 |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to gain full permission on 2nd drive?
Mount points have to exist. So create /media/bak. If Nautilus
show it, you shoud type "mount" to see where it's mounted. But Nautilus
sometimes uses GVFS to mount stuff, and GVFS has its own ways of
handling things. Creating your mount point will probably cure
everything, though.
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
September 12th, 2008
|
#93 | |
|
5 Cups of Ubuntu
![]() Join Date: Aug 2007
Beans: 25
|
Re: How to fstab
Thanks mssever. Not sure how to get to 'that' 2nd drive in the terminal. Here's what I typed:
Quote:
|
|
|
|
September 12th, 2008
|
#94 |
|
Ubuntu Guru
![]() |
Re: How to fstab
You need to make the mount point :
Code:
sudo mkdir /media/bak sudo mount /dev/sdb1 /media/bak
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
September 12th, 2008
|
#95 |
|
5 Cups of Ubuntu
![]() Join Date: Aug 2007
Beans: 25
|
Re: How to fstab
Thanks
for the follow-up, bodhi. That didn't work either. I still get a
"permission denied" whenever I try to copy or move anything to it.
Perhaps my problem is that I formatted this as a primary drive rather than extended? I intended it to be a discrete drive. And when I'm at the command line, I don't know how to navigate to this 2nd drive labeled 1000.2 GB Media. Last edited by zaine_ridling; September 12th, 2008 at 07:37 PM.. |
|
|
September 12th, 2008
|
#96 |
|
Ubuntu Guru
![]() |
Re: How to fstab
no, you are making progress. The drive mounted and now you simply have a permissions problem.
It appears as if the file system is ext3, so ... Code:
chown user.user /media/bak
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
September 12th, 2008
|
#97 |
|
5 Cups of Ubuntu
![]() Join Date: Aug 2007
Beans: 25
|
Re: How to fstab
That worked! I'm grateful, bodhi!
![]() |
|
|
September 13th, 2008
|
#98 |
|
5 Cups of Ubuntu
![]() Join Date: Jun 2008
Location: Doha
Beans: 40
|
Re: How to fstab
Thanks, Mr.Bodhi. This article helped me to understand the way the linux looks at the file system.
|
|
|
September 13th, 2008
|
#99 |
|
Spilled the Beans
![]() |
Re: How to fstab
Good guide.. Thanks
|
|
|
September 14th, 2008
|
#100 |
|
5 Cups of Ubuntu
![]() Join Date: Jun 2006
Beans: 28
|
Re: How to fstab
|
|
|

October 15th, 2008
|
#101 |
|
A Carafe of Ubuntu
![]() Join Date: Sep 2008
Location: North Carolina
Beans: 153
Xubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
Nice write-up! Clears up a few things for me.
Hope you don't mind me pointing out a couple of typos in the document while I'm here: For the ntfslabel command, the syntax is actually ntfslabel <device> <label>. In the section on ntfsprogs, the command to install it has ntfsprogs spelled ntfsporgs |
|
|
October 15th, 2008
|
#102 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
October 16th, 2008
|
#103 |
|
I Want My $2!!
![]() Join Date: Mar 2007
Location: Denver, CO
Beans: 7,070
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
I wanted to thank you on the original post however there wasnt a link to do so. Thanks for the great tutorial.
|
|
|
October 21st, 2008
|
#104 |
|
First Cup of Ubuntu
![]() Join Date: Apr 2008
Beans: 4
Kubuntu 8.04 Hardy Heron
|
mount ntfs-3g using labels?
Thanks
for the really helpful thread. I'm trying to mount NTFS partitions with
ntfs-3g in fstab using labels instead of /dev/sdx, due to device IDs
changing with USB keys.
LABEL=SEA_DISC /mnt/seagate ntfs-3g rw,umask=0000,defaults 0 0 This does not work, though it works fine using the standard device path. The man pages for ntfs-3g don't mention alternative device IDs. I've searched all over but only find examples of people using /dev/sdx. Am I missing something here? [root@localhost by-uuid]# mount -L SEA_DISC /mnt/seagate ntfs-3g rw,umask=0000,defaults 0 0 mount: no such partition found [root@localhost by-uuid]# ls /dev/disk/by-label -l total 0 lrwxrwxrwx 1 root root 10 Oct 21 12:45 SEA_DISC -> ../../sde1 |
|
|
October 21st, 2008
|
#105 |
|
Extra Roomy Joe
![]() Join Date: Mar 2008
Beans: 4,711
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
According to the fstab man page:
Code:
Instead of giving the device explicitly, one may indicate the (ext2 or xfs)
filesystem that is to be mounted by its UUID or volume label (cf. e2label(8) or
xfs_admin(8)), writing LABEL=<label> or UUID=<uuid>, e.g., ‘LABEL=Boot’ or
‘UUID=3e6be9de-8139-11d1-9106-a43f08d823a6’.
|
|
|
October 21st, 2008
|
#106 | |
|
Ubuntu Guru
![]() |
Re: mount ntfs-3g using labels?
Quote:
Code:
mount -L SEA_DISC /mnt/seagate -t ntfs-3g -o umask=000
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() Last edited by bodhi.zazen; October 21st, 2008 at 08:16 PM.. |
|
|
|
October 23rd, 2008
|
#107 |
|
First Cup of Ubuntu
![]() Join Date: Apr 2008
Beans: 4
Kubuntu 8.04 Hardy Heron
|
Re: mount ntfs-3g using labels?
@unutbu: this is apparently unsupported
@bodhi: thanks for the clarification; I had hastily cut and pasted to post. Since you bring it up: does the 'rw' replace specifying the uid and gid values? or does omitting rw and specifying umask simply assume full rw to start? In any case, after searching high and low and finding nothing I came upon this genious, simple solution over at http://forum.ntfs-3g.org/viewtopic.p...highlight=uuid I just ntfs-3g mount by label/uuid in the following way: ntfs-3g /dev/by-label/My_Label /mnt/ntfs_disk replace "by-label" with "by-uuid" to use that instead. Regards, Mike |
|
|
October 23rd, 2008
|
#108 |
|
Extra Roomy Joe
![]() Join Date: Mar 2008
Beans: 4,711
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
keenmonkey, that's really cool! Thanks for the tip.
Edit: I found http://forum.ntfs-3g.org/viewtopic.p...highlight=uuid a little confusing, so please correct me if I have this wrong: To mount an NTFS partition by label, you can do this: Code:
sudo apt-get install ntfsprogs sudo ntfslabel /dev/sdb1 My_Label sudo mkdir /media/My_Label Code:
/dev/disk/by-label/My_Label /media/My_Label ntfs defaults,uid=1000,gid=1000,dmask=027,fmask=137 0 2 This time, udev (or HAL?) will detect the Label of the NTFS partition and add an entry to /dev/disk/by-label. You can now mount the NTFS partition with Code:
sudo mount /media/My_Label Last edited by unutbu; October 23rd, 2008 at 04:09 PM.. |
|
|
November 14th, 2008
|
#109 |
|
Quad Shot of Ubuntu
![]() Join Date: Dec 2005
Location: Lansing, MI
Beans: 377
Ubuntu 7.10 Gutsy Gibbon
|
Re: How to fstab
If mtab has all currently mounted partitions, can I:
auto-mount a partition copy the corresponding record from mtab to fstab so that the partition will auto-mount at boot from now on?
__________________
Registered Linux user number 416065 | Never run a command with "rm" in it unless you understand exactly what it will do. Knowledge exists to be imparted. Ralph Waldo Emerson |
|
|
November 14th, 2008
|
#110 |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
That'll probably work. However, if you're dealing with a
removable device, you'll need to find another way to identify it. mtab
lists the actual device name, and sometimes those can change. With the
device mounted, look in /dev/disk/by-* for ideas.
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|

November 14th, 2008
|
#111 |
|
Quad Shot of Ubuntu
![]() Join Date: Dec 2005
Location: Lansing, MI
Beans: 377
Ubuntu 7.10 Gutsy Gibbon
|
Re: How to fstab
thanks
for the confirmation mssever. It's an internal drive, so I think we're
in the clear. If I get ambitious I'll figure out the UUID and change it.
__________________
Registered Linux user number 416065 | Never run a command with "rm" in it unless you understand exactly what it will do. Knowledge exists to be imparted. Ralph Waldo Emerson |
|
|
November 14th, 2008
|
#112 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
1. The last column in mtab is always "0". You may want this to be a "2". 2. You may need to add "auto" to the options if you wish to auto mount .
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
November 16th, 2008
|
#113 |
|
Just Give Me the Beans!
![]() Join Date: Jan 2008
Beans: 47
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
Thanks for the post really really great,
I have a silly question I hope you can help me with. I have added a line on fstab so to mount on boot an ext3 partition with my personal data. It all works fine, but I would like not to have the "15.7 GB Media" icon on the desktop, a bit like /home, I have it on a separate partition but I don't have the icon...I have seen someone else having a similar problem but I didn't understand what the solution is. Is it something I have to change with the settings on fstab, or is there anything you can suggest I should do with gconf? Thanks in advance M |
|
|
November 16th, 2008
|
#114 |
|
Ubuntu Guru
![]() |
Re: How to fstab
Personally I mount my partitions in /mnt
This keeps them off the desktop, regardless of window manager. If you want them in your home, use a link ln -s /mnt/dharma /home/user/dharma
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
November 17th, 2008
|
#115 |
|
Just Give Me the Beans!
![]() Join Date: Jan 2008
Beans: 47
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
BRILLIANT
it worked perfectly, no more icon on the desktop, tonight i will study a bit how the links work and create one. Thanks m |
|
|
November 25th, 2008
|
#116 |
|
5 Cups of Ubuntu
![]() Join Date: Sep 2008
Beans: 18
|
Re: How to fstab
Hello, perhaps somebody here can help me.
My computer has a fat32 partition, I was worried about editing the fstab file directly so I used Pysdm and that seemed to cause more problems. Now I keep editing Fstab basically every day and the changes keep reverting!, this is what Fstab says: /dev/sda5 /media/sda5 vfat user,auto,rw 0 0 This is what "mount" says: /dev/sda5 on /media/sda5 type vfat (rw,noexec,nosuid,nodev) What am I doing wrong?, I want that partition to be fully useable by anyone and I can only edit or save files as root which does work randomly after editing Fstab and rebooting several times each day. |
|
|
November 25th, 2008
|
#117 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
Or if you do not wish every file to be marked as executable, use dmask and fmask
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
November 25th, 2008
|
#118 |
|
5 Cups of Ubuntu
![]() Join Date: Sep 2008
Beans: 18
|
Re: How to fstab
Thank you very much, that did exactly what I wanted (sorry I
didn't get it directly from the how-to), and eventually I'll change it
to the non-executable version.
Last edited by Toci; November 25th, 2008 at 12:52 PM.. |
|
|
November 25th, 2008
|
#119 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
December 4th, 2008
|
#120 | |||
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
bodhi
Remember me, I still have the Acer 3680, now running hardy (intrepid was too painful!) Anwyay. I've got a new job, and I've been asked to set up the new team server. so on went Hardy 64 bit server edition. Samba shares and user logons are all sorted. Just one last little project, that should be in your sphere as it involves mounting some extra disks in a certain place. We have a number of 1 TB disks in the server (for backups and data) ~ once upon a time it was going to be a raid device but that went out the window when we realised that for the data we were generating we needed more disk space My Set up so far. I have a "guest" user logon that is shared over the local network to the rest of the team for holding their data (samba shares all working fine) So what the team (or rather my boss) would like is the following. We have 4 internal 1TB disks (soon to become 8 or more!, and others on the network). We want to have these 4 disks (and then the other at a later date) that are installed in the machine to appear as though they live as subsections of the "guest" area - I would like make it appear as if they were in fact sub folders. I want to mount them directly into the samba share here is some information from the system Quote:
Currently the fstab file had no details of these disks, but they mount automatically and appear in the mtab file with the following details Quote:
So I unmount them then add the following lines into the fstab Quote:
I've also re-booted the system but it makes no different. I assume that there is another file that the system is looking at for the mount points of the disks, but I'm not sure where it lives, or what it is. Unless of course this is working fine but I just don't see it doing so, when I sit in front of the pc I see 4 disks on the desktop. when I check the /home/guest/TB1 (or the others) folders the size of the folder is reported as being only 60GB in size (which would fit with the size of the /home.. partition. If this doesn't work I guess I can simply add "links" to the files and then share the disks also, but that doesn't feel like an elegant solution, or is what I am trying to do not possible?? I've just checked something, when I check the disk properties the dialog says that the disk location is "on the desktop", and confirms the mount point a /media/sda1 etc... I've also noticed something funny about the result of the ntfslabel command says the disk are called Disk I, Disk II etc... However in the <by-label> stuff above is says they are called Disk\x20I, Disk\x20II etc... Hmmm... I'm going to change my fstab to see if it makes a difference.... Edit YIPEEEE - it works.... but I needed to mount manually?? now to get it to happen on a boot up.... Last edited by theDaveTheRave; December 4th, 2008 at 01:49 PM.. Reason: It Works |
|||
|
|

December 4th, 2008
|
#121 |
|
Ubuntu Guru
![]() |
Re: How to fstab
I assume the "guest" is a single account ?
In that case use mount --bind mount --bind /media/HDI /home/guest/HDI In fstab : Code:
/media/HDI /home/guest/HDI none bind May I also suggest, if this is a linux server, you use a linux native file system (ext3) ? Linux can not really maintain (defragment) ntfs partitions and permissions (with so many users) will be easier to manage on a linux native system.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
December 5th, 2008
|
#122 |
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
Bodhi,
Thanks for the advice, I've managed to get it working, and it boots up with everything the way I wanted it, it all looks "seemless" to everyone now (I hope!). On partition types. My personal preference would have been for either a Reiser or EXT3 partition, but my boss wanted it in NTFS (so as the windows machines can easily read them etc) and I don't know a good way to explain about issues of "defragmentation" and with "samba" shares it doesn't really matter anyway.... Also for "safety" reasons the disks are easily removable, so we could potentially just pull out a disk and chuck it into another machine, if it is in NTFS format then this is easy. Are you aware of any good NTFS tools for linux that will regularly "defrag" the drive? This could become an issue as the team produce lots of "video" data in their experiments (time lapse over 2 or 3 days with pics every 30 mins). Thanks in advance for you advice. David. |
|
|
December 5th, 2008
|
#123 |
|
Ubuntu Guru
![]() |
Re: How to fstab
No, that is the problems with using ntfs.
Ask your boss if you can "demo" a linux native file system (as you indicated, you do not need the file system to be ntfs to share via samba).
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
December 6th, 2008
|
#124 |
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
Bodhi,
<I'm not sure if this is the place for this question? maybe we should start a new thread later on, your choice> I don't know if this makes sense or not, I know my boss won't be keen on the idea of using another filing system on the raid devices, but I do intend to maintain the MySQL database I am developing on the main HDD (for now and while it has space - I've been here for 4 months and the database is only really in "demo" mode and I've got 18 Gb of data - and only 3 tables, and no gene sequences yet!), and this is in EXT3 (i think?) Anyway... my question is this. When my colleagues are creating their data sets they start with about 60GB of video data, after analysis and stuff they normaly have it trimmed to about 20 or 30 Check out our web page to see some of the stuff we are doing -http://nuclear.movement.googlepages.com and here are some sample movies -http://nuclear.movement.googlepages.com/research2 What I was thinking, is when they "finalise" their movies they could potentially store them on a "separate" partition of the drive. Do logical partitions of drive space exist in a "physical" manner (ie when I split a drive into a partition is partition1 physically all together and partition2 physcialy after it?? if so could I do the following. Have one of my TB disks read only, so as I can do the following: Determine the size of a set of films for one experiment, then create a partition at the "front" of that disk of exactly the desired size to hold just that set of films. copy the films into this new partition (and potentially mount it as a separate read only sub folder). When they have the next set of films ready do the same procedure, resizing the larger portion of the disk that was remaining to hold just the films from the next experiment? and keep doing this, meaning that each experiment will exist on a separate partition that is READ ONLY and as it of a fixed size on the disk can't become "fragmented". Are there any dangers to doing this? such as the continuall repartitioning of the remaining space etc, will it corrupt the data in the partition at the front?? Another question, and I'm begining to think this question should be living in the hardware thread?, in fact I'm going to create this same question in a new thread in that section. I'll link to it later on Would doing this make access the "films" faster for my colleagues?? Would I then have an easier time of creating "archives" and backup procedures for the data?? Thanks in advance for your asstance. David Here is the link to where I have asked this question in the hardware section of the forums. http://ubuntuforums.org/newthread.ph...ewthread&f=332 Please direct any responses there, thankyou. Last edited by theDaveTheRave; December 6th, 2008 at 06:41 AM.. Reason: Added link to copy of question in Hardware forum, please respond there. |
|
|
December 9th, 2008
|
#125 |
|
Just Give Me the Beans!
![]() Join Date: Jun 2005
Beans: 78
|
Re: How to fstab
Ok, so I messed up my fstab pretty nicely.
I need to mount a partition to /music. But its mounting as root, so I can't copy my music backups onto it. The fstab: Code:
UUID=whatever /music ext3 relatime 0 2 |
|
|
December 9th, 2008
|
#126 | |
|
Skinny Extra Sweet Ubuntu
![]() Join Date: Feb 2007
Location: romania
My beans are hidden!
Ubuntu Development Release
|
Re: How to fstab
Quote:
You need to change the owner of the partition: Code:
sudo chown -R username:username /music You can read more about file permissions here: https://help.ubuntu.com/community/FilePermissions |
|
|
|
December 9th, 2008
|
#127 |
|
Extra Roomy Joe
![]() Join Date: Mar 2008
Beans: 4,711
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
Code:
sudo chown -R $USER:$USER /music |
|
|
December 13th, 2008
|
#128 | |
|
First Cup of Ubuntu
![]() Join Date: Dec 2008
Beans: 1
|
Re: How to fstab
thanks for the tutorial
but when I mount my external usb drive i get Quote:
|
|
|
|
December 13th, 2008
|
#129 |
|
I Ubuntu, Therefore, I Am
![]() |
Re: How to fstab
Please provide the details of how you're mounting (the relevant
fstab lines and/or the mount command you're using). It seems weird that
/etc/mtab~ even comes into play. In fact, check if /etc/mtab~ exists.
If it does, delete it.
__________________
What's a blub programmer? Registered Linux user #419974 My projects: |
|
|
December 15th, 2008
|
#130 |
|
Gee! These Aren't Roasted!
![]() Join Date: Jul 2008
Location: New Plymouth, ID
Beans: 157
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
I
am trying automount my music folder to see if it help rhytmbox with
loading my music. I am not understanding this /etc/fstab file.
The path that I would like to automount is /media/disk-1/Music I want it to mount with read,write, delete permissions Here is my /etc/fstab file, can you make any suggestions on how I do this. Code:
# /etc/fstab: static file system information. # # <file system> <mount point> <type> <options> <dump> <pass> proc /proc proc defaults 0 0 # /dev/sda1 UUID=05502dba-1d9d-41b7-ad03-ecf67e855e16 / ext3 relatime,errors=remount-ro 0 1 # /dev/sda5 UUID=ac866e41-b85e-453d-9fb8-ef84095507ed none swap sw 0 0 /dev/scd0 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0 |
|
|

December 15th, 2008
|
#131 |
|
Ubuntu Guru
![]() |
Re: How to fstab
Well, you mount a device to a location
/dev/sdxy /media/disk-1/music so ... we need to know the device you are trying to mount.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
December 16th, 2008
|
#132 |
|
Gee! These Aren't Roasted!
![]() Join Date: Jul 2008
Location: New Plymouth, ID
Beans: 157
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
|
|
|
December 16th, 2008
|
#133 | ||
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
Now what file system ? FAT or NTFS ? Also you may wish to mount by UUID (as the /dev can change) List your uuid by : Code:
sudo blkid Quote:
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
||
|
|
December 16th, 2008
|
#134 |
|
Gee! These Aren't Roasted!
![]() Join Date: Jul 2008
Location: New Plymouth, ID
Beans: 157
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
acreech@acreech-laptop:~/Music$ mount | grep /dev/sd
/dev/sda1 on / type ext3 (rw,relatime,errors=remount-ro) /dev/sdb1 on /media/disk-1 type ext3 (rw,nosuid,nodev,uhelper=hal) acreech@acreech-laptop:~$ sudo blkid [sudo] password for acreech: /dev/sda1: UUID="05502dba-1d9d-41b7-ad03-ecf67e855e16" TYPE="ext3" /dev/sda5: TYPE="swap" UUID="ac866e41-b85e-453d-9fb8-ef84095507ed" /dev/sdb1: UUID="dd94fee6-0dbd-4ed0-b7b5-2e90d5708c31" SEC_TYPE="ext2" TYPE="ext3" The type is ext3. I have a feeling that this will not do what I want in the end. I was just trying a suggestion. the problem I am attempting to fix is that I have all my music saved on a 2nd internal hard drive. That 2nd internal hard drive (/media/disk-1) automounts. Rhytmbox seems to forget where my music is kept and I have to go in and remind it every time I open the program. The suggestion is that if I automount the music folder then it will be there for Rhytmbox. I think that this won't work because the drive is already automounted, so shouldn't all the folders be automounted too? thanks for the help |
|
|
December 16th, 2008
|
#135 |
|
Ubuntu Guru
![]() |
Re: How to fstab
Well, that is why I was asking what you were wanting to do.
You can mount a partition somewhere, for example, you are mounting /dev/sdb1 at /media/disk-1 But you want a directory to mount. This can be done with mount -bind. mount -bind /directory-1 /directory_new You can also make a link. ln -s /media/disk-1/Music /home/user/Music
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
December 16th, 2008
|
#136 | |
|
Gee! These Aren't Roasted!
![]() Join Date: Jul 2008
Location: New Plymouth, ID
Beans: 157
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
Quote:
Then the files will still be stored on the 2nd internal hard drive and I could just point Rhythmbox to /home/acreech/Music I don't want to store that large of a folder on my main drive withthe operating system. I am assuming that this would be the code I would want to use in a terminal Code:
ln -s /media/disk-1/Music /home/acreech/Music |
|
|
|
December 16th, 2008
|
#137 |
|
Ubuntu Guru
![]() |
Re: How to fstab
yep, that should do the trick.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
December 16th, 2008
|
#138 |
|
Gee! These Aren't Roasted!
![]() Join Date: Jul 2008
Location: New Plymouth, ID
Beans: 157
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
|
|
|
December 17th, 2008
|
#139 |
|
Just Give Me the Beans!
![]() Join Date: Sep 2008
Beans: 63
|
Re: How to fstab
Hello,
I have a desktop computer with a DVD player RW (there is a second one but it is not used). It read ok (I have set up ubuntu from it)? I would like to copy a .iso file from the computer to a DVD disc. but when I use CD/DVD creator it asked for: Insert a rewritable or blank disc Please put a disc, with at least 2.3 GiB free, into the drive. The following disc types are supported: DVD+R DL, DVD-R, DVD-RW, DVD+R, DVD+RW I insert a 4.7GB disc in the driver but I get nothing back. /etc/fstab: static file system information. # <file system> <mount point> <type> <options> <dump> <pass> proc /proc proc defaults 0 0 # /dev/sda1 UUID=1948d24d-a767-490d-9d69-e513ef76c0ad / ext3 relatime,errors=remount-ro 0 1 # /dev/sda5 UUID=d19b101d-8f99-4e9f-b78a-07fab9bdd5c1 none swap sw 0 0 /dev/scd1 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0 When I try to accces (click on) the content (e.g. music) from the same DVD player: Places > Audio CD (was CE+RW / DVD+-RW Drive). It shows: Could not open location 'cdda://scd1/' Failed to execute child process "sound-juicer" (No such file or directory) When I try to accces the drive with the empty DVD in: Places > CE+RW / DVD+-RW Drive. I get nothing back. It is like it does not pick up there is a DVD ready to write on in the drive... What should I do? |
|
|
December 17th, 2008
|
#140 |
|
Extra Roomy Joe
![]() Join Date: Mar 2008
Beans: 4,711
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
This
is a guess: Ubuntu sees that you have two CD/DVD drives and labels them
/dev/scd0 and /dev/scd1. Your /etc/fstab links /dev/scd1 to
/media/cdrom0. My guess is that /dev/scd0 should be linked to
/media/cdrom0 instead. To test this guess:
Code:
gksu gedit /etc/fstab Save and exit. |
|
|

January 23rd, 2009
|
#141 |
|
5 Cups of Ubuntu
![]() Join Date: Sep 2007
Location: Seattle, USA
Beans: 19
Ubuntu 9.10 Karmic Koala
|
Re: How to fstab
Much appreciated! And in general, the information that I've found here on this forum is incredibly helpful.
In case it helps future visitors, here's the line I added to fstab to mount a FAT32 eSATA volume into an existing directory that I created called /media/disk-1: Code:
# VFAT # /dev/sda1 UUID=0FFD-432F /media/disk-1 vfat auto,users,utf8,umask=000 37 0 0 |
|
|
January 23rd, 2009
|
#142 |
|
Extra Roomy Joe
![]() Join Date: Mar 2008
Beans: 4,711
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
Hello daqron, welcome to the forums!
Just a let you know: there is a minor error in your fstab entry. Each fstab line (besides comments and empty lines) should have exactly six space-separated fields. Yours has seven: Code:
UUID=0FFD-432F /media/disk-1 vfat auto,users,utf8,umask=000 37 0 0 Code:
UUID=0FFD-432F /media/disk-1 vfat auto,users,utf8,umask=000 0 0 By default, however, Ubuntu does not install dump, so I think this field is meaningless unless you install dump. Cheers, unutbu |
|
|
January 27th, 2009
|
#143 |
|
Just Give Me the Beans!
![]() Join Date: Apr 2007
Beans: 59
|
Re: How to fstab
I must being doing something wrong that is simple.
When attempting to use e2label to assign a label to a partition on my other internal HD, I receive the following error message: e2label: Is a directory while trying to open /media/disk/newbackup Couldn't find valid filesystem superblock. There a number of partitions on my other HD, which is why I want to assign a label to this one before entering it in fstab to enable it for backups. |
|
|
January 27th, 2009
|
#144 |
|
Extra Roomy Joe
![]() Join Date: Mar 2008
Beans: 4,711
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
I
was able to reproduce your error message. It happens when you specify
the partition by mount point instead of specifying the partition by its
device name.
/media/disk/newbackup is the mount point. The device name might be something like /dev/sdb1 So the command you are looking for is Code:
sudo e2label /dev/sdb1 LABEL To find the device name type Code:
df |
|
|
January 29th, 2009
|
#145 |
|
5 Cups of Ubuntu
![]() Join Date: Sep 2007
Location: Seattle, USA
Beans: 19
Ubuntu 9.10 Karmic Koala
|
Re: How to fstab
Thank you sir and/or madam.
That is exactly what I meant. fstab auto-corrected by removing the superfluous "0" at the end, but I went ahead and changed the 37 to 0. Thanks for the clarification.
__________________
"I take it from your glum demeanor that your ill-advised foray into time-travel destroyed yet another reality." |
|
|
February 24th, 2009
|
#146 |
|
Still having fun...
![]() Join Date: Dec 2006
Beans: 3,095
Ubuntu 9.10 Karmic Koala
|
Re: How to fstab
Hi,
A quick question that may be a little off-topic: I am running Intrepid Ibex as guest using VirtualBox on a slackware host. I have set up a shared folder on the host and placed the matching folder on my Intrepid desktop. I have loaded this from fstab as: Code:
share /home/andrew/Desktop/share vboxsf uid=andrew,gid=users 0 0
I apologise ahead for this question as I suck at fstab Andrew |
|
|
February 24th, 2009
|
#147 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
By that I mean if you look at man mount http://linux.die.net/man/8/mount You will see each file system has it's own options, and this must then be the behavior of vboxsf . ====== Off topic: I find it is just as easy to use a shared USB device or better a Samba server. Just as easy, IMO, to set up. You can also use other network protocols, such as ssh (scp), sshfs, ftp, https, NFS, etc.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
February 25th, 2009
|
#148 | ||
|
Still having fun...
![]() Join Date: Dec 2006
Beans: 3,095
Ubuntu 9.10 Karmic Koala
|
Re: How to fstab
Hi bohdi.zazen,
Thanks for your reply: Quote:
Quote:
Thanks again, Andrew |
||
|
|
March 12th, 2009
|
#149 |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
I
want to make a general entry (in order to specify configuration
information) to mount any ISO image file, i wish; such that when I
issue mount command, image gets mounted (as staged below) and I don't
have to specify configuration information.
mount <image_path> <mountpoint> I tried LABEL='*' /media/IMAGE udf,iso9660 user,loop=/dev/loop0 0 0 but no avail. Do wildcards works in fstab entries? What is difference between the options 'loop' and 'loop=/dev/loop0'? Thanks in advance..
__________________
Nature Thoughts & Symmetry |
|
|
March 13th, 2009
|
#150 | |
|
A Carafe of Ubuntu
![]() |
Re: How to fstab
Quote:
__________________
Nature Thoughts & Symmetry |
|
|
|

March 26th, 2009
|
#151 |
|
5 Cups of Ubuntu
![]() Join Date: Mar 2008
Beans: 22
|
Great guide.. thanks for all the deatil.
I'm just wondering if people have noticed a difference in the behavior of fstab with the new 8.10 distro I noticed that fstab which worked with 8.04 is now not behaving as expected. Both are EXT3 mounts via USB. Their entries are: /dev/sdc1 /media/HT750HD ext3 rw,nouser,auto,async,relatime 0 2 /dev/sdb1 /media/MAXTORPART ext3 rw,nouser,auto,async,relatime 0 2 Was just wondering if anyone here noticed differences with the new distro? Last edited by cheruvim; March 26th, 2009 at 09:12 AM.. Reason: screwed up the fschk |
|
|
March 26th, 2009
|
#152 |
|
Extra Roomy Joe
![]() Join Date: Mar 2008
Beans: 4,711
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
cheruvim, in what way is Ubuntu 8.10 not behaving as expected?
If you format a partition as ext3 using Ubuntu 8.10 (Intrepid) it will use the newer 256 byte inode size for its filesystem. Whereas, if you format a partition as ext3 using Ubuntu 8.04 (Hardy) or earlier versions, it will use a 128 byte inode size for its filesystem. If you ask Hardy to mount an ext3 filesystem which had been formatted under Intrepid, I think it may have problems reading the filesystem. However, Intrepid should have no problem reading a Hardy-formatted ext3 filesystem. See http://ubuntuforums.org/showpost.php...48&postcount=9 http://ubuntuforums.org/showthread.php?t=837728 for a little more info on the 256 byte inode size. |
|
|
April 9th, 2009
|
#153 |
|
5 Cups of Ubuntu
![]() Join Date: Mar 2009
Beans: 17
|
Re: How to fstab
Thank
you so much! You saved me from pulling out what little hair the
military allows me to have. Anyhow, I do have some questions. Is there
a way to make this auto mount? I tried NTFS Config, and it won't do
anything for me. The last two line are the ones that I added to my
fstab, then forced mounted the drive. As you can tell from the bellow
lines and such. If I leave it plugged into my laptop, and reboot, will
it auto mount? Thank you very much!!
Another Learning Newbie... # /etc/fstab: static file system information. # # -- This file has been automaticly generated by ntfs-config -- # # <file system> <mount point> <type> <options> <dump> <pass> proc /proc proc defaults 0 0 # Entry for /dev/sda1 : UUID=1cc335cc-8cfe-4ca7-b8e0-c39d79dec4e7 / ext3 relatime,errors=remount-ro 0 1 # Entry for /dev/sda5 : UUID=a8b6c509-438d-4a61-a8c3-79b07d2558f7 /dev/sda5 /mnt/ntfs-sys ntfs 0 0 /dev/scd0 /media/cdrom0 udf,iso9660 user,noauto,exec,utf8 0 0 # Entry for /dev/sdb1 : UUID=AC5C04885C044F8E /media/usb ntfs 0 0 0 Notice the last two lines. I pulled up my UUID for the sdb1 and added it. this was the command for getting by UUID: ls /dev/disk/by-uuid -lah Then, I made a mount point: mkdir /media/usb after that, this command did the rest. mount -t ntfs-3g /dev/sdb1 /media/usb -o force Again, thanks for all of everyones help. |
|
|
May 1st, 2009
|
#154 |
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
Adding drives and powerfailures etc.
So if you hunt through this forum you will see a number of posts from your truly with issues of the UUID changing between re-boots (part way down the first page). Another set in here (related to setup of a multi part RAID TeraByte drive) had some questions relating to that also. So now, on this box with the multiple Terabye drives I've had an interesting anomaly that I will share with everyone (hopefully this will be of interest to you all). So I had initially 4 TB drives mounted into a samba shared partition. All was working very nicely thanks very much. I was then tasked with adding in 4 new drives. This really buggered around with the order of the original drives, so much so that they were no longer in the correct subdirectories of the shared drive. So with some playing around with the fstab etc I have been able to get them into the directories I wanted. So now the strange thing is, I seem to have lost control of one of these drives? it now just appears as a standard mount point as media/disk ? Essentially this isn't a problem but I know I'm going to have to play around with the fstab file again. The really strange thing is this. The I only seem to have lost control of a single disk, but, this has altered entirely the mount points for the others. I'm guessing that as this disk was part of the original 4 (mounted via the RAID controller) that this may have some bearing on the situation. For now I need to wait untill I am able to do a "full diagnostic" and understand what has happened. This won't be untill Monday. I will report back my findings, and my solutions then. However I suspect I will need to implement some sort of a solution so as we know when this happens again, as we use these disks for backups, and now the backup for thursday has ended up on the wrong disk (due to the mount point changing!) I'm guessing that by getting the corrected output for the various things (ls /media/disk/la... or whatever!) I'll be abel to run a boot time check of the files. I'm just not sure exactly for the best way of doing this at the moment. I'm thinking of using a shell script to do a file comparison or something... I'll let you all know how I sort this out, unless of course you have a solution for this sort of thing allready! David OK as promised, results of further investigations. As I had suspected it seemed that everything was "moved around" for some reason? the question is why? I can't say any more than that because when I arrived at the office this morning, the disks were back in the "normal" configuration, but we know that it was wrong as the backups went to the wrong place? Edit 2 So I've just had a mail telling me that the server disks are in the wrong order! So today, I organised for each mount point (ie HDD) to contain it's own specified file (giving it's ID). so the first disk has a file called disk1.txt, and the second disk2.txt. This means we can quickly determine if the disks are in the correct place! Today I shutdown the machine, and when my boss turned it back on again.... the mount points had all gone south (and some east and maybe even west as well!). The only change on this terminal is the instalation (an non functioning of) vmware server. Does anyone know if this may be causing my problem? I would guess that there is nothing wrong with the configuration file, otherwise it would never be correct. But why does it sometimes get it right and other times not? I need some help to try to figure out why this is happening, and what logs I need to be looking at. My initial guess is as that the part of the boot procedure that controls the mounting of disks from the fstab isn't happening at the right time (or not at all??) thanks in advance for the help. David Last edited by theDaveTheRave; May 5th, 2009 at 03:23 PM.. Reason: add info as promised. |
|
|
May 6th, 2009
|
#155 |
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
Hello again all
I'm adding an extra post as this is also a small "bump" for some advice / help. So if you read my above post you'll understand my strange situation. My solution. A little shell script that I will run as part of the boot sequence that will test for the location of the various control file names. If they are in the wrong place, it will send put a put a file into a designated place called either <goodConfig.txt> or <badConfig.txt> But I had a thought, I would like to understand why the mounting via the fstab is failing on the odd occasion. Hence I need to collect some of the files and store them somewhere, this isn't a problem. My questions in this instance are: Are there any extra files other than the </etc/fstab> <etc/mtab> and getting info from the output of commands like <ls </dev/disk/by-uuid -la> that I should be looking at? will the info be in the log files somewhere, if so which one? Am I able to reset the fstab after boot? if so what is the command, as it would be nice to find that the config is all wrong and then simple "re-mount" everything where it should be, then re-check that this has worked correctly, I'm sure it is in this post somewhere, but I can't find the command, please help on this one. some quick observations / notes the only things to have changed recently on this server are, the addition of vmware server (which doesn't currently work
), and the initiation of a "wake on lan" so as if the system is powered
down it can be restarted, could either of these be causing the issue?Is it possible that the fstab / mount of the drives is occuring before they are have all be "found" by the system? disk label's and the /dev/sdXY mount points seem not to be consistent, at least when we see these errors in the location. I think the label stays the same, but if the disk labeled as "diskI" moves from /dev/sda1 to dev/sdb1 will this "break" the control in the fstab? Also we now have 8 disks in the system, and this messed things up rather a lot also, the mount points in /dev/ all changed for the original 4. Also one of the disks is "bad" I can probe it (via an lshw) and everything seems fine, but I can't get it to mount. It has the same fstab line as for the other disks, appart from a change in the /dev/sdXY detail obviously? could this disk be causing problems in the mount procedure? - i have commented out the line in fstab, but this disk never appears on the desktop. In fact it was the appearance of a disk on the desktop that allerted me to the original error condition, which I didn't fully investigate because everything looked to be in the correct place, but in fact it was not! As allways your help is greatly appreciated. David |
|
|
May 15th, 2009
|
#156 |
|
Just Give Me the Beans!
![]() Join Date: Apr 2009
Beans: 77
|
Re: How to fstab
I get the same message when I'm on the desktop & press
"Places" -> Audio Disk. Also, my CD/DVD burner only mounts when I
open up Nautilus. Any suggestions?
|
|
|
May 18th, 2009
|
#157 | |
|
Tall Cafè Ubuntu
![]() Join Date: May 2007
Location: Charlotte, NC, USA
Beans: 2,530
Ubuntu 9.10 Karmic Koala
|
Re: How to fstab
Quote:
A couple of versions back (Ubuntu versions that is), I had some problems with my drives and their switching to unexpected positions in the food chain. The cure for me was to remove all the UUID info and leave it as /dev/sda1 - /dev/sdb1 - etc... This solved my problems but it was a non-raid setup. This probably didn't help you much but it's all I've got...
__________________
AMD ATHLON 64 X2 4800+ @ 2.6 GHz - Ubuntu Jaunty 9.04 MSI K8N Neo4 Platinum/SLI - BIOS 3.11 - 4 GB Curcial DDR MSI 8800 GT -- Plextor PX-880SA -- Pioneer DVR-115D 2x 74 GB WD Raptors SATA , 2x 250 GB Hitachi SATA (Data) |
|
|
|
May 19th, 2009
|
#158 | |
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
Quote:
that does sort of clear up a few potential ideas I had had on this. However due to the nature of the placement of the drives using /dev/sd1 - etc won't work anymore! The reason for this is the following... Initially the 1TB drives were hooked into the system via a "raid device", although the disks were not acting as a "raid" type system, (ie a 4 disk raid with redundancy) as we need all the disk space we can get for out data backups! So when we added the next 4 disks, it seemed to play around with the locations of the original disks (ie /dev/sda1 now became /dev/sda5), the reason for this (please correct me if I am wrong) is I think something to do with the "internal" disks being loaded into the system prior to those connected via the "raid device". all I know of this is that the order of the disks in mtab resulted in the original 4 disks being at the end of the file, which I thought of as very strange. sorry I can't me more clear on this at this time as I am "away" from the office and I can't ssh to ascertain the actual setup due to the firewall, and I can't convince the IT team to open a port for me (or that should probably read 'each time I suggest I should talk to the IT team I don't get much of a response' - so now I've all but given up asking!). Anyway... I digress.... The biggest curiosity for me is how sometimes the boot procedure get the setup correct and other not? I suspect that the disks are being mounted prior to the reading of the fstab or something? In the little shell script I created I finish with remounting all the disk with a call to Code:
mount -a which seems to put things right? Which is why I think that maybe the fstab isn't being read at the right time? Is this even possible? and what can I do to "prove" this theory? thanks again for all the help. David |
|
|
|
July 7th, 2009
|
#159 |
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
Hello again all.
so after further investigation, and not being able to solve my problem after multiple re-boots I started trawling my way though the /var/log/messages I have been having messages relating to one of the HDD and there being a "DRDY" and I/O error at given sectors (just by the number of lines I thing this may in fact be all the sectors!) I'm not sure but it may be related to this but on launchpad here. So if you are having a similar problem check the message log and then filter by device name. for me the device causing the grief was sdh. then if that gives you anything check the other logs for similar info at the same time. hope that helps anyone. David |
|
|
July 11th, 2009
|
#160 | |
|
Fresh Brewed Ubuntu
![]() Join Date: Mar 2008
Location: Deep South Texas
Beans: 1,345
Kubuntu 8.04 Hardy Heron
|
Re: How to fstab
Quote:
__________________
Don't forget to tip your software authors! |
|
|
|

July 13th, 2009
|
#161 |
|
Ubuntu Guru
![]() |
Re: How to fstab
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
July 22nd, 2009
|
#162 |
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
Hello again everyone.
I've got another question about fstab and mounting new drives into given locations. this time related to virtual machines, but I'm not sure where to ask the question so I'm asking it here in the first instance. My VM is an ubuntu install on a vista terminal. I created the disk as what I thought was "automatically expandable" but it won't expand! Not a problem I thought, I can simply add an extra HDD and mount it to wherever I need it.... not so. When you mount a disk in a given location (eg /home/username ) any files or directories in that partition will dissappear! not helpfull! I am sure that they must be a way of making Ubuntu think that the new disk is actually part of the original disk? - essentially extending the disk size at a given mount point? I wonder if this is possible by using symbolic links? I have read about using the LVM (logical volume manager) but from what I have read it seems as though LVM will only work if you are installed from the < alternate install cd >. Other suggestions are too boot from the live CD, but this is a VM so I'm not sure that this will work! any advice will be eagerly asborbed. Thanks in advance. David |
|
|
July 22nd, 2009
|
#163 |
|
Extra Roomy Joe
![]() Join Date: Mar 2008
Beans: 4,711
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
Hi theDaveTheRave.
You are correct: if you have files in /home/username on /dev/sdaX and then mount /dev/sdbY at /home/username, then the original files "disappear" (until you umount /dev/sdbY). The "mount" command does not merge directories together. Here are a few workarounds/options:
Last edited by unutbu; July 22nd, 2009 at 11:24 AM.. |
|
|
July 22nd, 2009
|
#164 |
|
Quad Shot of Ubuntu
![]() |
Re: How to fstab
Unutbu
I had thought it may be possible with the use of symlinks. However (and just because I want to add in a little bit of confusion) I will explain why I need to do this. I've been asked to create a virtual machine to hold a "dumbed down" version of a mysql database. The tables for mysql live in /var/lib/mysql I created the VM and it had the "normal" setup with apparently "automatically expandable HDD" which when I tried to load on the mysql tables didn't expand and promptly ran out of space! So now I need to add in a new Virtual HDD, which seems fine but I can't add a "logical Volume" into the system, and I can't use fstab to mount it either. this leads me nicely to my question. If I create a symbolic link (as you are suggesting) will that enable the mysql daemon to follow it automatically when adding in new tables / adding data to existing ones? Otherwise I had allready hit on the idea of simply copying everything over to the new disk, then de-import / re-import the relevant disks etc... which sounds far too complicated for my work colleagues! Ah well... only another 2 days and its the weekend.... David |
|
|
July 22nd, 2009
|
#165 | |
|
Extra Roomy Joe
![]() Join Date: Mar 2008
Beans: 4,711
Ubuntu 8.10 Intrepid Ibex
|
Re: How to fstab
theDaveTheRave, I don't have any experience with virtual machines.
I hope someone with knowledge about this will chime in, especially if I'm making some mistake. Until then I'm going to ignore that you're dealing with a VM and assume things work the same as a normal installation. Quote:
Starting with Intrepid (or maybe Hardy), Ubuntu installs mysql-server with an apparmor profile called /etc/apparmor.d/usr.sbin.mysqld. This apparmor profile restricts the directories into which mysql can read/write. In order to enable mysqld to read /data/var/lib/mysql/MY_DB you must edit /etc/apparmor.d/usr.sbin.mysqld by adding lines like this: Code:
/data/var/lib/mysql/ r, /data/var/lib/mysql/** rwk, Code:
sudo /etc/init.d/apparmor restart sudo /etc/init.d/mysql restart |
|
|
|
July 22nd, 2009
|
#166 |
|
Ubuntu Guru
![]() |
Re: How to fstab
I would look to see why your disk is full. Fix that problem (need a bigger disk ?).
Your example can not be solved with fstab or links. IMO easiest to make a new disk. Boot your Vm with a "live CD" and copy your /old_disk to the /new_disk You might also want to look at LVM.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
July 25th, 2009
|
#167 |
|
A Carafe of Ubuntu
![]() Join Date: Jun 2007
Location: Puerto Rico
Beans: 114
Ubuntu 9.10 Karmic Koala
|
Re: How to fstab
I think that I read this somewhere in this post but it will be good if it is included in the HowTo.
When making a new dir with sudo, if the directory is made in /mnt it will not show up in "Places" or in the dialogs that look for a folder. The drive will be mounted but you will have to manually navigate to /mnt/SOMEFOLDER to access said drive. I for one like to have the drive listed in "Places" with the drive icon. To do that, a new dir should be mounted in /media. I just spent a couple of hours trying to figure this out thinking that the drive was not mounting. To follow your example: Code:
sudo mkdir /media/SOMEFOLDER Code:
sudo mkdir /mnt/SOMEFOLDER
__________________
¡Levántate!, ¡Revuélvete!, ¡Resiste! Haz como el toro acorralado: ¡muge! O como el toro que no muge: ¡EMBISTE! - José de Diego, En la brecha - |
|
|
August 18th, 2009
|
#168 |
|
A Carafe of Ubuntu
![]() Join Date: Feb 2009
Beans: 97
|
Re: How to fstab
Hopefully this thread is still active and someone can help.
Here's my puzzle: I have a second hard disc sdb1 I use to store data and programs on. To create it, I formatted it to ext3 and did: Code:
sudo chown -R myName:myName /media/Data sudo chmod -R 755 /media/Data Code:
/dev/sdb1 /media/Data ext3 defaults,users,exec 0 0 |
|
|
August 18th, 2009
|
#169 |
|
A Carafe of Ubuntu
![]() Join Date: Feb 2009
Beans: 97
|
Re: How to fstab
Actually,
adding exec does seem to have done the trick. I mistakenly tried
running a .exe file as a test - which just threw up the archive
manager, so I assumed things weren't working.
Other binaries now do run - as do bash scripts (which gave a confusing error message before). Now is that fstab line secure, in the sense that is 'nosuid' enabled? I don't want a rogue binary have access to things I can't normally access. I thought 'defaults' enabled 'suid'. What's the recommended way here? |
|
|
August 18th, 2009
|
#170 |
|
Ubuntu Guru
![]() |
Re: How to fstab
I advise you use the options noexec and nosuid
If you want a binary, keep it in ~/bin rather then the data partition.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|

August 21st, 2009
|
#171 |
|
A Carafe of Ubuntu
![]() Join Date: Feb 2009
Beans: 97
|
Re: How to fstab
Ah, thanks Bohdi.
I am just developing some stand-alone programs to perform various scientific calculations. I like to keep the code and binaries together on my 'data' disc, as the binaries are of no use to anyone except me. If I create a ~/bin folder, does Ubuntu include it in the search path? What is the order of search? I think it is something like: /usr/local/bin first, followed by /usr/bin, then ... ? On a separate hard disc is my system disc, which holds a minimal /home directory, just to provide configuration info to the system programs like mplayer, etc. So I think this is a fairly clean separation between the things I do and what Ubuntu does. I backup my system disc now and then using 'dd' to another spare disc. I use rsync to back up my data disc, to a different spare disc. I suppose I could move my development environment back to /home, but I rather like the way things are set up now. Except for this 'suid' business. |
|
|
August 21st, 2009
|
#172 |
|
Ubuntu Guru
![]() |
Re: How to fstab
That all sounds reasonable to me, nothing wrong with it.
To see your path : Code:
echo $PATH
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
September 4th, 2009
|
#173 |
|
Gee! These Aren't Roasted!
![]() Join Date: Jun 2007
Location: City of Joy, India
Beans: 209
Ubuntu 7.10 Gutsy Gibbon
|
Re: How to fstab
Great Guide.
__________________
Rahim Linux user since June 2K7 Ubuntu User # 16769
|
|
|
September 9th, 2009
|
#174 |
|
First Cup of Ubuntu
![]() Join Date: Sep 2008
Beans: 6
|
Re: How to fstab
Good Work, very comprehensible guide.
|
|
|
October 20th, 2009
|
#175 |
|
Ubuntu Guru
![]() |
Re: How to fstab
Added a link to Pysdm, a gui tool to configure fstab.
pysdm is in the Ubuntu repositories and I have been taking it for a spin on Zenix. In general it works quite well.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
October 21st, 2009
|
#176 | |
|
Ubuntu addict and loving it
![]() Join Date: Feb 2005
Location: Melbourne, Australia
Beans: 7,259
Ubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
Quote:
Why packages like this - which are basically essential for any user who does not want to be forced to learn arcane things like working with the fstab file just to connect one of their disks permanently - are not installed by default is really baffling.
__________________
Regards, David. The Forum search function is useful for immediate help (give it a try).
Please mark your thread as "Solved" (using the Thread Tools) when appropriate. |
|
|
|
October 21st, 2009
|
#177 |
|
5 Cups of Ubuntu
![]() Join Date: Feb 2007
Location: United States
Beans: 24
Kubuntu 9.04 Jaunty Jackalope
|
Re: How to fstab
Thank
you for this! as a beginner to linux, I look to the internet for
assistance a lot for learning, and this is a very well done how-to.
|
|
|
October 22nd, 2009
|
#178 | |
|
First Cup of Ubuntu
![]() Join Date: Oct 2009
Beans: 1
|
Re: How to fstab
Quote:
Great post, helped this noob immensely. The above section from the original post contains a typo. The line should instead read Server:/share /media/nfs nfs rsize=8192,wsize=8192,noexec,nosuid Thanks |
|
|
|
October 22nd, 2009
|
#179 |
|
First Cup of Ubuntu
![]() Join Date: Oct 2009
Beans: 6
|
Re: How to fstab
Great ! Thank you. This will surely help
|
|
|
October 22nd, 2009
|
#180 | |
|
Ubuntu Guru
![]() |
Re: How to fstab
Quote:
![]() Thank you, I fixed that one.
__________________
A person with ubuntu is open and available to others, affirming of others, does not feel threatened that others are able and good, for he or she has a proper self-assurance that comes from knowing that he or she belongs in a greater whole and is diminished when others are humiliated or diminished, when others are tortured or oppressed. ~ Archbishop Desmond Tutu, 1999 ![]() |
|
|
|
| Bookmarks |
| Tags |
| fstab, mount |
|
|