라즈베리파이로 웹서버를 만드는데, vsftpd 를 설치하고 vsftpd.conf 파일을 수정 후 'service vsftpd start'를 했더니 ftp가 실행되지 않았다. 무슨 문제인가 해서 'service vsftpd status'로 확인해본 결과 아래있는 에러를 뱉어내었다.
vsftpd.service - vsftpd FTP server
Loaded: loaded (/lib/systemd/system/vsftpd.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Sun 2021-12-12 01:03:16 KST; 1min 13s ago
Process: 1826 ExecStartPre=/bin/mkdir -p /var/run/vsftpd/empty (code=exited, status=0/SUCCESS)
Process: 1827 ExecStart=/usr/sbin/vsftpd /etc/vsftpd.conf (code=exited, status=2)
Main PID: 1827 (code=exited, status=2)
CPU: 23ms
12월 12 01:03:16 raspberrypi systemd[1]: Starting vsftpd FTP server...
12월 12 01:03:16 raspberrypi systemd[1]: Started vsftpd FTP server.
12월 12 01:03:16 raspberrypi systemd[1]: vsftpd.service: Main process exited, code=exited, status=2/INVALIDARGUMENT
12월 12 01:03:16 raspberrypi systemd[1]: vsftpd.service: Failed with result 'exit-code'.
에러를 보니 내가 수정한 vsftpd.conf 파일에 문제가 있다는 것이다.
몇개 지우고 수정하니 정상적으로 돌아갔다.
----------------------------------------------------------------------------------------------------
또한, vsftpd가 돌아가고 있는 상황에서 vsftpd.conf 파일을 수정할 경우 설정이 꼬여서 위같이 작동하지 않는 불상사를 초래할 수 있다.
그럴 경우 삭제 후 재설치를 하면 된다.
삭제 : sudo apt-get remove --purge vsftpd
설치 : sudo apt-get install vsftpd
'코딩 > 라즈베리파이 웹서버' 카테고리의 다른 글
라즈베리파이 아파치 서브도메인 만들기 (0) | 2021.12.14 |
---|---|
라즈베리파이 웹서버 - 404 Not Found 페이지 만들기 (0) | 2021.12.12 |
SSH 접속 오류 해결방법 (0) | 2021.12.12 |