Author Topic: deep fstab  (Read 1802 times)

worker201

  • Global Moderator
  • Member
  • ***
  • Posts: 2,810
  • Kudos: 703
    • http://www.triple-bypass.net
deep fstab
« on: 28 July 2006, 02:13 »
Hey, this might sound stupid, but I got this new external hard drive that is formatted fat32.  I plugged it in and it just works, how about that?  But anyway, I want to change its mount settings.  Normally, I just open fstab and blingbling, there ya go.  But since I never wrote an fstab entry for this device, and I will probably be unplugging/replugging it often, how does that work?  If I change my fstab while the thing is in, will it remember?  How long will it be in the fstab after unmounting it?

btw, if you type Just with your left hand in the wrong place, you get Judy (qwerty only)

H_TeXMeX_H

  • Member
  • **
  • Posts: 1,988
  • Kudos: 494
    • http://draconishinobi.50webs.com/
Re: deep fstab
« Reply #1 on: 28 July 2006, 02:20 »
Well, I've edited the fstab before and all changes stayed ... it's a text file holding information about standard mounting procedures, there's no reason for an entry in there to just dissapear

piratePenguin

  • VIP
  • Member
  • ***
  • Posts: 3,027
  • Kudos: 775
    • http://piratepenguin.is-a-geek.com/~declan/
Re: deep fstab
« Reply #2 on: 28 July 2006, 02:25 »
I've plugged my mp3 player into this Ubuntu box before and there's no line in fstab, so either it removed the line after I last unplugged it or something, or there never was a line in fstab.

Either way, add/modify your own line, and hope Ubuntu doesn't overwrite it or do it's own thing. Might need to mount the FS manually then, I dunno.

edit: Hm, take a look at /etc/hal/fdi/policy/preferences.fdi I bet you can modify that, what is it you want to do?
editedit: and take a look at hal-device-manager - select your disk, and look at the advanced tab (so you know what settings you can (probably) change).
"What you share with the world is what it keeps of you."
 - Noah And The Whale: Give a little love



a poem by my computer, Macintosh Vigilante
Macintosh amends a damned around the requested typewriter. Macintosh urges a scarce design. Macintosh postulates an autobiography. Macintosh tolls the solo variant. Why does a winter audience delay macintosh? The maker tosses macintosh. Beneath female suffers a double scum. How will a rat cube the heavier cricket? Macintosh calls a method. Can macintosh nest opposite the headache? Macintosh ties the wrong fairy. When can macintosh stem the land gang? Female aborts underneath macintosh. Inside macintosh waffles female. Next to macintosh worries a well.

H_TeXMeX_H

  • Member
  • **
  • Posts: 1,988
  • Kudos: 494
    • http://draconishinobi.50webs.com/
Re: deep fstab
« Reply #3 on: 28 July 2006, 02:37 »
Quote from: piratePenguin
I've plugged my mp3 player into this Ubuntu box before and there's no line in fstab, so either it removed the line after I last unplugged it or something, or there never was a line in fstab.

Did it use automount ? If so automount uses /etc/auto.master not /etc/fstab

source: http://mercury.chem.pitt.edu/~sasha/LinuxFocus/English/January2001/article141.shtml

piratePenguin

  • VIP
  • Member
  • ***
  • Posts: 3,027
  • Kudos: 775
    • http://piratepenguin.is-a-geek.com/~declan/
Re: deep fstab
« Reply #4 on: 28 July 2006, 04:19 »
Quote from: H_TeXMeX_H
Did it use automount ? If so automount uses /etc/auto.master not /etc/fstab

source: http://mercury.chem.pitt.edu/~sasha/LinuxFocus/English/January2001/article141.shtml

Nope, Ubuntu doesn't use automount by the looks of things.

Anyhow, you don't need a line in fstab to mount a filesystem - all the options etc can be specified on the command line.

To make a FS mount in a different mount-point (for example), always and automatically, my bet (just looking at what's already (commented out) in this config file) is you would add something like this to the part of /etc/hal/fdi/policy/preferences.fdi :
Code: [Select]


 
    /path/to/new/mount/point
 

switch 49b9a949-e90a-407a-a21c-45fa1fdaabe7 with the volume.uuid of your FS - find it in the device manager, at the bottom of the advanced tab.

I'm not sure if that works at all though.

edit: pity you can't just make the changes in the device manager and it'll edit the config file, that'd be a neat feature
"What you share with the world is what it keeps of you."
 - Noah And The Whale: Give a little love



a poem by my computer, Macintosh Vigilante
Macintosh amends a damned around the requested typewriter. Macintosh urges a scarce design. Macintosh postulates an autobiography. Macintosh tolls the solo variant. Why does a winter audience delay macintosh? The maker tosses macintosh. Beneath female suffers a double scum. How will a rat cube the heavier cricket? Macintosh calls a method. Can macintosh nest opposite the headache? Macintosh ties the wrong fairy. When can macintosh stem the land gang? Female aborts underneath macintosh. Inside macintosh waffles female. Next to macintosh worries a well.

worker201

  • Global Moderator
  • Member
  • ***
  • Posts: 2,810
  • Kudos: 703
    • http://www.triple-bypass.net
Re: deep fstab
« Reply #5 on: 28 July 2006, 21:34 »
Another "duh" - do I need to unmount the devices before making fstab changes/additions?

Here's my current fstab:
Code: [Select]
# This file is edited by fstab-sync - see 'man fstab-sync' for details
LABEL=/                 /                       ext3    defaults        1 1
none                    /dev/pts                devpts  gid=5,mode=620  0 0
none                    /dev/shm                tmpfs   defaults        0 0
none                    /proc                   proc    defaults        0 0
none                    /sys                    sysfs   defaults        0 0
/dev/hdd1 /home ext3 defaults 1 2
/dev/hda5 /mnt/windows vfat gid=501,umask=002,user 0 0
LABEL=SWAP-hdb2         swap                    swap    defaults        0 0
/dev/sda2               /media/usbdisk          vfat    pamconsole,exec,noauto,utf8,managed 0 0
/dev/sda1               /media/usbdisk1         vfat    pamconsole,exec,noauto,utf8,managed 0 0
/dev/fd0                /media/floppy           auto    pamconsole,exec,noauto,utf8,managed 0 0
/dev/hdc                /media/cdrecorder       auto    pamconsole,exec,noauto,managed 0 0
/dev/sdb                /media/CRUZER           vfat    pamconsole,exec,noauto,utf8,managed 0 0
The ones I want to change are sda1 and sda2, to match settings of hda5.

And what's this fstab-sync shit?  Never saw that before!

piratePenguin

  • VIP
  • Member
  • ***
  • Posts: 3,027
  • Kudos: 775
    • http://piratepenguin.is-a-geek.com/~declan/
Re: deep fstab
« Reply #6 on: 28 July 2006, 21:39 »
Quote from: worker201
Another "duh" - do I need to unmount the devices before making fstab changes/additions?
No, but you will have to remount the device for the new options etc to come into effect.
Quote

And what's this fstab-sync shit?  Never saw that before!
I don't have it. What distro are you using? I bet fstab-sync is a (crappier :p) alternative to HAL. Run it and it sets up fstab according to what devices are attached.
"What you share with the world is what it keeps of you."
 - Noah And The Whale: Give a little love



a poem by my computer, Macintosh Vigilante
Macintosh amends a damned around the requested typewriter. Macintosh urges a scarce design. Macintosh postulates an autobiography. Macintosh tolls the solo variant. Why does a winter audience delay macintosh? The maker tosses macintosh. Beneath female suffers a double scum. How will a rat cube the heavier cricket? Macintosh calls a method. Can macintosh nest opposite the headache? Macintosh ties the wrong fairy. When can macintosh stem the land gang? Female aborts underneath macintosh. Inside macintosh waffles female. Next to macintosh worries a well.

worker201

  • Global Moderator
  • Member
  • ***
  • Posts: 2,810
  • Kudos: 703
    • http://www.triple-bypass.net
Re: deep fstab
« Reply #7 on: 28 July 2006, 21:42 »
Using FC4.

piratePenguin

  • VIP
  • Member
  • ***
  • Posts: 3,027
  • Kudos: 775
    • http://piratepenguin.is-a-geek.com/~declan/
Re: deep fstab
« Reply #8 on: 28 July 2006, 21:47 »
Quote from: worker201
Using FC4.
Yea, HAL is only starting to show in the newer distros.

http://freedesktop.org/wiki/Software_2fhal
"What you share with the world is what it keeps of you."
 - Noah And The Whale: Give a little love



a poem by my computer, Macintosh Vigilante
Macintosh amends a damned around the requested typewriter. Macintosh urges a scarce design. Macintosh postulates an autobiography. Macintosh tolls the solo variant. Why does a winter audience delay macintosh? The maker tosses macintosh. Beneath female suffers a double scum. How will a rat cube the heavier cricket? Macintosh calls a method. Can macintosh nest opposite the headache? Macintosh ties the wrong fairy. When can macintosh stem the land gang? Female aborts underneath macintosh. Inside macintosh waffles female. Next to macintosh worries a well.

Orethrius

  • Member
  • **
  • Posts: 1,783
  • Kudos: 982
Re: deep fstab
« Reply #9 on: 29 July 2006, 08:18 »
Quote from: piratePenguin
Yea, HAL is only starting to show in the newer distros.

http://freedesktop.org/wiki/Software_2fhal

 [offtopic]Are those suspend/hibernate scripts any good?[/offtopic]

Proudly posted from a Gentoo Linux system.

Quote from: Calum
even if you're renting you've got more rights than if you're using windows.

System Vitals

piratePenguin

  • VIP
  • Member
  • ***
  • Posts: 3,027
  • Kudos: 775
    • http://piratepenguin.is-a-geek.com/~declan/
Re: deep fstab
« Reply #10 on: 29 July 2006, 14:51 »
Quote from: Orethrius
[offtopic]Are those suspend/hibernate scripts any good?[/offtopic]
[offtopic]No idea ;)[/offtopic]
"What you share with the world is what it keeps of you."
 - Noah And The Whale: Give a little love



a poem by my computer, Macintosh Vigilante
Macintosh amends a damned around the requested typewriter. Macintosh urges a scarce design. Macintosh postulates an autobiography. Macintosh tolls the solo variant. Why does a winter audience delay macintosh? The maker tosses macintosh. Beneath female suffers a double scum. How will a rat cube the heavier cricket? Macintosh calls a method. Can macintosh nest opposite the headache? Macintosh ties the wrong fairy. When can macintosh stem the land gang? Female aborts underneath macintosh. Inside macintosh waffles female. Next to macintosh worries a well.