You are not logged in.
Yet another solution to the removable devices problem.
After a minor system overhaul I finally decided to get rid of a bunch of static mountpoints I had in /mnt. I checked Arch wiki, and what I saw there, well, raised some questions. I mean, it's udev, it's not supposed to be pretty, but pmount with a fixed user, as a recommended solution? Ugh.
So I came up with a perl script that modifies /etc/fstab dynamically and creates mountpoints under /mnt, but doesn't actually mount anything. This way user mounts do not require any specific handling, and overall it looks nice and simple.
To my slight surprise I couldn't find any good scripts that would do this even outside of the wiki (which is strange, btw, because the solution is obvious), so I decided to put it here. Maybe I'm not the only one who thinks auto-mounting is never a good thing.
https://raw.github.com/nkf/udevh/master/udevh-sd | https://raw.github.com/nkf/udevh/master/README
Comments, suggestions etc. are welcome.
Please check the source and udev rules before doing anything, it's fstab after all.
Offline
As long as you're happy..... ![]()
I'll just respond to your opinion that "the solution is obvious":
fstab - static information about the filesystems
# /etc/fstab: static file system information
fstab is only read by programs, and not written; it is the duty of the system administrator to properly create and maintain this file.
Also, the kludgy automount suggestions on the udev page - pmount with fixed user ZOMG - are deprecated now in favour of udisks-based setups.
Offline
which is strange, btw, because the solution is obvious), so I decided to put it here. Maybe I'm not the only one who thinks auto-mounting is never a good thing.
I think you're in the minority of folks who think dynamically modifying a system config file as crucial as /etc/fstab is a good thing.
Offline
With the above. Fstab is static, hacking that is just so counterproductive. There's nothing more easy than udisks - and there are plenty of frontends to it, like udiskie.
https://wiki.archlinux.org/index.php/Udiskie
Reinventing the wheel is not always necessary
.
Got Leenucks? :: Arch: Power in simplicity :: Get Counted! Registered Linux User #392717 :: Blog thingy
Offline
As long as you're happy.....
Well, yeah. I'm not a big fan of the current udev implementation, but this time it all worked very well.
As for the man page, well, it's not really set in stone. Ok, I admit I didn't read it, in Arch at least, but anyway, there must be reasons to call it static. mount is a simple tool, it's clear how it works, that's the only file it reads, and I see no intrinsic features in mount that would require fstab to be static. I'd say it's more of an self-imposed challenge to treat it as static, and not a necessity. At least for current implementation of mount, and current format of fstab, with "user", "users" etc.
Also, the kludgy automount suggestions on the udev page - pmount with fixed user ZOMG - are deprecated now in favour of udisks-based setups.
Maybe it should be removed then, or at least clearly labeled as deprecated?
Because when you read the page, it comes as a suggested solution. And udisks, well, I skipped that section at all, partly because it was above "Auto mounting USB devices", and party because it talks about KDE, Gnome and automounting.
Oh, and btw: I've just noticed that the fixed user in that example is "tomk" ;-)
I think you're in the minority of folks who think dynamically modifying a system config file as crucial as /etc/fstab is a good thing.
Somewhat off-topic, but /etc/fstab is one of the least critical files in the system, and one of the easiest to fix.
I didn't check with the current version, but if I'd was unable to boot without fstab, I'd call it a bug in initscripts.
There's nothing more easy than udisks - and there are plenty of frontends to it, like udiskie. (...) Reinventing the wheel is not always necessary.
Well, I'm reading about udisks now, and the problem is, when I want a wheel, I want a wheel, not a Segway.
I like my system to be simple (arch way and all), while this thing wants d-bus, polkit, some frontends and org.freedesktop.stuff.die.must.java style configuration variables just to be able to type "mount /mnt/sda1". Easy, maybe, for a given values of "easy"; simple, anything but.
Offline
https://wiki.archlinux.org/index.php/Udiskie
Reinventing the wheel is not always necessary
.
I'm confused... how is xfce4 out-of-the-box aware of usb drives when inserted?
Offline
How am I supposed to know? I don't even use it
.
And I didn't mention Xfce as far as I recall ![]()
Last edited by .:B:. (2011-11-26 19:05:40)
Got Leenucks? :: Arch: Power in simplicity :: Get Counted! Registered Linux User #392717 :: Blog thingy
Offline