LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
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 11-07-2003, 06:04 PM   #1
iLLuSionZ
Member
 
Registered: Oct 2003
Location: MI
Distribution: Knoppix 3.3 = XP = Mandrake 9.2
Posts: 343

Rep: Reputation: 30
question 2


===============================
[joe@localhost joe]$ su -
Password:
[root@localhost root]# mkdir /mnt/windows
[root@localhost root]# kwrite /etc/fstab
[root@localhost root]# mount /dev/hdb2
[mntent]: warning: no final newline at the end of /etc/fstab
mount: wrong fs type, bad option, bad superblock on /dev/hdb2,
or too many mounted file systems
(aren't you trying to mount an extended partition,
instead of some logical partition inside?)
[root@localhost root]# mount /dev/hdb1
[mntent]: warning: no final newline at the end of /etc/fstab
mount: /dev/hdb1 already mounted or /mnt/c busy
mount: according to mtab, /dev/hdb1 is already mounted on /mnt/c
[root@localhost root]# kwrite /etc/fstab
============================
heres my fstab

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/cdrom1 /mnt/cdrom1 udf,iso9660 noauto,owner,kudzu,ro 0 0
/dev/fd0 /mnt/floppy auto noauto,owner,kudzu 0 0
/dev/hdb1 /mnt/c ntfs auto,owner,ro, 0 0
/dev/hdb2 /mnt/windows ntfs auto,owner,ro, 0 0
============================
anything wrong? i tried to mount c on hdb1 but it didnt work..
i have 3 partitions on it for music and movies.. so i tried hdb2
and it still didnt work...

i just tried to access it in konqueror and it said only root can access /windows...
WTF i typed su - in the window a million times.. how do i get root all the time?
i press ctr alt f2 and type su - then p/w and it says incorrect login.. BAH
===========================
[joe@localhost boot]$ su -
Password:
[root@localhost root]# mount /dev/hdb1
mount: /dev/hdb1 already mounted or /mnt/c busy
mount: according to mtab, /dev/hdb1 is already mounted on /mnt/c
[root@localhost root]# mount /dev/hdb2
mount: wrong fs type, bad option, bad superblock on /dev/hdb2,
or too many mounted file systems
(aren't you trying to mount an extended partition,
instead of some logical partition inside?)
[root@localhost root]# mount /dev/hd3
mount: can't find /dev/hd3 in /etc/fstab or /etc/mtab
[root@localhost root]#
 
Old 11-07-2003, 06:23 PM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,702

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
To see how the drive is partitioned log in as root
fdisk -l /dev/hdb

An extended partiton is a container for logical drives and can not be mounted. The reason for extended partition / logical drives was to break the 4 parimary partition limit from the original Hard disk drive design. Logical partitions start at 5.

>>question 2a. warning: no final newline at the end of /etc/fstab

You need to insert an EOL character by moving the cursor to the end of the last line of the fstab file and press the enter key.
 
Old 11-07-2003, 06:49 PM   #3
iLLuSionZ
Member
 
Registered: Oct 2003
Location: MI
Distribution: Knoppix 3.3 = XP = Mandrake 9.2
Posts: 343

Original Poster
Rep: Reputation: 30
i knew that lol.. i forgot though...

and about the root thing... is there diff ways to do it? i go to terminal and type su - then p/w and it gives me temp root access... i want a perm access if possible
 
Old 11-07-2003, 07:06 PM   #4
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,702

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
There are several reasons not to log in as root on a perm basis. linux commands can be cryptic at times. If you make a mistake and wipe out something major your SOL because undeleting can be very difficult to impossible depending on the filesystem. The second important reson not to be root is if your connected to the internet you could be allowing root access to anyone if your system has any security vuneralbilities.

I don't run Redhat so I am unaware how to renable the root login. Have you looked at the documentation at Redhat's website?

Last edited by michaelk; 11-07-2003 at 07:07 PM.
 
Old 11-07-2003, 07:09 PM   #5
Azmeen
Senior Member
 
Registered: May 2003
Location: Malaysia
Distribution: Slackware, LFS, CentOS
Posts: 1,307

Rep: Reputation: 47
Try mount /mnt/c instead.
 
Old 11-07-2003, 07:32 PM   #6
iLLuSionZ
Member
 
Registered: Oct 2003
Location: MI
Distribution: Knoppix 3.3 = XP = Mandrake 9.2
Posts: 343

Original Poster
Rep: Reputation: 30
i did already... its not showed.. i think its mounted but i dont have permissions to access it....
 
Old 11-07-2003, 07:43 PM   #7
Azmeen
Senior Member
 
Registered: May 2003
Location: Malaysia
Distribution: Slackware, LFS, CentOS
Posts: 1,307

Rep: Reputation: 47
Change the /dev/hdb1 line to this:
Code:
/dev/hdb1         /mnt/c        ntfs         noauto,users,ro         0 0
Your old line has a trailing comma, that is what's causing the errors you mentioned earlier. I'd recommend using the users setting instead of owner so that non-root users can view the partition, this is based on assumption that this machine is only used by you and/or trusted people only.

I don't recommend automounting the NTFS partition... you'll have problems mounting it as non-root.

Last edited by Azmeen; 11-07-2003 at 07:48 PM.
 
Old 11-07-2003, 07:45 PM   #8
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,702

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
Here is some more reading:

http://linux-ntfs.sourceforge.net/info/ntfs.html#4.10

Last edited by michaelk; 11-07-2003 at 07:47 PM.
 
Old 11-09-2003, 02:16 AM   #9
iLLuSionZ
Member
 
Registered: Oct 2003
Location: MI
Distribution: Knoppix 3.3 = XP = Mandrake 9.2
Posts: 343

Original Poster
Rep: Reputation: 30
i tried the "users" and it didnt work... i got a few pics for you if youll take a look.... tell me whats wrong ok?

http://hardwarewiz.com/forums/attach...s=&postid=6096


http://hardwarewiz.com/forums/attach...s=&postid=6098

thanks alot
 
Old 11-09-2003, 07:15 AM   #10
Azmeen
Senior Member
 
Registered: May 2003
Location: Malaysia
Distribution: Slackware, LFS, CentOS
Posts: 1,307

Rep: Reputation: 47
On your Konsole, you're logged in as root... if you've mounted the partition as root, only root can view it. Unmount it first... then mount as a normal user, you should be able to access the partition then.

Your second screenshot shows the user flag... which is wrong... listen to good advice... use users instead.
 
Old 11-09-2003, 07:56 AM   #11
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,702

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
http://www.justlinux.com/nhf/Filesys...lesystems.html

Since it appears that you haven't read any of my other links or appeared to search for the answer yourself:

Change your /etc/fstab file
/dev/hdb1 /mnt/windows ntfs ro,umask=0222 0 0

If you read the man pages for mount on user,users options. With user can mount but the only the user that mounted can unmount. Users allows any user to unmount regardless of who mounted it.

Make sure that the permissions of the directory you want to mount the NTFS partition is set for read / write with hdb1 unmounted.

BTW if you haven't figured it out your other drives are hdb5 and hdb6.
 
Old 11-09-2003, 10:26 AM   #12
iLLuSionZ
Member
 
Registered: Oct 2003
Location: MI
Distribution: Knoppix 3.3 = XP = Mandrake 9.2
Posts: 343

Original Poster
Rep: Reputation: 30
ok so i change that last line to
/dev/hdb1 /mnt/windows ntfs ro,umask=0222 0 0

how do i unmount a drive?
i tried to unmount the /c by right clicking icon but it said its not in fstab so what do i put in there to unmount it?

Quote:
Make sure that the permissions of the directory you want to mount the NTFS partition is set for read / write with hdb1 unmounted.
how do i set the permissions to a file or folder? ls -l something?
can i set every file read write access?
 
Old 11-09-2003, 10:47 AM   #13
michaelk
Moderator
 
Registered: Aug 2002
Posts: 25,702

Rep: Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896Reputation: 5896
Quote:
ok so i change that last line to
/dev/hdb1 /mnt/windows ntfs ro,umask=0222 0 0

how do i unmount a drive?
i tried to unmount the /c by right clicking icon but it said its not in fstab so what do i put in there to unmount it?
Where do you have the NTFS drive mounted? /mnt/windows or /mnt/c?
Log in as root:
In a console window.
umount /mnt/c

The only way a regular user can mount / unmount a filesystem is if there is an entry in the /etc/fstab file and it has either the user or users option.

Quote:
how do i set the permissions to a file or folder? ls -l something?
can i set every file read write access?
Did you every read the URL I posted on file permisions from your
1st question? You need to use the chmod command. Setting everyfile to read / write is almost as bad as being logged in as root all of the time.
 
Old 11-09-2003, 01:05 PM   #14
iLLuSionZ
Member
 
Registered: Oct 2003
Location: MI
Distribution: Knoppix 3.3 = XP = Mandrake 9.2
Posts: 343

Original Poster
Rep: Reputation: 30
i had it mounted to /c but moved it to /windows....

o ok i forgot i read that.
 
  


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
Question, Apples Contribution to Open Source + MacOs file structure question Higgy3k Other *NIX 5 07-25-2005 04:23 AM
Not your regular GRUB question - just a short question for a fried MBR!! ziphem Linux - General 3 01-31-2005 01:51 PM
2 part question: Speeding up MDK9.1/GNOME question wardialer Linux - Newbie 6 10-14-2004 03:16 PM
login prompt question & kde scheme question JustinCoyan Slackware 2 06-09-2004 02:02 PM
RE: Suse 8.0 hardware question {newbie question, pls help} Radiouk Linux - Distributions 2 06-04-2002 12:53 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

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