How to redirect a domain with html extension in Nginx

A WordPress website needs to migrate to a different domain, on a new domain site use static HTML pages. On the source site, WordPress is configured to use URL like https://domain1/page-name/, on the new server, the same page available on URL https://domain2/page-name.html

To do the redirection, edit Nginx configuration for the website, on top […]

Read More…

Nginx file upload error

When uploading a file on a PHP Application running under an Nginx web server, I get the following error

The error was due to wrong ownership for folder /var/lib/nginx/tmp/client_body/ or one of its parent folders. On this web server, nginx was running as user nobody, so to fix the error, I run the following […]

Read More…

Enable SSL for icecast steam using nginx

On ubuntu server running icecast, when i try enable SSL as per CentovaCast Enable SSL on icecast, i get following error

I don’t compile my own icecast installation as it use Ubunu version of icecast, that get updated using apt. Instead of getting icecast serve steam using SSL, i installed Nginx, and proxy traffic […]

Read More…

Nginx Hotlink Protection

To block hotlink protection or bandwidth stealing, you can add following to server configuration of your web site.

If you need to allow hotlink from a specific domain, you can edit the valid_referers line and add the url. If you only want to limit access to images and videos, you can put above code […]

Read More…

Nginx Proxy Manager Certificate Key is not valid

When adding custom SSL on Nginx Proxy Manager, i get following error. Upload failed: Certificate Key is not valid (Command failed: openssl ec -in /tmp/15dbf072-4022-aee94-0f88e4fb8d86/tmp -check -noout 2>&1 ) I tried upgrading Nginx Proxy Manager to latest version with following commands

Even after the upgrade this error persist. I checked logs for the docker […]

Read More…

EasyEngine Could not create user

When creating a wordpress web site on EasyEngine, i get following error

This is because EasyEngine try to create a WordPress admin user, that failed to create due to length. To fix the error, you can specify a shorter wordpress admin user name with option –admin-user=admin

See EasyEngine […]

Read More…

Enable Nginx Status Page

Nginx status is provided by http_stub_status module. To verify if your Nginx is installed with this module, run

If the result shows “with-http_stub_status_module”, you have the module installed. To enbale stats edit nginx configuration file for your web site, add following code

To linmit access to this page, you can use allow


Read More…

Nginx upstream sent too big header

Plesk Nginx

When I log in to a PrestaShop website, I get an error on a Plesk server.

On checking error login for the site in folder /var/www/vhosts/, I found the following error message proxy_error_log:2020/11/25 19:41:41 [error] 1809#0: *39664 upstream sent too big header while reading response header from upstream, client:, server:, request: “POST […]

Read More…

Country Blocking with nginx GeoIP on Ubuntu/Debian

On Ubuntu/Debian, install nginx geoip module with

Now edit nginx.conf


Add below

You can add 2 letter country code and set ye/no as required. To implement GeoIP blocking for a web site, you need to edit server entry for the web site. In this cause, i will use the default […]

Read More…