LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 10-30-2004, 09:16 PM   #1
RandallC
LQ Newbie
 
Registered: Sep 2004
Distribution: Ubuntu!
Posts: 27

Rep: Reputation: 15
Added Windows HD to linux box. Trouble ensues.


So for various reasons I decided I needed I windows install on my linux box. The computer is running mandrake 10, installed on the primary hard drive.

Knowing that windows likes to eat previously installed OS's, I disconnected the linux HD and hooked up another HD in its place to install windows on.

Now I have two hard drives, and I can get either OS to boot by changing boot order in the BIOS. Not ideal.

The problem is this: while I can see the partition on the windows drive (hdb) using fdisk, the partition (hdb1) is not present in /dev (/dev/hdb1 does not exist). I can't mount the windows drive, and I can't add the windows partition to LILO.

Help?

Thanks.
 
Old 10-30-2004, 11:07 PM   #2
crabboy
Senior Member
 
Registered: Feb 2001
Location: Atlanta, GA
Distribution: Slackware
Posts: 1,821

Rep: Reputation: 121Reputation: 121
If you have no hdb1 you'll have to create it:
[code]
mknod /dev/hdb1 b 3 65
[code]

You may want to add b2, b3, b4 etc... b2 will be minor 66, and so on.
 
Old 10-31-2004, 08:42 AM   #3
RandallC
LQ Newbie
 
Registered: Sep 2004
Distribution: Ubuntu!
Posts: 27

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by crabboy
If you have no hdb1 you'll have to create it:
[code]
mknod /dev/hdb1 b 3 65
[code]

You may want to add b2, b3, b4 etc... b2 will be minor 66, and so on.
Cool! I only have 1 partition, so that should do it? I'm going to try now.

Edit: Didn't work. hdb1 shows up now, but when doing an 'ls' in /dev it looks different then, for example, hda1. It's yellow and doesn't have an @ symbol at the end of it.

Now when I try to mount the drive, it says
mount: /dev/hdb1 is not a valid block device

Adding it to lilo also fails.

Last edited by RandallC; 10-31-2004 at 08:51 AM.
 
Old 10-31-2004, 03:42 PM   #4
RandallC
LQ Newbie
 
Registered: Sep 2004
Distribution: Ubuntu!
Posts: 27

Original Poster
Rep: Reputation: 15
Bump for suggestions.
 
Old 10-31-2004, 04:03 PM   #5
UsualTuxpect
Member
 
Registered: Aug 2004
Location: New York
Distribution: --------- Gentoo-2004.2 [2.6.8] Redhat-9 [2.6.6]
Posts: 545

Rep: Reputation: 31
Windows doesnt like being in hdb connect it as master[hda] and see if it boots up your windows first.

You could also use ntloader instead of grub/lilo to boot into linux
-->http://www.geocities.com/epark/linux...w2k-HOWTO.html

What is your filesystem type on [/dev/hdb1] ???

and also when you are trying to mount the /dev/hdb1 make sure you are passing the right filesystem type as argument [-t vfstype] to the mount command.. read the manual for more info [#man mount]. And see if your kernel supports the file system you are trying to mount.
 
Old 10-31-2004, 06:06 PM   #6
RandallC
LQ Newbie
 
Registered: Sep 2004
Distribution: Ubuntu!
Posts: 27

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by UsualTuxpect
Windows doesnt like being in hdb connect it as master[hda] and see if it boots up your windows first.

You could also use ntloader instead of grub/lilo to boot into linux
-->http://www.geocities.com/epark/linux...w2k-HOWTO.html

What is your filesystem type on [/dev/hdb1] ???

and also when you are trying to mount the /dev/hdb1 make sure you are passing the right filesystem type as argument [-t vfstype] to the mount command.. read the manual for more info [#man mount]. And see if your kernel supports the file system you are trying to mount.
Thanks for the reply.

If I swap the master/slave configuration of the drives, windows will boot first. My problem isn't that I can't get into my windows drive--I can if I do that or change the boot order in my bios.

The filesystem type is FAT32, since I know NTFS support is sketchy at best.

I'll try using ntloader.

Edit: I went to that link, but it assumes linux is being installed. My situation is a little different--linux is already independently running off its own harddrive. GRUB is installed on the MBR on that drive.

So what exactly would I need to do? Somehow install GRUB to a new partition on the windows drive?

Last edited by RandallC; 10-31-2004 at 06:10 PM.
 
Old 10-31-2004, 08:43 PM   #7
UsualTuxpect
Member
 
Registered: Aug 2004
Location: New York
Distribution: --------- Gentoo-2004.2 [2.6.8] Redhat-9 [2.6.6]
Posts: 545

Rep: Reputation: 31
I am a little confused here... for a second, forget about Slave hard-disk [disconnect it..]


1)Are you able to boot window's harddisk as master

2)Are you able to boot Linux harddisk as master

Dont do anything with the boot order in your BIOS [let it boot from hda..]

Depending on your answer we'll go ahead...

Last edited by UsualTuxpect; 10-31-2004 at 08:46 PM.
 
Old 10-31-2004, 09:32 PM   #8
RandallC
LQ Newbie
 
Registered: Sep 2004
Distribution: Ubuntu!
Posts: 27

Original Poster
Rep: Reputation: 15
Yes and Yes.
 
Old 10-31-2004, 10:04 PM   #9
UsualTuxpect
Member
 
Registered: Aug 2004
Location: New York
Distribution: --------- Gentoo-2004.2 [2.6.8] Redhat-9 [2.6.6]
Posts: 545

Rep: Reputation: 31
Ok, Nice to know that.

*Now all you need to to is connect your Linux hard drive as master(hda) and connect your Windows Drive as Slave (hdb).

*Don't change anything in the BIOS..

*edit your /boot/grub/grub.conf file and **remove** all the lines (if) you have for windows and paste the following line's below the linux related lines..

title Windoze
map (hd1) (hd0)
map (hd0) (hd1)
rootnoverify (hd1,0)
makeactive
chainloader +1


* save it and restart linux.


EXAMPLE -->this is my grub.conf


title Red Hat Linux 9 [ KERNEL - 2.6.6-1.435 ]
root (hd0,6)
kernel /vmlinuz-2.6.6-1.435 ro root=LABEL=/ hdd=ide-cd apm=off
initrd /initrd-2.6.6-1.435.img

title Windoze
map (hd1) (hd0)
map (hd0) (hd1)
rootnoverify (hd1,0)
makeactive
chainloader +1

Last edited by UsualTuxpect; 11-01-2004 at 11:54 AM.
 
Old 11-01-2004, 07:02 AM   #10
RandallC
LQ Newbie
 
Registered: Sep 2004
Distribution: Ubuntu!
Posts: 27

Original Poster
Rep: Reputation: 15
Alrighty--just one problem. I don't have a grub.conf in /boot/grub. Is it hiding somewhere else?
 
Old 11-01-2004, 07:58 AM   #11
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
Perhaps you are using lilo. This does the same thing. It should be in the windows stanza.
map-drive=0x80
to=0x81
map-drive=0x81da
to=0x80

Or look for the 'menu.lst' file in the /boot/grub directory.

If you decide to make the windows drive the master, then be sure to edit the /etc/fstab file and the lilo.conf or grub.conf or menu.lst files. Then reinstall the mbr. For lilo you run /sbin/lilo as root.

For grub: grub-install (hd0)

Good Luck!
 
Old 11-01-2004, 09:48 AM   #12
320mb
Senior Member
 
Registered: Nov 2002
Location: pikes peak
Distribution: Slackware, LFS
Posts: 2,577

Rep: Reputation: 48
windows like to be on an "active" partition also.........NOT
on a "logical" partition..........

and there is the "2 gig and 1024 cylinder boundries" to think about

BUT windows can be tricked into thinking it is within these "boundries"--LOL
 
Old 11-01-2004, 10:46 PM   #13
RandallC
LQ Newbie
 
Registered: Sep 2004
Distribution: Ubuntu!
Posts: 27

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by jschiwal
Perhaps you are using lilo. This does the same thing. It should be in the windows stanza.
map-drive=0x80
to=0x81
map-drive=0x81da
to=0x80

Or look for the 'menu.lst' file in the /boot/grub directory.

If you decide to make the windows drive the master, then be sure to edit the /etc/fstab file and the lilo.conf or grub.conf or menu.lst files. Then reinstall the mbr. For lilo you run /sbin/lilo as root.

For grub: grub-install (hd0)

Good Luck!
Ok, couldn't get lilo to like that. So I switched to grub. I'm editting the menu.lst file, and have added the grub related "Windoze" code. Now I'm trying to use grub-install, but its not liking it. Is that the exact syntax above?

Thanks for the continued help!

Edit: Just wanted to say that after fiddling with it, it looks like everything is just fine and dandy with grub. I can boot into windows.

Can I change the order of the bootloader so that windows is below linux? There are a few other things there that were installed by default.

Next question: How do you think I should go about mounting my windows drive in linux? /dev/hdb1 doesn't show up. Any ideas?

Thanks!

Last edited by RandallC; 11-01-2004 at 10:56 PM.
 
Old 11-02-2004, 12:34 AM   #14
crabboy
Senior Member
 
Registered: Feb 2001
Location: Atlanta, GA
Distribution: Slackware
Posts: 1,821

Rep: Reputation: 121Reputation: 121
Does hdb show up in the output of dmesg? You should see something like this: (but for hda and hdb)
Code:
hde: Maxtor 6Y120L0, ATA DISK drive
ide2 at 0xe880-0xe887,0xe802 on irq 10
hdh: ST320413A, ATA DISK drive
ide3 at 0xe480-0xe487,0xe402 on irq 10
hde: max request size: 128KiB
hde: 240121728 sectors (122942 MB) w/2048KiB Cache, CHS=65535/16/63, UDMA(100)
hde: cache flushes supported
 hde: hde1 hde2 hde3 hde4
hdh: max request size: 128KiB
hdh: 39102336 sectors (20020 MB) w/512KiB Cache, CHS=38792/16/63, UDMA(100)
hdh: cache flushes not supported
 hdh: hdh1
 
Old 11-02-2004, 06:16 AM   #15
RandallC
LQ Newbie
 
Registered: Sep 2004
Distribution: Ubuntu!
Posts: 27

Original Poster
Rep: Reputation: 15
Quote:
Originally posted by crabboy
Does hdb show up in the output of dmesg? You should see something like this: (but for hda and hdb)
Code:
hde: Maxtor 6Y120L0, ATA DISK drive
ide2 at 0xe880-0xe887,0xe802 on irq 10
hdh: ST320413A, ATA DISK drive
ide3 at 0xe480-0xe487,0xe402 on irq 10
hde: max request size: 128KiB
hde: 240121728 sectors (122942 MB) w/2048KiB Cache, CHS=65535/16/63, UDMA(100)
hde: cache flushes supported
 hde: hde1 hde2 hde3 hde4
hdh: max request size: 128KiB
hdh: 39102336 sectors (20020 MB) w/512KiB Cache, CHS=38792/16/63, UDMA(100)
hdh: cache flushes not supported
 hdh: hdh1
Ooo good call. Yes, hdb has a few lines in the output, but there seems to be an error:

hdb: Maxtor 53073H4, ATA DISK drive
...
hdb: max request size: 128KiB
hdb: 60030432 sectors (30735 MB) w/2048KiB Cache, CHS=59554/16/63, UDMA(66)
/dev/ide/host0/bus0/target0/lun0: inconsistent partition table (overflow)
...
VFS: Can't find a calid FAT filesystem on dev hdb.

I typed this all in by hand so hopefully there are no subtle errors, but that should be the gist of it anyway.

Last edited by RandallC; 11-02-2004 at 10:58 AM.
 
  


Reply



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
Troubleshooting Slow Transfer Speed Between Linux Box and Windows Box timswim78 Linux - General 1 10-23-2005 11:45 AM
Windows XP box losing connection to Linux box after 30 sec. NeoZeus Linux - Networking 3 07-21-2005 12:02 AM
Linux box with eth0 to cable modem and eth1 to Windows box videojeff Linux - Networking 23 03-03-2005 07:58 PM
Transfairing files from windows xp box to mandrake linux 10.0 box. tyledogg Linux - Newbie 4 07-25-2004 11:24 PM
Linux box calling a batch script on a windows box to run? Is it possible? joelhop Programming 8 05-17-2004 04:49 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 02:29 PM.

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
Open Source Consulting | Domain Registration