# Nginx.conf issue?

**URL:** <https://www.ruby-forum.com/t/nginx-conf-issue/192486>\
**Category:** NGINX\
**Created:** [July 31, 2010, 5:15am UTC](https://www.ruby-forum.com/t/nginx-conf-issue/192486 "2010-07-31T05:15:23Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![filebackup](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/41988e/32.png) [@filebackup](https://www.ruby-forum.com/u/filebackup)\
**Post date:** [July 31, 2010, 5:15am UTC](https://www.ruby-forum.com/t/nginx-conf-issue/192486/1 "2010-07-31T05:15:23Z")

</div>

Hi, all.  
If I add more then four “if” tags in the location part, when I run  
command “killall nginx” or “/dir/nginx -s stop” to stop nginx process,  
in the /var/log/messages file I had founded the following error  
information: `Jul 31 10:49:14 localhost kernel: nginx[2314]:
segfault at 0000000000000000 rip 00002b0d618c8ce7 rsp 00007fffbcace590
error 4`

My OS is Centos5.5. The example of “location” config is here:

```auto
location ~ .*\.(php|php5)?$
{
if ($args ~ "mosConfig_[a-zA-Z_]{1,21}(=|\%3D)") {
set $args "";
rewrite ^.*$ http://$host/index.php last;
return 403;
}
if ($args ~ "base64_encode.*\(.*\)") {
set $args "";
rewrite ^.*$ http://$host/index.php last;
return 403;
}
if ($args ~* "(\<|%3C).*script.*(\>|%3E)") {
set $args "";
rewrite ^.*$ http://$host/index.php last;
return 403;
}
if ($args ~ "GLOBALS(=|\[|\%[0-9A-Z]{0,2})") {
set $args "";
rewrite ^.*$ http://$host/index.php last;
return 403;
}
if ($args ~ "_REQUEST(=|\[|\%[0-9A-Z]{0,2})") {
set $args "";
rewrite ^.*$ http://$host/index.php last;
return 403;
}
.
.
.
}
```

Kind Regards.  
filebackup  
07/31/2010

Posted at Nginx Forum:

> **[nginx.conf issue?](https://forum.nginx.org/read.php?2,115070,115070#msg-115070)**
>
> Hi, all. If I add more then four "if" tags in the location part, when I run command "killall nginx" or "/dir/nginx -s stop" to stop nginx process, in the /var/log/messages file I had founded the following error...

---

<div class="post-metadata">

**Author:** ![filebackup](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/41988e/32.png) [@filebackup](https://www.ruby-forum.com/u/filebackup)\
**Post date:** [August 1, 2010, 4:47am UTC](https://www.ruby-forum.com/t/nginx-conf-issue/192486/2 "2010-08-01T04:47:07Z")

</div>

If I removed any one of above five “if” tags, this error information  
won’t display. Maybe it’s nginx’s issue.?

Posted at Nginx Forum:

> **[Re: nginx.conf issue?](https://forum.nginx.org/read.php?2,115070,115324#msg-115324)**
>
> Hi, all. If I add more then four "if" tags in the location part, when I run command "killall nginx" or "/dir/nginx -s stop" to stop nginx process, in the /var/log/messages file I had founded the following error...

---

<div class="post-metadata">

**Author:** ![filebackup](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/f/41988e/32.png) [@filebackup](https://www.ruby-forum.com/u/filebackup)\
**Post date:** [August 1, 2010, 6:28pm UTC](https://www.ruby-forum.com/t/nginx-conf-issue/192486/3 "2010-08-01T18:28:13Z")

</div>

Hello!

On Sat, Jul 31, 2010 at 10:46:15PM -0400, filebackup wrote:

> If I removed any one of above five “if” tags, this error information  
> won’t display. Maybe it’s nginx’s issue.?

> **[GitHub - nginxinc/nginx-wiki: ARCHIVED -- Source for the now archived NGINX Wiki...](https://github.com/nginxinc/nginx-wiki)**
>
> ARCHIVED -- Source for the now archived NGINX Wiki section of https://www.nginx.com

Maxim D.
