Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
?
Solved

CFFTP: Could not parse response code

Posted on 2009-02-19
21
Medium Priority
?
3,267 Views
Last Modified: 2013-12-24
I've obviously replaced the import info : )

I get the following error when I run this code:
An error occurred while establishing an FTP connection.  
Error: Could not parse response code. Server Reply: SSH-2.0-0.0 .

I'm a newbie using this CF Tag. What does this mean ?
<p>cfftp lets users implement File Transfer Protocol operations. By default, cfftp caches
    an open connection to an FTP server.</p>
<p>cfftp operations are usually of two types:</p>
 
<ul>
    <li>Establishing a connection
    <li>Performing file and directory operations
</ul>
 
<p>This example opens and verifies a connection, lists the files in a directory, and closes
    the connection.</p>
 
<p>Open a connection</p>
 
<cfftp action = "open"
    username = "USER"
    connection = "My_query"
    password = "PASS"
    port="22"
    server = "TEST_SERV"
    passive="yes"
    stopOnError = "Yes">
 
<p>Did it succeed? <cfoutput>#cfftp.succeeded#</cfoutput>
 
<p>Close the connection:</p>
 
<cfftp action = "close"
    connection = "My_query"
    stopOnError = "Yes">
 
<p>Did it succeed? <cfoutput>#cfftp.succeeded#</cfoutput>

Open in new window

0
Comment
Question by:Michael Williams
  • 10
  • 4
  • 4
  • +1
20 Comments
 
LVL 16

Expert Comment

by:duncancumming
ID: 23684817
the remote host is expecting SSH instead of FTP.  Are you sure about your port number?  The default for FTP is 21, and for SSH is 22.  
0
 

Author Comment

by:Michael Williams
ID: 23684867
When I use 21 I get the following response:
An error occurred while establishing an FTP connection.  
Error: Connection reset.

0
 
LVL 16

Expert Comment

by:duncancumming
ID: 23684908
Try changing stopOnError = "Yes" to stopOnError = "No" and see what difference if any that makes
0
Get expert help—faster!

Need expert help—fast? Use the Help Bell for personalized assistance getting answers to your important questions.

 

Author Comment

by:Michael Williams
ID: 23685482
Now I get the following:
Invalid connection specified.
The connection attribute you specified, 'My_query', is invalid or does not exist.

Did it succeed? NO
0
 

Author Comment

by:Michael Williams
ID: 23685606
So that would fail because there's isn't a connection right ? It fails on the close.
0
 
LVL 16

Expert Comment

by:duncancumming
ID: 23686143
You're sure the FTP server is up and running, and when you try and do a normal FTP connection to it, with those settings, from that CF server it works?
0
 

Author Comment

by:Michael Williams
ID: 23686217
Like I said before I'm a newbie. As far as I know the server I'm trying to connect to is up and runnung. I will verify that.

What do I need to do on my end ?
0
 
LVL 39

Expert Comment

by:gdemaria
ID: 23692819
start by connecting to the web service using your ftp program on your PC.  If you don't have one try entering  ftp.theDomainName.com  as the address into your browser.  

Your code is showing "TEST_SERVER"  and dummy values for username and password.   I assume your code has the real values for these parameters and you're just altering it for public display..
0
 

Author Comment

by:Michael Williams
ID: 23692915
Yes, I'm altering the values.

The ftp would be: fileserv.fmcsa.dot.gov

Is this FTP or is this SSH ? If it is a true FTP would it be ftp.******* ?
0
 
LVL 39

Expert Comment

by:gdemaria
ID: 23694338
It doesn't seem to be an ftp site, I think you should find out what it is
0
 
LVL 16

Expert Comment

by:duncancumming
ID: 23694704
If it is a true FTP would it be ftp.******* ?

not necessarily.
0
 

Author Comment

by:Michael Williams
ID: 23694798
Ok

I will wait for the guy from the vendor to call me. I'll let yall know what happens : )
0
 
LVL 19

Expert Comment

by:v2Media
ID: 23705672
There's a chance that ftp is disallowed and that SSL-SFTP is operating on port 22. Try downloading core ftp le and connect to the site via ssh on port 22. If you're prompted about a security certificate, just accept it. If it connects, then I'd say there's no open ftp allowed to the server.

http://www.coreftp.com/download/

On windows, you want coreftplite.exe
0
 

Author Comment

by:Michael Williams
ID: 23710829
Ok, so I download coreftp. I have to switch to SSL-SFTP and use port 22. It comes back with: "SFTP connection error - Invalid username or password reported by server"

So obviously I need the correct Username or Password. I was told I had the correct one. I'm currently waiting for the Vendor to get back with me.

Lets say I get the correct Username and Password, will I be able to connect via CFFTTP using SSL-SFTP ?
0
 
LVL 19

Accepted Solution

by:
v2Media earned 2000 total points
ID: 23710936
If you got that far, ya, I'd say so. You have the port and protocol right, just need the correct username/pass. Obviously DW won't be able to manage ftp duties for this site.
0
 

Author Comment

by:Michael Williams
ID: 23722671
Well I can get to the directory if I use the Private Key provided. The directory doesn't actually have anything in it. I need to deal with them for this.

I guess my question would be how I can handle this FTP with SQL Server 2005 ? Any resources you all may no off for this type of FTP ?
0
 
LVL 19

Expert Comment

by:v2Media
ID: 23726964
FTP is FTP, either the files get there or they dont. Core FTP can connect and transfer the files yes? What more do you need...
0
 

Author Comment

by:Michael Williams
ID: 23727297
I guess I was trying to have a process out of one application : )

I guess it makes more sense to get an FTP Program and schedule a job to run at a certian time. I can then use what ever form of application or scripting to manipulate the downloaded file. This process would also be scheduled.
0
 

Author Comment

by:Michael Williams
ID: 23727301
Told you I was new at this : )
0
 
LVL 19

Expert Comment

by:v2Media
ID: 23728023
Welcome to dreamweaver. Perfect one day, hell the next.
0

Featured Post

[Webinar] Database Backup and Recovery

Does your company store data on premises, off site, in the cloud, or a combination of these? If you answered “yes”, you need a data backup recovery plan that fits each and every platform. Watch now as as Percona teaches us how to build agile data backup recovery plan.

Question has a verified solution.

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

In our day to day coding, how many times have we come across a necessity to check whether a URL is a broken link or not? For those of you that answered countless and are using ColdFusion like myself, then this article is for you.  It will show yo…
One of the typical problems I have experienced is when you have to move a web server from one hosting site to another. You normally prepare all on the new host, transfer the site, change DNS and cross your fingers hoping all will be ok on new server…
Whether it be Exchange Server Crash Issues, Dirty Shutdown Errors or Failed to mount error, Stellar Phoenix Mailbox Exchange Recovery has always got your back. With the help of its easy to understand user interface and 3 simple steps recovery proced…
Enter Foreign and Special Characters Enter characters you can't find on a keyboard using its ASCII code ... and learn how to make a handy reference for yourself using Excel ~ Use these codes in any Windows application! ... whether it is a Micr…
Suggested Courses

578 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