2

I tried with several ways which is given like telnet to test whether my ftp server working properly or not:

  1.  

    rama@rama-desktop:~$ telnet 192.164.0.102 21
    Trying 192.168.0.102...
    telnet: Unable to connect to remote host: Connection refused
    rama@rama-desktop:~$ telnet 127.0.0.1 21
    telnet: Unable to connect to remote host: Connection refused
    
  2.  

    ftp [email protected]
    ftp: [email protected]: No address associated with hostname
    

    In the above, ramaftp is the username that I have created earlier.

I am a novice in Ubuntu. Please help me to reset the ftp username and password for my machine.

I have tried:

  1. sudo mkdir /srv/ftp
  2. sudo usermod -d /srv/ftp ftp
  3. sudo /etc/init.d/vsftpd restart
  4. Modified conf file:

    local_enable=YES
    write_enable=YES
    
  5. restarted server with service vsftpd restart:

    stop: Unknown instance: 
    start: Rejected send message, 1 matched rules; type="method_call", sender=":1.72" (uid=1000 pid=3629 comm="start vsftpd ") interface="com.ubuntu.Upstart0_6.Job" member="Start" error name="(unset)" requested_reply="0" destination="com.ubuntu.Upstart" (uid=0 pid=1 comm="/sbin/init")
    

This is the error that I got, Thanks

10
  • 2
    Which ftp server are you using?
    – Dan
    Feb 21, 2013 at 12:19
  • 1
    It looks like that there is no server running (Connection refused) or, less probably, if it is running it's not listening for connections on the right interfaces. Could you tell us something more about your setup? The FTP server software you are using and the way you have installed/configured it are two essential information. Feb 21, 2013 at 12:27
  • By the way, the ftp(1) program does not accept the user name as an argument; you have first to connect and then use the user command. Check man ftp for more information. Feb 21, 2013 at 12:31
  • vsftp, which is I came to know the best ftp from internet
    – Chella
    Feb 21, 2013 at 12:34
  • let me know the probable reasons to refuse the connection
    – Chella
    Feb 21, 2013 at 12:35

4 Answers 4

3

ftp 127.0.0.1

OR

ftp localhost

The FTP server will ask you for a username and a password.. plain simple! :)

3
  • good answer but getting the same error ftp 127.0.0.1 ftp: connect: Connection refused ftp>
    – Chella
    Feb 21, 2013 at 12:28
  • check if your ftp is running or firewall.
    – maniat1k
    Feb 21, 2013 at 12:33
  • Did you checked out the settings file that actually ALLOWS connections from the localhost?, sometimes all this options are in "OFF" mode so that you have to actually turn it on. Also, as maniat1k sugested there also can be some rule at the local firewall that is actually blocking the connection from the localhost. To make sure the ftp server is running you can do this (i will use vsftpd as an example): sudo /etc/init.d/vsftpd stop and the do a sudo /etc/init.d/vsftpd start.
    – AcidRod75
    Feb 21, 2013 at 12:56
2
  1. Download Filezilla http://filezilla-project.org/download.php
  2. extract the downloaded package
  3. open bin folder --> filezilla

Filezilla configuration to access an Ubuntu machine open site manager --> new site

host: Protocol: SFTP login type : normal

1

Another way:

wget -O /dev/null -q  ftp://192.168.1.55

Returns 0 if the server is up, otherwise returns positive/negaive value.

Expanation:

wget tries to reach the url, in this case an ftp server. The -O option redirects the output, if any, to /dev/null so it is not written to a file not to stdout. The -q option suppresses any additional output (like progress bar). The only remaining thing is the return value, which you can use.

0

If you open your ftp programme and enter the following details:

  • Protocol: SFTP
  • Host: 127.0.0.1
  • Port: 22
  • username: root
  • Password: ******************
  • Path: /var/www/

This should give you access to your 'local' server.

Screen Shot

You must log in to answer this question.

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