Discussion:
Xubuntu automount confusion
(too old to reply)
DaveG
2012-01-29 13:28:46 UTC
Permalink
When I set up server, one of the shares is /media.

I mount it as /media on all my PCs

But now I'm using Xubuntu 10.04 LTS on a dual boot laptop. Most of my PCs
are currently in the loft so I tend to SSH into them from the laptop.

Anyway, I need to access the occasional USB pendrive etc on the laptop and
copy files from the nfs share /media.

The problem is that the automount system, whatever it is on this install,
prefers to use /media as it's base level mount point for removable
devices. They won't mount unless I umount /media first. That's a bit of
a problemwhen the file I want to transfer are on /media ;-)

Rather than change my entire network or have to use a different mount
point for the NFS shares on this one PC, is there any way to change the
behaviour so that Xubuntu default to, for example, /mnt or something else
of my choosing?

Googling around hasn't generated any useful results as yet. Most seem to
have no info on how the default automount system works. Other results
talk about files or automount systems which are not on the default
install. Rather than installing new software which may or may nor
conflict with the existing system, I'd much, much rather just change a bit
of text in an existing config file if someone can point me at it.

XP and FU to f.v.comp.linux
--
Dave
Beauty is in the eye of the beerholder
t***@isbd.co.uk
2012-01-29 15:28:19 UTC
Permalink
Post by DaveG
When I set up server, one of the shares is /media.
I mount it as /media on all my PCs
But now I'm using Xubuntu 10.04 LTS on a dual boot laptop. Most of my PCs
are currently in the loft so I tend to SSH into them from the laptop.
Anyway, I need to access the occasional USB pendrive etc on the laptop and
copy files from the nfs share /media.
The problem is that the automount system, whatever it is on this install,
prefers to use /media as it's base level mount point for removable
devices. They won't mount unless I umount /media first. That's a bit of
a problemwhen the file I want to transfer are on /media ;-)
Rather than change my entire network or have to use a different mount
point for the NFS shares on this one PC, is there any way to change the
behaviour so that Xubuntu default to, for example, /mnt or something else
of my choosing?
I suspect that it isn't xubuntu specific but rather built into the
underlying generic ubuntu stuff.
Post by DaveG
Googling around hasn't generated any useful results as yet. Most seem to
have no info on how the default automount system works. Other results
talk about files or automount systems which are not on the default
install. Rather than installing new software which may or may nor
conflict with the existing system, I'd much, much rather just change a bit
of text in an existing config file if someone can point me at it.
I'll ask on the xubuntu and xfce mailing lists to see if anyone there knows.
--
Chris Green
DaveG
2012-01-29 17:01:23 UTC
Permalink
Post by t***@isbd.co.uk
Post by DaveG
When I set up server, one of the shares is /media.
I mount it as /media on all my PCs
But now I'm using Xubuntu 10.04 LTS on a dual boot laptop. Most of my
PCs are currently in the loft so I tend to SSH into them from the
laptop.
Anyway, I need to access the occasional USB pendrive etc on the laptop
and copy files from the nfs share /media.
The problem is that the automount system, whatever it is on this
install, prefers to use /media as it's base level mount point for
removable devices. They won't mount unless I umount /media first.
That's a bit of a problemwhen the file I want to transfer are on /media
;-)
Rather than change my entire network or have to use a different mount
point for the NFS shares on this one PC, is there any way to change the
behaviour so that Xubuntu default to, for example, /mnt or something
else of my choosing?
I suspect that it isn't xubuntu specific but rather built into the
underlying generic ubuntu stuff.
Post by DaveG
Googling around hasn't generated any useful results as yet. Most seem
to have no info on how the default automount system works. Other
results talk about files or automount systems which are not on the
default install. Rather than installing new software which may or may
nor conflict with the existing system, I'd much, much rather just
change a bit of text in an existing config file if someone can point me
at it.
I'll ask on the xubuntu and xfce mailing lists to see if anyone there knows.
Ta.

As a temp workaround, I added:

/dev/sdb1 /pendrive vfat defaults,user,noauto 0 0

to /etc/fstab. The downside is that anything appearing to the system as
sdb1 will mount to /pendrive

Just checked and the kindle mounts there too. Fortunately, even though
the kindle wouldn't previously mount from the desktop, it did work via
Calibre, which it still does despite the mount changing/working now.

If no better, more elegant solution turns up, this one will do. The
laptop only has two USB ports anyway and one of those has a mouse in it so
I'll only ever have one other USB device connected.
--
Dave
Beauty is in the eye of the beerholder
sid
2012-01-29 20:55:40 UTC
Permalink
Post by DaveG
/dev/sdb1 /pendrive vfat defaults,user,noauto 0 0
to /etc/fstab. The downside is that anything appearing to the system as
sdb1 will mount to /pendrive
Just checked and the kindle mounts there too. Fortunately, even though
the kindle wouldn't previously mount from the desktop, it did work via
Calibre, which it still does despite the mount changing/working now.
If no better, more elegant solution turns up, this one will do. The
laptop only has two USB ports anyway and one of those has a mouse in it so
I'll only ever have one other USB device connected.
If you give the device a 'label' you can specify that label in /etc/fstab
and only that device will be mounted there.
--
sid
RLU 300284
2010.2
DaveG
2012-01-30 01:34:06 UTC
Permalink
Post by sid
If you give the device a 'label' you can specify that label in
/etc/fstab and only that device will be mounted there.
Yeah, I saw that option, but then remembered this pendrive gets formatted
every now and then and doesn't always get a label. Depends on what I'm
doing when I format it.

It's used for audiobooks in the car. The built-in USB port/MP3 player
plays tracks in the order they are written to the disk so it's not usually
an option to delete a book or two and just add new ones. I normally wait
'till I've heard them all then start with a "clean" pendrive. It's keeps
life simple.

Tracks don't get "mixed" between directories, but there seems to be little
logic in which order the tracks get played unless written to a "clean"
pendrive, one directory at a time. As you can imagine, this is rather
more important with an audio book than a music album :-)
--
Dave
Beauty is in the eye of the beerholder
t***@isbd.co.uk
2012-01-30 11:22:11 UTC
Permalink
Post by t***@isbd.co.uk
Post by DaveG
When I set up server, one of the shares is /media.
I mount it as /media on all my PCs
But now I'm using Xubuntu 10.04 LTS on a dual boot laptop. Most of my PCs
are currently in the loft so I tend to SSH into them from the laptop.
Anyway, I need to access the occasional USB pendrive etc on the laptop and
copy files from the nfs share /media.
The problem is that the automount system, whatever it is on this install,
prefers to use /media as it's base level mount point for removable
devices. They won't mount unless I umount /media first. That's a bit of
a problemwhen the file I want to transfer are on /media ;-)
Rather than change my entire network or have to use a different mount
point for the NFS shares on this one PC, is there any way to change the
behaviour so that Xubuntu default to, for example, /mnt or something else
of my choosing?
I suspect that it isn't xubuntu specific but rather built into the
underlying generic ubuntu stuff.
Post by DaveG
Googling around hasn't generated any useful results as yet. Most seem to
have no info on how the default automount system works. Other results
talk about files or automount systems which are not on the default
install. Rather than installing new software which may or may nor
conflict with the existing system, I'd much, much rather just change a bit
of text in an existing config file if someone can point me at it.
I'll ask on the xubuntu and xfce mailing lists to see if anyone there knows.
... and the answer is that it's Udev that does it.

Take a look at:-
http://www.tuxradar.com/answers/526
--
Chris Green
DaveG
2012-01-30 19:30:54 UTC
Permalink
Post by t***@isbd.co.uk
Post by t***@isbd.co.uk
Post by DaveG
When I set up server, one of the shares is /media.
I mount it as /media on all my PCs
But now I'm using Xubuntu 10.04 LTS on a dual boot laptop. Most of
my PCs are currently in the loft so I tend to SSH into them from the
laptop.
Anyway, I need to access the occasional USB pendrive etc on the
laptop and copy files from the nfs share /media.
The problem is that the automount system, whatever it is on this
install, prefers to use /media as it's base level mount point for
removable devices. They won't mount unless I umount /media first.
That's a bit of a problemwhen the file I want to transfer are on
/media ;-)
Rather than change my entire network or have to use a different mount
point for the NFS shares on this one PC, is there any way to change
the behaviour so that Xubuntu default to, for example, /mnt or
something else of my choosing?
I suspect that it isn't xubuntu specific but rather built into the
underlying generic ubuntu stuff.
Post by DaveG
Googling around hasn't generated any useful results as yet. Most
seem to have no info on how the default automount system works.
Other results talk about files or automount systems which are not on
the default install. Rather than installing new software which may
or may nor conflict with the existing system, I'd much, much rather
just change a bit of text in an existing config file if someone can
point me at it.
I'll ask on the xubuntu and xfce mailing lists to see if anyone there knows.
... and the answer is that it's Udev that does it.
Take a look at:-
http://www.tuxradar.com/answers/526
Ta for that. From the text at the end of the answer, I'll bet it's using
pmount rather than mount.

"This uses pmount instead of mount, which is more sophisticated and is
used by most automounters. One of its advantages is that it only needs the
device node as an argument, and creates the mount point in /media
automatically."

So, it's probably the behaviour of pmount I need to change rather than a
udev rule.

Nope, just checked "The program 'pmount' is currently not installed." so
back to udev.

Having wandered through the udev stuff now, I think I'll just stick with
the fstab workaround I did. I still can't find anything in the udev rules
which might put removable disks into /media by default despite grepping
through all of /lib/udev/rules.d and I'm not too fussed about creating a
custom rule for a one off problem on a one off pc.

Thanks for the help
--
Dave
Beauty is in the eye of the beerholder
Loading...