|
发表于 2008-3-30 03:05:24
|
显示全部楼层
Post by caijc;1832109
我用了。是根据论坛里的帖子改的:10-myudev.rules
KERNEL=="sd[b-z]", NAME="%k", SYMLINK+="DISK-%k", GROUP="users", OPTIONS="last_rule"
ACTION=="add", KERNEL=="sd[b-z][0-9]", SYMLINK+="DISK-%k", GROUP="users", NAME="%k"
ACTION=="add", KERNEL=="sd[b-z][0-9]", RUN+="/bin/mkdir -p /media/DISK-%k"
ACTION=="add", KERNEL=="sd[b-z][0-9]", PROGRAM=="/lib/udev/vol_id -t %N", RESULT=="vfat", RUN+="/bin/mount -t vfat -o rw,utf8=true,codepage=936,noauto,flush,quiet,nodev,nosuid,noexec,noatime,users,dmask=000,fmask=111 /dev/%k /media/DISK-%k",OPTIONS="last_rule"
ACTION=="add", KERNEL=="sd[b-z][0-9]", RUN+="/bin/mount -t auto -o rw,locale=zh_CN.UTF-8,noauto,sync,dirsync,noexec,nodev,noatime,users /dev/%k /media/DISK-%k", OPTIONS="last_rule"
ACTION=="remove", KERNEL=="sd[b-z][0-9]", RUN+="/bin/umount -l /media/DISK-%k"
ACTION=="remove", KERNEL=="sd[b-z][0-9]", RUN+="/bin/rm -rf /media/DISK-%k", OPTIONS="last_rule"
不仅如此,好像还无法删除U盘中中文名目录,说文件系统只读(忘了中文目录是Win
下创建的还是arch下创建的,反正用utf8能看,但无法删除它和其下的中文子目录。)。英文文件名能删除。
我也用的这个,中英文目录都能正常创建删除,但是就是一点,点右键选卸载卷时,弹出窗口“The volume "1G Removable Volume" was probably mounted manually on the command line”
只能用命令行卸载,有点不爽 |
|