Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

ProFTPd logging

Status
Not open for further replies.

fluid11

IS-IT--Management
Jan 22, 2002
1,627
US
I can't get ProFTPd to log anything. I used to have a very similar config in the past and it worked. I'll paste my config file below. Any ideas what I could be missing or forgetting to do? Everything else is working okay except for the logging to the 2 files I specified in the VirtualHost. Thanks in advance:)



ServerType standalone
DefaultServer on
Port 21
Umask 027
MaxInstances 10
AllowOverwrite on

<Limit ALL>
Order allow,deny
</Limit>

<VirtualHost 192.168.1.234>
ServerName &quot;Chris's Linux FTP Server&quot;
DefaultRoot /ftp
User proftpd
Group proftpd
DisplayLogin ./readme.txt
ExtendedLog ./.access.log read,write
ExtendedLog ./.auth.log auth

<Limit Login>
DenyGroup !proftpd
</Limit>

<Limit READ DIRS>
DenyGroup !proftpd
</Limit>

<Limit WRITE>
DenyGroup !admins
</Limit>

<Directory /ftp/upload/*>

<Limit WRITE>
AllowGroup proftpd
DenyAll
</Limit>

</Directory>

</VirtualHost>
 
You may need to specify an absolute pathname in your ExtendedLog directives.
 
I tried that and it didn't work. This is exactly how I had it in my old config, using relative paths to the DefaultRoot.

Thanks for your reply.
 
I just figured it out. I created the log files beforehand using &quot;touch&quot;. I deleted the files and let ProFTPd create them for me and it worked.
 
Check out who owns those files. I'll bet when you created them by touch-ing them, the permissions weren't right for the daemon to write to them.

Hmmm. You may have stumbled on an undocumented feature, I guess. ProFTPd's online documentation explicitly states that in the ExtendedLog directive, the filename argument &quot;must contain an absolute pathname to a logfile which will be appended to when proftpd starts&quot;

 
Thats weird. I had to set up another ProFTPd server today and I specified an absolute path to the log directory and it didn't work again.

DefaultRoot /var/ftp
ExtendedLog /var/ftp-logs/access.log read,write

Next, I changed it to a relative path to the DefaultRoot directive and it works now.

DefaultRoot /var/ftp
ExtendedLog ../ftp-logs/access.log read,write

Does this only happen to me?

 
I've always used absolute pathnames and I've never had a problem. Except in making sure that the user as which ProFTPd runs has access to write to the file.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top