Arch Linux

Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines

Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!
Tasklist

FS#6032 - rc.shutdown kills mount.ntfs-fuse instead of unmounting

Attached to Project: Arch Linux
Opened by Philip Nilsson (leffe) - Monday, 18 December 2006, 20:28 GMT
Last edited by Roman Kyrylych (Romashka) - Saturday, 12 May 2007, 13:13 GMT
Task Type Bug Report
Category System
Status Closed
Assigned To Thomas Bächler (brain0)
Architecture not specified
Severity High
Priority Normal
Reported Version 0.7.2 Gimmick
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

I quote:

Volume is scheduled for check.
Please boot into Windows TWICE, or use the 'force' option.
NOTE: If you had not scheduled check and last time accessed this volume
using ntfsmount and shutdown system properly, then init scripts in your
distribution are broken. Please report to your distribution developers
(NOT to us!) that init scripts kill ntfsmount or mount.ntfs-fuse during
shutdown instead of proper umount.
-- ntfsprogs/utils.c

I am afraid I cannot think of a good way of not killing certain processes. I will investigate to see what other distributions have done (if anything).
This task depends upon

Closed by  Roman Kyrylych (Romashka)
Saturday, 12 May 2007, 13:13 GMT
Reason for closing:  Fixed
Comment by Philip Nilsson (leffe) - Monday, 18 December 2006, 21:10 GMT
Gentoo remounts all filesystems read-only, while killing processes at the same time. (FUSE doesn't support the remount option though) I tried a workaround, which requires quite a lot of reordering in the rc.shutdown script. It works, but spews quite some messages. Also, it doesn't care about the fact that some processes being killed might want to write data somewhere.

for i in $(cat /proc/mounts | grep ^/dev/.d. | cut -f 1 -d ' ')
do
mount -n -o remount,ro $i || umount -n $i
done

The Gentoo solution is complex, and available here:
% wget -O - http://dev.gentoo.org/~uberlord/baselayout/baselayout-1.13.0_alpha9.tar.bz2 | tar xjf - sh/rc-services.sh init.d/halt.sh
Comment by Thomas Bächler (brain0) - Tuesday, 19 December 2006, 00:27 GMT
Until I can think of a good fix, please umount your ntfs volume in /etc/rc.local.shutdown (create the file if it doesn't exist, begin it with #!/bin/sh as any shell script and make it executable).
Comment by Attila (attila) - Tuesday, 19 December 2006, 14:30 GMT
Thanks for the hint about rc.local.shutdown. Perhaps it will be a good idea to include this file in the same way as rc.local in the initscripts package. Better will be that the file includes a comment about unmounting fuse mounts at this place.

A second candidat for rc.local.shutdown could be this removing of the psmouse module because for me this is a custom and not a system wide variable. So good it could be for laptops in my case with this line the light of my optical mouse is even on after shutdown the pc. So i even have to comment out this line which is not bad but handling such custom things in the same way as with rc.local would be more logical. But if nobody else have this problem forget the second paragraph.
Comment by Roman Kyrylych (Romashka) - Tuesday, 19 December 2006, 15:34 GMT
I agree. Having rc.local.shutdown (no matter empty or prefilled with some (commented, of course) most used commands) will be useful. Because now most users even don't know about the possibility to use rc.local.shutdown.
Comment by Thomas Bächler (brain0) - Saturday, 10 February 2007, 10:23 GMT
Guys, try this:
Edit /etc/rc.d/netfs, there is this line:
umount -a -t nfs,smbfs,codafs,cifs,shfs,fuse
change it to
umount -a -t nfs,smbfs,codafs,cifs,shfs,fuse,fuseblk
Don't forget to add the netfs DAEMON in rc.conf. See if that umounts ntfs-3g early.
Comment by Dimos Dimoulis (dimosd) - Friday, 11 May 2007, 18:24 GMT
Can we get some information about the status of this bug? The FUSE package doesn't contain an rc.d script right now. If a workaround is needed, is it recommended to umount in rc.local.shutdown?
Comment by Dimos Dimoulis (dimosd) - Friday, 11 May 2007, 19:08 GMT
I have "umount -a -t fuseblk" in rc.local.shutdown to be on the safe side, maybe the above change should go to rc.d/netfs
Comment by Roman Kyrylych (Romashka) - Saturday, 12 May 2007, 13:13 GMT
Fixed in initscripts-0.8-9 by adding fuseblk support to rc.sysinit and netfs.
Mounting/umounting of these filesystems are hadnled by netfs initscript:
nfs,smbfs,codafs,cifs,shfs,fuse,fuseblk

Loading...