Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

421 Service not available, remote server has closed connection #160

Closed
the1bit opened this issue May 14, 2021 · 2 comments
Closed

421 Service not available, remote server has closed connection #160

the1bit opened this issue May 14, 2021 · 2 comments

Comments

@the1bit
Copy link

the1bit commented May 14, 2021

Hi,

I try to use your image to create a simple FTP server on AKS (Azure Kubernetes). For the configuration I use the following documentation: http:https://dbaharrison.blogspot.com/2018/05/azure-aks-and-quest-for-paas-ftp-server.html

Unfortunately your image does not work there. When I try to connect to the FTP service I am facing the following issues:

  1. Option : Command line
    • Login Command: ftp -p 21
    • Result220---------- Welcome to Pure-FTPd [privsep] [TLS] ----------
    • Command: dir
    • Result: 421 Service not available, remote server has closed connection. Passive mode refused.
  2. Option: Total commander
    • Message flow:
      • 200 PORT command successfull
      • MLSD
      • PORT failde, try PASV mode!
      • PASV
  3. Option: WinSCP
    • With defined root path: Can't change directory to /home/ftpusers/user: No such file or directory
    • Without define root path: Timeout detected. (data connection). Could not retrieve directory listing. Error listing directory '/'.

Kubernbetes version: 1.19.9

pure-ftp.aml

apiVersion: apps/v1
kind: Deployment
metadata:
  name: ftp5-deployment
spec:
  replicas: 1
  selector:
    matchLabels:
      app: ftpuk
  strategy:
    type: Recreate
  template:
    metadata:
      labels:
        app: ftpuk
    spec:
      hostNetwork: true
      containers:
      - name: ftpuk
        image: stilliard/pure-ftpd:latest
        env:
        - name: ADDED_FLAGS
          value: -O w3c:/var/log/pure-ftpd/transfer.log
        ports:
        - containerPort: 21
        volumeMounts:
        - name: azuredisk
          mountPath: /home/ftpusers/
      volumes:
      - name: azuredisk
        persistentVolumeClaim:
          claimName: ftp-claim

Pod status:

NAME                               READY   STATUS    RESTARTS   AGE
ftp5-deployment-7bfd54c657-tqh6n   1/1     Running   0          20h

Could you please help me to use it on the right way?

Thanks in advance.

@stilliard
Copy link
Owner

Hi @the1bit,

I don't know much about the azure docker format above but I notice you're not passing the PUBLICHOST.

Check out our docker compose as an example:
https://github.com/stilliard/docker-pure-ftpd/blob/master/docker-compose.yml

@the1bit
Copy link
Author

the1bit commented Jun 3, 2021

It does not help. So I solved with ATMOZ SFTP. That works fine by default.

@the1bit the1bit closed this as completed Jun 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants