vsftpd 提示 500 OOPS: cannot change directory
selinux
selinux 已经disabled
vsftpd
useradd xxx.com -d /var/virtual/xxx.com -g apache
登录vsftpd
提示 500 OOPS: cannot change directory:/var/virtual/xxx.com
网上说的那些都是关闭selinux,可我selinux已经完全关闭的。
[root@localhost vsftpd]# setsebool -P ftp_home_dir 1
setsebool: SELinux is disabled.
[root@localhost vsftpd]#
整个过程
[root@localhost ~]# ls -la /var/virtual
total 12
drwxrwxr-x 3 root root 4096 Sep 9 00:50 .
drwxr-xr-x 23 root root 4096 Sep 8 23:54 ..
drwxrw---- 5 apache apache 4096 Sep 9 00:50 xxx.com
[root@localhost ~]# ftp localhost
Trying ::1...
ftp: connect to address ::1Connection refused
Trying 127.0.0.1...
Connected to localhost (127.0.0.1).
220 (vsFTPd 3.0.2)
Name (localhost:root): xxx.com
331 Please specify the password.
Password:
500 OOPS: cannot change directory:/var/virtual/xxx.com
Login failed.
ftp> exit
[root@localhost ~]# grep xxx.com /etc/passwd
xxx.com:x:1000:48::/var/virtual/xxx.com:/bin/bash
[root@localhost ~]#
cod-i
10 years, 4 months ago