Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Hai

I bought a 1 TB new hard disk. When installed in linux it say's fsck.ext3 file system not found. when i checked the BIOS it detected the hard disk. what to do to solve the problem in linux?.

Thank you

share|improve this question
    
Just to make things clear, this is a newly bought hard disk, on which noone has created any partitions or file systems? –  andol Dec 5 '09 at 9:35
    
No file system was created –  karthigeyan Dec 5 '09 at 9:36
    
I think you need to provide a little more information on exactly what you are doing. What commands are you running, what does your /etc/fstab look like etc. –  Roy Dec 5 '09 at 9:59

3 Answers 3

If you say 'no filesystem was created', I suggest you use fdisk to create partition(s) and the mke2fs or a similar utility to create a filesystem. Filesystems do not magically appear; you need to create them.

More specifically, you run

fdisk -l

to check whether the disk is detected by the OS at all. Then you run

fdisk /dev/yourdisk

and create partition(s) with the appropriate commands. fdisk has a fine help function, but basically, you create a new partition with 'n', and fdisk will ask you for more information.

Then, you might have to run

partprobe /dev/yourdisk

to make sure Linux sees your new partition(s) correctly.

Then, at last, you run

mke2fs -j /dev/yourparition

on each created partition to create ext3 filesystems. For ext2, leave off the -j. But you can also use any mkfs.* utility available on your system.

Finally, add the new partition(s) to your /etc/fstab file, by adding (a) line(s) following this convention:

device     mountpoint   filesystem     filesystemoptions     fs_freq     fs_passno

So, for example:

/dev/sda1     /u01     ext2     defaults     1     2

and you're all done.

share|improve this answer
1  
Shouldn't the last number be 2 on the fstab entry? As I understand it, it's rather important that the pass number is higher than the one set for root. –  Roy Dec 5 '09 at 10:43
    
You are absolutely right. Missed that. +1 for you and edited my post. –  wzzrd Dec 5 '09 at 10:55
1  
Also, suggesting something else than ext2 for a modern 1TB harddrive might make better use of that disk. Perhaps XFS or something similar :) –  pauska Dec 5 '09 at 11:52
    
...and he probably does NOT want it mounted in boot. A safer example might be /export/disk2 –  David Mackintosh Dec 5 '09 at 22:56
    
@pauska: I am not suggesting ext2, I am suggesting ext3, which makes perfect sense to me, as it is the default on virtually all distros today. I am merely telling what the -j option does. @David Mackintosh: the /etc/fstab snippet is an example, I am certainly not suggesting mounting a 1TB drive at boot. Where he wants it mounted is his thing to decide on. –  wzzrd Dec 6 '09 at 7:54

Sounds like you need to use a utility like Gparted to create a partition, then use the appropriate utility for the filesystem you want to create the FS.

share|improve this answer
    
Answering too quickly. –  phoebus Dec 5 '09 at 10:40
    
+1 for the user friendly GParted as opposed to a bunch of commandline executions. GParted can also be used to format to the partition you want. –  Ophidian Dec 7 '09 at 14:54

You need to create a filesystem with mkfs on the disk before using it. You may want to partition it first too. Partitions aren't mandatory to linux if you simply want to use it as a data disk, however you'll need to partition it to be able to boot from it.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.