Skip to content
Bots!
Bots!
  • About
    • Myself
    • আমার দোয়া
  • Bookmarks
    • Bookmarks
    • My OCI Bookmarks
    • Useful Proxmox Commands & Links
    • Learning Nano
    • Useful Sites
    • Useful Virtualbox Command
    • Useful MySQL Command
    • Useful Linux Command
    • BTT-CAS
  • Resources
    • Webinar on Cloud Adoption for Project Managers
  • Photos
  • Videos
  • Downloads
Bots!

Install nginx on virtualmin (GPL) server

Rumi, August 26, 2012

Installing Nginx Support

Switching a system from the Apache webserver (installed by default by Virtualmin to Nginx should only be done if no virtual servers with websites have been created yet. Ideally the change should be done on a freshly installed system, running RHEL 6.0, CentOS 6.0 or Debian 6.0 or later. Virtualmin version 3.89 or above is also required.

The steps to remove Apache and install Nginx are :

  1. Shut down Apache with the command /etc/init.d/httpd stop ; service httpd off (on RHEL or CentOS), or /etc/init.d/apache2 stop ; update-rc.d apache2 remove (on Debian).
  2. Install Nginx with the command yum install nginx (on RHEL or CentOS) or apt-get install nginx (on Debian).
  3. Start the Nginx webserver with the command /etc/init.d/nginx start
  4. Install Virtualmin's Nginx plugin with the command yum install wbm-virtualmin-nginx wbm-virtualmin-nginx-ssl (on RHEL or CentOS) or apt-get install webmin-virtualmin-nginx webmin-virtualmin-nginx-ssl (on Debian).

Once this is done, you can configure Virtualmin to use it as follows :

  1. Login to Virtualmin as root, and go to Webmin -> Servers -> Nginx Webserver and make sure that Nginx and its configuration files are found.
  2. If not, click on the Module Config link and set the config and command paths correctly.
  3. Return to Virtualmin, and go to System Settings -> Features and Plugins.
  4. Un-check the "Apache website" , "SSL website" and "DAV Login", "Mailman", "Protected web directories", "AWstats reporting" and "Subversion repositories" features.
  5. Check the "Nginx website" and "Nginx SSL website" features, then click "Save".
  6. If Virtualmin reports that any other features cannot be used without Apache, go back and de-select them too.
  7. Go to the System Information page and click Refresh system information in the top right.
  8. Verify that Nginx is shown as running in the "Status" section.

Using Nginx

Once Nginx support has been configured, you should be able to create virtual servers just as you would with Apache. However, on the Create Virtual Server page you will need to select Enable Nginx website? in the Enabled features section, instead of Enable Apache.

When creating a domain from the command-line API, you will need to use the --virtualmin-nginx flag instead of --ssl . For SSL websites, you will need to use --virtualmin-nginx-ssl instead of --ssl .

Similarly, when creating a domain via the remote API, you will need to use the virtualmin-nginx= parameter instead of web= .

Limitations of Nginx

Nginx as configured by Virtualmin lacks some features of Apache, such as :

  • Only one virtual server can have SSL enabled per IP address, even if a wildcard or UCC certificate would potentially allow multiple SSL sites to share the same IP.

  • Nginx does not support CGI, so any applications or Virtualmin scripts that use CGI will not work. Virtualmin should prevent the installation of scripts that require CGI, mod_perl or Apache-specific features.

  • PHP can only be executed via FastCGI, and all PHP scripts run with domain owner permissions. Execution via CGI or mod_php is not supported. For PHP to work, Virtualmin will setup a PHP FastCGI server process that Nginx communicates with for each virtual server.

  • Only one PHP version is supported, and Virtualmin will pick the highest version available on the system. This typically means that PHP v4 scripts cannot be run.

Src: https://www.virtualmin.com/documentation/web/nginx

Administrations Configurations (Linux) nginxvirtualminWebmin

Post navigation

Previous post
Next post

Myself…

Hi, I am Hasan T. Emdad Rumi, an IT Project Manager & Consultant, Virtualization & Cloud Savvyfrom Dhaka, Bangladesh. I have prior experience in managing numerous local and international projects in the area of Telco VAS & NMC, National Data Center & PKI Naitonal Root and CA Infrastructure. Also engaged with several Offshore Software Development Team.

Worked with Orascom Telecom-Banglalink, Network Elites as VAS partner, BTRC, BTT (Turkey) , Mango Teleservices Limited and Access to Informaiton (A2I-UNDP)

Currently working at Oracle Corporation as Principal Technology Solution and Cloud Architect.

You can reach me [h.t.emdad at gmail.com] and I will be delighted to exchange my views.

Tags

Apache Bind Cacti CentOS CentOS 6 CentOS 7 Debain Debian Debian 10 Debian 11 Debian 12 DKIM Docker endian icinga iptables Jitsi LAMP Letsencrypt Linux Munin MySQL Nagios Nextcloud NFS nginx pfsense php Postfix powerdns Proxmox RDP squid SSH SSL Ubuntu Ubuntu 16 Ubuntu 18 Ubuntu 20 Varnish virtualbox vpn Webmin XCP-NG zimbra

Topics

Recent Posts

  • Install Jitsi on Ubuntu 22.04 / 22.10 April 30, 2025
  • Key Lessons in life April 26, 2025
  • Create Proxmox Backup Server (PBS) on Debian 12 April 19, 2025
  • Add Physical Drive in Proxmox VM Guest April 19, 2025
  • Mount a drive permanently with fstab in Linux April 16, 2025
  • Proxmox 1:1 NAT routing March 30, 2025
  • Installation steps of WSL – Windows Subsystem for Linux March 8, 2025
  • Enabling Nested Virtualization In Proxmox March 8, 2025
  • How to Modify/Change console/SSH login banner for Proxmox Virtual Environment (Proxmox VE / PVE) March 3, 2025
  • Install Proxmox Backup Server on Debian 12 February 12, 2025

Archives

Top Posts & Pages

  • Install Jitsi on Ubuntu 22.04 / 22.10
©2025 Bots! | WordPress Theme by SuperbThemes