# Automounting eSATA external hard drive with ivman

## Zavior

Before I get into my problem just wanted to say I've just started with gentoo this past week and I'm loving it!

Anyway, on to the problem. I'm trying to get any combination of programs to automount my external SATA drive. I followed the guide I found here:

http://www.xaprb.com/blog/2006/05/20/how-to-auto-mount-removable-devices-in-gnulinux/

After following the guide and installing ivman and adding it to bashrc the drive still does not automount. On top of this not working when I mount the drive manually I cannot access it from a user account I can only access it from root. I've even tried adding the 'user' option in fstab and doing mount -a. 

Here's my fstab as I have it at the moment, the external drive comes in as sde

```
/dev/sdd1    /boot       ext2   defaults     1 2

/dev/sdd2    none        swap   sw           0 0

/dev/sdd3    /           ext4   noatime      0 1

/dev/cdrom   /mnt/cdrom  auto   noauto,user  0 0

/dev/sde1    /mnt/ehdd   ntfs   user         0 0
```

Any help would be greatly appreciated. Thanks!

----------

## Martux

I cannot help you with the issue. I gave up on this and put an alias in my .bashrc to mount my ESATA drive.

But you´ll probably have to put users in /etc/fstab to work.

----------

## Zavior

Thanks! I feel dumb about the users. Man. I even looked at everything else to make sure there was no typos. That's like 90% of all linux config problems; typos. I'll try it in a bit and post if that fixes the user problem. That will hopefully make my drive useful in the meantime if not 100% convenient.

----------

## Martux

He, no problem. You are right, typos suck   :Laughing: 

Why do you think I have so many posts? Not because I am überleet or what, but for asking many sometimes dumb questions.

That´s what a forum is for, right?

Please tell if you really manage to get esata to automount with this, and how exactly.

Thanks,

Marcus

----------

## Zavior

Strange. That didn't fix it. And actually in reading the man page for mount, it seems the user option is only to allow users to mount and unmount filesystems, it shouldn't actually effect permission to access it.

----------

## kingc

True about the "user" mount option.

When you mount filesystems as ntfs, the permissions are such that normal users cannot access them - only root. You can just alter the default permissions, e.g.:

```

/dev/sde1    /mnt/ehdd   ntfs   user,umask=000         0 0

```

If you search a bit, you'll find quite a few options in terms of setting user (umask/uid) and group (gmask/gid) permissions. Try searching on "ntfs umask" and see what you get.

Consider installing ntfs3g and letting your desktop environment mount the drive automatically (you'll probably also need to remove or comment the /dev/sde1 line in fstab for this to work - otherwise it will not be treated similarly to a removable device).

----------

## Zavior

Ok, I'll look into umask. The problem with letting my desktop environment auto mount for me is that I set up my own custom DE, using compiz-fusion, PCManFM, and lxbar. At the moment though I've broken xorg somehow when I recompiled it adding the "hal" use option. I'm probably going to be reinstalling gentoo on a new hard drive now that I've had a once through and have a better idea of what I'm doing. I'm going to make sure to compile the kernel with FUSE and ntfs. Is there a way to do ntfs3g instead of just ntfs or is that done in packages outside of the kernel? Also is there anything else obvious that I could be missing in the kernel compile that could help me out with this?

----------

## Martux

For ntfs-3g: simply emerge it and make sure you have fuse support in the kernel. For xorg & hal: If you want to keep the old input section in your xorg.conf, just emerge xorg without the hal flag. Or take a look here: https://forums.gentoo.org/viewtopic-t-722498.html

Personally I made the change with just evdev (needs to be in the kernel), but had a hard time.

----------

## Zavior

 *Martux wrote:*   

> For ntfs-3g: simply emerge it and make sure you have fuse support in the kernel. For xorg & hal: If you want to keep the old input section in your xorg.conf, just emerge xorg without the hal flag. Or take a look here: https://forums.gentoo.org/viewtopic-t-722498.html
> 
> Personally I made the change with just evdev (needs to be in the kernel), but had a hard time.

 

Thanks! That link did the trick as far as fixing the xorg/hal issues. Xorg is now booting. I'm still working on getting the drive to automount I'll let you know how that goes...

EDIT: I reinstalled gentoo on a new drive for several different reasons and ended up going with KDE 4.2 for my DE. I am now able to mount my drive manually and access it with regular users. NTFS-3G is what enabled me to do this. I am still working on automounting. KDE is not at the moment mounting my drive for me. I have emerged hal and dbus, and added them both to my default startup.

----------

