issue auto mounting to dir w/ a space in name[SOLVED]

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 this

issue auto mounting to dir w/ a space in name[SOLVED]

Postby wm_domino on Fri Jun 22, 2012 3:36 pm

have no issues mounting the drive using fstab as long as the directory's name doesn't have a space in it.

been trying to use: Storage Drive

i think the issue is in fstab, the mount location part of the line has no issues with:

/mnt/Storage

but i've tried using "Storage Drive" and Storage\020Drive and both return errors

the first indicates line 14 in fstab is bad on restart and it doesn't mount.
the second indicates dir doesn't exist and fails to mount also.

i'm sure this is just a case of my syntax in fstab. please help.
Last edited by wm_domino on Fri Jun 22, 2012 6:19 pm, edited 1 time in total.
novice pc user just trying to make mint work for me
wm_domino
Level 3
Level 3
 
Posts: 112
Joined: Tue Aug 09, 2011 3:21 pm

Linux Mint is funded by ads and donations.
 

Re: issue auto mounting to dir w/ a space in name

Postby Habitual on Fri Jun 22, 2012 3:54 pm

maybe
Code: Select all
Storage\ Drive/
?

P.S. HTML code in shell usually is not a good idea "Storage\020Drive"
My DorkBlog
Cirrhus9.com - Managed HA VDSs and Scalable grid solutions.
User avatar
Habitual
Level 7
Level 7
 
Posts: 1924
Joined: Sun Nov 21, 2010 8:31 pm
Location: Under the hood

Re: issue auto mounting to dir w/ a space in name

Postby wm_domino on Fri Jun 22, 2012 4:06 pm

didn't work, returns a 'line 14 in fstab is bad'.
novice pc user just trying to make mint work for me
wm_domino
Level 3
Level 3
 
Posts: 112
Joined: Tue Aug 09, 2011 3:21 pm

Re: issue auto mounting to dir w/ a space in name

Postby Habitual on Fri Jun 22, 2012 4:25 pm

Did you / can you try:

Code: Select all
"Storage\ Drive/"
My DorkBlog
Cirrhus9.com - Managed HA VDSs and Scalable grid solutions.
User avatar
Habitual
Level 7
Level 7
 
Posts: 1924
Joined: Sun Nov 21, 2010 8:31 pm
Location: Under the hood

Re: issue auto mounting to dir w/ a space in name

Postby wm_domino on Fri Jun 22, 2012 4:44 pm

didn't work either, returns same error on boot.
novice pc user just trying to make mint work for me
wm_domino
Level 3
Level 3
 
Posts: 112
Joined: Tue Aug 09, 2011 3:21 pm

Re: issue auto mounting to dir w/ a space in name

Postby altair4 on Fri Jun 22, 2012 5:35 pm

/mnt/Storage\020Drive

That's the traditional way one adds a line in fstab where something has a space in it.

Did you actually create that mountpoint?

What is the output of this command:
Code: Select all
ls -al /mnt

If it's not there then create it:
Code: Select all
sudo mkdir "/mnt/Storage Drive"


BTW, your life will be immensely easier if you adopt the Linux way of doing things and avoid spaces in names whenever possible.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 15
Level 15
 
Posts: 5508
Joined: Tue Feb 03, 2009 10:27 am

Re: issue auto mounting to dir w/ a space in name

Postby HughT on Fri Jun 22, 2012 5:51 pm

man fstab says
If the name of the mount point contains spaces these can be escaped
as `\040'.
Please Edit your post title and add [SOLVED] once your question is resolved.
HughT
Level 5
Level 5
 
Posts: 628
Joined: Thu Oct 20, 2011 1:54 pm
Location: England

Re: issue auto mounting to dir w/ a space in name

Postby altair4 on Fri Jun 22, 2012 5:58 pm

HughT wrote:man fstab says
If the name of the mount point contains spaces these can be escaped
as `\040'.

You are quite correct - my mistake. "\040", "%20" when and where to use each one always confuses me. In this case I made some kind of hybrid out of the two.
Please add a [SOLVED] at the end of your original subject header if your question has been answered and solved.
altair4
Level 15
Level 15
 
Posts: 5508
Joined: Tue Feb 03, 2009 10:27 am

Re: issue auto mounting to dir w/ a space in name

Postby wm_domino on Fri Jun 22, 2012 6:19 pm

total 16
drwxr-xr-x 4 root root 4096 Jun 22 13:56 .
drwxr-xr-x 22 root root 4096 Jun 22 13:12 ..
drwxr-xr-x 4 root root 4096 Jun 21 12:32 Storage
drwxr-xr-x 2 phil phil 4096 Jun 22 13:56 Storage Drive


and yes, it seems '/mnt/Storage\040Drive' works...

thanks so much!
novice pc user just trying to make mint work for me
wm_domino
Level 3
Level 3
 
Posts: 112
Joined: Tue Aug 09, 2011 3:21 pm

Re: issue auto mounting to dir w/ a space in name[SOLVED]

Postby HughT on Fri Jun 22, 2012 6:21 pm

you're welcome. don't forget to edit the title of your first post as SOLVED.
Please Edit your post title and add [SOLVED] once your question is resolved.
HughT
Level 5
Level 5
 
Posts: 628
Joined: Thu Oct 20, 2011 1:54 pm
Location: England

Linux Mint is funded by ads and donations.
 

Return to Newbie Questions

Who is online

Users browsing this forum: No registered users and 5 guests