cancel
Showing results for 
Search instead for 
Did you mean: 

FTP archiving from Unix to Windows server where filename contains invalid characters for Windows

former_member214137
Participant
0 Kudos

Hi,

The scenario I have is I have to FTP file(s) from a third party's Unix server the filename contains colons in between the time stamp on the file. PI is on a windows server and colons are invalid characters on windows so I am unable to archive on the PI server with the file name in it's current state.

I have tried a windows registry change that enables an automatic file name character translation for Windows and UNIX operating systems but this has not worked with archiving from PI.

Options I have looked at:

1. Archive locally on the third party vendor ftp server and periodically use Filezilla to download the files in bulk to our archive server, the character translation works here, but this solution is not elegant.

2. Archive to a mapped local unix server and use a scipt to rename and archive the files.

3. Ask third party to rename the file. Apparently this is too hard and no one else has issues.

The solution I would like would be to copy the file post message processing using OS commands.

I was looking at doing the following:

1. copy source filename removing the colons

2. next call a batch script on the server to rename the source file with the new filename from step 1.

3. copy new file to the windows server.

4. delete original file

I'm happy with step 1 and with writing Unix batch file to copy and delete the original file. What I'm not sure about is if I can actually call a batch file on the third party server and copying the file back to our server via the sender file adapter.

Is this possible and if so how? I have spent several hours searching for solutions but without result.

regards

Julian

Accepted Solutions (1)

Accepted Solutions (1)

former_member214137
Participant
0 Kudos

Resolution was to install an app called FTPDaemon on the PI server and configure it to modify the source filenames.

Answers (2)

Answers (2)

iaki_vila
Active Contributor
0 Kudos

Hi  Julian,

Sorry im a bit confused, are you using PI file adapter to move the files from one ftp to the other location?. In the adapter file you can establish the files as binary files.

Regards.

former_member214137
Participant
0 Kudos

Hi Iñaki,

Thanks for the response.The moving of files occurs when we archive the files. The issue here is the naming convention used is not allowed on Windows servers and hence we cannot archive which is then causing the entire process to fail.

Julian

stefan_grube
Active Contributor
0 Kudos

The easiest solution would be asking the provider of the file to avoid colons in the file name.

former_member214137
Participant
0 Kudos

Hi Stefan,

It is enough to make a grown man cry.

Apparently computer says "No" when asking for file name to be changed, date timestamp isn't flexible.

I can't criticise as PI doesn't have any flexibility as to the timestamp format either, that I'm aware of.

Looks like I'll have to go with either option 1 or 2 at the moment.

cheers

Julian