Archive for the tag 'file'

SBDavid

The usecpphp File

The usecpphp File

/var/cpanel/usecpphp, when it exists, causes cpsrvd to use a non-system PHP provided by cPanel. You may want to do this if the version of PHP that you have built for Apache does not have all of the features required to run inside of cpsrvd.

This cPanel-provided PHP binary exists on the system as 1 of the 2 following files:

/usr/local/cpanel/3rdparty/bin/php
/usr/local/cpanel/3rdparty/bin/php-cgi

php-cgi is preferred over php if both are available and executable.

This particular PHP binary contains all of the necessary options to run inside of cpsrvd. However, if you experience linking issues or require additional features in the PHP binary that cpsrvd uses, you will need to build an additional local PHP binary. You can do this by running the following script:

/scripts/makecpphp

This script uses the EasyApache framework to build a PHP configuration that will work with cpsrvd. This PHP binary will exist as 1 of the following 2 files:

/var/cpanel/3rdparty/bin/php
/var/cpanel/3rdparty/bin/php-cgi

php-cgi is preferred over php if both are available and executable.

However, if /var/cpanel/usecpphp does not exist, 1 of the the following 2 PHP binaries will be used:

/usr/bin/php
/usr/bin/php-cgi

Reference: http://www.cpanel.net/

CentOS Cpanel Quick Install CD ISO Images & kickstart file

CentOS-5.4-i386-cPanel.iso (Wed Feb 24 22:31:12 2010)
CentOS-5.4-x86_64-cPanel.iso (Wed Feb 24 22:32:13 2010)

Sample kickstart file for automated CentOS Linux installs:

http://httpupdate.cpanel.net/cpanel-ks.cfg

SBDavid

Cpanel failurls File

Cpanel failurls File

The failurls file, located at /var/cpanel/failurls, allows you to specify where resellers can redirect users who fail to authenticate with cPanel.

Enter the URLs to which resellers can redirect users, one per line, in the file.

Entries in this file must meet the following requirements:

Entries must be an exact match. Dynamic URLs are not acceptable.

Example:

http://example.com/index.php?failed=1

Dynamic content on the login page must be passed via hidden POST variables. Using the GET query string will fail because it will not match any entry in the failurls file exactly. When you are finished creating entries in the failurls file, you must restart cPanel. To restart cPanel, run the following command as the root user:

/usr/local/cpanel/startup

Reference : http://cpanel.net/

Building the Apache Configuration File in WHM

The build process begins by distilling and recording Apache’s current configuration. The build time options you configured during the EasyApache setup are used to begin building the configuration.

Option modules such as mod_security are installed, and their corresponding modifications are made to the new Apache configuration file.
A new, assumedly valid Apache configuration file will exist in the configuration directory.
Directives added to the final Apache configuration file as defaults have been removed at this point.
No VirtualHost entries exist in the configuration file at this point.

The new configuration is distilled in much the same way as before; however, this time the configuration is used as the basis for creating the server’s main Apache configuration template.
New directives and values are stored.

Any directives and values held over from the previous configuration will retain their values from that configuration.
The combination of the main template and data stores will be the basis for regenerating the final configuration file.

Finally, the new Apache configuration file is generated from the template and data stores and checked for syntactical correctness.
If the new file passes the test, the process is complete.
If the file fails the syntax check, the previous Apache configuration is restored.

Reference: http://cpanel.net

SBDavid

How to extract a .war file

How to extract a .war file

If your hosting provider supports Tomcat, but not .war files, then you can extract .war file in your public_html folder to run your Tomcat application from there.

jar xvf file-name.war

« Prev - Next »