General [M]ayhem

Go Back   General [M]ayhem > Real Time Sub-Forums > CompuGlobalHyperMegaNet
Register Members List Calendar

Reply
 
Thread Tools
matt00926
baaaaaa
 
matt00926's Avatar
 
Question about mounting storage partition in ubuntu

Having trouble mounting my storage partition. Here is the terminal log

matt@matt-desktop:~$ # sudo umount /dev/hda5
matt@matt-desktop:~$ mount /dev/hda5
[mntent]: line 8 in /etc/fstab is bad
mount: can't find /dev/hda5 in /etc/fstab or /etc/mtab
matt@matt-desktop:~$


How do i access /etc/fstab, and also how do i finally mount this partition. I finally figured out how to mount my windows partition so this is the last thing.
__________________
cd09d75f80807fd8baa143b39fa895eb [pornmay.com]
Old 01-16-2007, 04:36 PM matt00926 is offline  
Reply With Quote
#1  

Advertisement [Remove Advertisement]

Gtwy
 
open the terminal, sudo bash to get into root.


nano /etc/fstab

that will bring up fstab, copy the contents and paste them here using the [code] brackets.
Old 01-16-2007, 04:43 PM Gtwy is offline  
Reply With Quote
#2  

matt00926
baaaaaa
 
matt00926's Avatar
 
Quote:
Originally Posted by Gtwy View Post
open the terminal, sudo bash to get into root.


nano /etc/fstab

that will bring up fstab, copy the contents and paste them here using the [code] brackets.

Code:
  GNU nano 1.3.10                            File: /etc/fstab

# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/hda7       /               ext3    defaults,errors=remount-ro 0       1
/dev/hda8       none            swap    sw              0       0
/dev/hdc        /media/cdrom0   udf,iso9660 user,noauto     0       0
/dev/hda1 /media/windows ntfs-fuse auto,gid=1001,umask=0002 0 0sudo adduser matt ntfs
/dev/hda1    /media/windows ntfs  nls=utf8,umask=0222 0    0

HDA5 is the storage partition
__________________
cd09d75f80807fd8baa143b39fa895eb [pornmay.com]
Old 01-16-2007, 04:47 PM matt00926 is offline  
Reply With Quote
#3  

Gtwy
 
Quote:
Originally Posted by matt00926 View Post
Code:
  GNU nano 1.3.10                            File: /etc/fstab

# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/hda7       /               ext3    defaults,errors=remount-ro 0       1
/dev/hda8       none            swap    sw              0       0
/dev/hdc        /media/cdrom0   udf,iso9660 user,noauto     0       0
/dev/hda1 /media/windows ntfs-fuse auto,gid=1001,umask=0002 0 0sudo adduser matt ntfs
/dev/hda1    /media/windows ntfs  nls=utf8,umask=0222 0    0
HDA5 is the storage partition



uh, it's not in fstab. you can't just type mount /dev/hda5... you have to type:

Code:
mount /dev/hda5 /mount/to/this/directory
Old 01-16-2007, 05:03 PM Gtwy is offline  
Reply With Quote
#4  

matt00926
baaaaaa
 
matt00926's Avatar
 
I'm just new this day to ubuntu so bear with me. In a blank terminal I inputted the following:

Code:
matt@matt-desktop:~$ sudo bash
root@matt-desktop:~# mount /dev/hda5 /mount/to/this/directory
mount: mount point /mount/to/this/directory does not exist
root@matt-desktop:~#
Do I need to add a line in fstab? Can you just pretend we are starting from the beginning sorry
__________________
cd09d75f80807fd8baa143b39fa895eb [pornmay.com]
Old 01-16-2007, 05:18 PM matt00926 is offline  
Reply With Quote
#5  

Shad0w
 
Quote:
Originally Posted by matt00926 View Post
I'm just new this day to ubuntu so bear with me. In a blank terminal I inputted the following:

Code:
matt@matt-desktop:~$ sudo bash
root@matt-desktop:~# mount /dev/hda5 /mount/to/this/directory
mount: mount point /mount/to/this/directory does not exist
root@matt-desktop:~#
Do I need to add a line in fstab? Can you just pretend we are starting from the beginning sorry



He didn't actually mean /mount/to/this/directory

If you want to mount it to /blah, then you do mount /dev/hda5 /blah


Corrected fstab for you:

Code:
# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/hda7       /               ext3    defaults,errors=remount-ro 0       1
/dev/hda8       none            swap    sw              0       0
/dev/hdc        /media/cdrom0   udf,iso9660 user,noauto     0       0
/dev/hda5    /media/windows ntfs  nls=utf8,umask=0222 0    0
Replace it with what i've put above, then type: mount /media/windows

Also, do this:

fdisk /dev/hda

at the prompt hit "p" to print out the parition table, thne paste it in here so I can confirm what i just gave you is correct

Last edited by Shad0w; 01-16-2007 at 05:52 PM..
Old 01-16-2007, 05:48 PM Shad0w is offline  
Reply With Quote
#6  

Gtwy
 
oh god....
Old 01-16-2007, 06:03 PM Gtwy is offline  
Reply With Quote
#7  

matt00926
baaaaaa
 
matt00926's Avatar
 
Quote:
Originally Posted by Gtwy View Post
oh god....

lol yeah brain fart..

how do i save the edited fstab?
__________________
cd09d75f80807fd8baa143b39fa895eb [pornmay.com]
Old 01-16-2007, 06:15 PM matt00926 is offline  
Reply With Quote
#8  

VoodoochildBC
cutie patootie <3 bonnie
 
VoodoochildBC's Avatar
 
Quote:
Originally Posted by matt00926 View Post
lol yeah brain fart..

how do i save the edited fstab?
If you're using nano/pico it's ctrl + o.
Old 01-16-2007, 06:26 PM VoodoochildBC is offline  
Reply With Quote
#9  

2slow
Whatsisname
I'm a pederast. 12yr old boys turn me on!
 
2slow's Avatar
 
99% of the time when using sudo to open a root prompt, run "sudo -i", do not run "sudo bash" like Gtwy said.

If you want to use superuser priveledges for a single command or two, then do sudo command
__________________
DESU DESU DESU DESU DESU
DESU DESU DESU DESU DESU
DESU DESU DESU DESU DESU
DESU DESU DESU DESU DESU
DESU DESU DESU DESU DESU
DESU DESU DESU DESU DESU
DESU DESU DESU DESU DESU

RMS of the [M] GNU\Linux Krew 2006

Last edited by Whatsisname; 01-16-2007 at 06:56 PM..
Old 01-16-2007, 06:54 PM 2slow is offline  
Reply With Quote
#10  

matt00926
baaaaaa
 
matt00926's Avatar
 
Shadow - I replaced the fstab and did what you said. I rebooted and the storage is mounted but now my windows xp drive (ntfs) is gone. Here is the print of the partitions

Code:
            

Device Boot      Start         End      Blocks   Id  System
/dev/hda1   *           1       10164    81642298+   7  HPFS/NTFS
/dev/hda2           10165       30401   162553702+   f  W95 Ext'd (LBA)
/dev/hda5           10165       23202   104727703+   7  HPFS/NTFS
/dev/hda6           27836       30401    20611363+   7  HPFS/NTFS
/dev/hda7   *       23203       27643    35672301   83  Linux
/dev/hda8           27644       27835     1542208+  82  Linux swap / Solaris

I tried to do mount /dev/hda1 etc but i'm not sure what to do


By the way I have 3 partitions on one drive
-windows, storage, and a partition with nothing on it
__________________
cd09d75f80807fd8baa143b39fa895eb [pornmay.com]
Old 01-16-2007, 07:23 PM matt00926 is offline  
Reply With Quote
#11  

Gtwy
 
Quote:
Originally Posted by 2slow View Post
99% of the time when using sudo to open a root prompt, run "sudo -i", do not run "sudo bash" like Gtwy said.

If you want to use superuser priveledges for a single command or two, then do sudo command

it's the same thing, why do you say "do not" as if sudo bash is going to break your system or something?!
Old 01-16-2007, 09:44 PM Gtwy is offline  
Reply With Quote
#12  

VoodoochildBC
cutie patootie <3 bonnie
 
VoodoochildBC's Avatar
 
Quote:
Originally Posted by Gtwy View Post
it's the same thing, why do you say "do not" as if sudo bash is going to break your system or something?!
Because you're logging yourself into another shell session when you do that. Kind of defeats the purpose of sudo.
Old 01-16-2007, 10:48 PM VoodoochildBC is offline  
Reply With Quote
#13  

Cyrius
 
Code:
# /etc/fstab: static file system information.
#
# <file system> <mount point>   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/hda7       /               ext3    defaults,errors=remount-ro 0       1
/dev/hda8       none            swap    sw              0       0
/dev/hdc        /media/cdrom0   udf,iso9660 user,noauto     0       0
/dev/hda1    /media/windows ntfs  nls=utf8,umask=0222 0    0
/dev/hda5    /media/storage ntfs  nls=utf8,umask=0222 0    0
Should fix your fstab. You'll (probably) have to create the directory /media/storage, using the command sudo mkdir /media/storage

Your windows partition will be on /media/windows (mount it with mount /media/windows) and your storage partition will be on /media/storage (mount it with mount /media/storage).

Just fyi (for future reference should you ever need to mount something else):
The general format of the mount command is as follows:
mount [-t fstype] something somewhere
something would be the location of the device (the storage partition you were trying to mount would be /dev/hda5).
somewhere would be a physical directory on your hard drive. In ubuntu, disks are usually mounted to a subdirectory of the /media directory.

If what you're trying to mount has an entry in the fstab, then you only need to specify one of the above arguments, as mount will look up either the something or somewhere in your fstab to get the missing argument(s).

Note that if the filesystem of what you're trying to mount isn't something that's easy for Linux to autodetect, you might also have to provide a type with the -t option, as shown above.

Type man mount at a command line to get the manual page (and all of the specifics) about the mount command - this goes for every command really, as you can type man justaboutanything to get info about how a command works.
__________________
[M] GNU/Linux/BSD Crew
ruby -e "puts (0..5).map{|x|-0.45*x**5+4.33*x**4-10.25*x**3-7.3*x**2+36*x+99}.pack('c*')"

Last edited by Cyrius; 01-16-2007 at 11:32 PM..
Old 01-16-2007, 11:30 PM Cyrius is offline  
Reply With Quote
#14  

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 On
HTML code is Off

Forum Jump



All times are GMT -7. The time now is 04:31 AM.



Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.