This forum uses cookies
This forum makes use of cookies to store your login information if you are registered, and your last visit if you are not. Cookies are small text documents stored on your computer; the cookies set by this forum can only be used on this website and pose no security risk. Cookies on this forum also track the specific topics you have read and when you last read them. Please confirm whether you accept or reject these cookies being set.

A cookie will be stored in your browser regardless of choice to prevent you being asked this question again. You will be able to change your cookie settings at any time using the link in the footer.

Cannot Connect via FTP anymore.
#1
Cannot Connect via FTP anymore.
So a little while back I was messing with Ubuntu (which has Sentora on it) and I installed another FTP program. SO I know now that this was bad idea. My problem is, since then I have tried to uninstall it the other FTP program, but I was able to connect using filezilla (it was working fine before I installed another FTP program). 

Is there any was I can purge my Ubuntu off all FTP programs, and reinstall proftpd so I don't have to do a clean install of Sentora. I'm not to good with Linux but I have been a quick learn,this was my first go at a web server. Typically I don't post question because I am sure someone has done this before. But over the last few days I have be unable to find a fix for my particular problem. 

After trying a few different things I was able to get a few errors, The first one I believe was only when both FTP were installed. I believe I got that error because it was trying connect to the wrong FTP program. 

Second one if from when I uninstalled it.


Response: 331 Please specify the password.
Command: PASS ********
Response: 530 Login incorrect.
Error: Critical error: Could not connect to server


Status: Connection attempt failed with "ECONNREFUSED - Connection refused by server".

Thanks in advanced Tom.
Thanks given by:
#2
RE: Cannot Connect via FTP anymore.
I've never done this, however I would try the following steps:
  • First, remove and purge the other FTP program (not proftpd):
    apt-get purge ftp-program-name
  • Install proftpd
    apt-get install proftpd

Now for the tricky part....

Make sure you delete /etc/proftpd/proftpd.conf and make a symlink to /etc/sentora/configs/proftpd/proftpd-mysql.conf
Code:
rm /etc/proftpd/proftpd.conf
ln -sv /etc/proftpd/proftpd.conf /etc/sentora/configs/proftpd/proftpd-mysql.conf

Read:http://askubuntu.com/questions/320634/how-do-i-create-a-symbolic-link

I've not tested this but should work.
My Sentora Resources
[Module] Mail Quota Count | Vagrant Box with Sentora

[Image: vanguardly-logo-micro.png]
Graphic and Web Design. Development.
www.vanguardly.com


Thanks given by:
#3
RE: Cannot Connect via FTP anymore.
Hey apinto, Thank you for the quick reply.

all seems to be good and I was on that track. The symlink is were I was going wrong. However, when I went to install proftpd I got this during the install and it seems to be causing some issues. 



Code:
Note, selecting 'proftpd-basic' instead of 'proftpd'
Suggested packages:
  openbsd-inetd inet-superserver proftpd-doc proftpd-mod-ldap
  proftpd-mod-mysql proftpd-mod-odbc proftpd-mod-pgsql proftpd-mod-sqlite
  proftpd-mod-geoip
The following NEW packages will be installed:
  proftpd-basic

there is no option to stop it, it seems to just go right on installing proftpd-basic. When I try the lines of code you suggested, the don't work (which I expected): 
Code:
tom@pannel:~$ sudo rm /etc/proftpd/proftpd.conf
sudo: unable to resolve host pannel.innovativetom.com
rm: cannot remove ‘/etc/proftpd/proftpd.conf’: No such file or directory
tom@pannel:~$ sudo ln -sv /etc/proftpd/proftpd.conf /etc/sentora/configs/proftpd/proftpd-mysql.conf
sudo: unable to resolve host pannel.innovativetom.com
ln: failed to create symbolic link ‘/etc/sentora/configs/proftpd/proftpd-mysql.conf’: File exists
tom@pannel:~$
Any further suggestions?

Again thanks.
Thanks given by:
#4
RE: Cannot Connect via FTP anymore.
Innovative Tom, thank you for taking the time to provide a detailed report of your errors.

Regarding the proftpd install command it is:
Quote:apt-get install proftpd
(eventually with or without sudo depending if oyu are using root or not)
You can also check How To Set Up ProFTPD on Ubuntu (Digital Ocean), the steps should be similar, but actually you are only looking for the install one.

Installing proftpd-basic is normal behavior I think.


Checking if proFTPd is installed
Get a list of all installed packages with the word ftp.
Code:
$ dpkg --get-selections | grep ftp

Expected output is:
ftp                          install
openssh-sftp-server          install
proftpd-basic                install
proftpd-mod-mysql            install

If you see any other packages, remove them (apt-get remove ***), take in consideration this assumes most FTP packages have ftp in the name, if they do not have ftp in the name they will not be listed on the output and oyu need to know what you installed.


The other issue, "unable to resolve..."
This error should not be related to FTP, probably it is related to you hostname.

Check the file /etc/hosts and /etc/hostname you should have the same machine hostname on both files, correct example bellow:

/etc/hosts
Code:
127.0.0.1 pannel.innovativetom.com
Most likely than not, this file will have other entries, do not worry, just make sure it has the correct hostname.

/etc/hostname
Code:
pannel.innovativetom.com
My Sentora Resources
[Module] Mail Quota Count | Vagrant Box with Sentora

[Image: vanguardly-logo-micro.png]
Graphic and Web Design. Development.
www.vanguardly.com


Thanks given by:
#5
RE: Cannot Connect via FTP anymore.
Ok, ok. I feel like I'm getting someone where now. But Filezilla now give me this error:
Code:
Connection attempt failed with "ECONNREFUSED - Connection refused by server".
So I think ok, port forwarding from my router. Not the case. It seems like ftp or proftpd are not listen to port 21 or anything. Here is the list. 
Code:
tom@pannel:/$ sudo netstat -ntlp | grep LISTEN
tcp        0      0 127.0.0.1:10025         0.0.0.0:*               LISTEN      1168/master
tcp        0      0 127.0.0.1:3306          0.0.0.0:*               LISTEN      1013/mysqld
tcp        0      0 0.0.0.0:2222            0.0.0.0:*               LISTEN      943/sshd
tcp        0      0 0.0.0.0:110             0.0.0.0:*               LISTEN      961/dovecot
tcp        0      0 0.0.0.0:143             0.0.0.0:*               LISTEN      961/dovecot
tcp        0      0 10.0.0.62:53            0.0.0.0:*               LISTEN      1004/named
tcp        0      0 127.0.0.1:53            0.0.0.0:*               LISTEN      1004/named
tcp        0      0 0.0.0.0:25              0.0.0.0:*               LISTEN      1168/master
tcp        0      0 127.0.0.1:953           0.0.0.0:*               LISTEN      1004/named
tcp        0      0 0.0.0.0:4190            0.0.0.0:*               LISTEN      961/dovecot
tcp6       0      0 :::2222                 :::*                    LISTEN      943/sshd
tcp6       0      0 :::80                   :::*                    LISTEN      1320/apache2
tcp6       0      0 :::53                   :::*                    LISTEN      1004/named
tcp6       0      0 :::25                   :::*                    LISTEN      1168/master
Don't ask me how I got this far down before realizing I could see the top but I think I'm almost out now.


edit: also possible issue
Code:
tom@pannel:/$ cd /etc/proftpd/
tom@pannel:/etc/proftpd$ ls
blacklist.dat  conf.d  dhparams.pem  ldap.conf  modules.conf  proftpd.conf  sql.conf  tls.conf  virtuals.conf
tom@pannel:/etc/proftpd$ rm /etc/proftpd/proftpd.conf
rm: remove write-protected regular file ‘/etc/proftpd/proftpd.conf’? y
rm: cannot remove ‘/etc/proftpd/proftpd.conf’: Permission denied
tom@pannel:/etc/proftpd$ sudo rm /etc/proftpd/proftpd.conf
tom@pannel:/etc/proftpd$ ls
blacklist.dat  conf.d  dhparams.pem  ldap.conf  modules.conf  sql.conf  tls.conf  virtuals.conf
tom@pannel:/etc/proftpd$ sudo ln -sv /etc/proftpd/proftpd.conf /etc/sentora/configs/proftpd/proftpd-mysql.conf
ln: failed to create symbolic link ‘/etc/sentora/configs/proftpd/proftpd-mysql.conf’: File exists
tom@pannel:/etc/proftpd$
Thanks given by:
#6
RE: Cannot Connect via FTP anymore.
Are oyu running the commands as root? I think not judging by your user (tom@pannel)

Try to add "sudo" to your commands and post results.
My Sentora Resources
[Module] Mail Quota Count | Vagrant Box with Sentora

[Image: vanguardly-logo-micro.png]
Graphic and Web Design. Development.
www.vanguardly.com


Thanks given by:
#7
RE: Cannot Connect via FTP anymore.
(08-15-2015, 01:38 AM)apinto Wrote: Are oyu running the commands as root? I think not judging by your user (tom@pannel)

Try to add "sudo" to your commands and post results.

I have ran them as sudo, when I attpemed to start the services proftpd, i get:
Code:
tom@pannel:/etc/proftpd$ sudo service proftpd start
grep: /etc/proftpd/proftpd.conf: Too many levels of symbolic links
egrep: /etc/proftpd/proftpd.conf: Too many levels of symbolic links
egrep: /etc/proftpd/proftpd.conf: Too many levels of symbolic links
* Starting ftp server proftpd                                                                      2015-08-16 13:25:48,373 pannel.innovativetom.com proftpd[2067]: Fatal: unable to read configuration file '/etc/proftpd/proftpd.conf': Too many levels of symbolic links
Thanks given by:
#8
RE: Cannot Connect via FTP anymore.
Did not have much to lose so I did a clean install. Net time I will be more careful. Thank you for your help!

Tom
Thanks given by:
#9
RE: Cannot Connect via FTP anymore.
Great you could "solve" the issue.
If a fresh install is possible it is usually the best solution out of a case like this Smile however sometimes we need to dig.
My Sentora Resources
[Module] Mail Quota Count | Vagrant Box with Sentora

[Image: vanguardly-logo-micro.png]
Graphic and Web Design. Development.
www.vanguardly.com


Thanks given by:
#10
RE: Cannot Connect via FTP anymore.
Hi guys...
I have the same problem...
I deleted the file proftpd.conf with the command: sudo rm /etc/proftpd/proftpd.conf
That I dont create symbolic link... I runed all commands with root user...

user@panel:~$ sudo ln -sv /etc/proftpd/proftpd.conf /etc/sentora/configs/proftpd/proftpd-mysql.conf
ln: failed to create symbolic link ‘/etc/sentora/configs/proftpd/proftpd-mysql.conf’: File exists

Can you help me?
Thanks
Thanks given by:


Possibly Related Threads…
Thread Author Replies Views Last Post
unable to connect to vps ip using ftp xRyu99 5 18 ,132 08-27-2019, 03:41 PM
Last Post: maxmilan
can't connect to ftp.. lonewolf91 3 13 ,685 12-13-2017, 05:32 PM
Last Post: varun.naharia
COULD NOT CONNECT TO SERVER ipanjan 8 23 ,017 12-13-2017, 05:30 PM
Last Post: varun.naharia

Forum Jump:


Users browsing this thread: 8 Guest(s)