Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Why do I still get error code returns even the file uploads by sftp to window server succesfully?

Posted on 2008-06-09
5
Medium Priority
?
1,924 Views
Last Modified: 2013-12-20
Dear Expert,

When I tried to upload the file from unix machine to remote window ftp server in Perl script, my perl script dies since the code catches the $CHILD_ERROR with value 1536 from the system call even the file is transfered to the ftp server completely.  

Then I tried to do the same thing from the unix command line, and the following is what I have:

I am using public key authorization.
>sftp user@serveraddress
GlobalSCAPE Secure FTP Server * UNREGISTERED COPY *
sftp> put test.txt
test.txt                      |  238B |  238B/s | TOC: 00:00:01 | 100%
chmod_dest_before_transfer: ././test.txt (dst): no such file (server msg: 'File not found')

The first line tells us that the file is transfered completely. But I don't know what the second line means, and I am suspecting that the error caught in the script is from this second line.

Could anyone help on this?

Thansk,
Hanqian

 

0
Comment
Question by:Hanqian
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 

Accepted Solution

by:
Hanqian earned 0 total points
ID: 21752042
Current our client sftp software for Unix has the issue when sftp file to the window ftp server. It tries CHMOD command after transferring fiels , but secure SFTP Windows servers do not support  that command, so system call returns error. We ignore this error for now in perl script.  We are installing new version soon. We hope that it may resolve this issue.

Thanks,
Hanqian
0
 
LVL 39

Expert Comment

by:Adam314
ID: 21752659
You might also want to look at the Net::SFTP module for perl:
http://search.cpan.org/~dbrobins/Net-SFTP-0.10/lib/Net/SFTP.pm
0
 
LVL 28

Expert Comment

by:FishMonger
ID: 21752667
I don't have an answer as to why your sftp client tries to do a chmod command without you explicitly issuing the command, but instead of doing a system call, have you tried or considered using the Net::SFTP module?

http://search.cpan.org/~dbrobins/Net-SFTP-0.10/lib/Net/SFTP.pm
0

Featured Post

Will your db performance match your db growth?

In Percona’s white paper “Performance at Scale: Keeping Your Database on Its Toes,” we take a high-level approach to what you need to think about when planning for database scalability.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
In this blog, we’ll look at how improvements to Percona XtraDB Cluster improved IST performance.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
In this video, Percona Solutions Engineer Barrett Chambers discusses some of the basic syntax differences between MySQL and MongoDB. To learn more check out our webinar on MongoDB administration for MySQL DBA: https://www.percona.com/resources/we…

721 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question