Backup script special characters

Advertisement

namit
Joined:
Posts:
7
Location:
Ireland

Backup script special characters

Hey I have a script that backups my computer every night but it crashes out when i comes across any file that has special characters that are not English like Ukranian ones or ??? marks in them. How do i get around this?

It seams to come back with file does not exist skip(S) retry(R) abort(A) but it just aborts.

Thanks


# VPSLink Sample Backup Script for WinSCP
option exclude "*.mp4; *.lnk; *.exe; *.msi; My Pictures; My Music; My Videos; @college; .metadata;"

# Comment out the next two lines to test
option batch on
option confirm off

# Connect - format: user:password@host
open user:pass@server.org

# Force binary mode transfer
option transfer binary

# Download backup file to remote directory
synchronize remote F:\+myfiles\ /home/user/recent

# Disconnect
close

# Exit WinSCP
exit

only seams to happen with script not with GUI but can not schedule the gui to run every night.

Reply with quote

Advertisement

namit
Joined:
Posts:
7
Location:
Ireland

Backup started at 10/11/2008
exclude      *.mp4; *.lnk; *.exe; *.msi; My Pictures; My Music; My Videos; @college; .metadata; *.cab; *.exe; *.msi;
batch        on
confirm      off
Searching for host...
Connecting to host...
Authenticating...
Using username "test".
Authenticating with pre-entered password.
Authenticated.
Starting the session...

....
File or folder 'C:\Shared Docs\Update 21 April 2008\Shared Docs\Ukraine\13-17 ?ctober - Key Notes.doc' does not exist.
- Hide quoted text -
System Error.  Code: 123.
The filename, directory name, or volume label syntax is incorrect
(A)bort, (R)etry, (S)kip, Ski(p) all: Abort
Session 'test@server.server.org' closed.
No session.
Error: 09/11/2008

This is the output of script backup.

Thanks

Reply with quote

namit
Joined:
Posts:
7
Location:
Ireland

Gui shows

System Error.  Code: 123.
The filename, directory name, or volume label syntax is incorrect

but i would prefer to have it all scripted.

Reply with quote

Advertisement

namit
Joined:
Posts:
7
Location:
Ireland

I put in thing below to my script and it solved it for some copying

option exclude "*.mp4; *.lnk; *.exe; *.msi; My Pictures; My Music; My Videos; @college; .metadata; *.cab; *.exe; *.msi; *_?*; ~$?*; *-?*; Tatjana;"

but have a corrupt file that is called
???? ???? ?? .doc
but putting *?* just stops copying everything.

Think because ? is being picked up as a regex am i right?

If so is there a way of solving this and making it not come out as a regex.

Thanks again

Reply with quote

martin
Site Admin
martin avatar

namit wrote:

If so is there a way of solving this and making it not come out as a regex.
You can try to specify full file name "???? ???? ?? .doc" and hope it does not match another file. However I do not think that the question marks are actually question marks. So it may not help.

Reply with quote

namit

Think its because the file is corrupted, is there a way in scripts like the gui to say if file name is two long or corrupt to skip over it and not abort?

Thanks

Reply with quote

martin
Site Admin
martin avatar

namit wrote:

Think its because the file is corrupted, is there a way in scripts like the gui to say if file name is two long or corrupt to skip over it and not abort?
You can use "option batch continue".

Reply with quote

Advertisement

Anant
Guest

winscp login error

Hello,

when I am trying to login through winscp to remote system it is given me connection refused error

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
40,476
Location:
Prague, Czechia

Re: winscp login error

Anant wrote:

when I am trying to login through winscp to remote system it is given me connection refused error
Sorry, your post does not include enough information.

Please read how to troubleshoot problems with WinSCP. If it turns out that you are not able to help yourself, read how to ask for support or report bugs efficiently, so others can help you.

Also start a new thread as I do not see any relation to this one.

Reply with quote

iannis
Guest

"option batch continue" does not work for this

martin wrote:

namit wrote:

Think its because the file is corrupted, is there a way in scripts like the gui to say if file name is two long or corrupt to skip over it and not abort?
You can use "option batch continue".

I have exactly the same problem (code 123) with french accented characters in the filename. "Skip" button in the GUI works ok. However in the script, although "option batch continue" answers with "Skip", the script exits after that.

Version 4.3.6 build 1655.

Thanks for this great software!

Reply with quote

martin
Site Admin
martin avatar
Joined:
Posts:
40,476
Location:
Prague, Czechia

Re: "option batch continue" does not work for this

iannis wrote:

I have exactly the same problem (code 123) with french accented characters in the filename. "Skip" button in the GUI works ok. However in the script, although "option batch continue" answers with "Skip", the script exits after that.

Version 4.3.6 build 1655.
Can you try unicode 5.0.5 beta?

Reply with quote

Advertisement

Guest

Re: "option batch continue" does not work for this

martin wrote:

iannis wrote:

I have exactly the same problem (code 123) with french accented characters in the filename. "Skip" button in the GUI works ok. However in the script, although "option batch continue" answers with "Skip", the script exits after that.

Version 4.3.6 build 1655.
Can you try unicode 5.0.5 beta?

Problem solved in 5.0.5 beta, no more errors with Code 123.

Filenames with accents in unnicode encoding (the usual case) are synchronized without problem.

Some files, saved from mail attachments, contain accented letters not in unicode. These files are first deleted during synchronization ("synchronize remote -delete") and then transfered again; this happens in every synchronization. I had just to rename these files and type again the accented characters so that they become unicode and everything is fine now, they are synchronized only once.

Thanks again.

Reply with quote

Advertisement

You can post new topics in this forum