<?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>cPanel Admins &#187; PHP</title>
	<atom:link href="http://www.cpaneladmins.com/category/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.cpaneladmins.com</link>
	<description>Random Notes for cPanel Admins</description>
	<lastBuildDate>Wed, 08 Sep 2010 10:15:24 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>How to Install ffmpeg</title>
		<link>http://www.cpaneladmins.com/2010/09/01/how-to-install-ffmpeg/</link>
		<comments>http://www.cpaneladmins.com/2010/09/01/how-to-install-ffmpeg/#comments</comments>
		<pubDate>Wed, 01 Sep 2010 22:03:10 +0000</pubDate>
		<dc:creator>tech</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[ffmpeg]]></category>
		<category><![CDATA[ffmpeg-php]]></category>
		<category><![CDATA[flv2tool]]></category>
		<category><![CDATA[flvtool]]></category>

		<guid isPermaLink="false">http://www.cpaneladmins.com/?p=395</guid>
		<description><![CDATA[This post will provide you with the instructions to download and install ffmpeg, ffmpeg-php, flvtool, lame, mplayer, libogg, libvorbis, mencoder, and other codecs used with ffmpeg. # cd /usr/local/src wget http://rubyforge.org/frs/download.php/17497/flvtool2-1.0.6.tgz wget http://downloads.sourceforge.net/project/lame/lame/3.98.4/lame-3.98.4.tar.gz wget http://www.mplayerhq.hu/MPlayer/releases/mplayer-export-snapshot.tar.bz2 wget http://downloads.sourceforge.net/project/ffmpeg-php/ffmpeg-php/0.6.0/ffmpeg-php-0.6.0.tbz2 wget http://downloads.xiph.org/releases/ogg/libogg-1.2.0.tar.gz wget http://downloads.xiph.org/releases/vorbis/libvorbis-1.3.1.tar.gz wget http://www.mplayerhq.hu/MPlayer/releases/codecs/essential-20071007.tar.bz2 wget http://ffmpeg.org/releases/ffmpeg-0.6.tar.gz tar xvzf flvtool2-1.0.6.tgz tar xvzf lame-3.98.4.tar.gz tar jxvf ffmpeg-php-0.6.0.tbz2 tar [...]]]></description>
			<content:encoded><![CDATA[<p>This post will provide you with the instructions to download and install ffmpeg, ffmpeg-php, flvtool, lame, mplayer, libogg, libvorbis, mencoder, and other codecs used with ffmpeg.</p>
<pre class="brush:bash"># cd /usr/local/src</pre>
<pre class="brush:bash">wget http://rubyforge.org/frs/download.php/17497/flvtool2-1.0.6.tgz
wget http://downloads.sourceforge.net/project/lame/lame/3.98.4/lame-3.98.4.tar.gz
wget http://www.mplayerhq.hu/MPlayer/releases/mplayer-export-snapshot.tar.bz2
wget http://downloads.sourceforge.net/project/ffmpeg-php/ffmpeg-php/0.6.0/ffmpeg-php-0.6.0.tbz2
wget http://downloads.xiph.org/releases/ogg/libogg-1.2.0.tar.gz
wget http://downloads.xiph.org/releases/vorbis/libvorbis-1.3.1.tar.gz
wget http://www.mplayerhq.hu/MPlayer/releases/codecs/essential-20071007.tar.bz2
wget http://ffmpeg.org/releases/ffmpeg-0.6.tar.gz</pre>
<pre class="brush:bash">tar xvzf flvtool2-1.0.6.tgz
tar xvzf lame-3.98.4.tar.gz
tar jxvf ffmpeg-php-0.6.0.tbz2
tar xvzf libogg-1.2.0.tar.gz
tar xvzf libvorbis-1.3.1.tar.gz
tar jxvf essential-20071007.tar.bz2
tar jxvf mplayer-export-snapshot.tar.bz2
tar xvzf ffmpeg-0.6.tar.gz </pre>
<p>Make a directory to store all the codecs:</p>
<pre class="brush:bash"># mkdir /usr/local/lib/codecs/</pre>
<p>Install any necessary packages:</p>
<pre class="brush:bash">yum install gcc gmake make libcpp libgcc libstdc++ gcc4 gcc4-c++  ncurses-devel</pre>
<p>Copy codecs for mplayer:</p>
<pre class="brush:bash">
mv /usr/local/src/essential-20071007/* /usr/local/lib/codecs/
chmod -R 755 /usr/local/lib/codecs/</pre>
<p>Installing Lame:</p>
<pre class="brush:bash">cd /usr/local/src/lame-3.98.4
./configure
make &#038;&#038; make install</pre>
<p>Installing Libogg:</p>
<pre class="brush:bash">
cd /usr/local/src/libogg*
./configure &#038;&#038; make &#038;&#038; make install
Installing libvorbis:</pre>
<pre class="brush:bash">cd /usr/local/src/libvorbis*
./configure &#038;&#038; make &#038;&#038; make install</pre>
<p>Installing flvtool2:</p>
<pre class="brush:bash">cd /usr/local/src/flvtool*
ruby setup.rb config
ruby setup.rb setup
ruby setup.rb install</pre>
<pre class="brush:bash"># cd /usr/local/src/mplayer*
./configure &#038;&#038; make &#038;&#038; make install</pre>
<p>Installing ffmpeg PHP module</p>
<pre class="brush:bash">cd /usr/local/src/ffmpeg-*
./configure --enable-libmp3lame --enable-libvorbis --disable-mmx --enable-shared</pre>
<p>(If you need to customize your install, run &#8220;./configure &#8211;help&#8221; to see a complete list of the available flags)</p>
<pre class="brush:bash">make &#038;&#038; make install</pre>
<pre class="brush:bash">ln -s /usr/local/lib/libavformat.so.50 /usr/lib/libavformat.so.50
ln -s /usr/local/lib/libavcodec.so.51 /usr/lib/libavcodec.so.51
ln -s /usr/local/lib/libavutil.so.49 /usr/lib/libavutil.so.49
ln -s /usr/local/lib/libmp3lame.so.0 /usr/lib/libmp3lame.so.0
ln -s /usr/local/lib/libavformat.so.51 /usr/lib/libavformat.so.51</pre>
<p>Installing ffmpeg-php:</p>
<pre class="brush:bash"># cd /usr/local/src/ffmpeg-php*
phpize
./configure</pre>
<p>There&#8217;s a small issue in this version of ffmpeg-php which, when &#8220;make&#8221; is run, will cause the following error:</p>
<pre class="brush:bash"> gcc -I. -I/usr/local/src/ffmpeg-php-0.6.0 -DPHP_ATOM_INC -I/usr/local/src/ffmpeg-php-0.6.0/include -I/usr/local/src/ffmpeg-php-0.6.0/main -I/usr/local/src/ffmpeg-php-0.6.0 -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/TSRM -I/usr/include/php/Zend -I/usr/include/php/ext -I/usr/include/php/ext/date/lib -I/usr/local/include/libavcodec/ -I/usr/local/include/libavformat/ -I/usr/local/include/libavutil/ -I/usr/local/include/libswscale/ -I/usr/local/include/libavfilter/ -I/usr/local/include/libavdevice/ -I/usr/include/php -DHAVE_CONFIG_H -g -O2 -Wall -fno-strict-aliasing -c /usr/local/src/ffmpeg-php-0.6.0/ffmpeg_frame.c  -fPIC -DPIC -o .libs/ffmpeg_frame.o
/usr/local/src/ffmpeg-php-0.6.0/ffmpeg_frame.c: In function 'zim_ffmpeg_frame_toGDImage':
/usr/local/src/ffmpeg-php-0.6.0/ffmpeg_frame.c:336: error: 'PIX_FMT_RGBA32' undeclared (first use in this function)
/usr/local/src/ffmpeg-php-0.6.0/ffmpeg_frame.c:336: error: (Each undeclared identifier is reported only once
/usr/local/src/ffmpeg-php-0.6.0/ffmpeg_frame.c:336: error: for each function it appears in.)
/usr/local/src/ffmpeg-php-0.6.0/ffmpeg_frame.c: In function 'zim_ffmpeg_frame_ffmpeg_frame':
/usr/local/src/ffmpeg-php-0.6.0/ffmpeg_frame.c:421: error: 'PIX_FMT_RGBA32' undeclared (first use in this function)
make: *** [ffmpeg_frame.lo] Error 1</pre>
<p>To correct this issue, we&#8217;ll update ffmpeg_frame.c and replace every instance of PIX_FMT_RGBA32 with PIX_FMT_RGB32</p>
<pre class="brush:bash">vi ffmpeg_frame.c</pre>
<pre class="brush:bash">:%s/PIX_FMT_RGBA32/PIX_FMT_RGB32

:w :q!</pre>
<p>Now we can proceed with compiling:</p>
<pre class="brush:bash">make
make install</pre>
<p>Now that we&#8217;ve compiled, let&#8217;s make sure that ffmpeg.so is in the proper extensions directory:</p>
<pre class="brush:bash">php -i | grep extensions
/usr/local/lib/php/extensions/no-debug-non-zts-20060613</pre>
<p>Now we&#8217;ll tell PHP that it needs to load our module:</p>
<pre class="brush:bash"> echo 'extension=ffmpeg.so' >> /usr/local/lib/php.ini</pre>
<p>Restart apache:</p>
<pre class="brush:bash">service httpd restart</pre>
<p>Now we&#8217;ll do a quick list of the modules to ensure that ffmpeg-php is loaded:</p>
<pre class="brush:bash">php -m | grep ffmpeg
ffmpeg</pre>
<p>All done!</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.cpaneladmins.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>]]></content:encoded>
			<wfw:commentRss>http://www.cpaneladmins.com/2010/09/01/how-to-install-ffmpeg/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>PHPInfo</title>
		<link>http://www.cpaneladmins.com/2010/04/22/phpinfo/</link>
		<comments>http://www.cpaneladmins.com/2010/04/22/phpinfo/#comments</comments>
		<pubDate>Thu, 22 Apr 2010 21:50:14 +0000</pubDate>
		<dc:creator>tech</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[phpinfo]]></category>

		<guid isPermaLink="false">http://www.cpaneladmins.com/?p=280</guid>
		<description><![CDATA[PHPInfo pages can be useful when needing to verify what php modules are installed/loading properly, or to see which php.ini a site is using. http://us3.php.net/phpinfo]]></description>
			<content:encoded><![CDATA[<p>PHPInfo pages can be useful when needing to verify what php modules are installed/loading properly, or to see which php.ini a site is using.</p>
<p><code><?php</p>
<p>// Show all information, defaults to INFO_ALL<br />
phpinfo();</p>
<p>// Show just the module information.<br />
// phpinfo(8) yields identical results.<br />
phpinfo(INFO_MODULES);</p>
<p>?></code></p>
<p>http://us3.php.net/phpinfo</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.cpaneladmins.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>]]></content:encoded>
			<wfw:commentRss>http://www.cpaneladmins.com/2010/04/22/phpinfo/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to Install EAccelerator, IonCube, Zend Optimizer, SourceGuardian, and SuHosin outside of EasyApache</title>
		<link>http://www.cpaneladmins.com/2010/04/10/how-to-install-eaccelerator-zend-optimizer-ioncube-on-cpanelr/</link>
		<comments>http://www.cpaneladmins.com/2010/04/10/how-to-install-eaccelerator-zend-optimizer-ioncube-on-cpanelr/#comments</comments>
		<pubDate>Sun, 11 Apr 2010 03:41:23 +0000</pubDate>
		<dc:creator>tech</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[EasyApache]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.cpaneladmins.com/?p=205</guid>
		<description><![CDATA[Many don&#8217;t know that you don&#8217;t need to run EasyApache to install EAccelerator, IonCube Loader, Zend Optimizer, SourceGuardian, or SuHosin. Why waste your time? You can use /scripts/phpextensionmgr to install or uninstall these modules! # /scripts/phpextensionmgr list Available Extensions: EAccelerator IonCubeLoader Zendopt SourceGuardian PHPSuHosin So, if you wanted to install Zend Optimizer, you&#8217;d run: # [...]]]></description>
			<content:encoded><![CDATA[<p>Many don&#8217;t know that you don&#8217;t need to run EasyApache to install EAccelerator, IonCube Loader, Zend Optimizer, SourceGuardian, or SuHosin.  Why waste your time? </p>
<p>You can use /scripts/phpextensionmgr to install or uninstall these modules!</p>
<p><code># /scripts/phpextensionmgr list<br />
Available Extensions:<br />
EAccelerator<br />
IonCubeLoader<br />
Zendopt<br />
SourceGuardian<br />
PHPSuHosin<br />
</code></p>
<p>So, if you wanted to install Zend Optimizer, you&#8217;d run:</p>
<p><code># /scripts/phpextensionmgr install Zendopt<br />
Installing Zendopt<br />
Determining PHP version<br />
Installing Zend Optimizer binary<br />
Activating Zend Optimizer in /usr/local/lib/php.ini<br />
Zend Optimizer activated<br />
Skipping install to /usr/local/php4, missing php.ini</code></p>
<p>Easy peasy. <img src='http://www.cpaneladmins.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.cpaneladmins.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>]]></content:encoded>
			<wfw:commentRss>http://www.cpaneladmins.com/2010/04/10/how-to-install-eaccelerator-zend-optimizer-ioncube-on-cpanelr/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Modifying your PHP Handler Configuration via SSH</title>
		<link>http://www.cpaneladmins.com/2010/04/10/modifying-your-php-handler-configuration-via-ssh/</link>
		<comments>http://www.cpaneladmins.com/2010/04/10/modifying-your-php-handler-configuration-via-ssh/#comments</comments>
		<pubDate>Sun, 11 Apr 2010 03:34:31 +0000</pubDate>
		<dc:creator>tech</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Command Line]]></category>
		<category><![CDATA[PHP]]></category>

		<guid isPermaLink="false">http://www.cpaneladmins.com/?p=200</guid>
		<description><![CDATA[Your PHP handler and SuExec configuration can be modified in WHM >> Apache Configuration >> PHP and SuExec Configuration, but if you&#8217;d like to make your change via SSH, you can use rebuild_phpconf. Note: with this utility, you can not add new handlers, or enable an alternate PHP version if it&#8217;s not installed. You&#8217;d need [...]]]></description>
			<content:encoded><![CDATA[<p>Your PHP handler and SuExec configuration can be modified in WHM >> Apache Configuration >> PHP and SuExec Configuration, but if you&#8217;d like to make your change via SSH, you can use rebuild_phpconf.  </p>
<p><strong>Note</strong>: with this utility, you can not add new handlers, or enable an alternate PHP version if it&#8217;s not installed.  You&#8217;d need to use EasyApache to enable that change.</p>
<p><strong>What&#8217;s my current configuration?<br />
</strong><code># /usr/local/cpanel/bin/rebuild_phpconf --current<br />
Available handlers: suphp dso cgi none<br />
DEFAULT PHP: 5<br />
PHP4 SAPI: none<br />
PHP5 SAPI: suphp<br />
SUEXEC: enabled</code></p>
<p><strong>Let&#8217;s say I wanted to switch to DSO, keeping PHP4 disabled, and SuExec enabled:</strong><br />
<code># /usr/local/cpanel/bin/rebuild_phpconf 5 none fcgi 1</code></p>
<p><strong>For reference, the usage details:</strong><br />
<code>Usage: /usr/local/cpanel/bin/rebuild_phpconf [--dryrun] [--no-restart] [--no-htaccess] [--current|--available] <Default PHP> <PHP4 Handler> <PHP5 Handler> <Suexec><br />
 --dryrun       : Only display the changes that would be made<br />
 --no-restart   : Don't restart Apache after updating the php.conf link<br />
 --no-htaccess  : Don't update user configurable PHP mime mapping.<br />
 --current      : Show current settings<br />
 --available    : Show available handlers and PHP SAPIs<br />
 <Default PHP>  : Version of PHP to set as default handler for .php files<br />
 <PHP# Handler> : Type of Apache module to use in serving PHP requests<br />
 <Suexec>       : enabled, disabled, 1 or 0<br />
</code></p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.cpaneladmins.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>]]></content:encoded>
			<wfw:commentRss>http://www.cpaneladmins.com/2010/04/10/modifying-your-php-handler-configuration-via-ssh/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Install SSH2 for PHP</title>
		<link>http://www.cpaneladmins.com/2009/10/16/install-ssh2-for-php/</link>
		<comments>http://www.cpaneladmins.com/2009/10/16/install-ssh2-for-php/#comments</comments>
		<pubDate>Fri, 16 Oct 2009 13:59:29 +0000</pubDate>
		<dc:creator>tech</dc:creator>
				<category><![CDATA[Command Line]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[SSH2]]></category>

		<guid isPermaLink="false">http://www.cpaneladmins.com/?p=80</guid>
		<description><![CDATA[wget http://downloads.sourceforge.net/project/libssh2/libssh2-1.2.1.tar.gz?use_mirror=softlayer tar -zxvf libssh2-0.12.tar.gz cd libssh2-0.12 ./configure &#038;&#038; make all install Run the pear installer for PECL/ssh2: pear install ssh2 If this installing via pear fails, wget http://pecl.php.net/get/ssh2-0.11.0.tgz tar -zxvf ssh2-0.11.tgz cd ssh2-0.11 phpize &#038;&#038; ./configure --with-ssh2 &#038;&#038; make Copy ssh2.so to /usr/local/lib/php/extensions/no-debug-non-zts-20020429. cp modules/ssh2.so /usr/local/lib/php/extensions/no-debug-non-zts-20020429 Add extension=ssh2.so to /usr/lib/php.ini Run service restart httpd [...]]]></description>
			<content:encoded><![CDATA[<pre lang=”LANGUAGE” line=”1″ file=”download.txt” colla=”+”>
wget http://downloads.sourceforge.net/project/libssh2/libssh2-1.2.1.tar.gz?use_mirror=softlayer
 tar -zxvf libssh2-0.12.tar.gz
 cd libssh2-0.12
./configure &#038;&#038; make all install
</pre>
<p>Run the pear installer for PECL/ssh2: </p>
<pre lang=”LANGUAGE” line=”1″ file=”download.txt” colla=”+”>
pear install ssh2
</pre>
<p>If this installing via pear fails,</p>
<pre lang=”LANGUAGE” line=”1″ file=”download.txt” colla=”+”>
wget http://pecl.php.net/get/ssh2-0.11.0.tgz
 tar -zxvf ssh2-0.11.tgz
 cd ssh2-0.11
 phpize &#038;&#038; ./configure --with-ssh2 &#038;&#038; make
</pre>
<p>Copy ssh2.so to /usr/local/lib/php/extensions/no-debug-non-zts-20020429.</p>
<pre lang=”LANGUAGE” line=”1″ file=”download.txt” colla=”+”>
 cp modules/ssh2.so /usr/local/lib/php/extensions/no-debug-non-zts-20020429
</pre>
<p>Add extension=ssh2.so to /usr/lib/php.ini<br />
Run service restart httpd to enable these changes.</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.cpaneladmins.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>]]></content:encoded>
			<wfw:commentRss>http://www.cpaneladmins.com/2009/10/16/install-ssh2-for-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Horde &#8211; Fatal error: Call to undefined method Registry::hasInterface() in /usr/local/cpanel/base/horde/config/prefs.php on line 134</title>
		<link>http://www.cpaneladmins.com/2009/09/28/horde-fatal-error-call-to-undefined-method-registryhasinterface-in-usrlocalcpanelbasehordeconfigprefs-php-on-line-134/</link>
		<comments>http://www.cpaneladmins.com/2009/09/28/horde-fatal-error-call-to-undefined-method-registryhasinterface-in-usrlocalcpanelbasehordeconfigprefs-php-on-line-134/#comments</comments>
		<pubDate>Mon, 28 Sep 2009 19:21:02 +0000</pubDate>
		<dc:creator>tech</dc:creator>
				<category><![CDATA[Horde]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Webmail]]></category>

		<guid isPermaLink="false">http://www.cpaneladmins.com/?p=68</guid>
		<description><![CDATA[Fatal error: Call to undefined method Registry::hasInterface() in /usr/local/cpanel/base/horde/config/prefs.php on line 134 If you are using the Turkish language in Horde, you may want to utilize English, if at all possible, due to a bug in PHP 5.2 which will not be resolved until PHP 6. http://bugs.php.net/bug.php?id=35050]]></description>
			<content:encoded><![CDATA[<p><code>Fatal error: Call to undefined method Registry::hasInterface() in<br />
/usr/local/cpanel/base/horde/config/prefs.php on line 134<br />
</code></p>
<p>If you are using the Turkish language in Horde, you may want to utilize English, if at all possible, due to a bug in PHP 5.2 which will not be resolved until PHP 6.</p>
<p>http://bugs.php.net/bug.php?id=35050</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.cpaneladmins.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>]]></content:encoded>
			<wfw:commentRss>http://www.cpaneladmins.com/2009/09/28/horde-fatal-error-call-to-undefined-method-registryhasinterface-in-usrlocalcpanelbasehordeconfigprefs-php-on-line-134/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Roundcube hangs when sending mail</title>
		<link>http://www.cpaneladmins.com/2009/09/27/roundcube-hangs-when-sending-mail/</link>
		<comments>http://www.cpaneladmins.com/2009/09/27/roundcube-hangs-when-sending-mail/#comments</comments>
		<pubDate>Sun, 27 Sep 2009 16:38:29 +0000</pubDate>
		<dc:creator>tech</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Roundcube]]></category>
		<category><![CDATA[Webmail]]></category>
		<category><![CDATA[net-smtp]]></category>

		<guid isPermaLink="false">http://www.cpaneladmins.com/?p=61</guid>
		<description><![CDATA[In recent builds of roundcube, you may find that you can&#8217;t send mail using Roundcube. If /var/cpanel/roundcube/log/errors shows the following: [30-Jan-2009 14:07:11] Invalid response code received from server (421): [30-Jan-2009 14:07:11] Invalid response code received from server (-1): [30-Jan-2009 14:07:34 -0800] SMTP Error: SMTP error: Authentication failure: STARTTLS failed (Code: ) in /usr/local/cpanel/base/3rdparty/roundcube/program/steps/mail/func.inc on line [...]]]></description>
			<content:encoded><![CDATA[<p>In recent builds of roundcube, you may find that you can&#8217;t send mail using Roundcube.  If /var/cpanel/roundcube/log/errors shows the following:</p>
<p><code><br />
[30-Jan-2009 14:07:11] Invalid response code received from server (421):<br />
[30-Jan-2009 14:07:11] Invalid response code received from server (-1):<br />
[30-Jan-2009 14:07:34 -0800] SMTP Error: SMTP error: Authentication failure: STARTTLS failed (Code: ) in /usr/local/cpanel/base/3rdparty/roundcube/program/steps/mail/func.inc on line 1248 (POST /3rdparty/roundcube/index.php?_task=mail&#038;_action=send)<br />
[30-Jan-2009 14:10:29] STARTTLS failed ():<br />
</code></p>
<p>Then there is an issue with the most recent Net-SMTP PHP module.  To resolve this, edit the following file:</p>
<p><code><br />
/usr/local/cpanel/base/3rdparty/roundcube/config/main.inc.php</code></p>
<p>and change </p>
<p><code>// SMTP username (if required) if you use %u as the username RoundCube<br />
// will use the current username for login<br />
$rcmail_config['smtp_user'] = '%u';</code></p>
<p>to this:</p>
<p><code><br />
// SMTP username (if required) if you use %u as the username RoundCube<br />
// will use the current username for login<br />
$rcmail_config['smtp_user'] = '';</code></p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.cpaneladmins.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>]]></content:encoded>
			<wfw:commentRss>http://www.cpaneladmins.com/2009/09/27/roundcube-hangs-when-sending-mail/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>suphp 500 error, Premature end of script headers</title>
		<link>http://www.cpaneladmins.com/2009/09/26/suphp-500-error-premature-end-of-script-headers/</link>
		<comments>http://www.cpaneladmins.com/2009/09/26/suphp-500-error-premature-end-of-script-headers/#comments</comments>
		<pubDate>Sat, 26 Sep 2009 15:07:32 +0000</pubDate>
		<dc:creator>tech</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[suphp]]></category>
		<category><![CDATA[VPS]]></category>

		<guid isPermaLink="false">http://www.cpaneladmins.com/?p=49</guid>
		<description><![CDATA[[Sat Sep 26 22:02:33 2008] [error] [client 111.222.333.444] Premature end of script headers: phpinfo.php [Sat Sep 26 22:02:33 2008] [error] [client 111.222.333.444] File does not exist: /home/username/public_html/500.shtml First step: ensure that you&#8217;re using proper permissions on your files for suphp. Your php files should have 644 permissions, and ownership of the user whose home folder [...]]]></description>
			<content:encoded><![CDATA[<p><code><br />
[Sat Sep 26 22:02:33 2008] [error] [client 111.222.333.444] Premature end of script headers: phpinfo.php<br />
[Sat Sep 26 22:02:33 2008] [error] [client 111.222.333.444] File does not exist: /home/username/public_html/500.shtml<br />
</code></p>
<p>First step: ensure that you&#8217;re using proper permissions on your files for suphp.  Your php files should have 644 permissions, and ownership of the user whose home folder the files are in.</p>
<p>If ownership and permissions are correct, it could be a memory issue.  I&#8217;ve found that some users who experience this error are running out of available memory for php to execute properly. You can try switching your PHP handler to cgi or fcgi, which will actually display an &#8220;out of memory&#8221; error in apache&#8217;s error_log, but suphp will not.</p>
<p><code><br />
[Sat Sep 26 08:48:02 2009] [error] [client 111.222.333.444] Premature end of<br />
script headers: php5<br />
[Sat Sep 26 08:48:02 2009] [error] [client 111.222.333.444] File does not exist:<br />
/home/username/public_html/500.shtml<br />
[Sat Sep 26 08:48:02 2009] [error] [client 111.222.333.444] Out of memory<br />
</code></p>
<p>If you do have available RAM, but PHP isn&#8217;t able to use it, try increasing the RLimit value in httpd.conf and see if your script will execute then.  If you look at &#8220;free&#8221; and you don&#8217;t have much free memory, you may need to upgrade your server or VPS.</p>
<p><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save"><img src="http://www.cpaneladmins.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share/Bookmark"/></a> </p>]]></content:encoded>
			<wfw:commentRss>http://www.cpaneladmins.com/2009/09/26/suphp-500-error-premature-end-of-script-headers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
