# Installation does not detect hard disk



## aidin36 (May 11, 2012)

I downloaded the FreeBSD-9.0-RELEASE-amd64-memstick.img and wrote it on a 8GB flash disk with dd.

It booted successfully. But when it comes to partitioning the hard dis*k*, it only detects one hard disk: the flash disk, as /dev/da0

I*'ve* done these things:

Using "Shell" command instead of "Install", I found out that there's only /dev/da0, and no other disks.
I changed my "On board SATA mode" from "AHCI" to "IDE". No new result.
I disabled ACPI boot option, but I faced this error at the boot time:

```
panic: No usable event timer found!
```


Some other info:

At the boot time, it write*s* these lines:

```
BIOS Drive C: is Disk 0
BIOS Drive D: is Disk 1
```

My mainboard is "Elite Group A740GM-M"

Any idea?
Thanks in advance.


----------



## JakkFrosted (May 12, 2012)

Because you're using a bootable release, the disks in your system are not mounted. If you explore the /dev directory you will see your disks and other devices. You need to mount the disks in order to access them. It may appear as sda0 or hda0, etc. Try [CMD="fdisk"] sda0[/CMD] (or w/e your disk device name is) and if will display info about it that will help you to determine which disk it actually is. Then to mount just run the command [CMD="mount"] /dev/sda0 /mnt/whateverdrivenameyouwant[/CMD]. Note that the directory must first exist for you to mount onto it. In order to mount sda0 to /mnt/mydrivename, the directory _mydrivename_ must first be created.


----------



## JakkFrosted (May 12, 2012)

*Edit:*

Uhg. I can't edit my posts yet. I replied too hastily. I see you mean they aren't even showing in /dev. Try [CMD="pciconf"]-lv[/CMD] and determine what your disk controller is. Then enable the correct module in the /boot/loader.conf file. Reboot and if you enabled the correct module the disks should be present.


----------



## aidin36 (May 12, 2012)

I found out that I have a SB7x0/SB8x0/SB9x0 SATA Controller

Because the flash disk was mounted as Readonly filesystem, I couldn't edit /boot/loader.conf

So I've done this:
On the boot menu, I pressed ESC, then:

```
load ataati
enable-module ataati
boot
```

I also try ataahci, and both together. Nothing changed.

But I think that I found out the problem.
On my dmesg I found these lines:

```
ahcich1: Time out on slot 0 port 0
ahcich1: is 00000002 cs 00000000 ss 00000000 rs 00000001 tfd 50 serr 00000000 cmd 00046017

ahcich0: Time out on slot 0 port 0
ahcich0: is 00000002 cs 00000000 ss 00000000 rs 00000001 tfd 50 serr 00000000 cmd 00046017
```


----------



## aidin36 (May 12, 2012)

If it helps, this is the output of the lshw command which I run on my Linux Mint on the same machine.


----------



## JakkFrosted (May 12, 2012)

Maybe try the disks with RAID mode enabled in the bios.


----------



## aidin36 (May 13, 2012)

Thank you Jesse.

I tried RAID too. But still the same result.
I'm going to download FreeBSD-9.0-RELEASE-amd64-disc1.iso and see if it works.


----------



## aidin36 (May 14, 2012)

I tried the disk1.iso.

I still get the same time-out error at the boot time. In addition, the following error happens when it tries to mount root:


```
mounting from cd9660:/dev/iso9660/FREEBSD_INSTALL Failed with error 19
```

And it falls into mountroot. When I type *?*, it says:


```
list of GEDM managed disk devices:
```

And the list is empty.


----------



## xeemo (May 14, 2012)

I'm having I believe this same problem.  All installation media greater than 8.2 don't detect the SATA drives on my desktop.


----------



## cucu007 (May 22, 2012)

Downloaded 9-RELEASE and having same issues as many of you, any solutions to this?


----------



## jb_fvwm2 (May 23, 2012)

Slight chance this is due to the following drivers not loaded.
geom_mbr.ko; geom_bsd.ko; geom_label.ko. (A while back a good number of threads mentioned those...)


----------



## pranavrana (Jun 3, 2012)

I recently downloaded 'PCBSD-9.img' and faced the same problem of my SATA hard disk not being detected by the setup. Maybe there was a problem with the hard disk not being mounted. I made a little change in my BIOS which is to 'enable' the following options:

AHCI Mode
Wake on LAN
Intel R Speedstep Tech
I don't know which one of these actually did the trick, but after this my HDD was being detected and I am posting this message form my PC-BSD installation.

PCBSD is based on FreeBSD, this trick may work for FreeBSD as well.

PS: I think 'AHCI Mode' is the one.

Hope this helps.


----------



## DeliciousD (Apr 29, 2016)

For what it's worth, I discovered that the predecessor chipset (SB600) to the A740GM-M (SB700) had a problem with Message Signaled Interrupts according to PR 174985. Suspecting the same condition was preventing the 10.3-RELEASE installation medium from detecting the SATA disks, I set the loader driver hint variable for ahci(4) to disable msi `set hint.ahci.0.msi=0`. The result is that the disks are detected and available when the system boots.

The drive is not mountable, however. `gpart show` will detect the USB attached drives, but the internal one /dev/ada0 appears as a raw disk even though it has `gpart` partitions and a full 8.4-STABLE installation.

At the moment I have no more time to experiment with the installing the upgrade. I'll try to remember to post results, but make no promises.


----------



## DeliciousD (May 2, 2016)

I have solved the mystery of the inaccessible /dev/ada0. The disk contained old graid(8) data as detailed in the handbook section "18.5 Software RAID Devices". On boot I noticed errors from graid(8) and using `graid list -a` saw the disk had been identified as a member of a stripe set and the status set to spare. Unfortunately for me, the procedure for clearing this documented in the handbook was unsuccessful. I tried using dd to overwrite the first 10MB of the disk and it is still saying it is part of a stripe set. The workaround is to disable RAID in the kernel.

The RAID stripe setting on the disk may have come from the motherboard's on board RAID array tool which I used before. The volume showed up in the MB raid utility, and I deleted it, but FreeBSD still sees the data on the disk and tries to use it as a member of a stripe set.

Summary

To install FreeBSD 10.3 on my Elite Group A740GM-M v7.0 motherboard, it was necessary at boot to choose the loader prompt and disable MSI in the ahci(4) driver.
`set hint.ahci.X.msi=0`
("X" is the bus number, in my case 0.)

Then, if the disk is generating GRAID errors on boot and you are unable to write to the disk (and your disk is not meant to be part of a RAID array) follow the handbook procedures noted above.

After installation, add `hint.ahci.X.msi=0` to /boot/device.hints. If your disk is stubborn about not identifying itself as a member of a non-existent RAID set, add `kern.geom.raid.enable=0` to /boot/loader.conf


----------

