Operating System - Linux
1821203 Members
3577 Online
109631 Solutions
New Discussion юеВ

Re: ftp connection refused

 
andrew medhurst
Advisor

ftp connection refused

hi guys
I am a relative new guy with red hat linux, i have to ftp some files from one 2.1 advanced server to another.
but i get connection refused all the time, i have looked at the ftpaccess and ftpusers file and as far as i can see they look standard i can rlogin in both directions with non issues.
but now i am under time presure and would apprecate some help.
regards
Andrew
8 REPLIES 8
Kodjo Agbenu
Honored Contributor

Re: ftp connection refused

Hi Andrew,Several things to be checked.First : Red Hat default installation does not allow FTP service (nor it allows telnet).To enable FTP, you must install a FTP server (included in something called "legacy network servers" in Red Hat package naming).Then, go to /etc/xinetd.d/ and look for the FTP configuration file. Comment out the line "disable = yes", then re-start or "kill -1" the xinetd daemon :killall -1 xinetdAnother point : SSH has become the standard connection daemon for most Linux distros. Due to security flaws (passwords transmitted in clear text), telnet and ftp are less used than before.To copy files using SSH :scp -rp src_file_or_dir user@dest_host:/pathor scp -rp user@src_host:/path/to/file_or_dir dest_dirGood luck.Kodjo
Learn and explain...
Jan Sladky
Trusted Contributor

Re: ftp connection refused

Hi Andrew,
have you installed and started ftp server ?

rpm -qa | grep ftp

ps -ef | grep ftp

If ssh is running you don't need ftp, use scp:

upload: scp file user@remotebox:/dir
download: scp user@remotebox:/dir your_path

br Jan


GSM, Intelligent Networks, UNIX
Ross Minkov
Esteemed Contributor

Re: ftp connection refused

what's the error message?
HGN
Honored Contributor

Re: ftp connection refused

Hi

By default the ftp rpm does not get loaded, you can download from redhat site the wu-ftpd rpm and install it. Once you install it run setup and enable wu-ftpd,after you have done this do a kill -HUP on the inetd process after this ftp will start working.

Rgds

HGN
Fodil ATTAR
Frequent Advisor

Re: ftp connection refused

Hi Andrew,

I experienced troubles, for the Kerberos ftp package was installed (which is more sticky to configure) instead of the regular one.

Things became immediatly easier with the regular (which is probably less secure)

How about your machine ?

Good luck

Fodil.
We must become the change we want to see cf. GHANDI
Fodil ATTAR
Frequent Advisor

Re: ftp connection refused

Andrew,

You may have a look on :

/etc/hosts
/etc/sysconfig/network
/etc/sysconfig/network-scripts/ifcfg-eth0
(where eth0 is your machine interface's name)

To restart daemons let have a look on :

/etc/rc5.d/S10network reload
/etc/rc5.d/S56xinetd restart (***)
/etc/rc.d/inti.d/network restart

Regards,

Fodil.
We must become the change we want to see cf. GHANDI
Fodil ATTAR
Frequent Advisor

Re: ftp connection refused

Once again...

To manage services let's execute :

ntsysv

Fodil.
We must become the change we want to see cf. GHANDI
HGN
Honored Contributor

Re: ftp connection refused

Hi

By default ftp is not on the OS, to get ftp working you need to do the following

Install wuftpd rpm which can be downloaded from redhat site

After installing using rpm -ivh wuftp*.rpm
then run setup go to services and select wuftpd
Save and exit
do a ps -ef|grep inetd
do a kill -HUP on inetd pid and after that ftp will satrt working

No reboot required for the whole process.

Hope this helps

Regards

Gopi