dynamic logs

Igor Sysoev is at rambler-co.ru
Fri Sep 12 00:36:48 MSD 2008


On Thu, Sep 11, 2008 at 08:15:30PM +0000, Vladan Popovic wrote:

> Hi,
> I'm using version 0.716 and trying to make dynamic log files work.
> The log file is created but subsequently nothing is written inside the file.
> The configuration is as follows:
> # Catch all web site
> #
> server {
>         server_name _ ;
> 
>         location  /widgets/ { alias  /home/http/lib/widgets/; }
>         rewrite ^/crm/(.*)$ https://$host/crm/$1 permanent;
> 
>         if ($host ~* "^([^.]+(\.[^.]+)*)\.((.*)\.(com|net|org)(\..*)?)$"){
>                 set $subd $1;
>                 set $dom  $3;
>                 set $myroot /sites/$dom/$subd/htdocs ;
>         }
> 
>         location / {
>            index  index.php index.html index.htm;
>         }
> 
>         root            /home/http$myroot ;
>         include         php-fastcgi;
> 
>         access_log  /var/log/nginx/$dom debug ;
> 
> }
> 
> 
> I get an error as follows:
> 2008/09/12 02:06:19 [alert] 9832#0: *6 write() to "/var/log/nginx/be-o.com"
> failed (22: Invalid argument) while logging request, 

Could you run nginx using truss/ktrace/strace and try the request ?


-- 
Igor Sysoev
http://sysoev.ru/en/





More information about the nginx mailing list