You are here
Hale - Wed, 2013/06/19 - 13:08
Somehow Automount in fileserver doesn't work, despite it is listed as a feature.
How can I fix it?
I need CD and USB drives to be automounted to SAMBA. The appliance is running under VirtualBox for Windows (x64).
Forum:
Tags:
The strange thing is there is
The strange thing is there is udevd running, but do nothing.
Seems like automount is disabled by default and no manual tells how to enable it back!
People, please, help!
It, actually does't automount VBOX shares the same. FSTAB doesn't work because it is processed too soon to see VBOX shares, UDEV doesn't work.
:(
I'm not sure what you want to do
Sorry, but I am missing something.
What, exactly, do you want to do?
Fileserver: It is said that
Fileserver:
I want CD support. USB flash drives support, if possible (seems it is the same as CD for UDEV)
It is said that CD Automount is supported for Fileserver.
cdrom share is present by default in preconfigured Samba
It is obvious that I want Automount to function. I.e.:
- create /media/cdrom on CD insert HAL event
- mount /media/cdrom or /media/cdrom/{volume_name} the same time.
- unmount and delete the folder on removal HAL event.
There is everything needed in the TKL, but configuration is broken. I can't figure out how to fix UDEV configs to mount CDROM and USB drives.
I didn't think it was obvious....
automount is also used to automatically mount shares from remote servers, so I was just trying to confirm what you wanted to do.
Thank you for that.
I tried it on an older version of TKL fileserver (all that I have available at the moment) and saw the same behaviour (the CD not autmounting). I also noticed that the autofs package was not installed on my system, which might be a clue as to why it's not working.
If you find the solution, please post back as I am sure it will help others.
do you have experience with
do you have experience with udev? it seems, it should be enough to automount CDs...it works well on archlinux and a couple of others. but something is wrong there, in TKL.
I have successfully had VBox shares automounting...
Although unfortunately I don't recall the exact steps. I got all the info on how to do it via google though...
I'm not sure about it being mentioned as a feature anywhere because as far as I know TKL doesn't have automount configured by default (and rightly so IMO) but it should be pretty straight forward...
If you keep in mind that the current TKL v12.x is based on Debian 6/Squeeze, a google such as "automount cd samba debian squeeze" serves up a number of results that look like they'd be useful. I think you'll also need to investigate
Bottom line is that it seems to me that you are having a few separate issues. Whilst they are sort of interrelated, addressing them one at a time is the way to go IMO.
please see previous
please see previous comment.
It is not just TKL, but a Fileserver appliance with /media present and CDROM share created by default.
udev is running by default, but some hot head blocked the support for automount.
Oh ok, didn't realise your problem was with CDROM...
I thought you were complaining about USB not automounting (which AFAIK is not configured in any TKL appliances...)
I haven't ever tested that feature so I won't deny that it's a possibly a bug, but I doubt very much that it was caused by "some hot head". Assuming that you are using the v12.1 release (which only just came out) then perhaps it is a regression?
The other thing that springs to mind is the question of whether you have VBox tools installed? TBH I don't know if that's a requirement but I'd be inclined to install them and see if it helps. Also have you made sure that you have the CDROM passing through correctly to the VM? Can you mount it ok manually?
"The other thing that springs
"The other thing that springs to mind is the question of whether you have VBox tools installed?"
I have. Do you think the've damaged udev?
Actually, I mount the host's NTFS volume through VBOX to use it with SAMBA. It is just easier to manage contents this way.
I tried to pass CDROM and to mount images.
My experience tells that it should generate the same insertion events in Ubuntu and Windows guests.
Yes, I can mount CD's manually from /dev/sr0 and /dev/sda1.
I wouldn't think that it would've broken udev
But TBH I have no idea... I have never run TKL servers on hardware nor used automount with the Fileserver so I have no idea whether this behaviour is limited to running inside VBox or whether it is just totally broken (regardless of where it is running...)
I vaguely recall needing to install VBox tools to get host shares auto mounting at boot...
I do know that to automount USBs you need to install AutoFS (or similar - as suggested above by Eric). Seeing as you also have stated that you desire USB automounting (and auto sharing) then perhaps it's worth installing now anyway and see if that also helps with CD automount? I'm not sure on the best practice for auto-sharing USBs though...
that startup mount doesn't
that startup mount doesn't work either (I don't know why people call it auto, because it is not automatic)...the fstab is processed earlier than tools module. so I mount it in the startup script.
Do you mean VBox shared folder?
If so then that definately did work (I had it working fine with v12.0 on a VBox (forget which version) install I did some time ago... I wrote this tutorial as I did it... Although IIRC there is a step missing towards the end as by default only root has access when mounted with fstab).
If VBox auto mount of shared folders at boot (shared on your host via VBox) isn't working then either you have made some mistake or there is a regression somewhere (perhaps in TKL v12.1 or the version of VBox itself or the version of Vbox tools you've used...).
Sorry, I didn't understand
Sorry, I didn't understand the Idea you are talking about...
I have:
turnkey-fileserver-12.0-squeeze-x86-vmdk
uname -r 2.6.32-5-686
VirtualBox 4.2.12 build r84980
host: win7 x64
vbox tools installed according to the VBOX help (updates and dkms are according manual)
both, VBOX shares and CD can be mounted manually via mount.
VBOX can't be mounted during boot. According to google this is a common problem caused by late process of tools/share. I mount it as a last directive in the boot script.
CD doesn't automount, i.e. automatically upon disk insertion.
/etc/udev/rules.d .rules for CD (concearning sr0 and sda1 devices) are not processed uppon disk insertion
udevadm monitor doesn't produce any output to console uppon disk insertion.
tried this script, doesn't
tried this script, doesn't work.
devices to mount are correct, /dev/sr0 = /dev/sda1
But nothing happens when inserting disk.
It's like udev is permanently disabled, or all events are filtered out, I don't know...
/etc/udev/rules.d/10-cdrom.rules
KERNEL!="sr[0-9]*", GOTO="disc_by_label_auto_mount_end"
# Get label
ACTION=="add", PROGRAM=="/sbin/blkid -o value -s LABEL %E{device}", ENV{dir_name}="%c"
ACTION=="add", RUN+="/bin/mkdir -p '/media/%E{dir_name}'", RUN+="/bin/mount -t auto -o %E{mount_options} /dev/%k '/media/%E{dir_name}'"
ACTION=="remove", RUN+="/bin/umount -l '/media/%E{dir_name}'", RUN+="/bin/rmdir '/media/%E{dir_name}'"
LABEL="disc_by_label_auto_mount_end"
Are you running in VBox too?
Out of interest, is acpi-support installed?
Not acpid - acpi-support
So yes a package called 'acpi-support'. TBH I don't know a lot about it, but acording to what I have read it supports "a range of hardware events" and I thought perhaps telling the OS that a CD has been inserted may be one of those hardware events... IDK but it may be worth a shot...!?
Also FWIW you do need it installed (or at least 'acpi-support-base') to get a VBox VM to shutdown cleanly.
... does it mean udev is
... does it mean udev is broken in TKL?
Can fixing it be set as a goal of the future releases?
I'm not sure why it doesn't work
And I'm not going to speculate on what it imay be (I don't know enough).... But I have lodged an issue (bug report) on the TKL Dev Tracker (https://github.com/turnkeylinux/tracker/issues/43)
Are there any changes in TKL
Are there any changes in TKL 13 ?
Add new comment