mount devices

All Gurus once were Newbies
Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.
Before you post please read how to get help
Level 1
Level 1
Posts: 2
Joined: Fri Feb 15, 2013 7:47 am

mount devices

Postby unnilquadium » Fri Feb 15, 2013 8:27 am

I'm totally new to linux and I don't know much about computers.

I've just installed linux mint 14 (MATE) and I can't seem to understand how it deals with drives.

I have only one hard disk. When I open "Computer" on desktop it shows a "drive" named file system (I guess this is not an actual drive) which I am able to open and browse with no problems.
Then I have another "drive" (which I think it's the actual disk) named "250 GB Hard Disk", and when I click on it I get the error "unable to mount location can't mount file". How to get it to work? Is it already mounted? Isn't this the same as the file system?

I have an actual floppy drive on my computer. It runs perfectly when I have a floppy disk inside it, but when I don't I always get an error at start-up:
"Error mounting system-managed device /dev/fd0: Command-line `mount "/media/floppy0"' exited with non-zero exit status 32: mount: /dev/fd0 is not a valid block device".

Mind you, when I DO have a floppy inside it, it runs normally, so I think the system is always trying to mount it at start-up, even when no floppy disk is present.
Any ideas on how to prevent this?


Level 4
Level 4
Posts: 370
Joined: Tue Aug 24, 2010 2:47 am
Location: Stenungsund, Sweden

Re: mount devices

Postby cecar » Fri Feb 15, 2013 8:46 am

Is mint the only operating system on your computer or is it a dualboot?

Open up a terminal and post the output of

Code: Select all

sudo blkid

Level 1
Level 1
Posts: 2
Joined: Fri Feb 15, 2013 7:47 am

Re: mount devices

Postby unnilquadium » Fri Feb 15, 2013 12:01 pm


Yes. Linux Mint is the only OS installed, and is supposedly using all of the hard drive.

Results for sudo blkid are:
/dev/sda1: UUID="0327efb0-be29-4c31-af4b-d0b76a8da7b1" TYPE="ext4"
/dev/sda5: UUID="e9159582-c57a-4ef9-895d-6d05f5da4ef1" TYPE="swap"


Level 3
Level 3
Posts: 124
Joined: Sun Mar 04, 2012 9:06 pm

Re: mount devices

Postby pgmer6809 » Sat Feb 16, 2013 8:54 pm

I hope you get a more detailed answer from some experts.
Firstly Here is a link to a tutorial on the linux file system.

If you know windows at all, then you know that under 'MyComputer' you will see several devices, C:, D:, A: etc. and also some Network locations etc.
In Linux the entire list of all devices is under / (Forward slash). That is the beginning (root).
The other major difference in Linux is that to make a device, or a disk partition visible, you need to 'mount' it. (This is a GOOD thing in general, but it does mean there is an extra step, and extra level of complexity).

In your case you have what amounts to only one 'disk drive' /dev/sda1 the first partition on your hard drive. in Windows this would be the C: drive usually.
This is mounted at "/" as part of the boot process.
Your other partition is /dev/sda5, which linux uses to save stuff to disk when it runs out of memory. This is like the windows 'pagefile.sys' except it is in its own partition instead of being in with other files.

Now lets say you have a file on a floppy disk you want to get at.
To make your floppy visisble you need two things.
a) The Kernel (Linux OS) must have detected the floppy during boot. Usually it wiil create a device called /dev/fd0 when it detects it.
b) you need to 'mount' the device. you could mount it anywhere, but the usual place is in /media/floppy or /media/fd0. (that is a zero)
Check to see that you have a directory called /media by issuing the cmd

Code: Select all

ls -l /media

you should see something like:
drwxr-xr-x 2 root root 4096 Jan 12 22:18 cdrom0
drwxr-xr-x 2 root root 4096 Jan 12 22:18 fd0
drwxr-xr-x 2 root root 4096 Jan 12 22:18 usb0

so now you can put a floppy in the drive and issue the cmd

Code: Select all

sudo mount -t vfat /dev/fd0 /media/fd0

and when sudo prompts you you can enter your password.
If all goes well you can then say:

Code: Select all

ls -l  /media/fd0

to see what is on the disk.
to copy a file called say myjunk.txt to your home directory:

Code: Select all

cp /media/fd0/myjunk.txt ~/mygoodstuff.txt

To explain:
the sudo mount mumbo jumbo above tells linux that the type of media in the drive is a FAT kind of filesystem (as for msdos etc.) and you want to make this drive avaiable through the media/fd0 directory.
You usually need to use sudo to mount things, because for security reasons linux does not by default let users mount stuff. (i.e. they might be mounting disks with viruses on them for example).
If there is no disk in the drive then the mount cmd will fail. The error message you get may not be all that accurate, but that will be the problem most often.
The mount cmd might fail if there is a hardware problem with the drive also, but that is more rare.

There is another aspect to this.
In linux there are many 'magic' files that tell various pieces of linux what to do.
One of these is /etc/fstab
In this file you can specify defaults for various mount options, so you don't have to type them out every time.
In some cases Linux has been configured to automatically detect when a CD or DVD is inserted, or a USB device is connected, or a floppy is inserted and to automatically
take certain actions. But that is another topic, somewhat beyond my expertise to explain.

If you are getting a 'cannot mount floppy' type of error at boot, it is probably because you have a line in /etc/fstab that refers to /dev/fd0 and you have no disk in the drive.
You could try to use an editor to modify fstab (BACK IT UP FIRST), and put a hash mark (#) in front of the line with /dev/fd0 on it.

Code: Select all

cd /etc
sudo cp fstab fstab_original
sudo vi fstab

........ etc.

Return to “Newbie Questions”

Who is online

Users browsing this forum: Stavrose and 12 guests