1829384 Members
5397 Online
109991 Solutions
New Discussion

bash

 
Sajjad Sahir
Honored Contributor

bash

ftp> mput bash*.*
mput bash-3.2-hppa-11.23.depot.gz? y
200 PORT command successful.
150 Opening BINARY mode data connection for bash-3.2-hppa-11.23.depot.gz.
> Netout :Connection reset by peer

why i am getting such an error?
how to manage it?

Sajjad
14 REPLIES 14
Jeeshan
Honored Contributor

Re: bash

Hi Sajjad

This is almost always caused by server configuation timeout.

If there is no action from the sending to recieving server for 15 minutes the connection times out.

or may be there is something abt the space related issue, where u put the depot.
a warrior never quits
Matti_Kurkela
Honored Contributor

Re: bash

By the response "200 PORT command successful", I see you're using the active mode of the FTP protocol.

See this document:
http://www.troubleshootingnetworks.com/ftpinfo.html

The FTP protocol actually uses two distinct network connections: the first is the control connection, and the second is the data connection.

The control connection is formed when you start your FTP client and log in. It is used to tell the FTP server what you want it to do. The actual data transfer happens with the data connection: it is opened only when something must be transferred.

Furthermore, the port numbers of the data connections are not static: the FTP client and server negotiate them using the control connection. This makes it difficult to allow FTP through firewalls and NAT devices: the firewall/NAT must be smart enough to read the messages in the FTP control connection and dynamically change the filtering rules to allow the data connections associated with any allowed FTP (control) connection.

In your case, the FTP control connection works, but something stops the data connection from working.

Try using the PASV command before MPUT, if your FTP client understands it: it switches the FTP server to "passive mode" for your connection. This makes the connection a bit easier to handle in firewall/NAT devices.

MK
MK
Sajjad Sahir
Honored Contributor

Re: bash


dear
ftp> pasv
Invalid command.
Sajjad Sahir
Honored Contributor

Re: bash

Dear Kurkala
from ftp prompt I used pasv command but it gives an error that is an invalid command

see my above posting

one more thing
by using I installed alot fo pacakges by uisng mput *.* command in the same server it was perfectly fine
only in this bash case i am facing problem
I dont why only in this case
according to u suggesstion i used pasv command in ftp prompt but it is giving an invalid command message
Sajjad Sahir
Honored Contributor

Re: bash

Dear Ahsan

not that issue, because i transferred a lot of packages before without any issue.

thanks and rgds

sajjad
Rasheed Tamton
Honored Contributor

Re: bash

Try with pa

ftp> pa
Passive mode on.


Rasheed Tamton
Honored Contributor

Re: bash

I think you are using MS ftp from windows. Try with a smaller size file and see what result you get.
Sajjad Sahir
Honored Contributor

Re: bash

dear rasheed

ftp> pa
Invalid command.

same as the above

I did before sudo, gdb etc.. that time I didn't face problem, now only i mean regarding bash i am facing problem

thanks and regards

sajjad
Sajjad Sahir
Honored Contributor

Re: bash

see just now i transferred one file

ftp> bin
200 Type set to I.
ftp> cd /usr/local
250 CWD command successful.
ftp> mput sud*.*
mput sudo-1.6.9p11-hppa-11.23.depot.gz? y
200 PORT command successful.
150 Opening BINARY mode data connection for sudo-1.6.9p11-hppa-11.23.depot.gz.
226 Transfer complete.
ftp: 203804 bytes sent in 0.30Seconds 686.21Kbytes/sec.

thanks and regards

sajjad
Rasheed Tamton
Honored Contributor

Re: bash

Dear Sajjad,

pa or pasv commands are not avble in MS FTP.
How big is this file you want to transfer. Did you check the free space left on the destination system/dir.

Do you have another FTP tool or sftp to check with the same souce/destination.

If it is bigger than 2GB size you need to check whether the file system is supported for the largefiles.


Regards,
Rasheed Tamton.
Sajjad Sahir
Honored Contributor

Re: bash

it is just 962 kb only
Sajjad Sahir
Honored Contributor

Re: bash


dear all
I solved this issue
the problem was clusterign environment
so i suspected before due to this issue
such an error i got during ftp
i halted cluster now
it is ok in my both servers
thanks
see the out put
ftp> cd /usr/local
250 CWD command successful.
ftp> mput bash*.*
mput bash-3.2-hppa-11.23.depot.gz? y
200 PORT command successful.
150 Opening BINARY mode data connection for bash-3.2-hppa-11.23.depot.gz.
226 Transfer complete.
ftp: 985501 bytes sent in 1.31Seconds 750.57Kbytes/sec.

Steven Schweda
Honored Contributor

Re: bash

> Try using the PASV command [...]

Note that PASV is an FTP _server_ command.
An FTP _client_ may have some different
command which lets the user put it into
passive mode ("SET PASSIVE ON", or "passive",
for example). Note, too, that sending an
artificial PASV command to an FTP server
(using a method like "quote PASV") is doomed
to fail, because passive mode requires some
cooperation between the client and the
server, so you can't make it work by trying
to fool the server this way. (And the PASV
command is more complicated than this,
anyway. Everything's complicated.)
Sajjad Sahir
Honored Contributor

Re: bash

closed