티스토리 뷰
root@localhost:~# vi /etc/ssh/sshd_config
Subsystem sftp /usr/lib/openssh/sftp-server -f local2 -l INFO
위의 내용이 없다면, 적당한 위치에 추가 하고 저장 하고 나온다.
root@localhost:~# vi /etc/rsyslog.conf
# sftp log
local2.* /var/log/sftp/sftp.log
적당한 위치에 위의 내용을 넣고 저장 하고 나온다.
root@localhost:~# /etc/init.d/rsyslog restart
[ ok ] Restarting rsyslog (via systemctl): rsyslog.service.
root@localhost:~# /etc/init.d/ssh restart
[ ok ] Restarting ssh (via systemctl): ssh.service.
root@localhost:~# tail -f /var/log/sftp/sftp.log
Feb 19 17:13:36 sftp-server[55648]: opendir "/home/freecatz"
Feb 19 17:13:36 sftp-server[55648]: closedir "/home/freecatz"
Feb 19 17:13:36 sftp-server[55648]: open "/home/freecatz/TEST.xml" flags READ mode 0666
Feb 19 17:13:36 sftp-server[55648]: close "/home/freecatz/TEST.xml" bytes read 59974 written 0
Feb 19 17:13:53 sftp-server[55648]: open "/home/freecatz/TEST2.xml" flags READ mode 0666
Feb 19 17:13:53 sftp-server[55648]: close "/home/freecatz/TEST2.xml" bytes read 326680 written 0
Feb 19 17:13:57 sftp-server[55648]: open "/home/freecatz/TEST3.xml" flags READ mode 0666
Feb 19 17:14:06 sftp-server[55648]: close "/home/freecatz/TEST3.xml" bytes read 24142026 written 0
Feb 19 17:14:26 sftp-server[55648]: session closed for local user freecatz from [192.168.0.10]
Feb 19 17:14:26 sftp-server[55644]: session closed for local user freecatz from [192.168.0.10]
댓글
공지사항
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
TAG
- SSL
- Compile
- Fun
- kotlin
- JavaScript
- gpkiapi
- Flutter
- springboot
- web
- Linux
- place
- HTTP
- devel
- development
- Security
- 엘리스센터
- food
- Mobile
- ssh
- 맛집
- devtools
- MySQL
- Android
- Java
- dart
- TIP
- json parse
- samba
- Spring
- Review
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | |||
5 | 6 | 7 | 8 | 9 | 10 | 11 |
12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | 22 | 23 | 24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 |
글 보관함