If I understand you correctly you are saying that you installed a brand new hard drive and issuing the fdisk -l command shows the drive as /dev/hdb.
If that is the case then you have to create a partition table and then create a file system in the partition(s), just like in Windows.
If you have cfdisk that is easier to use than using fdisk to create a partition table. So first check to see if you have the cfdisk utility.
Code:
root> which cfdisk
/sbin/cfdisk
If you enter the "which cfdisk" command and you don't see any listing then you don't have it. If you do have it then enter the cfdisk /dev/hdb command. If you don't have cfdisk then just enter the fdisk /dev/hdb command.
Next create a partition. Make it type 83. Write the partition table back onto the disk. Exit the cfdisk or fdisk utility.
Next you have to create a file system. This is the same as when you format a partition in Windows. In Linux we use the mkfs command. There are a lot of different types of file systems. You can look them up. Let's say that you want to use the tried and true ext2 file system. This is what you would do to create an ext2 file system on /dev/hdb1.
Code:
root> mkfs -t ext2 -cv /dev/hdb1
This command will take a long time to finish because it is checking the partition for bad blocks as it creates the file system.
Once this finishes you can mount the file system. Let's say that you want to mount this file system at /mnt/hdb1. First you have to create the directory where you want to mount it. Then you mount the file system. Note that you only have to create the directory/mount point once.
Code:
root> mkdir /mnt/hdb1
root> mount /dev/hdb1 /mnt/hdb1
That's all there is to it. Now you can enter the following line in your /etc/fstab file to mount the file system automatically when you restart Linux.
Code:
/dev/hdb1 /mnt/hdb1 ext2 defaults 0 0
There are a lot of things that you can do in addition to what I have said here. You might want to prevent people from running programs that are on this partition. You can do this using the noexec option. This would go next to the word defaults in the fstab entry as in:
Code:
/dev/hdb1 /mnt/hdb1 ext2 defaults,noexec 0 0
You can look up all of the mount options by looking at the man page for the mount command and the man page for the fstab file.