LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-03-2002, 10:48 AM   #1
CyberSteve
LQ Newbie
 
Registered: Feb 2002
Location: USA
Distribution: Ubuntu 14.04
Posts: 15

Rep: Reputation: 0
Dual booting of 2 linux hard drives


I have 2 Maxtor hard drives installed in my PC. The PC is a 586
new standard AT type motherboard, nothing special. The bootable hard drive (primary master) has a new working installation of redhat 7.1. The second drive (primary slave) has
redhat 7.0 installed and working.

When the PC boots it does recognize in the standard PC screen that lists how many drives, ram, serial & parallel ports etc.
both drives are listed with the correct drive size, etc.

When the Master drive boots it lists hda for the primary drive
and hdb for the slave.

I cannot mount hdb and gain access from the command line to access directories and/or files.

Both drives in lilo.conf list boot=/dev/hda and the files are
almost identical.

So if command line access doesn't work maybe dual booting will.
thanks..............for some input.
 
Old 02-03-2002, 05:01 PM   #2
taz.devil
Senior Member
 
Registered: Nov 2001
Location: Wa. State
Distribution: Slackware
Posts: 1,261

Rep: Reputation: 45
How are you trying to mount hdb? Is there a line in your /etc/fstab file like;

/dev/hdb /mountpoint ext2 defaults 1 1

/mountpoint = Any directory you want to mount the drive to. You'll have to make the directory though, so assume you want to access hdb from a directory called /redhat-7.1, you need to mkdir redhat-7.1 and use that in fstab etc...
 
Old 02-03-2002, 09:41 PM   #3
linuxcool
LQ Addict
 
Registered: Jun 2001
Posts: 1,183

Rep: Reputation: 47
Using taz.devil's line caused linux to try to mount the whole drive hdb and it tried to do it automatically at startup. You need to specify the partition you want to mount. Let's say you want to mount the / partition of 7.0 and it's hdb1. You would enter at the command prompt mount -t ext2 /dev/hdb1 /mountpoint. The line in your fstab file would be:

/dev/hdb1 /mountpoint ext2 noauto,user 0 0

With this line in the fstab file, all you would have to enter would be mount /mountpoint. BTW, /mountpoint is the mountpoint you create to mount the partition. hdb1 is just a partition I selected as an example. You'll have to use the the one that indicates yours.

Last edited by linuxcool; 02-03-2002 at 09:43 PM.
 
Old 02-04-2002, 01:16 PM   #4
CyberSteve
LQ Newbie
 
Registered: Feb 2002
Location: USA
Distribution: Ubuntu 14.04
Posts: 15

Original Poster
Rep: Reputation: 0
accessing directory / files on slave disk

linuxcool..........thank you for your reply.

On the second physical hard drive (primary slave) is hdb.
There are 2 partitions on this drive; / is native linux ext2
and /swap.

I added /dev/hdb1 / ext2 noauto,user 0 0 in the next line
of fstab.

I used your mount -t ext2 /dev/hdb1 / to mount to hdb1.

On the primary Master hard drive; the mount cmd showed
the mount cmd worked -- /dev/hdb1 on / type ext2 (rw).

I still cannot access any directories or files using the cd???

Maybe its a syntax issue. Trying different combinations of
cd cmd I get error message /dev/hdb1 / is busy or bash:
/dev/hdb1 is not a directory or file???

What am I doing wrong.

I cannot umount /dev/hdb1 either.........thanks for your help.
 
Old 02-04-2002, 04:48 PM   #5
CyberSteve
LQ Newbie
 
Registered: Feb 2002
Location: USA
Distribution: Ubuntu 14.04
Posts: 15

Original Poster
Rep: Reputation: 0
dual drive access troubles

linuxcool..........I have made some progress:

I re-entered the changes as you listed them. I can mount hdb1
and now can umount hdb1.

In the mountpoint directory on the Master drive. it has only on
directory on the Slave drive called lost+found. I can access
from /mountpoint to lost+found on the slave hard drive. But
nowhere else???

I changed the file permissions from 0 0 to 1 1, but made no
difference.

How do I get full access to the other directories and files on
the slave drive?? Thanks.
 
Old 02-04-2002, 06:39 PM   #6
linuxcool
LQ Addict
 
Registered: Jun 2001
Posts: 1,183

Rep: Reputation: 47
You're close. You just made one mistake. I guess I wasn't clear on you having to make a directory to mount the partition under. The / directory is not where you want to mount the partition. The /mountpoint was an example. Let's see if red hat created a directory named /mnt. Run ls / and see if there is a directory named /mnt. If there is, then run this command mkdir /mnt/rh7.0. This will create a directory named rh7.0 in the /mnt directory.If there is no /mnt, then run mkdir /rh7.0. This will create it in the / directory. Next, edit your fstab line.

/dev/hdb1 /mnt/rh7.0 ext2 noauto,user 0 0

or:

/dev/hdb1 /rh7.0 ext2 noauto,user 0 0

Depending where you created the directory. Then you can mount the partition by running mount /mnt/rh7.0 or mount /rh7.0. Don't forget to unmount when you're done. And one other thing, if you cd onto the partition, don't forget to cd off of the partition before you try to unmount. Otherwise, it won't let you.

Last edited by linuxcool; 02-04-2002 at 06:42 PM.
 
Old 02-04-2002, 08:34 PM   #7
CyberSteve
LQ Newbie
 
Registered: Feb 2002
Location: USA
Distribution: Ubuntu 14.04
Posts: 15

Original Poster
Rep: Reputation: 0
dual booting to slave hard drive

Hi linuxcool..........I made the changes /mnt/rh7.0.

I mounted /mnt/rh7.0. I then ran the mount cmd and it showed
I had mounted to /dev/hdb1 etc.

I still cannot access any directories on the rh7.0 slave drive.

After I use any cd commands, I am still on the Master drive???

What cd commands should I be using.

I had assumed after I mounted to /dev/hdb1 I would be in the
/mnt directory on the second physical drive(slave)??

Thanks for your patience.............
 
Old 02-04-2002, 11:27 PM   #8
linuxcool
LQ Addict
 
Registered: Jun 2001
Posts: 1,183

Rep: Reputation: 47
After you mount the partition, you are still in the same directory you were before you mounted the partition. You have to use the cd command to move onto the hdb1 partition. Like this:cd /mnt/rh7.0. You will now be in the root directory of the partition. Now, run ls and you will see the contents of the root directory. You should see bin, sbin, etc, root, home, and all the others that you would normally see when you are running rh7.0. When you are done using cd to move around the partition, run cd /. This will move you off the partition and allow to unmount it.
 
Old 02-05-2002, 12:04 PM   #9
CyberSteve
LQ Newbie
 
Registered: Feb 2002
Location: USA
Distribution: Ubuntu 14.04
Posts: 15

Original Poster
Rep: Reputation: 0
accessing slave hard drive

Hi linuxcool.........I re-checked everything from the last several postings. I confirm /dev/hdb1 /mnt/rh7.0 is mounted using
the mount command on the primary master drive.

Using cd /mnt/rh7.0 in am still on the Master hard drive, Not
the 2nd drive (slave) / location.

There is something about the path that isn't coming into the
picture, I would guess??

To make this work, must I do anything to the 2nd physical drive,
primary slave ??

Here are the contents of the Master / booted drive:
/mnt directory --
directory for cdrom, floppy and rh7.0
/mnt/rh7.0 --
12 files like map, message,boot.b etc....
4 pointers I think, like kernel.h ->kernel.h-2.2.16 &
kernel.h ->2.4.0 etc.......
1 directory called lost+found with no contents.

So where do we go from here?
 
Old 02-05-2002, 06:13 PM   #10
linuxcool
LQ Addict
 
Registered: Jun 2001
Posts: 1,183

Rep: Reputation: 47
I think I see the problem. hdb1 is not your / partition, it's your /boot partition. Either you or rh7.0 created a /boot partition. You need to find out what your / partition is. Run fdisk -l /dev/hdb and determine which partition is your / partition and then substitute the correct number into your fstab file.
 
Old 02-05-2002, 08:28 PM   #11
CyberSteve
LQ Newbie
 
Registered: Feb 2002
Location: USA
Distribution: Ubuntu 14.04
Posts: 15

Original Poster
Rep: Reputation: 0
access slave hard drive

Hi linuxcool.......

Here is what fdisk says: 2nd hard drive (slave) rh7.0

Device Boot Start End ID System
/dev/hdb1 * 1 3 83 Linux
/dev/hdb2 4 1245 5 Extended
/dev/hdb5 4 554 83 Linux
/dev/hdb6 555 1105 83 Linux
/dev/hdb7 1106 1138 83 Linux
/dev/hdb8 1139 1171 83 Linux
/dev/hdb9 1172 1204 82 Linux Swap

I did try substituting /dev/hdb2...............I got the following
error msg: wrong fs type, bad option, bad option........cannot
mount logical partition.

I used the fdisk cmd on the booted Master drive. it showed
on 2 partitions /dev/hda1 & 2 - one way / and /swap.

Hopefully this helps.............thanks.
 
Old 02-05-2002, 11:23 PM   #12
linuxcool
LQ Addict
 
Registered: Jun 2001
Posts: 1,183

Rep: Reputation: 47
WHOA!!!

I didn't know your slave drive had so many partitions. CyberSteve, I'm going to need you to boot up into rh 7.0 and then post a copy of rh 7.0's /etc/fstab file. It's the only way I'm going to be able to sort this out. BTW, did you partition the slave drive yourself?
 
Old 02-07-2002, 08:09 PM   #13
CyberSteve
LQ Newbie
 
Registered: Feb 2002
Location: USA
Distribution: Ubuntu 14.04
Posts: 15

Original Poster
Rep: Reputation: 0
accessing 2nd physical drive

Hi linuxcool..........have been working on the same problem.
Last night I accidentally overwrote the /etc/fstab file on the 2nd physical drive.

Needless to say, the machine will not boot fully and the filesystem
is giving all kinds of error messages that it cannot file various file
during the boot up of the slave drive.

From notes, I have tried to reconstruct the fstab file but every
re-boot is making the filesystem issue worse.

Now I cannot get a #prompt even using the install cd linux rescue
mode gives you a prompt but nothing works at the command line.

The boot diskette fails at the same place the hard drive boot
does...........

Is there anyway to get a working prompt so some files can be pulled off or are we beating a dead horse? Time to reformat
& learn from this? Thanks for all your replies on this too......
 
Old 02-07-2002, 10:54 PM   #14
linuxcool
LQ Addict
 
Registered: Jun 2001
Posts: 1,183

Rep: Reputation: 47
You might be able to gain access to files on rh 7.0 by running rh 7.1 and then mounting the partitions from the terminal command line. Then you could use the file manager in X window to look for the files you want. We know that hdb1 is your /boot partition from the contents that you listed in one of your posts. Just run mount /dev/hdb? /mnt/rh7.0. Use the numbers 5, 6, 7, or 8 in place of the ' ? '. Don't forget to move off of the partition before you unmount. If you can find what's left of your fstab file, maybe you can reconstruct it.

Last edited by linuxcool; 02-07-2002 at 10:56 PM.
 
Old 02-09-2002, 08:02 PM   #15
CyberSteve
LQ Newbie
 
Registered: Feb 2002
Location: USA
Distribution: Ubuntu 14.04
Posts: 15

Original Poster
Rep: Reputation: 0
Hi Linuxcool.............we've tried everything we can think of and no go. Even running e2fsck on that hard drive didn't clean up the filesystem enough to allow the hard drive to boot.

At this point we'll reformat and do a clean install of Linux 7.1......

Thank you for all your help !
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Dual Booting SuSE 9.2 & XP Pro/dual hard drives The_Bug Linux - General 3 01-04-2006 06:44 PM
Dual Booting with 2 hard drives bjs Linux - Newbie 3 04-06-2004 06:39 PM
Dual Booting w/ two hard drives- Help! /home/dick Linux - Hardware 3 03-10-2004 04:48 AM
Dual booting on 2 hard drives olivierrrrr Linux - Newbie 18 10-12-2003 01:53 AM
Dual booting w/ 2 hard drives SpC Linux - Newbie 11 06-21-2002 09:48 PM


All times are GMT -5. The time now is 10:58 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration