Web servers in NG cluster load and run the following services:

  • Apache with NG modules
  • NG caching service (shstg)
  • NG NSS plugin library libnss_ng.so

With NG module loaded Apache requests information about websites configuration not from text configuration files as in Legacy Apache Shared Hosting but rather from NG Caching Service which in turn requests it from Configuration Database.

An NG web server has the following plugins:

  • Name Service Switch (NSS) plugin
  • Apache NG plugins
  • FTP plug-in (used to resolve user name/login for FTP service, it is loaded as module in the /etc/proftpd.h2e.conf file)
  • pam plug-in (to configure LVE limits for SSH users, SSH is not started under LVE by default). All SSH users have /bin/lve_bash as their shell. This binary moves user process into their LVE, and then executes common bash. No chroot is performed, user UID is the same as webspace ID.

IP addresses of all websites hosted on NG web server are configured as aliases on loopback ‘lo’ interface. Only shared IP addresses can be seen by ifconfig utility, others are added to different routing tables and can be seen with help of 'ip a' command. If due to whatever reason IP address was not setup on loopback interface on webserver it can be setup manually by calling the command

service shstg reconfigure

Customer webspaces are placed on NFS volume which is mounted to all webservers though automount, its configuration can be found in the /etc/auto.h2e file included from the /etc/auto.master file.

The example of NFS automount configuration on web server is provided below:

# cat /etc/auto.master
 +auto.master
 /var/www/vhosts /etc/auto.h2e
# cat /etc/auto.h2e
1       -proto=tcp,auto,intr,rw,nosuid,nodev,soft,nfsvers=3,noatime,nodiratime,actimeo=600,wsize=32768 10.39.94.45:/ngshare

From the example it may be seen that NFS volume #1 (ID is defined in /etc/auto.h2e) is mounted from NFS server 10.39.94.45:/ngshare as /var/www/vhosts/1 (defined in /etc/auto.master) on web server.

Web site logs are stored in webspace on NFS volume. Also logs in /var/log/httpd/ folder on NG web server can be checked in case of problems.

Logs writing is buffered in the Apache NG module. There is one common buffer for all sites handled by one server. Buffer is flushed once a 10 seconds or if  it reaches 16MB – whatever happens earlier. These values can be modified in the /etc/h2e_shstg.conf file by adding tags 'flush-interval' and 'max-allowed-buffer-size'.

See the main Knowledgebase article #114326 Linux Shared Hosting NG: General Information, Best Practices and Troubleshooting for more information about NG Hosting in Parallels Automation.

Internal content