# [SOLVED] External drives not mounting

## deathcon1

So, last night I backed up my entire drive using tar, played with my partitions a bit (EFI was not happy about having 5x "partitions" even though there were only 4x and I had 128mb of space between SDA2 and SDA3, so it had to be fixed, but the space needed to goto SDA4.)  So, fix the partitions, restore the tarball, everythings working good except I can no longer mount my external drives (I'm writing this from my laptop.)  I've tried watching 'messages' and 'dmesg' when plugging the drives in, but I can't see anything wrong.  Tried reinstall gnome-mount, udev, and hal but those didn't fix it either.  The drives are NTFS, but so is SDA4 which mounts perfectly with full read/write.  

Plugging in:

```

tail -f /var/log/messages

Mar 21 18:12:25 Stalker usb 2-1: new high speed USB device using ehci_hcd and address 6

Mar 21 18:12:25 Stalker usb 2-1: configuration #1 chosen from 1 choice

Mar 21 18:12:25 Stalker scsi5 : SCSI emulation for USB Mass Storage devices

Mar 21 18:12:25 Stalker usb-storage: device found at 6

Mar 21 18:12:25 Stalker usb-storage: waiting for device to settle before scanning

Mar 21 18:12:25 Stalker NetworkManager: <debug> [1206137545.502725] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_152d_2339_DC07629155FF').

Mar 21 18:12:25 Stalker NetworkManager: <debug> [1206137545.551880] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_152d_2339_DC07629155FF_if0').

Mar 21 18:12:30 Stalker scsi 5:0:0:0: Direct-Access     WDC WD16 00BEVS-22UST0         PQ: 0 ANSI: 2 CCS

Mar 21 18:12:30 Stalker sd 5:0:0:0: [sdb] 312581808 512-byte hardware sectors (160042 MB)

Mar 21 18:12:30 Stalker sd 5:0:0:0: [sdb] Write Protect is off

Mar 21 18:12:30 Stalker sd 5:0:0:0: [sdb] Mode Sense: 00 38 00 00

Mar 21 18:12:30 Stalker sd 5:0:0:0: [sdb] Assuming drive cache: write through

Mar 21 18:12:30 Stalker sd 5:0:0:0: [sdb] 312581808 512-byte hardware sectors (160042 MB)

Mar 21 18:12:30 Stalker sd 5:0:0:0: [sdb] Write Protect is off

Mar 21 18:12:30 Stalker sd 5:0:0:0: [sdb] Mode Sense: 00 38 00 00

Mar 21 18:12:30 Stalker sd 5:0:0:0: [sdb] Assuming drive cache: write through

Mar 21 18:12:30 Stalker NetworkManager: <debug> [1206137550.545812] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_152d_2339_DC07629155FF_if0_scsi_host').

Mar 21 18:12:30 Stalker NetworkManager: <debug> [1206137550.547035] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_152d_2339_DC07629155FF_if0_scsi_host_scsi_device_lun0').

Mar 21 18:12:30 Stalker sdb: sdb1

Mar 21 18:12:30 Stalker sd 5:0:0:0: [sdb] Attached SCSI disk

Mar 21 18:12:30 Stalker sd 5:0:0:0: Attached scsi generic sg2 type 0

Mar 21 18:12:30 Stalker usb-storage: device scan complete

Mar 21 18:12:30 Stalker NetworkManager: <debug> [1206137550.562891] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/usb_device_152d_2339_DC07629155FF_if0_scsi_host_scsi_device_lun0_scsi_generic').

Mar 21 18:12:30 Stalker NetworkManager: <debug> [1206137550.622678] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/storage_serial_WDC_WD16_00BEVS_22UST0_DC07629155FF_0_0').

Mar 21 18:12:30 Stalker NetworkManager: <debug> [1206137550.738694] nm_hal_device_added(): New device added (hal udi is '/org/freedesktop/Hal/devices/volume_uuid_04F06475F0646F3C').

```

```

dmesg

usb 2-1: new high speed USB device using ehci_hcd and address 6

usb 2-1: configuration #1 chosen from 1 choice

scsi5 : SCSI emulation for USB Mass Storage devices

usb-storage: device found at 6

usb-storage: waiting for device to settle before scanning

scsi 5:0:0:0: Direct-Access     WDC WD16 00BEVS-22UST0         PQ: 0 ANSI: 2 CCS

sd 5:0:0:0: [sdb] 312581808 512-byte hardware sectors (160042 MB)

sd 5:0:0:0: [sdb] Write Protect is off

sd 5:0:0:0: [sdb] Mode Sense: 00 38 00 00

sd 5:0:0:0: [sdb] Assuming drive cache: write through

sd 5:0:0:0: [sdb] 312581808 512-byte hardware sectors (160042 MB)

sd 5:0:0:0: [sdb] Write Protect is off

sd 5:0:0:0: [sdb] Mode Sense: 00 38 00 00

sd 5:0:0:0: [sdb] Assuming drive cache: write through

 sdb: sdb1

sd 5:0:0:0: [sdb] Attached SCSI disk

sd 5:0:0:0: Attached scsi generic sg2 type 0

usb-storage: device scan complete
```

Ideas?Last edited by deathcon1 on Sun May 04, 2008 4:54 pm; edited 1 time in total

----------

## guruvan

what is the box's response if you use the mount command on the command line?

these are mounted via the ntfs driver? ntfs-3g? 

My first guess is there are errors on the ntfs partitions; you'll have to have windows chkdsk /f them. Since you said "fix the partitions" I'd bet that these are not marked clean. 

(unless there's new toys I don't know about)

----------

## coolsnowmen

 *guruvan wrote:*   

> 
> 
> My first guess is there are errors on the ntfs partitions; you'll have to have windows chkdsk /f them. Since you said "fix the partitions" I'd bet that these are not marked clean. 

 

he said fix the partitions on his /dev/sda (primary) disk and now his sdb doesn't mount

@deathcon1

do you see partitions? as in

does fdisk -l return anything about the drives after the've been plugged in and settled (10 seconds?)

Can usb sticks be mounted?

----------

## deathcon1

Both drives have been mounted and written to/read from in both OS X and Windows XP, so I'm farily certain that the FS itself is intact.  I can see the partitions using fdisk -l (as you can see here).  

```
fdisk -l

WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted.

Disk /dev/sda: 160.0 GB, 160041885696 bytes

255 heads, 63 sectors/track, 19457 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Disk identifier: 0x2a562a55

   Device Boot      Start         End      Blocks   Id  System

/dev/sda1               1          26      204819+  ee  EFI GPT

Partition 1 does not end on cylinder boundary.

/dev/sda2              26       11576    92772760   af  Unknown

Partition 2 does not end on cylinder boundary.

/dev/sda3   *       11576       14202    21099985   83  Linux

/dev/sda4           14203       19457    42210787+   7  HPFS/NTFS

Disk /dev/sdb: 160.0 GB, 160041885696 bytes

255 heads, 63 sectors/track, 19457 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Disk identifier: 0x470fcb52

   Device Boot      Start         End      Blocks   Id  System

/dev/sdb1   *           1       19457   156288321    7  HPFS/NTFS

Disk /dev/sdc: 250.0 GB, 250059350016 bytes

255 heads, 63 sectors/track, 30401 cylinders

Units = cylinders of 16065 * 512 = 8225280 bytes

Disk identifier: 0xf9d1200b

   Device Boot      Start         End      Blocks   Id  System

/dev/sdc1   *           1       30400   244187968+   7  HPFS/NTFS

```

----------

## coolsnowmen

 *guruvan wrote:*   

> what is the box's response if you use the mount command on the command line?
> 
> these are mounted via the ntfs driver? ntfs-3g? 

 

And to your other helper's question?

----------

## deathcon1

Just tested, turns out the ntfs3g driver in portage is taking Good Friday off, so I'm compiling the in-kernel one right now see if it'll accept the holiday pay.

Edit: Well, with ntfs built into the kernel I no longer mount my windows partition, same story with the externals.  Switching back to the userland ntfs driver so I can at least mount my local windows partition.

----------

## guruvan

what ntfs options are set in your kernel? 

do you get any errors in /var/log/messages when you try to mount the partitions?

these aren't VISTA ntfs partitions? (just to be sure.....) 

do you need a file from my repo to get ntfs3g running? (if you can't get something from the gentoo sites to get going, you can get one from me....I should have the distfiles you need)

----------

## deathcon1

Sorry for the delay in updates, Easter weekend, family, blah blah blah. 

So I believe these are Vista formatted NTFS partitions (I have my reasons for using Vista, as unfortunate as it is). 

As to settings in the kernel they are: (copy/pasted right out of menuconfig).

```
 

  │ │    <*> MSDOS fs support                                            

  │ │    <*> VFAT (Windows-95) fs support                               

  │ │    (437) Default codepage for FAT                                   

  │ │    (iso8859-1) Default iocharset for FAT                             

  │ │    <*> NTFS file system support                               

  │ │    [ ]   NTFS debugging support  

  │ │    [*]   NTFS write support   
```

Edit: No, no errors reported in messages or dmesg.

----------

## NeddySeagoon

bercik,

Vista does not use MSDOS partition tables.

For the kernel to see Vista made partitiond you need gpt support.

Do not use fdisk to modify a gpt partition table as fdisk cannot read it properly.

----------

## deathcon1

Solved the issue.  Turns out if you install GParted it will cause HAL to ignore USB devices

```
rm /usr/share/hal/fdi/policy/gparted-disable-automount.fdi 
```

fixed the problem for me.

----------

