Nginx not listening to hostname anymore

Hi all,

my server is local
My nginx was listening to the requests from the web via” which is C-named to my local network via our hosted webserver
where “” is our domain.
however when being local everyone just used
“erp” is the servers hostname
hence I assume nginx just listened to the port and redirected to the erpnext site.

Today did

bench setup nginx

now when calling
I get the following response from nginx

Not Found

./erp/site_config.json does not exist

what can I do??

@spa you will need to set default your site as default site.

$ bench use
$ bench set-default-site
$ bench setup nginx
$ bench restart

SSL without domain name is tricky thing you will need to manually edit nginx.conf file as well as /etc/hosts file to reflect changes is beyond my scope.
It may or absolutely may not work. Where as in such setup with SSL works most of the time and that is the reason you were able to use it earlier on.

Btw, your FQDN is your hostname (, not just subdomain (erp)

If it solves your issue, please accept my answer.

1 Like

Hi @yashodhan,

thanks for quick replay…
unfortunately no luck - still the same behavior
but thank you anyway :+1:

anyone any other ideas?


I fugured that new nginx versions dont catch all anymore
I think I ll have to pass the “default_server” but I´m struggling
as nginx still points to ./erp
which is not a subfolder of …/sites
It should point to when calling

anyone who has more experience setting up nginx??

please mention the host name in the frappe-bench$ folder config/nginx.conf
-relaod the nginx
please check the port of nginx is running.

Sagar Shiragawakar
New Indictrans Technologies Pvt Ltd.

Run bellow commands:
bench config dns_multitenant off
bench setup nginx
sudo service nginx reload

this worked for me, hope it’s work for you also

1 Like

Hi @mayar

ja that works also - quick fix if you only run one instance but as I have 3 installations

one native
one for app dev
and one stable

I had to play about with @sagars solution and get deeper into nginx configuration took a bit but worked in the end

thanks to all