Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
using paths containing spaces in fstab
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
supermihi
Guru
Guru


Joined: 09 Feb 2005
Posts: 348

PostPosted: Sun Feb 27, 2005 9:19 am    Post subject: using paths containing spaces in fstab Reply with quote

I want to create an fstab entry to mount a filesystem in a path that contains spaces. Unfortunally, fstab seems not to support to write the spaces containig path in "..." Is there any way to manage this?
_________________
"You may say I'm a dreamer, but I'm not the only one."
Back to top
View user's profile Send private message
amiatrome
Apprentice
Apprentice


Joined: 28 Jun 2004
Posts: 180
Location: Campus | Arena Country Club | Home

PostPosted: Sun Feb 27, 2005 9:48 am    Post subject: Reply with quote

You could try enclosing the path in double-quotes "/mnt/spaced out path" or escaping the space, /mnt/spaced\ out\ path

I never tried them before but I figure it should be pretty similar to the bash shell.

//edit just did a google and RTFM. Seems like it may not work after all.
Quote:
Each filesystem is described on a separate line; fields on each line are separated by tabs or spaces.

Maybe its time to remove them spaces. :wink:
_________________
blog | homepage | alias | prompts
Back to top
View user's profile Send private message
supermihi
Guru
Guru


Joined: 09 Feb 2005
Posts: 348

PostPosted: Sun Feb 27, 2005 10:45 am    Post subject: Reply with quote

Yes, I already tried quotes and escape characters. This really isn't nice. The only way is to add appropriate mount-command as init-script. :(
_________________
"You may say I'm a dreamer, but I'm not the only one."
Back to top
View user's profile Send private message
Naib
Watchman
Watchman


Joined: 21 May 2004
Posts: 6051
Location: Removed by Neddy

PostPosted: Sun Feb 27, 2005 11:37 am    Post subject: Reply with quote

Code:

jrb@Fluid ~ $ cd /mnt/w2k/

jrb@Fluid w2k $ ls
AUTOEXEC.BAT*  Documents and Settings/  RECYCLER/                   boot.ini*
BJPrinter/     IO.SYS*                  System Volume Information/  make.txt*
BcBtRmv.log*   MSDOS.SYS*               WINNT/                      ntldr*
CONFIG.SYS*    NTDETECT.COM*            arcldr.exe*                 xorg.conf*
Config.Msi/    Program Files/           arcsetup.exe*

jrb@Fluid w2k $ cd Documents\ and\ Settings/


you see the forward slash - that might work
_________________
Quote:
Removed by Chiitoo
Back to top
View user's profile Send private message
supermihi
Guru
Guru


Joined: 09 Feb 2005
Posts: 348

PostPosted: Sun Feb 27, 2005 3:11 pm    Post subject: Reply with quote

No, that doesn't work, that's what I meant with "Escape characters".
_________________
"You may say I'm a dreamer, but I'm not the only one."
Back to top
View user's profile Send private message
compu-tom
Guru
Guru


Joined: 09 Jan 2003
Posts: 415
Location: Berlin, Germany

PostPosted: Sun Feb 27, 2005 3:21 pm    Post subject: Re: using paths containing spaces in fstab Reply with quote

supermihi wrote:
I want to create an fstab entry to mount a filesystem in a path that contains spaces.

How about this?: symlink "/path /with /spaces" to a "/path/without/spaces" and enter the symlink's path to fstab.
Back to top
View user's profile Send private message
supermihi
Guru
Guru


Joined: 09 Feb 2005
Posts: 348

PostPosted: Sun Feb 27, 2005 4:10 pm    Post subject: Reply with quote

I already had the same idea, but I want to do this in a FAT32 filesystem, which doesn't support symlinks. I thinK I'll just write something like
Code:
mount /dev/hdb7 "/path/with/spaces"
as an initscript.
_________________
"You may say I'm a dreamer, but I'm not the only one."
Back to top
View user's profile Send private message
shanenin
Guru
Guru


Joined: 28 Nov 2003
Posts: 578
Location: Rochester, MN U.S.A

PostPosted: Sun Feb 27, 2005 4:31 pm    Post subject: Reply with quote

is this by any chance a samba share? if it is, you may have no luck getting it to work. I changed my "My Documuets" to "mydocuments", to make it work.
_________________
http://brighteyedcomputer.com
Back to top
View user's profile Send private message
supermihi
Guru
Guru


Joined: 09 Feb 2005
Posts: 348

PostPosted: Sun Feb 27, 2005 4:50 pm    Post subject: Reply with quote

For now, it's not a share, but possibly I want to share it later. The Problem is that I also want to use it with my Windows installation.
_________________
"You may say I'm a dreamer, but I'm not the only one."
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum