0

I have an issue when trying to upload a file using PHP FTP from my website that is deployed on the GCP Kubernetes Engine. And when I try to upload it manually from the Pod terminal using the ftp command, it allows me to open the connection and login with the given username and password.

But, when I try to upload the file and even do the ls command to see the directory list, it is always stuck. There is no helpful error or any message as shown below.

FTP Connect Screehot

But then, when I try to cancel it, I get this message: enter image description here

I have tried all of the above steps on my local computer and it's working. I can upload it to that FTP server. So, there is no issue with the FTP server.

Is there a way to trace what is the issue?

And what should I do so I can upload the file from GCP Kubernetes Pods?

Thanks

1
  • If the answer was useful, please mark the answer as accepted for greater visibility for the community or upvote if the answer has some useful information. Aug 19, 2022 at 7:13

1 Answer 1

1

An FTP server probably is configured correctly, but the problem is with authorizing users at login or you are behind a firewall that isn't allowing the incoming reverse connection from the ftp server to your client.

This error occurs mainly due to Invalid FTP Host, firewall restrictions , ISP restrictions and you need to configure FTP in Passive mode

Below are the possible ways to check :

  1. first check in the system allow to do ftp in the locally See if it is allowing then also check /var/adm/inetd.sec there is some entry for ftp

  2. check the /var/log/messages log file on server

getaddrinfo ‘Hostname_Is_Here’ error: Name or service not known warning: unable to determine IP address of ‘host.domain.tld domain’

This is because the FTP server cannot determine the IP address of the server by hostname.

3)) Try to PING Hostname #ping hostname If ping does not respond, you will have to define the correct hostname in the configuration files as follows and restart network service.

/etc/hosts

/etc/sysconfig/network

/etc/init.d/network restart

Kindly follow this doc and solutions which will help you in troubleshooting this issue.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .