Jay Culley
Occasional Visitor
Is there a log file that shows ftp logins, activity?
Thanks
Thanks
#!/bin/sh
CONFIG=$1
source /usr/sbin/helper.sh
pc_replace "xferlog_enable=NO" "xferlog_enable=YES" $CONFIG
pc_replace "syslog_enable=NO" "syslog_enable=YES" $CONFIG
I don't think it does by default. But you can enable it by creating a /jffs/scripts/vsftpd.postconf file
Code:#!/bin/sh CONFIG=$1 source /usr/sbin/helper.sh pc_replace "xferlog_enable=NO" "xferlog_enable=YES" $CONFIG pc_replace "syslog_enable=NO" "syslog_enable=YES" $CONFIG
Note that with /jffs/configs/vsftpd.conf your replace the file /etc/vsftpd.confThank you! I started reading on vsftpd and a page on Merlin's custom config files and I just made a vsftpd.conf file in /jffs/configs with all of options in the regular conf file in etc and added
xferlog_enable=YES
log_ftp_protocol=YES
xferlog_file=/jffs/vsftpd.log
syslog_enable=NO
And it did not work. I will try your script now, thanks.
I do something similar and store the ftp logs on the USB drive. Regarding "damage", I'm not sure I follow what you're getting at. If you un-mount the USB drive from the web interface it will try to shut down the USB-based services cleanly before un-mounting, just like any OS.This creates a lot of entries in syslog.log so i was thinking about specifying
xferlog_file=/tmp/mnt/ExtHDD/logs/
That is the 1GB attached USB drive where I specified the location of the Traffic History and IPTraffic data files. One thing that worries me about doing that, what kind of damage will it cause if this drive is unmounted during router operations?
I do something similar and store the ftp logs on the USB drive. Regarding "damage", I'm not sure I follow what you're getting at. If you un-mount the USB drive from the web interface it will try to shut down the USB-based services cleanly before un-mounting, just like any OS.
#!/bin/sh
CONFIG=$1
source /usr/sbin/helper.sh
# Normal vsftpd logs
pc_replace "xferlog_enable=NO" "xferlog_enable=YES" $CONFIG
pc_append "vsftpd_log_file=/mnt/Seagate_Backup_Plus_Drive/vsftpd.log" $CONFIG
pc_append "log_ftp_protocol=YES" $CONFIG
# wu logs
pc_append "dual_log_enable=YES" $CONFIG
pc_append "xferlog_file=/mnt/Seagate_Backup_Plus_Drive/xfer.log" $CONFIG
service restart_ftpd
listen_port=874 is add by /jffs/configs/vsftpd.conf.addanonymous_enable=NO
nopriv_user=root
write_enable=YES
local_enable=YES
chroot_local_user=YES
local_umask=000
dirmessage_enable=NO
xferlog_enable=NO
syslog_enable=NO
connect_from_port_20=YES
use_localtime=YES
listen=YES
pasv_enable=YES
pasv_min_port=57530
pasv_max_port=57560
tcp_wrappers=NO
max_clients=5
ftp_username=anonymous
ftpd_banner=Welcome to ASUS RT-AC86U FTP service.
ssl_enable=NO
listen_port=874
#!/bin/sh
CONFIG=$1
source /usr/sbin/helper.sh
# Normal vsftpd logs
pc_replace "xferlog_enable=NO" "xferlog_enable=YES" $CONFIG
pc_append "vsftpd_log_file=/mnt/USB/vsftpd.log" $CONFIG
pc_append "log_ftp_protocol=YES" $CONFIG
# wu logs
pc_append "dual_log_enable=YES" $CONFIG
pc_append "xferlog_file=/mnt/USB/xfer.log" $CONFIG
anonymous_enable=NO
nopriv_user=root
write_enable=YES
local_enable=YES
chroot_local_user=YES
local_umask=000
dirmessage_enable=NO
xferlog_enable=YES
syslog_enable=NO
connect_from_port_20=YES
use_localtime=YES
listen=YES
pasv_enable=YES
pasv_min_port=57530
pasv_max_port=57560
tcp_wrappers=NO
max_clients=5
ftp_username=anonymous
ftpd_banner=Welcome to ASUS RT-AC86U FTP service.
ssl_enable=NO
vsftpd_log_file=/mnt/USB/vsftpd.log
log_ftp_protocol=YES
dual_log_enable=YES
xferlog_file=/mnt/USB/xfer.log
listen_port=874
What do you mean by "It didn't work"?First I created a /jffs/scripts/vsftpd.postconf script exactly as follows:
It didn't work.
/etc/vsftpd.conf
was not changed, it was changed but didn't log anything, or something else?When I created vsftpd.postconf the /etc/vsftpd.conf was not changed.What do you mean by "It didn't work"?/etc/vsftpd.conf
was not changed, it was changed but didn't log anything, or something else?
The most obvious question: Did you reboot the router after creating the script?I checked /etc/vsftpd.conf and was not changed.
Welcome To SNBForums
SNBForums is a community for anyone who wants to learn about or discuss the latest in wireless routers, network storage and the ins and outs of building and maintaining a small network.
If you'd like to post a question, simply register and have at it!
While you're at it, please check out SmallNetBuilder for product reviews and our famous Router Charts, Ranker and plenty more!