Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

SSIS FTP Task results

Posted on 2014-01-16
13
Medium Priority
?
147 Views
Last Modified: 2016-06-02
Is these a way to get the stdout from an ftp task?  

I was working on a large file issue, and when I ran FTP at dos prompt I discovered that it was out of disk space.  If I could see the error in SSIS, it would save lots of time.
0
Comment
Question by:No1Coder
  • 5
  • 5
13 Comments
 
LVL 16

Expert Comment

by:AlexPace
ID: 39787458
Do you mean the protocol-level log of the FTP session?
0
 

Author Comment

by:No1Coder
ID: 39789643
No.  I want to see the output as if I was running it from a command prompt.  Any error message, etc.  I want to put that information is a variable.
0
 
LVL 16

Expert Comment

by:AlexPace
ID: 39789941
The command prompt ftp.exe is a standalone FTP client program.  The SSIS task does not use that client for its connection.  It should, however, be able to create a log that will look something like what you might see if you ran ftp.exe in verbose mode.
0
What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

 

Author Comment

by:No1Coder
ID: 39789953
How do you create the log?
0
 
LVL 16

Expert Comment

by:AlexPace
ID: 39790095
I apologize I was mis-remembering a protocol-level trace log file I got by using an EXEC task to launch Robo-FTP and run a script.  That log was generated by Robo-FTP rather than by SSIS.  So I don't really know what SSIS is capable of as far as logging but I am sure it doesn't use ftp.exe because an FTP task can do Passive Mode but ftp.exe only does active mode.

So I would try setting the logging on the package itself to "verbose" mode and see if that provides enough information.  If that doesn't give you enough then you could use WireShark or other similar sniffer to log the text over the wire.  If you are more of an ftp.exe kinda guy than a WireShark kinda guy you could use an EXEC task to launch ftp.exe (1) in verbose mode and (2) pass the name of a script to run and (3) redirect output to a text file.  That should work as long as you can use Active mode.  If you need anything more than the most basic behavior then ftp.exe might not be appropriate for your needs.  WinSCP is free and has scripting that is a little better than ftp.exe and it has logging.  Robo-FTP is commercial but it has the best FTP scripting and support so it might be a good option if this is a project for work rather than for a hobby ore a favor.
0
 

Author Comment

by:No1Coder
ID: 39806316
I want to use the FTP task.  That is what it is for.  Is this just another limitation of Microsoft software, or is there a way to accomplish this?
0
 
LVL 17

Expert Comment

by:dbaSQL
ID: 39810344
0
 
LVL 16

Expert Comment

by:AlexPace
ID: 39812291
@dbaSQL - cool, I didn't know you could do that!
0
 

Author Comment

by:No1Coder
ID: 39815856
Thanks for this, however this is not exactly what I was looking for.  I really wanted the "console output" (what you would see if you connected to the same site using command line FTP command).  I was under impression that SSIS just put a wrapper around the FTP command.  Just trying to get stdout.
0
 
LVL 16

Accepted Solution

by:
AlexPace earned 2000 total points
ID: 39816156
There is not an FTP command.
There is a tiny FTP client program named ftp.exe that you can use from DOS.
You can be 100% sure that SSIS does not use that program under-the-hood because it supports passive mode data channels and ftp.exe does not.
If I had to guess I would say their either wrote their own FTP client or they made a wrapper for the same functions that Internet Explorer uses.
That said, you really can use an execute process to launch ftp.exe and use it instead of the built-in FTP task...  and you really can redirect stdout from ftp.exe into a little text file that becomes your "log" of the FTP session, especially if you launch it in verbose mode.

Perhaps we don't need a log.  What is the actual problem that you are trying to solve?  If, for example, you have something that works in FileZilla but not in the FTP task the problem usually comes down to file and folder permissions...
0
 

Assisted Solution

by:No1Coder
No1Coder earned 0 total points
ID: 39816208
The problem is the ftp task was failing, and there was no indication of why.  I discovered (using WSFTP) that the target server didn't have enough disk space.  This took a long time to figure out because there is no output from the FTP task.  All I want is for the task to provide some information as to why it is failing.  The FTP command log would probably work, but seems overkill.  If it isn't available, okay.  I am over the immediate hurdle anyway.  I really have wasted more time on this than I should have.
0

Featured Post

Get your Conversational Ransomware Defense e‑book

This e-book gives you an insight into the ransomware threat and reviews the fundamentals of top-notch ransomware preparedness and recovery. To help you protect yourself and your organization. The initial infection may be inevitable, so the best protection is to be fully prepared.

Question has a verified solution.

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

This article shows gives you an overview on SQL Server 2016 row level security. You will also get to know the usages of row-level-security and how it works
An alternative to the "For XML" way of pivoting and concatenating result sets into strings, and an easy introduction to "common table expressions" (CTEs). Being someone who is always looking for alternatives to "work your data", I came across this …
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed
Viewers will learn how to use the SELECT statement in SQL and will be exposed to the many uses the SELECT statement has.

927 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