LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   How do I mount a second hard drive? (PC/OS : Ubuntu) (https://www.linuxquestions.org/questions/linux-newbie-8/how-do-i-mount-a-second-hard-drive-pc-os-ubuntu-692243/)

Crystal_Bits 12-22-2008 10:03 AM

How do I mount a second hard drive? (PC/OS : Ubuntu)
 
I have FreeDOS installed on a second internal hard drive that is recognized (/dev/sdb) but not mounted. My primary hard drive is 20G Linux ext3 and swap. The second is 5 different partitions, all fat16 or fat32.

I cannot access the second drive without a live CD (win 98 or FreeDOS). I am sure there is a simple way I can mount it and run my DOS programs from the console if I can figure out how to mount it and change my fstab file so it will always be available.

Who has the knowledge to help me out?

camorri 12-22-2008 11:05 AM

First of all, you do not mount a hard drive. You mount a file system. You need to know the devices that represent the partitions on sdb. They will be, for example, sdb1 sdb5 sdb6 etc.

You can run the 'df' command to find out the devices.

You need a mount point. Decide where in your linux system you want to see each partition. You make a mount point with mkdir command.

Then you issue a mount command for each partition. If you want this to happen each time you boot linux, then as root edit the /etc/fstab file and add an entry for each partition.

Dos programs will not run under linux. You might be able to get some, or all to run under wine, or some other environment, but they will not run directly on linux.

Here is a sample of a fat file system that mounts in my fstab file.

Quote:

/dev/sdb1 /mnt/pictures vfat defaults 0 0
The first part is the partition. Next is the mount point. Next is the file system type. The rest is the defaults, that work for me.

Hope this helps.

schneidz 12-22-2008 01:02 PM

the linux kernal is pretty good at guessing file system types. this should get you started:
Code:

mkdir part1 part2 part3 part4 part5
sudo mount /dev/sdb1 part1
sudo mount /dev/sdb2 part2
sudo mount /dev/sdb3 part3
sudo mount /dev/sdb4 part4
sudo mount /dev/sdb5 part5

man mount to learn how to mess with read/write options and the such...

Crystal_Bits 12-23-2008 11:34 AM

Thanks to both of you. I just switched over to PC/OS from Kubuntu. I used Kubuntu for a couple of years and had installed Dosemu to run my database programs. I think I will like using the apt-get system once I figure out how to check for dependencies, but your comments stirred my memory for another go. Thanks!


All times are GMT -5. The time now is 07:11 PM.