If you know about NGINX and servers, Webinoly is for you!
0 votes
52 views
by Rookie

Hello Brothers,

I am facing this problem

nginx: [emerg] duplicate location "/" in /etc/nginx/common/wpfc.conf:24

when I try to turn on cache on root wordpress site which also has subdir wordpress site.

I will explain,

I installed wordpress site with "sudo site example.com -wp" and "sudo site example.com -wp=custom -subfolder=/news"

Everythings works well. But Problem started when I turned on cache with

"sudo site example.com -cache=on"

I got this :

"Job for nginx.service failed because the control process exited with error code.
See "systemctl status nginx.service" and "journalctl -xe" for details."

journalctl -xe shows "nginx: [emerg] duplicate location "/" in /etc/nginx/common/wpfc.conf:24".

This above is problem case. but I found the way to turn on cache on root wordpress site which aslo has subdir wordpress site.

First I need to turn on cache on subdir wordpress site with

"sudo site example.com -cache=on -subfolder=/news" it works without error. then

"sudo site example.com -cache=on" it also works without above problem case.

This is testng on new vps. but I am having problem in production vps with above problem, I can't reload nginx. How to revert this conditon.?

Thanks , sorry for my english.

.............................

by Expert

Fixed in v1.12.0 released today!

by Rookie
Thanks I will update webinoly.

1 Answer

+2 votes
by Expert
Thanks for reporting this issue and sorry for the inconvenience!

I can confirm I was able to reproduce it on my end and it will be fixed in the next release (v1.12.0).

If you need to urgently fix it, see the comments below.
by Expert

Open your site Nginx conf file: /etc/nginx/sites-available/example.com

You will see that wpfc.conf file is duplicate.

This is how it should look with cache=off

# WebinolyCustom
include apps.d/example.com_news-php.conf;
# WebinolyCustomEnd

include common/php.conf;
include common/wpcommon.conf;

This is how it should look with cache=on

# WebinolyCustom
include apps.d/example.com_news-wpfc.conf;
# WebinolyCustomEnd

include common/wpfc.conf;
include common/wpcommon.conf;
Welcome to the Community site for Webinoly.

Our Optimized LEMP Web Server is a powerful set of commands for doing just about anything you could wish.

With Webinoly you can set up your NGINX web server in just one step.

* * * * * * *

To report a bug, please create a new issue on GitHub or ask a question here with the bug tag.

Donations

Webinoly Support Paypal Donations Webinoly Support Bitcoin Donations GitHub Sponsors

Your regular donations is what keep this project moving forward. If you like Webinoly, buy me a coffee or a beer to show support.

Affiliate Links

It is very important that any visitor to the site read the disclaimer, terms of use and privacy and legal statement before start browsing.

...