<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>SupportSages &#187; Snippets</title>
	<atom:link href="http://www.supportsages.com/blog/category/snippets/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.supportsages.com/blog</link>
	<description>Technical Support and Server Management : Musings in the fox hole.</description>
	<lastBuildDate>Fri, 16 Jul 2010 02:47:40 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>All about SSL</title>
		<link>http://www.supportsages.com/blog/2010/07/all-about-ssl/</link>
		<comments>http://www.supportsages.com/blog/2010/07/all-about-ssl/#comments</comments>
		<pubDate>Wed, 07 Jul 2010 22:14:05 +0000</pubDate>
		<dc:creator>victor</dc:creator>
				<category><![CDATA[General]]></category>
		<category><![CDATA[Howtos]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[Training]]></category>
		<category><![CDATA[Troubleshooting]]></category>
		<category><![CDATA[VPS]]></category>
		<category><![CDATA[cPanel]]></category>
		<category><![CDATA[ca bundle]]></category>
		<category><![CDATA[certificate]]></category>
		<category><![CDATA[crt]]></category>
		<category><![CDATA[csr]]></category>
		<category><![CDATA[digest]]></category>
		<category><![CDATA[digital signature]]></category>
		<category><![CDATA[https]]></category>
		<category><![CDATA[key]]></category>
		<category><![CDATA[mac]]></category>
		<category><![CDATA[ssl]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=962</guid>
		<description><![CDATA[﻿﻿﻿﻿SSL or Secure Sockets Layer (Notice the last s in sockets) is used to secure the communication over the internet. This technique was introduced by Netscape. It uses the RSA public key cryptography for encryption/decryption.

In the protocol stack used in the internet. The SSL protocol runs above TCP/IP and below higher-level protocols such as HTTP or IMAP.

The SSL protocol includes two sub-protocols:
1) SSL record protocol
2) SSL handshake protocol

The SSL record protocol defines the format used to transmit data. The SSL handshake protocol involves using the SSL record protocol to exchange a series of messages between an SSL-enabled server and an ...]]></description>
			<content:encoded><![CDATA[<p>﻿﻿﻿﻿SSL or Secure Sockets Layer (Notice the last s in sockets) is used to secure the communication over the internet. This technique was introduced by Netscape. It uses the RSA public key cryptography for encryption/decryption.</p>
<p>In the protocol stack used in the internet. The SSL protocol runs above TCP/IP and below higher-level protocols such as HTTP or IMAP.</p>
<p>The SSL protocol includes two sub-protocols:<br />
1) SSL record protocol<br />
2) SSL handshake protocol</p>
<p>The SSL record protocol defines the format used to transmit data. The SSL handshake protocol involves using the SSL record protocol to exchange a series of messages between an SSL-enabled server and an SSL-enabled client when they first establish an SSL connection.</p>
<p><strong>Now SSL for the layman<br />
<span style="font-weight: normal;">SSL basically creates an encrypted communication channel between the two parties involved in the communication. For a third person involved in the middle of this communication channel, the data seems to be garbled.<span id="more-962"></span></span></strong></p>
<p>Suppose Alice (A, the browser) wishes to communicate with Bob (B, the server) then the exact steps that takes place inorder to begin the encrypted communication are:</p>
<p>1) A -&gt; B	hello<br />
Alice contacts Bob and requests for a private communication (request for an https link at port 443)</p>
<p>2) B -&gt; A	Hi, I&#8217;m Bob, <em>bobs-certificate</em><br />
Bob send back to Alice his certificate. A certificate authenticates that it is Bob who is actually communicating with Alice. It is like a unique ID card displayed.</p>
<p>3) A -&gt; B	prove it<br />
Alice requests Bob to prove his identity.</p>
<p>4) B -&gt; A	Alice, This Is bob <em>{ digest[Alice, This Is Bob] } bobs-private-key</em><br />
Bob sends back a message and its digest encrypted with his private key. This step can also be like sending a document with a digital signature (when you have Alice&#8217;s public key).</p>
<p>5) A -&gt; B	ok bob, here is a secret <em>{secret} bobs-public-key</em><br />
Alice sends back to Bob some secret. Usually a session key encrypted using Bob&#8217;s public key obtained from his certificate</p>
<p>6) B -&gt; A	<em>{some message,MAC}secret-key</em><br />
Next Bob generates a secret key from Alice&#8217;s secret (earlier step) and sends back to Alice the real message and its MAC encrypted with this secret key. This is actually the encrypted website.</p>
<p><a  href="http://www.supportsages.com/blog/wp-content/uploads/2010/07/ssl-handshake.gif" class="thickbox no_icon" rel="gallery-962" title="ssl handshake"><img class="size-full wp-image-976 aligncenter" title="ssl handshake" src="http://www.supportsages.com/blog/wp-content/uploads/2010/07/ssl-handshake.gif" alt="" width="614" height="525" /></a><strong><span style="text-decoration: underline;">Terminologies</span></strong></p>
<p><strong>Certificate<br />
<span style="font-weight: normal;">This is actually bobs public key containing document which is digitally signed by a certificate issuer&#8217;s private key (like Verisign). In this process Verisign gets all the necessary documents to verify that Bob&#8217;s identity is correct and it gets Bob&#8217;s public key (and some other data like certificate expiry period, Bobs identity) and encrypts it with its own private key. Now Verisign&#8217;s public key comes built-in along with every browser (so that the browser can get bobs public key from within it).</span></strong></p>
<p><strong>Digest<br />
<span style="font-weight: normal;">Digest or more appropriately Message Digest is like a summary of the actual message or a portion of the message. The digest of a message is is unique for every unique message, it is a one way function such that obtaining the digest, it is never possible to recover the original message (This does not involve using any key in the process). Message Digest always appears with the original message. Upon reception of this Message and its digest at the receiver&#8217;s end, the receiver can once again calculate the digest from the original message and verify the integrity of the message.</span></strong></p>
<p><strong>Digital signature<br />
<span style="font-weight: normal;"><strong><span style="font-weight: normal;">Let Bob send a document to Alice which is digitally signed. For this Bob must have Alice&#8217;s public key and Alice must have Bob&#8217;s public key.Bob takes the document, encrypts it first with Alice&#8217;s public key and next with its own private key(Bob&#8217;s)</span></strong></span></strong></p>
<p>B -&gt; A<span style="white-space: pre;"> </span><em>[{message}alices-public-key ]bobs-public-key</em></p>
<p><strong>Session Key</strong><br />
The only secret which is communicated using public key encryption is a session key. Now the session key is chosen from the &#8217;secret&#8217; that the parties accept. the session key could be the secret itself or a portion of the secret or the result when the secret is passed through a previously agreed algorithm. The SSL encrypted communication does&#8217;t necessary have to be created using a public key encryption technique (This uses a lot of overhead, i.e. processing and time), it may be simple symmetric cypher(less overhead) using this session key once agreed upon. There are a variety of cypher suites available (IDEA Blow-fish RSA DES MD5 KEA) and both the parties may choose some encryption technique based on the protocol used (SSL1.0 SSL2.0 TLS etc)</p>
<p><strong>MAC</strong><br />
MAC or Message Authentication Code is similar to the Message Digest we have discussed. It is used to verify the integrity of the Message.</p>
<p><em>MAC := Digest[ some message, secret ]</em></p>
<p><strong><span style="text-decoration: underline;">Files associated with SSL</span></strong></p>
<p><strong>CSR</strong><br />
CSR or Certificate Signing Request is a string of text generated by the server. This file is sent to the SSL vendor while purchasing an SSL. In the process of generating your CSR, you provide a number of details regarding the domain being registered. Excerpts of text from all these are taken to generate your private key. This private key is present only within the server and nowhere else. The content of the CSR basically contains the public key along with all the details you have used. You get this as domain.com.csr or domain_com.csr.</p>
<p><strong>CA bundle</strong><br />
CA (Certificate Authority) bundle file is one which contains the public key of the Certificate Issuer (Like Verisign&#8217;s public key). Usually this is not required while installing the SSL and most browsers will have this detail in advance to decrypt the SSL certificate (the CRT file) from the server. You get this as domain.com.cabundle or domain_com.ca-bundle.</p>
<p><strong>CRT</strong><br />
This is the actuall SSL certificate as obtained from the SSL vendor. It is a file (containing the public key of the domain secured with SSL and other details like the expiry date, owner information, address etc of the SSL) which is encrypted with the private key of the SSL vendor (Digitaly signed by the SSL vendor). You get this as domain.com.crt or domain_com.crt .</p>
<p><strong>Key file</strong><br />
This is the file which holds your private key (strictly confidential material). The file will have the RSA private key as generated by your server software. You get this as customcardsplus.com.key or customcardsplus_com.key. This file is not usually send to your SSL vendor unlike the CSR. You get this as domain.com.key or domain_com.key .</p>
<p><strong>SSL in a cPanel server</strong><br />
Any service can be secured in a communication channel which is encrypted with SSL. Each of this service on the encrypted channel will be on a different port. Some of them are as follows:</p>
<table style="height: 148px;" border="1" cellpadding="3" width="160">
<tbody>
<tr style="text-align: center;">
<td>
<h2><strong>service</strong></h2>
</td>
<td>
<h2><strong>normal</strong></h2>
</td>
<td>
<h2><strong>ssl</strong></h2>
</td>
</tr>
<tr>
<td>http</td>
<td>80</td>
<td>443</td>
</tr>
<tr>
<td>telnet</td>
<td>23</td>
<td>992</td>
</tr>
<tr>
<td>imap</td>
<td>143/220</td>
<td>993</td>
</tr>
<tr>
<td>pop</td>
<td>109/110</td>
<td>995</td>
</tr>
<tr style="text-align: left;">
<td>smtp</td>
<td>25</td>
<td>465</td>
</tr>
</tbody>
</table>
<p>A domain served as a secure webpage will require a dedicated IP (in a shared environment). SSL protocol is designed to use IP-based mapping. SSL does not support host headers. Therefore, you should have a unique IP address assigned to your secure site. These pages are served from the port 443. Let us examine the configuration of such a website in the apache&#8217;s config file /usr/local/apache/conf/httpd.conf.</p>
<p>Every website (in our example domain.com with username: doma) enabled with SSL has a unique set of directives in the VirtualHost section for the 443 port as:</p>
<pre class="brush: bash;">
&lt;VirtualHost 266.11.208.293:443\&gt; Dedicated IP of the domain

ServerName domain.com #Domain name secured with SSL
ServerAlias www.domain.com

DocumentRoot /home/doma/public_html

ServerAdmin webmaster@domain.com
UseCanonicalName off
CustomLog /usr/local/apache/domlogs/domain.com combined

CustomLog /usr/local/apache/domlogs/domain.com-bytes_log &quot;%{%s}t %I .\n%{%s}t %O .&quot;
ScriptAlias /cgi-bin/ /home/doma/public_html/cgi-bin/
SSLEngine on #This directive enables the SSL on this domain
SSLCertificateFile /etc/ssl/certs/www.domain.com.crt #Location of CRT file
SSLCertificateKeyFile /etc/ssl/private/www.doma.com.key #Location of Private key
SSLCACertificateFile /etc/ssl/certs/www.domain.com.cabundle #Location of CAbundle file
CustomLog /usr/local/apache/domlogs/domain.com-ssl_log combined #Log specific for the SSL served webpage
SetEnvIf User-Agent &quot;.*MSIE.*&quot; nokeepalive ssl-unclean-shutdown

&lt;Directory &quot;/home/doma/public_html/cgi-bin&quot;&gt;
SSLOptions +StdEnvVars #This directive will pass mod_ssl environment variables to the server scripts.
&lt;/Directory&gt;

&lt;/VirtualHost&gt;
</pre>
<p>Some times the directive SSLCertificateChainFile is used in place of SSLCACertificateFile. The minimal addition you will have to make to enable SSL in your httpd.conf file is:</p>
<pre class="brush: bash;">
&lt;VirtualHost 192.168.0.1:443&gt;
DocumentRoot /var/www/html
ServerName www.yourdomain.com
SSLEngine on
SSLCertificateFile /path/to/your_domain_name.crt
SSLCertificateKeyFile /path/to/your_private.key
SSLCertificateChainFile /path/to/DigiCertCA.crt
&lt;/VirtualHost&gt;
</pre>
<p>There are two locations where you are likely to find the SSL related files in your cPanel server. Usually the crt, key and the ca bundle are present in the home directory of the user in /home/username/ssl/, if it was installed using the client&#8217;s cpanel. However if the WHM was used instead to install the same, you will find it in /etc/ssl/. In either of these locations you will find two directories: certs/ and private/. certs contain the crt and cabundle while the private contains the keys.</p>
<p>Now you know how ssl works in your server, Any more questions? just comment!</p>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=All+about+SSL+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F962" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=All+about+SSL+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F962" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2010/07/all-about-ssl/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Source compilation of Apache</title>
		<link>http://www.supportsages.com/blog/2010/06/source-compilation-of-apache/</link>
		<comments>http://www.supportsages.com/blog/2010/06/source-compilation-of-apache/#comments</comments>
		<pubDate>Sat, 05 Jun 2010 21:03:45 +0000</pubDate>
		<dc:creator>victor</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[Howtos]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[Training]]></category>
		<category><![CDATA[VPS]]></category>
		<category><![CDATA[installation]]></category>
		<category><![CDATA[source]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=871</guid>
		<description><![CDATA[<strong>﻿Basics of Compilation of Apache with PHP</strong>

Here we are going to install apache using the source only. The choice of Operating System here is Linux (distro: Centos). The procedure we follow here will lead to a simple apache installation for dynamic loading of php. PHP will be installed as a module to apache. With a little bit of patience and time, all the necessary modules can be installed with apache. I will be giving a brief idea about the installation of the other modules later.
The basics of installation from the source involves mainly three <em>simple</em> steps (assuming you are lucky):

[bash]
./configure
make
make ...]]></description>
			<content:encoded><![CDATA[<p><strong>﻿Basics of Compilation of Apache with PHP</strong></p>
<p>Here we are going to install apache using the source only. The choice of Operating System here is Linux (distro: Centos). The procedure we follow here will lead to a simple apache installation for dynamic loading of php. PHP will be installed as a module to apache. With a little bit of patience and time, all the necessary modules can be installed with apache. I will be giving a brief idea about the installation of the other modules later.<br />
The basics of installation from the source involves mainly three <em>simple</em> steps (assuming you are lucky):</p>
<pre class="brush: bash;">
./configure
make
make install</pre>
<p>./configure creates the MAKEFILE on the fly. We can provide the necessary options to configure. To list the available options in the configuring step use</p>
<pre class="brush: bash;">./configure --help</pre>
<p>&#8211;prefix=/path/&#8230; mentions where the executable and its files are installed. If not mentioned it takes the default values.<br />
&#8211;enable-[Feature] will enable the specified Feature in apache as it is being built. We are only interested in the DSO capability and hence we enable it with: &#8211;enable-so</p>
<p>As a convention we always keep the source code tar ball inside a directory in /usr/src/, thus source installation begins in this directory.</p>
<p><strong>Apache Compilation</strong></p>
<p>Download the required source tar ball of the apache you would like to compile. Here I am installing httpd-2.0.63 from http://httpd.apache.org/download.cgi#apache20. I save it in the /usr/src/ folder.</p>
<pre class="brush: bash;">
cd /usr/src/
wget http://www.bizdirusa.com/mirrors/apache/httpd/httpd-2.0.63.tar.gz</pre>
<p>This will result in the generation of the file httpd-2.0.63.tar.gz</p>
<pre class="brush: bash;">
tar -xzf httpd-2.0.63.tar.gz</pre>
<p>This will result in the creation of the directory httpd-2.0.63. Next enter inside this directory and execute the ./configure command.</p>
<pre class="brush: bash;">
cd httpd-2.0.63
./configure --prefix=/usr/local/webserver --enable-so</pre>
<p>We are installing apache inside /usr/local/webserver and enable DSO to run php as a module to apache. During this process we may get a lot of errors. We resolve these by manually installing the unresolved dependencies either by obtaining their rpms or by using yum. Normally the first dependency we will get to resolve are:</p>
<pre class="brush: bash;">
gcc
glibc
libxml and
their corresponding devel packages</pre>
<p>In the days where there were no package management tools like yum, pirut, apt-get etc. The old rpms served the installation of these packages with some effort. The task of determining the required rpm package for the required architecture and resolving the other dependencies which arise due to the installation of this rpm may be a tedious task. Some sites which helped in obtaining the necessary rpm suited for our installation and its other dependancies are:</p>
<pre class="brush: bash;">

http://rpm.pbone.net/

http://www.rpmfind.net/linux/RPM/

http://ftp.freshrpms.net/

http://dries.ulyssis.org/rpm/packages.html

http://apt.sw.be/

http://rpms.famillecollet.com/ (Remi RPM Repository)</pre>
<p>Once everything goes well (we do the ./configure step again to determine this), the make command is executed.</p>
<pre class="brush: bash;">
make</pre>
<p>If errors are encountered in this stage, We resolve them by installing the unresolved dependencies (Same as the previous step) and then do:</p>
<pre class="brush: bash;">
make clean</pre>
<p>After this we repeat the make command and then issue:</p>
<pre class="brush: bash;">
make install</pre>
<p>This process installs the package finally within the system. Modify the init script ( /etc/rc.d/init.d/httpd or /etc/init.d/httpd they are symbolic links) Or sometimes you may even have to create one from the apache site.</p>
<p>The following is the content of one such init script I have used. The line beginning with apachectl/some/path/here and httpd=/some/path/here have to replaced with the appropriate line we have used in the &#8211;prefix portion of ./configure.</p>
<pre class="brush: bash;">
#!/bin/bash
#
# Startup script for the Apache Web Server
#
# chkconfig: - 85 15
# description: Apache is a World Wide Web server.  It is used to serve \
#              HTML files and CGI.
# processname: httpd
# processname: httpd
# pidfile: /usr/local/apache2/logs/httpd.pid
# config: /usr/local/apache2/conf/httpd.conf
# Source function library.
. /etc/rc.d/init.d/functions
if [ -f /etc/sysconfig/httpd ]; then
. /etc/sysconfig/httpd
fi
# This will prevent initlog from swallowing up a pass-phrase prompt if
# mod_ssl needs a pass-phrase from the user.
INITLOG_ARGS=&quot;&quot;
# Path to the apachectl script, server binary, and short-form for messages.
apachectl=/usr/local/webserver/bin/apachectl
httpd=/usr/local/webserver/bin/httpd
pid=$httpd/logs/httpd.pid
prog=httpd
RETVAL=0
# The semantics of these two functions differ from the way apachectl does
# things -- attempting to start while running is a failure, and shutdown
# when not running is also a failure.  So we just do it the way init scripts
# are expected to behave here.
start() {
echo -n $&quot;Starting $prog: &quot;
daemon $httpd $OPTIONS
RETVAL=$?
echo
[ $RETVAL = 0 ] &amp;amp;&amp;amp; touch /var/lock/subsys/httpd
return $RETVAL
}
stop() {
echo -n $&quot;Stopping $prog: &quot;
killproc $httpd
RETVAL=$?
echo
[ $RETVAL = 0 ] &amp;amp;&amp;amp; rm -f /var/lock/subsys/httpd $pid
}
reload() {
echo -n $&quot;Reloading $prog: &quot;
killproc $httpd -HUP
RETVAL=$?
echo
}
# See how we were called.
case &quot;$1&quot; in
start)
start
;;
stop)
stop
;;
status)
status $httpd
RETVAL=$?
;;
restart)
stop
start
;;
condrestart)
if [ -f $pid ] ; then
stop
start
fi
;;
reload)
reload
;;
graceful|help|configtest|fullstatus)
$apachectl $@
RETVAL=$?
;;
*)
echo $&quot;Usage: $prog {start|stop|restart|condrestart|reload|status&quot;
echo $&quot;|fullstatus|graceful|help|configtest}&quot;
exit 1
esac
exit $RETVAL</pre>
<p>Next we add the daemon name to the list of services and run it. For this follow the below steps.</p>
<pre class="brush: bash;">
chkconfig --add httpd
chkconfig --level 2345 httpd on
chkconfig --list httpd
/etc/init.d/httpd start
lynx http://localhost/ will display the default apache page which means success.</pre>
<p><strong>PHP Compilation</strong><br />
Now we are going to install PHP 5.2.13 from source!<br />
Go to /usr/src/</p>
<pre class="brush: bash;">
cd /usr/src/</pre>
<p>Download the PHP source tarball and extract it</p>
<pre class="brush: bash;">
wget http://in3.php.net/get/php-5.2.13.tar.gz/from/in.php.net/mirror
tar -xzf php*
cd php*</pre>
<p>Just like in the previous apache installation, we are going to do the ./configure step with the required setting which are displayed using</p>
<pre class="brush: bash;">./configure --help</pre>
<p>We are only interested in enabling php as a module (&#8211;with-apxs2) support for mysql (&#8211;with-mysql) and prefix line. So we go for:</p>
<pre class="brush: bash;">
./configure --with-apxs2=/usr/local/webserver/bin/apxs --with-mysql --prefix=/usr/local/webserver/php</pre>
<p>The long command can be written in a shorter, more clearer format with:</p>
<pre class="brush: bash;">
./configure --with-apxs2=/usr/local/webserver/bin/apxs \
--with-mysql \
--prefix=/usr/local/webserver/php</pre>
<p>The same instructions go for the errors here.<br />
Once everything goes smooth:</p>
<pre class="brush: bash;">
make
make install</pre>
<p>We can provide the recommeneded php.ini setting in the path /usr/local/webserver/php/lib (what ever is the &#8211;prefix + /lib) or just copy the recommended settings to /usr/local/webserver/php/lib (This file may have the name php.ini-recommended or php.ini-production)<br />
cp php.ini-recommended /usr/local/webserver/php/lib/php.ini</p>
<p>From now on we can have php&#8217;s index page to be the default index page. For this in the apache&#8217;s config file append index.php to the directive &#8211; DirectoryIndex</p>
<p>The line would thus look like:</p>
<pre class="brush: bash;">
DirectoryIndex index.html index.html.var index.php</pre>
<p>To make make apache call modular php to execute the php script when encountered, add the following lines to the conf file.</p>
<pre class="brush: bash;">
AddType application/x-httpd-php .php
DirectoryIndex index.html index.html.var index.php</pre>
<p>Next to test your installation.<br />
In the default document root, create a phpinfo file with the file name index.php an d the contents as:</p>
<pre class="brush: bash;">
&amp;lt;?
phpinfo();
?&amp;gt;</pre>
<p>Now we will test the apache configuration for any syntax errors and then reload the apache webserver:</p>
<pre class="brush: bash;">
apachectl configtest (No errors should be reported)
/etc/init.d/httpd reload</pre>
<p>Open a browser window and load the localhost as URL, we will be viewing the phpinfo page in here. In the phpinfo page, the portion Configure Command shows the actual compilation time options used while ./configure is used. The row corresponding to Server API mentions how the php is loaded. &#8216;Apache 2.0 Handler&#8217; means that php was loaded as a module of apache. The rest of the values can be globally changed by making the required changes in php.ini or locally in .htaccess (which is possible only because it is loaded as an apache module).</p>
<p><strong>Tips on installing PHP as a CGI</strong></p>
<p>Here we do not require installing apache with the &#8211;enable-so option. A normal installation will do. The installation of php will not require the option &#8211;with-apxs2. However we will have to mention the location of apache source directory with &#8211;with-apache=../apache_1.3.14</p>
<p>In the httpd.conf file you will require adding:</p>
<pre class="brush: bash;">
ScriptAlias /php/ [path where your php folder is located]
AddType application/x-httpd-php .php
AddType application/x-httpd-php .php3
AddType application/x-httpd-php .phtml
Action application/x-httpd-php /php/php5</pre>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=Source+compilation+of+Apache+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F871" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=Source+compilation+of+Apache+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F871" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2010/06/source-compilation-of-apache/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Adjusting the language settings in spamassassin</title>
		<link>http://www.supportsages.com/blog/2009/08/adjusting-the-language-settings-in-spamassassin/</link>
		<comments>http://www.supportsages.com/blog/2009/08/adjusting-the-language-settings-in-spamassassin/#comments</comments>
		<pubDate>Fri, 14 Aug 2009 22:44:43 +0000</pubDate>
		<dc:creator>Jince</dc:creator>
				<category><![CDATA[Howtos]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[cPanel]]></category>
		<category><![CDATA[ok_languages]]></category>
		<category><![CDATA[spamassassin]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=514</guid>
		<description><![CDATA[To change the language settings of spamassassin edit the file <strong>user_prefs</strong> located at  <strong>/home/username/.spamassassin</strong> if it isn't located there you need to create one.

We need to edit or add values <strong>ok_languages</strong> with the extra languages you would like to have in the two letter code.
This option is used to specify which languages are considered OK for incoming mail.
<blockquote>ok_languages all (allow all languages)
ok_languages en (only allow English)
ok_languages en ja hi (allow English, Japanese, and Hindi)</blockquote>]]></description>
			<content:encoded><![CDATA[<p>To change the language settings of spamassassin edit the file <strong>user_prefs</strong> located at  <strong>/home/username/.spamassassin</strong> if it isn&#8217;t located there you need to create one.</p>
<p>We need to edit or add values <strong>ok_languages</strong> with the extra languages you would like to have in the two letter code.<br />
This option is used to specify which languages are considered OK for incoming mail.</p>
<blockquote><p>ok_languages all (allow all languages)<br />
ok_languages en (only allow English)<br />
ok_languages en ja hi (allow English, Japanese, and Hindi)</p></blockquote>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=Adjusting+the+language+settings+in+spamassassin+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F514" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=Adjusting+the+language+settings+in+spamassassin+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F514" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2009/08/adjusting-the-language-settings-in-spamassassin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Magento Installation SOAP error in loading WSDL</title>
		<link>http://www.supportsages.com/blog/2009/07/magento-installation-soap-error-in-loading-wsdl/</link>
		<comments>http://www.supportsages.com/blog/2009/07/magento-installation-soap-error-in-loading-wsdl/#comments</comments>
		<pubDate>Thu, 16 Jul 2009 12:42:32 +0000</pubDate>
		<dc:creator>George</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[Troubleshooting]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=437</guid>
		<description><![CDATA[When you are trying to access the URL at http://www.example.com/api/soap/index/ , it gets redirected to http://www.example.com/index.php/api/soap/index/ you get the following error. But if you try to load the API directly, you get the WSDL as it should be in a XML format.

<code><span style="color: #007700;">&#60;</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">:</span><span style="color: #0000bb;">Envelope xmlns</span><span style="color: #007700;">:</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">=</span><span style="color: #dd0000;">"http://schemas.xmlsoap.org/soap/envelope/"</span><span style="color: #007700;">&#62;
&#60;</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">:</span><span style="color: #0000bb;">Body</span><span style="color: #007700;">&#62;
&#60;</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">:</span><span style="color: #0000bb;">Fault</span><span style="color: #007700;">&#62;
&#60;</span><span style="color: #0000bb;">faultcode</span><span style="color: #007700;">&#62;</span><span style="color: #0000bb;">WSDL</span><span style="color: #007700;">&#60;/</span><span ...]]></description>
			<content:encoded><![CDATA[<p>When you are trying to access the URL at http://www.example.com/api/soap/index/ , it gets redirected to http://www.example.com/index.php/api/soap/index/ you get the following error. But if you try to load the API directly, you get the WSDL as it should be in a XML format.</p>
<p><code><span style="color: #007700;">&lt;</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">:</span><span style="color: #0000bb;">Envelope xmlns</span><span style="color: #007700;">:</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">=</span><span style="color: #dd0000;">"http://schemas.xmlsoap.org/soap/envelope/"</span><span style="color: #007700;">&gt;<br />
&lt;</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">:</span><span style="color: #0000bb;">Body</span><span style="color: #007700;">&gt;<br />
&lt;</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">:</span><span style="color: #0000bb;">Fault</span><span style="color: #007700;">&gt;<br />
&lt;</span><span style="color: #0000bb;">faultcode</span><span style="color: #007700;">&gt;</span><span style="color: #0000bb;">WSDL</span><span style="color: #007700;">&lt;/</span><span style="color: #0000bb;">faultcode</span><span style="color: #007700;">&gt;<br />
&lt;</span><span style="color: #0000bb;">faultstring</span><span style="color: #007700;">&gt;</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ERROR</span><span style="color: #007700;">: </span><span style="color: #0000bb;">Parsing WSDL</span><span style="color: #007700;">: </span><span style="color: #0000bb;">Couldn</span><span style="color: #dd0000;">'t load from '</span><span style="color: #0000bb;">http</span><span style="color: #007700;">:</span><span style="color: #ff8000;">//www.example.com/api/soap/index/wsdl/1/'&lt;/faultstring&gt;<br />
</span><span style="color: #007700;">&lt;/</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">:</span><span style="color: #0000bb;">Fault</span><span style="color: #007700;">&gt;<br />
&lt;/</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">:</span><span style="color: #0000bb;">Body</span><span style="color: #007700;">&gt;<br />
&lt;/</span><span style="color: #0000bb;">SOAP</span><span style="color: #007700;">-</span><span style="color: #0000bb;">ENV</span><span style="color: #007700;">:</span><span style="color: #0000bb;">Envelope</span><span style="color: #007700;">&gt;</span></code></p>
<p>There could be many reasons for this. But the issue with us for that particular issue is that www.example.com was not resolving from the server. A simple /etc/hosts entry in the server (poor solution) or making it resolve from the server should solve the issue.</p>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=Magento+Installation+SOAP+error+in+loading+WSDL++http%3A%2F%2Fwww.supportsages.com%2Fblog%2F437" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=Magento+Installation+SOAP+error+in+loading+WSDL++http%3A%2F%2Fwww.supportsages.com%2Fblog%2F437" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2009/07/magento-installation-soap-error-in-loading-wsdl/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>rar and unrar archives in linux</title>
		<link>http://www.supportsages.com/blog/2009/07/rar-and-unrar-archives-in-linux/</link>
		<comments>http://www.supportsages.com/blog/2009/07/rar-and-unrar-archives-in-linux/#comments</comments>
		<pubDate>Sun, 12 Jul 2009 11:10:39 +0000</pubDate>
		<dc:creator>victor</dc:creator>
				<category><![CDATA[Howtos]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[Training]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=431</guid>
		<description><![CDATA[<p style="text-align: left;">Rar archived files are very common these days and we have a solution for rar file extraction and compression in linux. To extract rar files we have the unrar application.</p>
<blockquote>
<p style="text-align: left;">To use unrar to extract use the following commands:
unrar e &#60;filename.rar&#62; use this to unpack the rar file in current directory
unrar l &#60;filename.rar&#62; use this to list the files inside the archive
unrar x &#60;filename.rar&#62; use this to extract the files with the full path
unrar t &#60;filename.rar&#62; use this to test the integrity of archive</blockquote>
<p style="text-align: left;">Now for those who wish to compress files into the rar archived ...]]></description>
			<content:encoded><![CDATA[<p style="text-align: left;">Rar archived files are very common these days and we have a solution for rar file extraction and compression in linux. To extract rar files we have the unrar application.</p>
<blockquote>
<p style="text-align: left;">To use unrar to extract use the following commands:<br />
unrar e &lt;filename.rar&gt; use this to unpack the rar file in current directory<br />
unrar l &lt;filename.rar&gt; use this to list the files inside the archive<br />
unrar x &lt;filename.rar&gt; use this to extract the files with the full path<br />
unrar t &lt;filename.rar&gt; use this to test the integrity of archive</p></blockquote>
<p style="text-align: left;">Now for those who wish to compress files into the rar archived format, we have the rar application and the following commands will come in handy:</p>
<blockquote><p>rar a &lt;desired filename.rar&gt; &lt;path of directory to archieve&gt; use this to create a normal compressed rar archieve<br />
rar a &lt;desired filename.rar&gt; &lt;path to file1&gt; &lt;path to file2&gt; &lt;path to file3&gt; &#8230; use this more multiple individual files to be archived into a sigle rar file.<br />
rar a -p&lt;password&gt; &lt;desired filename.rar&gt; &lt;path to dir or file&gt; use this to password protect the rar files<br />
rar a -m&lt;level of compression 1-least 5-best&gt; -v&lt;size of each rar file&gt; &lt;desired filename.rar&gt;&lt;path to dir or file&gt; use this to split the file to a number of rar archived files of desired size.</p></blockquote>
<p style="text-align: left;">Now to get all this and install the rar and unrar application, proceed with the following commands:</p>
<blockquote><p>wget http://www.rarlab.com/rar/rarlinux-3.6.0.tar.gz<br />
tar -zxvf rarlinux-3.6.0.tar.gz<br />
cd rar<br />
cp rar unrar /bin</p></blockquote>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=rar+and+unrar+archives+in+linux+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F431" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=rar+and+unrar+archives+in+linux+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F431" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2009/07/rar-and-unrar-archives-in-linux/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>YUMmy problem in Centos 5.3</title>
		<link>http://www.supportsages.com/blog/2009/06/yummy-problem-in-centos-53/</link>
		<comments>http://www.supportsages.com/blog/2009/06/yummy-problem-in-centos-53/#comments</comments>
		<pubDate>Sun, 07 Jun 2009 01:17:22 +0000</pubDate>
		<dc:creator>victor</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[Troubleshooting]]></category>
		<category><![CDATA[VPS]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=413</guid>
		<description><![CDATA[This is a rare issue found in certain VPSes purchased recently. There will be no problem within the system but yum will refuse to function properly. No installations or updations will be possible with yum. All you get to see is a collection of error statements in the shell (upon running the yum command):

Loaded plugins: fastestmirror
error: no dbpath has been set
error: cannot open Packages database in /%{_dbpath}
Traceback (most recent call last):
File "/usr/bin/yum", line 29, in ?
yummain.user_main(sys.argv[1:], exit_code=True)
File "/usr/share/yum-cli/yummain.py", line 229, in user_main
errcode = main(args)
File "/usr/share/yum-cli/yummain.py", line 84, in main
base.getOptionsConfig(args)
File "/usr/share/yum-cli/cli.py", line 184, in getOptionsConfig
enabled_plugins=self.optparser._splitArg(opts.enableplugins))
File "/usr/lib/python2.4/site-packages/yum/__init__.py", line 191, in _getConfig
self._conf = ...]]></description>
			<content:encoded><![CDATA[<p>This is a rare issue found in certain VPSes purchased recently. There will be no problem within the system but yum will refuse to function properly. No installations or updations will be possible with yum. All you get to see is a collection of error statements in the shell (upon running the yum command):</p>
<p>Loaded plugins: fastestmirror<br />
error: no dbpath has been set<br />
error: cannot open Packages database in /%{_dbpath}<br />
Traceback (most recent call last):<br />
File &#8220;/usr/bin/yum&#8221;, line 29, in ?<br />
yummain.user_main(sys.argv[1:], exit_code=True)<br />
File &#8220;/usr/share/yum-cli/yummain.py&#8221;, line 229, in user_main<br />
errcode = main(args)<br />
File &#8220;/usr/share/yum-cli/yummain.py&#8221;, line 84, in main<br />
base.getOptionsConfig(args)<br />
File &#8220;/usr/share/yum-cli/cli.py&#8221;, line 184, in getOptionsConfig<br />
enabled_plugins=self.optparser._splitArg(opts.enableplugins))<br />
File &#8220;/usr/lib/python2.4/site-packages/yum/__init__.py&#8221;, line 191, in _getConfig<br />
self._conf = config.readMainConfig(startupconf)<br />
File &#8220;/usr/lib/python2.4/site-packages/yum/config.py&#8221;, line 754, in readMainConfig<br />
yumvars['releasever'] = _getsysver(startupconf.installroot, startupconf.distroverpkg)<br />
File &#8220;/usr/lib/python2.4/site-packages/yum/config.py&#8221;, line 824, in _getsysver<br />
idx = ts.dbMatch(&#8216;provides&#8217;, distroverpkg)<br />
TypeError: rpmdb open failed</p>
<p>At the same time rpm is also not found to be working for any of the users reporting this issue. &#8216;rpm&#8217; simply will not install any rpm packaged file. It will exit with no result.</p>
<p>To solve the issue execute the following commands as root:</p>
<blockquote><p>#rm /dev/urandom<br />
#mknod -m 644 /dev/urandom c 1 9<br />
#yum clean all<br />
#yum update all</p></blockquote>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=YUMmy+problem+in+Centos+5.3+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F413" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=YUMmy+problem+in+Centos+5.3+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F413" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2009/06/yummy-problem-in-centos-53/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Howto find what distribution of Linux, you are running ?</title>
		<link>http://www.supportsages.com/blog/2009/05/howto-find-what-distribution-of-linux-you-are-running/</link>
		<comments>http://www.supportsages.com/blog/2009/05/howto-find-what-distribution-of-linux-you-are-running/#comments</comments>
		<pubDate>Sun, 31 May 2009 08:51:46 +0000</pubDate>
		<dc:creator>George</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[different flavors of linux]]></category>
		<category><![CDATA[distro]]></category>
		<category><![CDATA[Linux snippets]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=394</guid>
		<description><![CDATA[I often compare different distributions of Linux with different flavors of icecream. Usually the comparison does click, for those who are confused with the versions and demands redhat linux on their desktop. Whenever I go to a home to install linux, they often want Redhat Linux. And it would my job to make them understand that we know their tastes better, when it comes to linux and end up in installing Ubuntu.

However in sysadmin profession, we logs into 100s of boxes every day. How do we know which version of Linux is installed and other details ? For debian based ...]]></description>
			<content:encoded><![CDATA[<p>I often compare different distributions of Linux with different flavors of icecream. Usually the comparison does click, for those who are confused with the versions and demands redhat linux on their desktop. Whenever I go to a home to install linux, they often want Redhat Linux. And it would my job to make them understand that we know their tastes better, when it comes to linux and end up in installing Ubuntu.</p>
<p>However in sysadmin profession, we logs into 100s of boxes every day. How do we know which version of Linux is installed and other details ? For debian based boxes, you check /etc/*version and redhat based boxes we do /etc/*release. But what about others and tons of flavors out there ?</p>
<p>Solution resides with Linux Standard Base, best explained at <a  href="http://en.wikipedia.org/wiki/Linux_Standard_Base">http://en.wikipedia.org/wiki/Linux_Standard_Base</a> which is a joint project by several Linux distributions under the organizational structure of the Linux Foundation </p>
<p>Know the command lsb_release and find them all.</p>
<blockquote><p>lsb_release &#8211;all</p></blockquote>
<p>Linux tip for the day <img src='http://www.supportsages.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=Howto+find+what+distribution+of+Linux%2C+you+are+running+%3F+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F394" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=Howto+find+what+distribution+of+Linux%2C+you+are+running+%3F+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F394" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2009/05/howto-find-what-distribution-of-linux-you-are-running/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>lxadmin aka Kloxo not listening in a centos after a default installation. Please help!</title>
		<link>http://www.supportsages.com/blog/2009/05/lxadmin-aka-kloxo-not-listening-in-a-centos-after-a-default-installation-please-help/</link>
		<comments>http://www.supportsages.com/blog/2009/05/lxadmin-aka-kloxo-not-listening-in-a-centos-after-a-default-installation-please-help/#comments</comments>
		<pubDate>Mon, 18 May 2009 13:06:25 +0000</pubDate>
		<dc:creator>George</dc:creator>
				<category><![CDATA[Howtos]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[Troubleshooting]]></category>
		<category><![CDATA[firewall]]></category>
		<category><![CDATA[iptables]]></category>
		<category><![CDATA[kloxo]]></category>
		<category><![CDATA[lighttpd]]></category>
		<category><![CDATA[lxadmin]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=361</guid>
		<description><![CDATA[Klaxo was installed without any errors. But still inside the server Klaxo and the stuffs were working, but from a browser in the WWW, it isn't and hows cannot be found or page cannot be displayed errors

telnet ip.ip.ip.ip 7777 was working from inside the server, but not from outside network. It was showing,
<code>
telnet  ip.ip.ip.ip 7777
Trying  ip.ip.ip.ip...
telnet: Unable to connect to remote host: No route to host</code>

It was returning the same for every port, except 22. In a normal situation, if the port 22 also was not working, the issue could have been network related, but in this case ...]]></description>
			<content:encoded><![CDATA[<p>Klaxo was installed without any errors. But still inside the server Klaxo and the stuffs were working, but from a browser in the WWW, it isn&#8217;t and hows cannot be found or page cannot be displayed errors</p>
<p>telnet ip.ip.ip.ip 7777 was working from inside the server, but not from outside network. It was showing,<br />
<code><br />
telnet  ip.ip.ip.ip 7777<br />
Trying  ip.ip.ip.ip...<br />
telnet: Unable to connect to remote host: No route to host</code></p>
<p>It was returning the same for every port, except 22. In a normal situation, if the port 22 also was not working, the issue could have been network related, but in this case port 22 was working fine. So the issue was not related to networking, but &#8230;&#8230; ? Guess what ?</p>
<p>Yes. Any seasoned administrator should have guessed the answer to be the firewall and yes that was right. The iptables ruleset had a line which says,</p>
<p><code>REJECT     all  --  0.0.0.0/0            0.0.0.0/0           reject-with icmp-host-prohibited</code></p>
<p>Deleted that line and things went smooth after that.</p>
<p>Don&#8217;t forget to run save the iptables rules, by executing the commands below,<br />
<code><br />
[root@server ~]# iptables -D RH-Firewall-1-INPUT  10<br />
[root@server ~]# /etc/init.d/iptables save<br />
Saving firewall rules to /etc/sysconfig/iptables:          [  OK  ]<br />
[root@server ~]# iptables-save</code></p>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=lxadmin+aka+Kloxo+not+listening+in+a+centos+after+a+default+installation.+Please+help%21+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F361" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=lxadmin+aka+Kloxo+not+listening+in+a+centos+after+a+default+installation.+Please+help%21+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F361" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2009/05/lxadmin-aka-kloxo-not-listening-in-a-centos-after-a-default-installation-please-help/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Howto move horde specific settings especially calendar, address box, notepad settings etc when moved from one cPanel server to another</title>
		<link>http://www.supportsages.com/blog/2009/05/howto-move-horde-specific-settings-especially-calendar-address-box-notepad-settings-etc-when-moved-from-one-cpanel-server-to-another/</link>
		<comments>http://www.supportsages.com/blog/2009/05/howto-move-horde-specific-settings-especially-calendar-address-box-notepad-settings-etc-when-moved-from-one-cpanel-server-to-another/#comments</comments>
		<pubDate>Sat, 16 May 2009 16:25:05 +0000</pubDate>
		<dc:creator>George</dc:creator>
				<category><![CDATA[Howtos]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[cPanel]]></category>
		<category><![CDATA[calendar]]></category>
		<category><![CDATA[horde]]></category>
		<category><![CDATA[horde sql settings transfer]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=355</guid>
		<description><![CDATA[How often you, as a sysadmin or LII support had this issue where a customer complains that his horde settings were not transferred from his old server to new one ? We had this issue many times.

Ben Thomas from cPanel has a script written for it, which I am sharing here. Weird fact is that you won't see this anywhere in a cPanel server, not even in /scripts folder. So why wait ? download the file below and help your customers next time, the easy way :)

<a href="http://www.supportsages.com/blog/wp-content/uploads/2009/05/horde_settings_transferpl.gz">http://www.supportsages.com/blog/wp-content/uploads/2009/05/horde_settings_transferpl.gz</a>

Usage is as below,

<code>./horde_sql_transfer.pl -u &#60;username&#62; -d &#60;data dir&#62; -o &#60;archive &#124; restore&#62;</code>]]></description>
			<content:encoded><![CDATA[<p>How often you, as a sysadmin or LII support had this issue where a customer complains that his horde settings were not transferred from his old server to new one ? We had this issue many times.</p>
<p>Ben Thomas from cPanel has a script written for it, which I am sharing here. Weird fact is that you won&#8217;t see this anywhere in a cPanel server, not even in /scripts folder. So why wait ? download the file below and help your customers next time, the easy way <img src='http://www.supportsages.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><a  href="http://www.supportsages.com/blog/wp-content/uploads/2009/05/horde_settings_transferpl.gz">http://www.supportsages.com/blog/wp-content/uploads/2009/05/horde_settings_transferpl.gz</a></p>
<p>Usage is as below,</p>
<p><code>./horde_sql_transfer.pl -u &lt;username&gt; -d &lt;data dir&gt; -o &lt;archive | restore&gt;</code></p>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=Howto+move+horde+specific+settings+especially+calendar%2C+address+box%2C+notepad+settings+etc+when+moved+from+one+cPanel+server+to+another+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F355" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=Howto+move+horde+specific+settings+especially+calendar%2C+address+box%2C+notepad+settings+etc+when+moved+from+one+cPanel+server+to+another+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F355" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2009/05/howto-move-horde-specific-settings-especially-calendar-address-box-notepad-settings-etc-when-moved-from-one-cpanel-server-to-another/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Virtfs dir for shell enabled user is not removed on termination of account or removal of shell</title>
		<link>http://www.supportsages.com/blog/2009/05/virtfs-dir-for-shell-enabled-user-is-not-removed-on-termination-of-account-or-removal-of-shell/</link>
		<comments>http://www.supportsages.com/blog/2009/05/virtfs-dir-for-shell-enabled-user-is-not-removed-on-termination-of-account-or-removal-of-shell/#comments</comments>
		<pubDate>Sat, 16 May 2009 15:59:30 +0000</pubDate>
		<dc:creator>George</dc:creator>
				<category><![CDATA[Howtos]]></category>
		<category><![CDATA[Snippets]]></category>
		<category><![CDATA[cPanel]]></category>
		<category><![CDATA[bash shell]]></category>
		<category><![CDATA[jailshell]]></category>
		<category><![CDATA[quota]]></category>
		<category><![CDATA[shell account]]></category>
		<category><![CDATA[termination of account]]></category>
		<category><![CDATA[virtfs]]></category>

		<guid isPermaLink="false">http://www.supportsages.com/blog/?p=353</guid>
		<description><![CDATA[Virtfs dir for a jailshell enabled user is not removed on termination of account or removal of shell from his account. This often happens when you enable jailshell only and not normal bash shell. This issue has been there, since I started with hosting industry since 2005 and there is only advice which I want to provide you all.

<strong>DON"T EVER DELETE /home/virtfs/user DIRECTORY</strong>

Here is one solution which worked for me around 80% of time, which forces the unmount of virtfs of the user. Command is below,

<code>cat /proc/mounts &#124; grep virtfs &#124; grep username &#124;cut -d ' ' -f2 &#124; xargs ...]]></description>
			<content:encoded><![CDATA[<p>Virtfs dir for a jailshell enabled user is not removed on termination of account or removal of shell from his account. This often happens when you enable jailshell only and not normal bash shell. This issue has been there, since I started with hosting industry since 2005 and there is only advice which I want to provide you all.</p>
<p><strong>DON&#8221;T EVER DELETE /home/virtfs/user DIRECTORY</strong></p>
<p>Here is one solution which worked for me around 80% of time, which forces the unmount of virtfs of the user. Command is below,</p>
<p><code>cat /proc/mounts | grep virtfs | grep username |cut -d ' ' -f2 | xargs umount </code></p>
<p>Good luck!!!</p>
<p align="left"><a  class="tt" href="http://twitter.com/home/?status=Virtfs+dir+for+shell+enabled+user+is+not+removed+on+termination+of+account+or+removal+of+shell+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F353" title="Post to Twitter"><img class="nothumb" src="http://www.supportsages.com/blog/wp-content/plugins/tweet-this/icons/tt-twitter.png" alt="Post to Twitter" /></a> <a  class="tt" href="http://twitter.com/home/?status=Virtfs+dir+for+shell+enabled+user+is+not+removed+on+termination+of+account+or+removal+of+shell+http%3A%2F%2Fwww.supportsages.com%2Fblog%2F353" title="Post to Twitter">Tweet This Post</a></p>]]></content:encoded>
			<wfw:commentRss>http://www.supportsages.com/blog/2009/05/virtfs-dir-for-shell-enabled-user-is-not-removed-on-termination-of-account-or-removal-of-shell/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
