LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
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 01-19-2013, 09:27 PM   #1
Steve R.
Member
 
Registered: Jun 2009
Location: Morehead City, NC
Distribution: Ubuntu 14.04
Posts: 221

Rep: Reputation: 44
Cannot Mount USB Flash Drive Under FSTAB


I have a modem which allows two USB devices to be attached to it. I inserted a USB drive into it, to be used for backup storage. The file manager recognizes it. Also sbackup (when it works) succesfuly backs up to the USB drive.

This works when executed in the terminal:
Code:
sudo mount -o rw //rt-n56u/sda1 /media/usbdrive
"rt-n56u" is the modem itself
"sda1" is the virtual hard drive since it is a flash drive.

When I run the command below from the terminal, I get an error message:
Code:
sudo mount -a
The error message:
Quote:
mount: special device //rt-n56u/sda1 does not exist
Below is the line of code the FSTAB file which does not work.
Code:
//rt-n56u/sda1 /media/usbdrive vfat rw,user,sync 0 0
Is there anything wrong with the code in the FSTAB file?
Does the existence of the "-" in rt-n56u have an effect?
 
Old 01-20-2013, 03:55 AM   #2
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,901

Rep: Reputation: 746Reputation: 746Reputation: 746Reputation: 746Reputation: 746Reputation: 746Reputation: 746
Yes.
No.

vfat file system type is only used when a drive is physically attached to the computer and you are trying to mount a FAT32 partition. In this instance /sda1 is a share name and does not reference a real drive.

The correct file system type to use is cifs. cifs is actually a networking protocol which is used in linux for sharing files and printers between linux and windows computers.

http://en.wikipedia.org/wiki/Server_Message_Block
http://www.samba.org/

Last edited by michaelk; 01-20-2013 at 04:05 AM.
 
1 members found this post helpful.
Old 01-20-2013, 06:36 PM   #3
Steve R.
Member
 
Registered: Jun 2009
Location: Morehead City, NC
Distribution: Ubuntu 14.04
Posts: 221

Original Poster
Rep: Reputation: 44
Success. Thanks michaelk for providing the clues necessary to figure this out.

As with many errors, this was not one single error, but a vatiety of little errors which had to be tediously eliminated one at a time.

Fisrt it appears that both, smbnetfs and cifs-utils need to be installed: For an apparently outdated tutorial, see MountWindowsSharesPermanently, which does not mention smbnetfs. However, smbnetfs is mentioned in a newer discussion covering Ubuntu 12.xx located here: 12.10 cifs shares not mounting after modifying /etc/fstab. One respondent wrote: "fixed my trouble under a fresh 64-bit install of 12.10. (Also had installed smbnetfs before looking here. I believe both are needed, but am not positive."

Second, as with many programs the software has "evolved", some of the advice related to cifs appears dated and some of the options that seemingly should have work with FSTAB seem to have been deprciated (in terms of cifs), such as sync. See this FSTAB file descirption.

Finally, note that "RT-N56U" is captialized in the line of code below. Lower case worked in terminal mode, but not from the FSTAB file!!!

Working code below.
Code:
//RT-N56U/sda1 /media/usbdrive cifs guest,rw,nofail 0 0
Any obviously missing cifs options that should be added?

The backup program that I have been using (sbackup) seems to periodically fail when backing up to an external device. The hope is that by having the USB flahdrive already mounted, that sbackup will become more reliable. I will soon findout.

Last edited by Steve R.; 01-20-2013 at 10:44 PM.
 
Old 03-24-2013, 11:54 AM   #4
Steve R.
Member
 
Registered: Jun 2009
Location: Morehead City, NC
Distribution: Ubuntu 14.04
Posts: 221

Original Poster
Rep: Reputation: 44
It is now two months later. sbackup has been working without a problem now (to the external device) that the USB flash drive is automounted by FSTAB.
 
  


Reply

Tags
fstab, sbackup


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
when i mount my USB Flash Drive A Messenge has come that mount: can't find /dev/sda/h feda82 Red Hat 2 12-24-2005 07:16 AM
when i mount my USB Flash Drive A Messenge has come that mount: can't find /dev/sda/h feda82 Red Hat 1 12-24-2005 04:25 AM
when i mount my USB Flash Drive A Messenge has come that mount: can't find /dev/sda/h feda82 Red Hat 2 12-24-2005 02:15 AM


All times are GMT -5. The time now is 11:28 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration