Just copy & past the patch source code from above into your favorite editor and save it as "usbmount-ntfs3g.patch". Now transfer the file to your LS. After this, apply the patch as user root issuing the command <pre>patch /usr/share/usbmount/usbmount <path>/usbmount-ntfs3g.patch</pre>Thats it!

Latest revision as of 11:31, 11 November 2007

Contents

Description

Requirements

Kernnel 2.6 and above. However, I have also had this working on 2.4.20

Installation and configuration

To install, under Debian distribution, type:

apt-get install udev

This also requires the legacy hotplug but this is slowly being removed.

udev establishes a directory /etc/udev. Within this are the configration files and rules for udev. The configuration file udev.conf can be left as installed. The rules (udev.rules and directory rules.d) will be left to the user to edit depending on the devices being used. The rules detail what is to happen on detection of certain hardware types. Descriptions can use manufacturers names or device code, pretty much anything really and wild cards can also be used. This can then indicate what kernel modules are required, permissions and launched scripts.

Another directory, /etc/dev.d is also created. This contains directorys pertaining to the type of device, say block for a scsi based device. This directory contains a file (extension of .dev) which is the script that is auto run on detection of the device. This script will perform actions depending on if the device has been 'added' or 'removed'.

Example uses

For 'hotplug' USB devices, install usbmount:

apt-get install usbmount

This installs a udev script at /etc/dev.d/block/usbmount.dev and also a bash script in /usr/sbin. A configuration file is used to determine where the media is to be mounted, defaults to /media/usb1..9. udev will auto-detect the drive and the usbmount script will mount each detected partition at /media/usb1, /media/usb2, ... On removal, the drive will be un-mounted and the device node removed.

The current version of usbmount does not support NTFS-3G. It will always use the kernel NTFS driver that has some drawbacks writing to NTFS volumes.

Applying the following patch to usbmount allows you to specify a new configuration variable USE_NTFS3G in /etc/usbmount/usbmount.conf. If this variable is set to "yes", then usbmount will utilize NTFS-3G instead of the kernel mode NTFS driver.

Just copy & past the patch source code from above into your favorite editor and save it as "usbmount-ntfs3g.patch". Now transfer the file to your LS. After this, apply the patch as user root issuing the command