On Sat, 2004-10-23 at 08:07, Cristi Banciu wrote: > Hi, > > I am using apache with mass virtual hosting. I need to keep separate log > files for each vhosts into something like thist > /var/log/httpd/$vhost.without.www/$year/$month/$day/access.log > > I have found a little perl script that says it does that. Unfortunatelly > it does not working, apache error.log saying something like this: > piped log program '/usr/local/sbin/logger' failed unexpectedly > > Here is the perl script > ###start program ###
Your script must _not_ start with the line above. It should start with the line below. It wont be run as a perl script otherwise. > #!/usr/bin/perl Try the function below without the parenthesis. > sub writeLog(){ > my $logDir = shift @_; > my $type = shift @_; > if( ! -d $logDir ) { > `mkdir -p $logDir`; > } That got it to work for me. -davidc -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]