LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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 04-23-2004, 04:07 PM   #1
BobNz
Member
 
Registered: May 2003
Location: NewZealand
Distribution: RH9.0
Posts: 74

Rep: Reputation: 15
cant see other linux drives


Hi, I have 2 drives on the same pc, both with rh9.0 installed (80gb, 10gb) the 10 gig was the original linux install, and dual booted with win2k (80gb drive) which I have now installed rh9.0 on as well. (bye bye MS)The thing is I cant see the original 10gb drive from the 80gb install. There is some problem with having 2 boot partitions I think, (conflict) but how do I go about making the 10gb drive accessible from the 80gb drive do I have to set a mountpoint?

any help appreciated.

this my fstab if its any help.
Code:
LABEL=/                 /                         ext3             defaults        1 1
LABEL=/boot        /boot                   ext3             defaults        1 2
none                      /dev/pts               devpts       gid=5,mode=620  0 0
none                     /proc                     proc           defaults        0 0
none                     /dev/shm              tmpfs        defaults        0 0
/dev/hda3            swap                     swap        defaults        0 0
/dev/cdrom          /mnt/cdrom           udf,i         so9660 noauto,owner,kudzu,ro 0 0
/dev/fd0                /mnt/floppy           auto         noauto,owner,kudzu 0 0
Bob

Last edited by BobNz; 04-24-2004 at 06:39 AM.
 
Old 04-23-2004, 05:10 PM   #2
coolamit78
Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: RHEL AS 3/4, Windows XP
Posts: 546

Rep: Reputation: 31
Hi...

I assume that

first drive = /dev/hda = 10GB
second drive = /dev/hdb = 80GB

In case its opposite, then the device names will change accordingly..

Now on your 80 gig drive i.e /dev/hdb, create a folder

mkdir /mnt/redhat

To mount your 10 Gig drive temporarily, give the command

mount -t ext3 /dev/hda /mnt/redhat

If you want to have this drive mounted automatically at boot, then add this entry in your /etc/fstab

/dev/hda /mnt/redhat ext3 defaults 0 0

In that way, you should be able to access your first drive from your second drive.

You can similarly create a folder in /mnt of the first hard disk and link the second drive (80 Gig)..The entry would be

/dev/hdb /mnt/redhat ext3 defaults 0 0

Hope that helps...

Regards,

amit
 
Old 04-23-2004, 05:17 PM   #3
coolamit78
Member
 
Registered: Aug 2003
Location: New Delhi, India
Distribution: RHEL AS 3/4, Windows XP
Posts: 546

Rep: Reputation: 31
Just to add...

If your 10GB drive has only 1 partition (i.e '/' ), then you can mount your this partition by replacing /dev/hda with /dev/hdax ( where x is partition number that you wish to mount )

Regards,

amit
 
Old 04-23-2004, 06:13 PM   #4
BobNz
Member
 
Registered: May 2003
Location: NewZealand
Distribution: RH9.0
Posts: 74

Original Poster
Rep: Reputation: 15
Hi Ammit, thanks for the reply.

I dont have a hdb or an hda folder in the dev directory am I supposed to?

when i do df:

[root@localhost dev]# df
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/hda2 76304192 2704176 69723936 4% /
[root@localhost dev]#

so 80gb driv is hda

should I then create a hdb folder in dev directory and run

mkdir /dev/hdb and then cd to hdb and run mkdir /mnt/redhat

followed by

mount -t ext3 /dev/hdb/mnt/redhat

when I try to create the hdb folder i get:

[root@localhost dev]# mkdir hdb
mkdir: `hdb' exists but is not a directory
[root@localhost dev]#


Bob
 
Old 04-24-2004, 06:25 AM   #5
Cerbere
Member
 
Registered: Dec 2002
Location: California
Distribution: Slackware & LFS
Posts: 799

Rep: Reputation: 33
No, you don't need (or want) to create hdb or hda directories in /dev.

Look closely at the command that coolamit gave you:
Code:
mount -t ext3 /dev/hda /mnt/redhat
And notice that there is a space between /dev/hda and /mnt/redhat.

Now, that being said, this command may or may not work for a couple of reasons. First, you should mount the partition and not the drive, so you'll want to replace /dev/hdb with /dev/hdb1 as amit indicated (assuming that your original install is on the first partition). Second, your original install may be on an ext2 filesystem, rather than an ext3 filesystem (which your new install apparently uses). in which case, you'll want to omit the '-t ext3' flag. So, try the command:

mount -t ext3 /dev/hdb1 /mnt/redhat

Then, if that doesn't work, try:

mount /dev/hdb1 /mnt/redhat

If neither of these works, then post the fstab from your original install (I'm assuming you can still boot into it) as well as the output of the command 'fdisk -l' (that's a lower-case L, not a one).

BTW if you type [_code_] before and [_/code_] after (remove the underscores) blocks of text like the output of commands or like your fstab file, then it'll be much easier for us to read.

Enjoy!
--- Cerbere

Last edited by Cerbere; 04-24-2004 at 06:32 AM.
 
Old 04-24-2004, 06:50 AM   #6
BobNz
Member
 
Registered: May 2003
Location: NewZealand
Distribution: RH9.0
Posts: 74

Original Poster
Rep: Reputation: 15
Hi, thanks for the reply.

did:
[root@localhost root]#mount -t ext3 /dev/hdb1 /mnt/redhat
[root@localhost root]# cd /mnt/redhat
[root@localhost redhat]# ls -l
Code:
total 10018
-rw-r--r--    1 root     root         5824 Jan 25  2003 boot.b
-rw-r--r--    1 root     root          612 Jan 25  2003 chain.b
-rw-r--r--    1 root     root        44762 Feb  5 14:50 config-2.4.20-30.9
-rw-r--r--    1 root     root        44309 Mar 14  2003 config-2.4.20-8
drwxr-xr-x    2 root     root         1024 Mar 26 20:52 grub
-rw-r--r--    1 root     root       149024 Mar 26 20:52 initrd-2.4.20-30.9.img
-rw-r--r--    1 root     root       150792 Dec 11 03:11 initrd-2.4.20-8.img
-rw-r--r--    1 root     root          473 Dec 11 03:11 kernel.h
drwx------    2 root     root        12288 Dec 11 03:07 lost+found
-rw-r--r--    1 root     root        23108 Feb 25  2003 message
-rw-r--r--    1 root     root        21282 Feb 25  2003 message.ja
lrwxrwxrwx    1 root     root           23 Mar 26 20:51 module-info -> module-info-2.4.20-30.9
-rw-r--r--    1 root     root        15438 Feb  5 14:50 module-info-2.4.20-30.9
-rw-r--r--    1 root     root        15436 Mar 14  2003 module-info-2.4.20-8
-rw-r--r--    1 root     root          640 Jan 25  2003 os2_d.b
lrwxrwxrwx    1 root     root           22 Apr 15 10:04 System.map -> System.map-2.4.20-30.9
-rw-r--r--    1 root     root       522619 Feb  5 14:50 System.map-2.4.20-30.9
-rw-r--r--    1 root     root       520129 Mar 14  2003 System.map-2.4.20-8
-rw-r--r--    1 root     root      3216789 Feb  5 14:50 vmlinux-2.4.20-30.9
-rw-r--r--    1 root     root      3193503 Mar 14  2003 vmlinux-2.4.20-8
lrwxrwxrwx    1 root     root           19 Mar 26 20:51 vmlinuz -> vmlinuz-2.4.20-30.9
-rw-r--r--    1 root     root      1134059 Feb  5 14:50 vmlinuz-2.4.20-30.9
-rw-r--r--    1 root     root      1122186 Mar 14  2003 vmlinuz-2.4.20-8
I dont really know what to do with this lol doesnt look like anything I know. What happened to all the directories?
heres fstab from main drive.
Code:
LABEL=/                 /                       ext3    defaults        1 1
LABEL=/boot             /boot                   ext3    defaults        1 2
none                    /dev/pts                devpts  gid=5,mode=620  0 0
none                    /proc                   proc    defaults        0 0
none                    /dev/shm                tmpfs   defaults        0 0
/dev/hda3               swap                    swap    defaults        0 0
/dev/cdrom              /mnt/cdrom              udf,iso9660 noauto,owner,kudzu,ro 0 0
/dev/fd0                /mnt/floppy             auto    noauto,owner,kudzu 0 0
/dev/hda   		/mnt/redhat 		ext3 	defaults 	0 0
[bob

Last edited by BobNz; 04-24-2004 at 06:58 AM.
 
Old 04-24-2004, 07:26 AM   #7
Cerbere
Member
 
Registered: Dec 2002
Location: California
Distribution: Slackware & LFS
Posts: 799

Rep: Reputation: 33
That looks like the /boot directory from your original install, which is on /dev/hdb1.

If your original install matches your new one, then you should try mounting /dev/hdb2. But be sure to unmount /dev/hdb1 first, using this command:

umount /dev/hdb1

Notice the spelling here, it's umount not uNmount.

Then try:

mount -t ext3 /dev/hdb2 /mnt/redhat

If this doesn't work, then post the output of 'fdisk -l'.

Enjoy!
--- Cerbere
 
Old 04-24-2004, 03:39 PM   #8
BobNz
Member
 
Registered: May 2003
Location: NewZealand
Distribution: RH9.0
Posts: 74

Original Poster
Rep: Reputation: 15
Hi, that worked


Code:
[root@localhost redhat]# ls -l
total 220
drwxr-xr-x    2 root     root         4096 Mar 26 20:29 bin
drwxr-xr-x    2 root     root         4096 Dec 11 03:07 boot
drwxr-xrwx    2 root     root         4096 Apr 13 18:27 Data
drwxr-xr-x   20 root     root       118784 Apr 22 23:13 dev
drwxr-xr-x   64 root     root         8192 Apr 22 23:13 etc
drwxr-xr-x    4 root     root         4096 Apr  4 08:40 home
drwxr-xr-x    2 root     root         4096 Jan 25  2003 initrd
drwxr-xr-x    9 root     root         4096 Mar 26 20:26 lib
drwx------    2 root     root        16384 Dec 11 03:07 lost+found
drwxr-xr-x    2 root     root         4096 Jan 28  2003 misc
drwxr-xr-x    4 root     root         4096 Dec 10 16:27 mnt
drwxr-xr-x    2 root     root         4096 Jan 25  2003 opt
-rw-r--r--    1 root     root            0 Apr 22 23:13 poweroff
drwxr-xr-x    2 root     root         4096 Dec 11 03:07 proc
drwxr-x---   24 root     root         4096 Apr 22 23:12 root
drwxr-xr-x    2 root     root         8192 Mar 26 20:30 sbin
drwxrwxrwx    2 root     root         4096 Apr  8 18:06 Scratch
drwxr-xr-x    3 root     root         4096 Dec 11 03:24 tftpboot
drwxrwxrwt   24 root     root         4096 Apr 22 23:13 tmp
drwxr-xr-x    2 root     root         4096 Apr 13 09:32 usbstick
drwxr-xr-x   17 root     root         4096 Apr 16 16:13 usr
drwxr-xr-x   23 root     root         4096 Apr 19 12:53 var
[root@localhost redhat]#
this is fstab from original drive
Code:
LABEL=/                 /                       ext3    defaults        1 1
LABEL=/boot             /boot                   ext3    defaults        1 2
none                    /dev/pts                devpts  gid=5,mode=620  0 0
none                    /proc                   proc    defaults        0 0
none                    /dev/shm                tmpfs   defaults        0 0
/dev/hdb3               swap                    swap    defaults        0 0
/dev/cdrom              /mnt/cdrom              udf,iso9660 noauto,owner,kudzu,ro 0 0
/dev/fd0                /mnt/floppy             auto    noauto,owner,kudzu 0 0
/dev/sda               /mnt/usbstick           vfat    noauto,user,umask=0 0 0
I tried ammits suggestion for getting hdb2 to mount automatically at boot but doesnt seem to work.
Code:
LABEL=/                 /                       ext3    defaults        1 1
LABEL=/boot             /boot                   ext3    defaults        1 2
none                    /dev/pts                devpts  gid=5,mode=620  0 0
none                    /proc                   proc    defaults        0 0
none                    /dev/shm                tmpfs   defaults        0 0
/dev/hda3               swap                    swap    defaults        0 0
/dev/cdrom              /mnt/cdrom              udf,iso9660 noauto,owner,kudzu,ro 0 0
/dev/fd0                /mnt/floppy             auto    noauto,owner,kudzu 0 0
/dev/hdb2		/mnt/redhat		ext3	defaults	0 0
Im told that you should always work as a user not as root, yet I find that quite restricting. Even using su wont allow me to write to read only file i have to chmod then write then chmod back, and if I want to browse directory tree I cant use file manager.
Any answer to this or is this just how it is?

tried the fdisk -l just to see what it did but nothing happened, I imagine it should return something?

thanks again for your help.
Bob

Last edited by BobNz; 04-24-2004 at 04:30 PM.
 
  


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
Adding additional drives/resizing drives in RAID arrays kheldar Linux - Hardware 1 10-19-2005 01:21 PM
Give user permission to mount/use cdrom drives or usb drives zwyrbla Linux - Newbie 2 08-23-2004 04:30 PM
Re: Mandrake 9.2 destroys LG cd drives...( but what obout Lite-On cd drives?) aweir14150 Mandriva 1 03-03-2004 07:52 PM
Upgrading hard drives on Software raid 1 boot drives. linuxboy123 Linux - General 0 12-11-2003 03:28 PM
how do you get the drives from a non linux SIAS99 Linux - General 2 10-15-2001 07:01 PM

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

All times are GMT -5. The time now is 02:55 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