Check autofs(5)! It's usable in 10.1.My question is: Why the automount is on ports and not included into FreeBSD?
Check autofs(5)! It's usable in 10.1.My question is: Why the automount is on ports and not included into FreeBSD?
How to use/configure it to have a USB pendrive automounting like with sysutils/automount?Check autofs()! It's usable in 10.1.
I didn't upgrade 10.0 to 10.1 yet, so I don't know details, sorry.How to use/configure it to have USB pendrive automounting like with sysutils/automount?
Hello,
I've been using automount 1.4.3 successfully for quite some time on FreeBSD 10.0-RELEASE, FreeBSD 9.3-RELEASE, and FreeBSD 9.2-RELEASE.
When FreeBSD 10.1-RELEASE was released this past week, I installed it on a second hard drive, and set[]up my standard desktop environment with Xfce to do some testing.
I installed automount using ports. I did not compile it with support for any of the special filesystems listed in the configuration options. I only use FAT (MSDOSFS) and UFS.
I made the appropriate changes to the /usr/local/etc/devd/automount_devd.conf file as shown in the thread above:
I also have modified the /usr/local/etc/automount.config file as follows:Code:notify 100 { match "system" "DEVFS"; match "type" "CREATE"; match "cdev" "(da|mmcsd)[0-9]+.*"; action "/usr/local/sbin/automount $cdev attach"; }; notify 100 { match "system" "DEVFS"; match "type" "DESTROY"; match "cdev" "(da|mmcsd)[0-9]+.*"; action "/usr/local/sbin/automount $cdev detach"; };
I use this same configuration on my FreeBSD 10.0-RELEASE machine as well.Code:USERUMOUNT=YES ATIME=NO REMOVEDIRS=YES FM="thunar" USER=jda ENCODING="en_US.ISO8859-1" CODEPAGE="cp437"
Using a USB memory stick that is formatted using the following commands (This works with my FreeBSD 10.0-RELEASE install with out any issue):
gpart destroy -F /dev/da0
gpart create -s mbr /dev/da0
gpart add -t \!12 /dev/da0
newfs_msdosfs -F32 /dev/da0s1
Gives me the following in the log file located in /var/log/automount.log when I insert the USB memory stick on my FreeBSD 10.1-RELEASE machine.
Any guesses as to what I may be doing wrong here?Code:2014-11-16 15:31:22 /dev/da0: attach 2014-11-16 15:31:22 /dev/da0: filesystem not supported or no filesystem 2014-11-16 15:31:22 /dev/da0s1: attach 2014-11-16 15:31:22 /dev/da0s1: filesystem not supported or no filesystem
Nope, no conflict.I was looking at this again today, and I noticed that the new autofs and associated utilities, that is now included with FreeBSD 10.1-RELEASE, has a system binary in /usr/sbin/ that is named automount. Does this by chance conflict with the script named automount that's installed by /usr/ports/sysutil/automount located in usr/local/sbin/?
2014-12-13 23:14:26 /dev/da0: random wait for '2,0' seconds before 'attach' action
2014-12-13 23:14:26 /dev/da0: attach
2014-12-13 23:14:27 /dev/da0: filesystem not supported or no filesystem
2014-12-13 23:14:27 /dev/da0s1: random wait for '1,0' seconds before 'attach' action
2014-12-13 23:14:27 /dev/da0s1: attach
2014-12-13 23:14:28 /dev/da0s1: filesystem not supported or no filesystem
2014-12-13 23:14:28 /dev/da1: random wait for '1,0' seconds before 'attach' action
2014-12-13 23:14:28 /dev/da1: attach
2014-12-13 23:14:28 /dev/da1: filesystem not supported or no filesystem
notify 100 {
match "system" "DEVFS";
match "type" "CREATE";
match "cdev" "(da|mmcsd)[0-9]+.*";
action "/usr/local/sbin/automount $cdev attach";
};
notify 100 {
match "system" "DEVFS";
match "type" "DESTROY";
match "cdev" "(da|mmcsd)[0-9]+.*";
action "/usr/local/sbin/automount $cdev detach";
};
USERUMOUNT=YES
ATIME=NO
REMOVEDIRS=YES
FM="xfe"
USER=vg
MNTPREFIX="/mnt/vg"
ENCODING="ru_RU.UTF-8"
CODEPAGE="cp866"
Yes. Both da0s1, and da1 are manually mounted without problems.Can you mount da0s1? ...
Have you carefully checked this post?Yes. Both da0s1, and da1 are manually mounted without problems.
vermaden, I appreciate you taking the time to create and offer a port for this. I've been using it for some time and it's been working great. Dziękuję!
I asked one of the FreeBSD Developers to update the port but no luck.I noticed on the GitHub page you linked to in one of your posts, you have a tarball for a version 1.5(?) vs version 1.43 in the ports tree. Did you have any plans on updating the port in the near future? It is working fine for me as is, but was only curious.
To make your program work on 10.1 I had to add-k
to Line 287 (v1.5). That is, I had to change
toCode:case $( file -b -L -s ${DEV} | sed -E 's/label:\ \".*\"//g' ) in
Code:case $( file -k -b -L -s ${DEV} | sed -E 's/label:\ \".*\"//g' ) in
Now it works like a charm
Last time I checked file(1) is not able to tell if there is ZFS pool on the device or not.I have one quick question, and maybe a feature idea. How about a ZPOOL on a stick? I find most USB devices to be pretty slow when used with the more traditional file systems but pretty fast when using larger blocks on them. That might speed things up a bit, but I do not want to run FAT with 128KB clusters...
zpool --import
could be run after the detection of a new storage device. Then, with the output being "0", the script would continue as it does without any ZFS awareness, otherwise switch to ZFS related commands.It's been some time now but doing this caused a hard panic and rebooted my system last time I unwittingly did this. It don't know if this is still the case today. I was using 10-STABLE at the time so it could of course just have been my setup.Is the problem in fact that zpool export -f POOL will not remove the hanging filesystem? In that case, this is bad luck indeed.