# Vsftpd, user cant login

## Yamakasi

Hi,

Im using the ftp server called Vsftpd.

I cant login ftp from a remote computer.

```

[root@honda /]# ftp 192.168.1.4 

Connected to 192.168.1.4 (192.168.1.4).

421 Service not available, remote server has closed connection

ftp> 

```

I cant login ftp locally too, but the error is different

```

acura / # ftp 127.0.0.1

Connected to 127.0.0.1.

220 ready, dude (vsFTPd 1.0.1: beat me, break me)

Name (127.0.0.1:root): cngo

331 Please specify the password.

Password:

500 OOPS: str_getpwnam

Login failed.

421 Service not available, remote server has closed connection

ftp> 

```

Plz help!!!

----------

## silvercat

edit /etc/xinetd.d/vsftpd... and add a line beginning with the only_from parameter..

if you want only localhost to be able to access the ftp server on your local machine... add the line..

```
only_from       = localhost
```

if you want only localhost and your local network to be able to access the ftp server on your local machine (i'm using the local net 10.0.0.0 as an example)... add the line..

```
only_from       = localhost 10.0.0.0/24
```

and if u want everyone to be able to access the ftp server on your local machine.. (i think it's configured like this).. add the line..

```
only_from       = 0.0.0.0/0
```

Credit goes to hoppy... over here.. https://forums.gentoo.org/viewtopic.php?t=15460&highlight=hosts+allow

I had the same problem as you..

----------

## larryn

 *Yamakasi wrote:*   

> Hi,
> 
> Im using the ftp server called Vsftpd.
> 
> I cant login ftp from a remote computer.
> ...

 

Look at your xinetd.conf . Comment out the line only_from = localhost

That's it  :Razz: 

----------

## hsien110

Do you have configured the /etc/vsftp.conf??

----------

## bosshoff

Simply commenting out the only_from directive didn't work in my case.  I had to use the last example contributed by silvercat to allow everyone access to my ftp server.

----------

## wjholden

 :Rolling Eyes:   Look at dates when you post, people.

----------

