<?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>x83.net &#187; ipcrm</title>
	<atom:link href="http://www.x83.net/tag/ipcrm/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.x83.net</link>
	<description></description>
	<lastBuildDate>Sat, 24 Jul 2010 09:50:05 +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>Fix Apache &#8211; No space left on device: Couldn&#8217;t create accept lock</title>
		<link>http://www.x83.net/fix-apache-no-space-left-on-device-couldnt-create-accept-lock/</link>
		<comments>http://www.x83.net/fix-apache-no-space-left-on-device-couldnt-create-accept-lock/#comments</comments>
		<pubDate>Tue, 23 Jun 2009 09:02:01 +0000</pubDate>
		<dc:creator>Giany</dc:creator>
				<category><![CDATA[Centos]]></category>
		<category><![CDATA[Debian]]></category>
		<category><![CDATA[Fedora]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Redhat]]></category>
		<category><![CDATA[Ubuntu]]></category>
		<category><![CDATA[awk]]></category>
		<category><![CDATA[http]]></category>
		<category><![CDATA[httpd.conf]]></category>
		<category><![CDATA[ipcrm]]></category>
		<category><![CDATA[ipcs]]></category>
		<category><![CDATA[kernel.sem]]></category>
		<category><![CDATA[perl]]></category>
		<category><![CDATA[reboot]]></category>
		<category><![CDATA[semaphores]]></category>
		<category><![CDATA[sslmutex]]></category>
		<category><![CDATA[sysctl]]></category>
		<category><![CDATA[xargs]]></category>

		<guid isPermaLink="false">http://www.x83.net/?p=276</guid>
		<description><![CDATA[This issue is related to semaphores. To view how many semaphores you have use:
root@hal [~]# sysctl -a &#124; egrep kernel.sem\&#124;kernel.msgmni
kernel.sem = 250        32000   32      128
kernel.msgmni = 16

You can change this values by adding them in /etc/sysctl.conf and then using sysctl -p [...]]]></description>
			<content:encoded><![CDATA[<p>This issue is related to semaphores. To view how many semaphores you have use:</p>
<blockquote><p>root@hal [~]# sysctl -a | egrep kernel.sem\|kernel.msgmni<br />
kernel.sem = 250        32000   32      128<br />
<strong>kernel.msgmni = 16</strong>
</p></blockquote>
<p>You can change this values by adding them in /etc/sysctl.conf and then using sysctl -p to activate them.<br />
There is no need to reboot.</p>
<p>To remove sempahores use either one of these commands:</p>
<blockquote><p>for i in `ipcs -s | grep nobody | awk &#8216;{print $2}&#8217;`; do ipcrm -s $i; done<br />
/scripts/restartsrv_httpd</p></blockquote>
<p><strong>or in Perl</strong></p>
<blockquote><p>ipcs -s | grep nobody | perl -e &#8216;while (<STDIN>) { @a=split(/\s+/); print `ipcrm sem $a[1]`}&#8217;</p></blockquote>
<p><strong>or with xargs</strong></p>
<blockquote><p>ipcs -s | grep nobody | awk &#8216; { print $2 } &#8216; | xargs ipcrm</p></blockquote>
<p><strong>or bash style</strong></p>
<blockquote><p>for ipsemId in $(ipcs -s | grep nobody | cut -f 2 -d &#8216; &#8216;); do ipcrm $ipsemId;done </p></blockquote>
<p>Other errors :</p>
<p><em>Cannot create SSLMutex</em></p>
<p>add in httpd.conf</p>
<p><em>SSLMutex sem</em></p>
]]></content:encoded>
			<wfw:commentRss>http://www.x83.net/fix-apache-no-space-left-on-device-couldnt-create-accept-lock/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Script to autorestart httpd server if it fails</title>
		<link>http://www.x83.net/script-to-autorestart-httpd-server-if-it-fails/</link>
		<comments>http://www.x83.net/script-to-autorestart-httpd-server-if-it-fails/#comments</comments>
		<pubDate>Thu, 18 Jun 2009 06:24:38 +0000</pubDate>
		<dc:creator>Giany</dc:creator>
				<category><![CDATA[Scripting]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[checkhttp.sh]]></category>
		<category><![CDATA[httpd]]></category>
		<category><![CDATA[ipcrm]]></category>
		<category><![CDATA[ipcs]]></category>
		<category><![CDATA[nobody]]></category>
		<category><![CDATA[restart]]></category>
		<category><![CDATA[restartsrv_httpd]]></category>
		<category><![CDATA[script]]></category>

		<guid isPermaLink="false">http://www.x83.net/?p=261</guid>
		<description><![CDATA[I use this script on a cpanel server..if output of pgrep command is 0 then the $restart command is issued
#!/bin/bash
restart=&#8221;/scripts/restartsrv_httpd&#8221;
pgrep httpd &#124;&#124; $restart
exit 0
If its a VPS then I might add to clear the Semaphore Arrays.
for i in `ipcs -s &#124; grep nobody &#124; awk &#8216;{print $2}&#8217;`; do ipcrm -s $i; done
Then I put this [...]]]></description>
			<content:encoded><![CDATA[<p>I use this script on a cpanel server..if output of pgrep command is 0 then the $restart command is issued</p>
<blockquote><p>#!/bin/bash<br />
restart=&#8221;/scripts/restartsrv_httpd&#8221;<br />
pgrep httpd || $restart<br />
exit 0</p></blockquote>
<p>If its a VPS then I might add to clear the Semaphore Arrays.</p>
<blockquote><p>for i in `ipcs -s | grep nobody | awk &#8216;{print $2}&#8217;`; do ipcrm -s $i; done</p></blockquote>
<p>Then I put this script into Cron to run every 5 minutes.</p>
<blockquote><p># MIN HOUR DAYOFMONTH MONTH DAYOFWEEK COMMAND<br />
*/5 * * * * /root/checkhttp.sh
</p></blockquote>
]]></content:encoded>
			<wfw:commentRss>http://www.x83.net/script-to-autorestart-httpd-server-if-it-fails/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
