LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise
User Name
Password
Linux - Enterprise This forum is for all items relating to using Linux in the Enterprise.

Notices


Reply
  Search this Thread
Old 11-01-2007, 09:21 AM   #1
fukas
LQ Newbie
 
Registered: Nov 2007
Posts: 1

Rep: Reputation: 0
How can I found the drive number XP is on..


Alright hey everyone.. forgive me if this has been posted but I dont think it has been before.. Anyway.

I have installed CentOS as a normal desktop configuration, works wonders.
When I installed it, I put it on my 2nd harddrive so I can dual boot with XP.

Later I realized that I had to add XP into grubs configuration so I can choose to boot from it. Thats all find a dandy I suppose, however, I can not find the right drive number? I guess I can call it that.

An example from a post I found on here (centos-4.0-windows-xp-dual-boot-314195)

Quote:
# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You do not have a /boot partition. This means that
# all kernel and initrd paths are relative to /, eg.
# root (hd0,0)
# kernel /boot/vmlinuz-version ro root=/dev/sda1
# initrd /boot/initrd-version.img
#boot=/dev/sda
default=2
timeout=5
splashimage=(hd0,0)/boot/grub/splash.xpm.gz
hiddenmenu
title CentOS 4.0 (2.6.9-5.0.3.ELsmp)
root (hd0,0)
kernel /boot/vmlinuz-2.6.9-5.0.3.ELsmp ro root=LABEL=/1 rhgb quiet
initrd /boot/initrd-2.6.9-5.0.3.ELsmp.img
title CentOS 4.0-up (2.6.9-5.0.3.EL)
root (hd0,0)
kernel /boot/vmlinuz-2.6.9-5.0.3.EL ro root=LABEL=/1 rhgb quiet
initrd /boot/initrd-2.6.9-5.0.3.EL.img
title Windows XP
rootnoverify (hd1,0)
chainloader +1
map (hd1) (hd0)
map (hd0) (hd1)
That's what mine looks like, however, hd1,0 isnt my drive with xp..

So is there any command I havent learned yet to see what disk my computer has installed so I can fix this and be blessed with dual booting xp successfully?


thanks for any help..
~chris
 
Old 11-01-2007, 08:44 PM   #2
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
To list all of your drives (and the partitions on them) you can use the command:

Code:
fdisk -l
 
Old 11-07-2007, 06:20 PM   #3
Mountain
Member
 
Registered: Nov 2007
Location: A place with no mountains
Distribution: Kubuntu, sidux, openSUSE
Posts: 214

Rep: Reputation: 41
I want to list all my drives and all partitions.

When I type "fdisk -l" the output is empty - nothing is listed.

What am I doing wrong?
 
Old 11-07-2007, 08:59 PM   #4
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
that is "dash lowercase L" not the pipe symbol

Code:
fdisk -l
 
Old 11-08-2007, 07:21 AM   #5
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
Also make sure you are running it as root, otherwise you will get nothing back.
 
Old 11-09-2007, 12:10 AM   #6
Mountain
Member
 
Registered: Nov 2007
Location: A place with no mountains
Distribution: Kubuntu, sidux, openSUSE
Posts: 214

Rep: Reputation: 41
Quote:
Originally Posted by MS3FGX View Post
Also make sure you are running it as root, otherwise you will get nothing back.
That must be the issue. I find that strange. I tried sudo and I still got nothing back. But when I logged in as root, it worked.
 
Old 11-09-2007, 12:18 AM   #7
jschiwal
LQ Guru
 
Registered: Aug 2001
Location: Fargo, ND
Distribution: SuSE AMD64
Posts: 15,733

Rep: Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682Reputation: 682
You can also use tab completion in the grub shell when booting to locate the partition that contains your xp installation.
 
  


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
How do I change the /dev/sdx number of a drive ? Christof999 Linux - Hardware 1 06-08-2007 03:29 PM
Drive volume serial number: any similar concept in Linux? viettrung Programming 8 01-12-2007 08:54 AM
Hard Drive Serial Number? daver Linux - Hardware 4 03-17-2004 09:57 AM
USB hard drive rejects dev number mad2physicist Linux - Hardware 16 12-15-2003 12:11 PM
What is the max number of drive interfaces? tells Linux - Hardware 1 12-04-2003 02:42 PM

LinuxQuestions.org > Forums > Enterprise Linux Forums > Linux - Enterprise

All times are GMT -5. The time now is 07:29 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
Open Source Consulting | Domain Registration