Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to handle spaces in filenames

Status
Not open for further replies.
Feb 27, 2008
9
0
0
US
Hi,

I've got files on an AIX system that have spaces in the filenames. The spaces were created by CAD software and are needed for revision levels, etc. My question is how to restore a single file for a VG backup.

Here's what I tried ("20003 b" is my file name in the examples):

1) Just using the path and file name , ex. restorevgfiles -s -r -f/dev/rmt1 abc/def/20003 b

2) Putting the whole path in single quotes : restorevgfiles -s -r -f/dev/rmt1 'abc/def/20003 b'

3) putting just the file in single quotes : restorevgfiles -s -r -f/dev/rmt1 abc/def/'20003 b'

The only way I could get it back was using a wildcard : restorevgfiles -s -r -f/dev/rmt1 abc/def/20003* , which as along as the file is unique, that works, but if not, i need to determine how to tell it the exact file

Suggestions ??
 
Double quote it "abc/def/20003 b"

Mike

"Whenever I dwell for any length of time on my own shortcomings, they gradually begin to seem mild, harmless, rather engaging little things, not at all like the staring defects in other people's characters."
 
See my failed syntaxes below.....

restorevgfiles -s -r -f'/backup/lloyd.savevg' ''./raid5/crap/D_30581100 01 b''
restorevgfiles -s -r -f'/backup/lloyd.savevg' "./raid5/crap/D_30581100 01 b"
restorevgfiles -s -r -f'/backup/lloyd.savevg' './raid5/crap/'D_30581100 01 b''
restorevgfiles -s -r -f'/backup/lloyd.savevg' './raid5/crap/"D_30581100 01 b"'
restorevgfiles -s -r -f'/backup/lloyd.savevg' "./raid5/crap/'D_30581100 01 b'"
restorevgfiles -s -r -f'/backup/lloyd.savevg' ./raid5/crap/'D_30581100 01 b'
restorevgfiles -s -r -f'/backup/lloyd.savevg' ./raid5/crap/"D_30581100 01 b"
restorevgfiles -s -r -f'/backup/lloyd.savevg' ./raid5/crap/*
x ./raid5/crap/D_30581100 01 b
restorevgfiles -s -r -f'/backup/lloyd.savevg' ./raid5/crap/''D_30581100 01 b''
 
Using quotes around filenames w/ spaces generally does the trick. But I'm betting the restorevgfiles is a shell script which somehow looses the quotes around the name of the file you want to restore, because somewhere along the line that shell script invokes a restore command and the spaces then separate 3 different files to restore and none of 'em are found...

I'd try with double and single quoting:

[tt]restorevgfiles -s -r -f/backup/lloyd.savevg "'./raid5/crap/D_30581100 01 b'"[/tt]



HTH,

p5wizard
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top