Can't connect fo FTP (CentOS)

Associate
Joined
18 Oct 2002
Posts
1,863
Location
Ammanford, Wales, UK.
Hi Guys,

Let me start out by saying that I'm not an expert with Linux....I know what I need to get by. But I've been scratching my head with this one for a few days.

I can't connect to FTP externally. Locally it works fine.
I'm running CentOS 6.4 64 Bit.
I've tried multiple ftp servers (vsftpd and pureftp)
I have also tried disabling both iptables and ip6tables to no effect.

nmap shows the port as open also.

Code:
Starting Nmap 5.51 ( http://nmap.org ) at 2014-01-17 19:24 CET
Nmap scan report for localhost (127.0.0.1)
Host is up (0.000013s latency).
Not shown: 996 closed ports
PORT     STATE SERVICE
21/tcp   open  ftp
25/tcp   open  smtp
80/tcp   open  http
3306/tcp open  mysql

Code:
[root@CentOS-64-64-minimal pure-ftpd]# ftp localhost 21
Connected to localhost (127.0.0.1).
220---------- Welcome to Pure-FTPd [privsep] [TLS] ----------
220-You are user number 1 of 50 allowed.
220-Local time is now 19:27. Server port: 21.
220-IPv6 connections are also welcome on this server.
220 You will be disconnected after 15 minutes of inactivity.
Name (localhost:root): faststone
331 User faststone OK. Password required
Password:
230 OK. Current directory is /
Remote system type is UNIX.
Using binary mode to transfer files.
ftp>

Any suggestions would be greatly appreciated, and if you need any further info just ask :)

Intra~
 
Last edited:
Thanks for the replies guys.
Sorry for the confusion Shadow. Yes, when I said locally I meant through ssh.

I do normally use sftp, however I also use a program called Faststone which allows me to screengrab and instantly upload the image to my webserver.
This software requires FTP, doesn't have an sftp option.

Iptables has no policies at the moment.

Code:
[root@CentOS-64-64-minimal ~]# iptables -L
Chain INPUT (policy ACCEPT)
target     prot opt source               destination

Chain FORWARD (policy ACCEPT)
target     prot opt source               destination

Chain OUTPUT (policy ACCEPT)
target     prot opt source               destination
[root@CentOS-64-64-minimal ~]#

There is nothing relevant in the logs that I can see.

The exact error is this, using Filezilla
Code:
Status:	Connecting to *.*.*.*:21... (IP Removed)
Error:	Connection timed out
Error:	Could not connect to server

When I connect using sftp, its fine.
Code:
Status:	Connecting to *.*.*.*:2224...
Response:	fzSftp started
Command:	open "faststone@*.*.*.*" 2224
Command:	Pass: *****************
Status:	Connected to *.*.*.*
Status:	Retrieving directory listing...

Code:
[root@CentOS-64-64-minimal ~]# cat /etc/sysconfig/selinux

# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
#     enforcing - SELinux security policy is enforced.
#     permissive - SELinux prints warnings instead of enforcing.
#     disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
#     targeted - Targeted processes are protected,
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted
 
Last edited:
Have you got a default GW set?

Code:
[root@CentOS-64-64-minimal ~]# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
144.*.*.*  0.0.0.0         255.255.255.255 UH    0      0        0 eth0
169.254.0.0     0.0.0.0         255.255.0.0     U     1002   0        0 eth0
0.0.0.0         144..*.*.*  0.0.0.0         UG    0      0        0 eth0
[root@CentOS-64-64-minimal ~]#


*Removed public IP
 
Last edited:
Back
Top Bottom