Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
AP Tempe FTP notes using a Linux system
We are just using a .netrc file to connect to the server and a put command to place the files there.
ftp 158.52.2.14
Connected to 158.52.2.14 (158.52.2.14).
220 FTP Server ready.
331 Password required for aptempe.
230 User aptempe logged in.
Remote system type is UNIX.
ftp> ls
227 Entering Passive Mode (158,52,2,14,215,131)
ftp: connect: Connection timed out
It hangs on entering passive mode, that could be a firewall issue. You have probably opened up the FTP command port (port 20) but the passive port range (data) is most likely still blocked. Are you using iptables, firewalld or a hardware firewall? I'd check there first. I have to admit to forgetting the most secure way of configuring iptables for Passive Ranges, assuming it is iptables or firewalld that is.
Just a note, normal FTP is unencrypted and thus not safe for anything sensitive in anyway. If you need things encrypted I'd use SFTP instead which is the preferred method of transferring files to a Linux Server. Personally I don't like the idea of transmitting passwords in plaintext, something normal FTP will do.
Last edited by r3sistance; 02-24-2017 at 01:16 PM.
Yes, you can set up SFTP to authenticate using keys, as per established best practice. Then you can load the SFTP commands you want into a text file and read them into the SFTP client using the -b option. Again this only works with keys, but also again keys are the established best practice.
See here i cant make any changes. Becuase people who are establishing FTP connection with us are our clients and they said they wont be using SFTP.
And they are not ready to change anything on their side.
Any help on this existing issue would be much appreciated.
It still could be firewall, if it only one client then it could be THEIR firewall. I did make a mistake on the port but you failure is at the point of creating a passive connection and so still indicate it'd be firewall related since the data connection isn't being made.
you know the tricky part is they are able to send the data to our test servers but not to production server. And, in case of passive mode i dont think client firewall has any role to play.ALso, client is able to send files through filezilla but not through Linux .netrc file.
Last edited by whirlpoolq; 02-26-2017 at 02:02 AM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.