<?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>System Network Programming Solution - Linux - windows - centos- security- cpanel - plesk -directadmin helm&#187; Apache</title>
	<atom:link href="http://thegioinguonmo.com/tag/apache/feed/" rel="self" type="application/rss+xml" />
	<link>http://thegioinguonmo.com</link>
	<description>SHARING EVERYTHING</description>
	<lastBuildDate>Mon, 06 Feb 2012 09:45:09 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<item>
		<title>Cannot start Web server from Plesk panel, No such file ‘/usr/local/etc/rc.d/apache2.sh’ error appears</title>
		<link>http://thegioinguonmo.com/hosting-controller/plesk-control-panel/start-web-server-plesk-panel-file-usrlocaletcrcdapache2sh-error-appears.html</link>
		<comments>http://thegioinguonmo.com/hosting-controller/plesk-control-panel/start-web-server-plesk-panel-file-usrlocaletcrcdapache2sh-error-appears.html#comments</comments>
		<pubDate>Sat, 28 Jan 2012 00:53:39 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Plesk]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[plesk]]></category>
		<category><![CDATA[plesk control panel]]></category>
		<category><![CDATA[psa]]></category>
		<category><![CDATA[web server]]></category>

		<guid isPermaLink="false">http://thegioinguonmo.com/?p=2272</guid>
		<description><![CDATA[Attempts to start or stop apache web service on Server &#62; Services page fail with error ERROR: PleskFatalException Unable to make action: Unable to manage service by websrvmng: websrvmng: No such file ‘/usr/local/etc/rc.d/apache2.sh’: No such file or directory System error 2: No such file or directory &#160; Apache startup script name is specified with the [...]]]></description>
			<content:encoded><![CDATA[<p>Attempts to start or stop apache web service on Server &gt; Services page fail with error</p>
<p><span style="color: #ff0000;">ERROR</span>: PleskFatalException<br />
Unable to make action: Unable to manage service by websrvmng:<br />
websrvmng: No such file ‘/usr/local/etc/rc.d/apache2.sh’:<br />
No such file or directory System error 2: No such file or directory</p>
<p>&nbsp;</p>
<p>Apache startup script name is specified with the following variable in /etc/psa/psa.conf file:</p>
<pre class="brush:plain">#apache startup script
HTTPD_SERVICE apache2</pre>
<p>Find out what the actual apache startup script file name is, it may be either apache2 or apache2.sh:</p>
<pre class="brush:plain"># ls /usr/local/etc/rc.d/apache2*
/usr/local/etc/rc.d/apache2</pre>
<p>then set the correct value in /etc/psa/psa.conf for HTTPD_SERVICE variable.</p>
<h4>Incoming search terms:</h4><ul><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/start-web-server-plesk-panel-file-usrlocaletcrcdapache2sh-error-appears.html" title="ERROR: PleskFatalException StatInfo-&gt;getProductVersion failed: Plesk version file doesnt exist or empty debian">ERROR: PleskFatalException StatInfo-&gt;getProductVersion failed: Plesk version file doesnt exist or empty debian</a> (2)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/start-web-server-plesk-panel-file-usrlocaletcrcdapache2sh-error-appears.html" title="websrvmng: service /usr/local/etc/rc d/apache2 failed to restart">websrvmng: service /usr/local/etc/rc d/apache2 failed to restart</a> (2)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/start-web-server-plesk-panel-file-usrlocaletcrcdapache2sh-error-appears.html" title="councurrent execution flvtool2 windows">councurrent execution flvtool2 windows</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/start-web-server-plesk-panel-file-usrlocaletcrcdapache2sh-error-appears.html" title="plesk apache-config t failed">plesk apache-config t failed</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/start-web-server-plesk-panel-file-usrlocaletcrcdapache2sh-error-appears.html" title="pleskfatalexception: /usr/local/psa/admin/bin/apache-config -t failed with code 1">pleskfatalexception: /usr/local/psa/admin/bin/apache-config -t failed with code 1</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/start-web-server-plesk-panel-file-usrlocaletcrcdapache2sh-error-appears.html" title="unable to exec utility packagemng: file does not exist or is not executable: /usr/local/psa/admin/bin/packagemng">unable to exec utility packagemng: file does not exist or is not executable: /usr/local/psa/admin/bin/packagemng</a> (1)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://thegioinguonmo.com/hosting-controller/plesk-control-panel/start-web-server-plesk-panel-file-usrlocaletcrcdapache2sh-error-appears.html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>What is .htaccess and how to disable .htaccess?</title>
		<link>http://thegioinguonmo.com/os/linux/what-is-htaccess-and-how-to-disable-htaccess.html</link>
		<comments>http://thegioinguonmo.com/os/linux/what-is-htaccess-and-how-to-disable-htaccess.html#comments</comments>
		<pubDate>Fri, 27 Jan 2012 21:42:35 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[error]]></category>
		<category><![CDATA[service]]></category>
		<category><![CDATA[use]]></category>
		<category><![CDATA[way]]></category>
		<category><![CDATA[website]]></category>

		<guid isPermaLink="false">http://thegioinguonmo.com/?p=1043</guid>
		<description><![CDATA[What is .htaccess and how to disable .htaccess? .htaccess is use to modify the way Apache behaves for a directory and it’s sub-directories. It gives you an extra control on your server, like setting up custom error messages, password protect a directory, writing rewrite rules, blocking IPs etc. However, it can be a potentially dangerous [...]]]></description>
			<content:encoded><![CDATA[<blockquote><p><strong>What is .htaccess and how to disable .htaccess?</strong></p></blockquote>
<p><strong>.htaccess is use to modify the way Apache behaves for a directory and it’s sub-directories.</strong> It gives you an extra control on your server, like setting up custom error messages, password protect a directory, writing rewrite rules, blocking IPs etc.</p>
<p>However, it can be a potentially dangerous file. For example, a hacker can redirect your website to an external website say a malware website.</p>
<p><strong>In order to disable .htaccess server wide</strong>, edit the Apache configuration file</p>
<blockquote><p><strong>pico /etc/httpd/conf/httpd.conf</strong></p></blockquote>
<p><strong>Search for</strong></p>
<pre class="brush:plain">    AllowOverride All

replace it with

    AllowOverride None</pre>
<p>Save the file and restart the Apache service.</p>
<blockquote><p><strong>service httpd restart</strong></p></blockquote>
<h4>Incoming search terms:</h4><ul><li><a href="http://thegioinguonmo.com/os/linux/what-is-htaccess-and-how-to-disable-htaccess.html" title="disable htaccess plesk">disable htaccess plesk</a> (1)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://thegioinguonmo.com/os/linux/what-is-htaccess-and-how-to-disable-htaccess.html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PHP pages asking for download</title>
		<link>http://thegioinguonmo.com/os/linux/php-pages-asking-for-download.html</link>
		<comments>http://thegioinguonmo.com/os/linux/php-pages-asking-for-download.html#comments</comments>
		<pubDate>Wed, 25 Jan 2012 21:46:57 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[download]]></category>
		<category><![CDATA[file]]></category>
		<category><![CDATA[htaccess file]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[php files]]></category>

		<guid isPermaLink="false">http://thegioinguonmo.com/?p=1004</guid>
		<description><![CDATA[If your .php files are prompting for download on browsing, make sure PHP is compiled with Apache and you have following lines in your Apache configuration file AddHandler application/x-httpd-php .php .html You can also add the above line in your .htaccess file of the domain. Incoming search terms:php file is asking to download (1)]]></description>
			<content:encoded><![CDATA[<p>If your <strong>.php files are prompting for download</strong> on browsing, make sure PHP is compiled with Apache and you have following lines in your Apache configuration file</p>
<blockquote><p><strong>AddHandler application/x-httpd-php .php .html</strong></p></blockquote>
<p>You can also add the above line in your <strong>.htaccess file</strong> of the domain.</p>
<h4>Incoming search terms:</h4><ul><li><a href="http://thegioinguonmo.com/os/linux/php-pages-asking-for-download.html" title="php file is asking to download">php file is asking to download</a> (1)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://thegioinguonmo.com/os/linux/php-pages-asking-for-download.html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Accessing Plesk directories outside httpdocs / php open_basedir error</title>
		<link>http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html</link>
		<comments>http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html#comments</comments>
		<pubDate>Fri, 20 Jan 2012 10:34:47 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Plesk]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[open_basedir]]></category>
		<category><![CDATA[plesk]]></category>
		<category><![CDATA[plesk control panel]]></category>

		<guid isPermaLink="false">http://thegioinguonmo.com/?p=2238</guid>
		<description><![CDATA[PHP open_basedir errors occur when a script tries to access a directory outside of httpdocs. For security reasons Plesk only allows access to the httpdocs and tmp directories. So what if you need to access a different directory? The easiest way is to amend the vhost.conf file of the specific domain. Open the vhost.conf file [...]]]></description>
			<content:encoded><![CDATA[<p>PHP open_basedir errors occur when a script tries to access a directory outside of httpdocs. For security reasons Plesk only allows access to the httpdocs and tmp directories.</p>
<p>So what if you need to access a different directory?</p>
<p>The easiest way is to amend the vhost.conf file of the<br />
specific domain.</p>
<p>Open the vhost.conf file if it exists. If not&#8230;create it. The vhost.conf file is found under /PATH-TO-DOMAIN/YourDomain.tld/conf/vhost.conf</p>
<p>Add these lines:-</p>
<pre class="brush:shell">&lt;Directory /PATH-TO-DOMAIN/YourDomain.tld/httpdocs&gt;
php_admin_value open_basedir /PATH-TO-DOMAIN/YourDomain.tld/httpdocs:/tmp:/ADD-YOUR-DIR:/
&lt;/Directory&gt;</pre>
<p>Save the vhost.conf file and run this command to load the changes into Apache</p>
<pre class="brush:shell">/usr/local/psa/admin/sbin/websrvmng -a -v</pre>
<p>Restart Apache&#8230;.your finished</p>
<h4>Incoming search terms:</h4><ul><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html" title="centos php open_basedir error">centos php open_basedir error</a> (3)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html" title="access htdocs folder outside plesk panel">access htdocs folder outside plesk panel</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html" title="plesk open_basedir update">plesk open_basedir update</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html" title="plesk module open_basedir">plesk module open_basedir</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html" title="plesk ftp outside httpdocs">plesk ftp outside httpdocs</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html" title="plesk files outside of httpdocs">plesk files outside of httpdocs</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html" title="open_basedir how to linux">open_basedir how to linux</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html" title="how to find httpdocs in plesk">how to find httpdocs in plesk</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html" title="folders outside httpdocs in cpanel">folders outside httpdocs in cpanel</a> (1)</li><li><a href="http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html" title="centos find directory outside httpdocs">centos find directory outside httpdocs</a> (1)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://thegioinguonmo.com/hosting-controller/plesk-control-panel/accessing-plesk-directories-httpdocs-php-openbasedir-error.html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Network UPS Tools (NUT) For USB UPSs On CentOS 5.5</title>
		<link>http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html</link>
		<comments>http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html#comments</comments>
		<pubDate>Fri, 20 Jan 2012 10:09:21 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[cgi]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[nut]]></category>
		<category><![CDATA[ups tool]]></category>

		<guid isPermaLink="false">http://thegioinguonmo.com/?p=2222</guid>
		<description><![CDATA[This tutorial shows how to configure and use Network UPS Tools (NUT) software with an USB (Uninterruptible Power Supply) on CentOS 5.5. NUT is a software which supports several thousand models. To check if your UPS is supported, this is the link to the HCL: http://www.networkupstools.org/stable-hcl.html Install NUT dependencies: yum install net-snmp-libs gd httpd Download [...]]]></description>
			<content:encoded><![CDATA[<p>This tutorial shows how to configure and use Network UPS Tools (NUT) software with an USB (Uninterruptible Power Supply) on CentOS 5.5. NUT is a software which supports several thousand models. To check if your UPS is supported, this is the link to the HCL: <a rel="nofollow" target="_blank" href="http://www.networkupstools.org/stable-hcl.html" target="_blank">http://www.networkupstools.org/stable-hcl.html</a></p>
<p>Install NUT dependencies:</p>
<p>yum install net-snmp-libs gd httpd</p>
<p>Download the latest CentOS NUT rpm release for your architecture from: <a rel="nofollow" target="_blank" href="http://geekery.blog.com/category/linux/nut-ups-rpms/" target="_blank">http://geekery.blog.com/category/linux/nut-ups-rpms/</a></p>
<p>NOTE: you can also download NUT from EPEL repository or the tarball directly from the NUT official site (http://www.networkupstools.org/)</p>
<p>Install downloaded rpms:</p>
<p>rpm -Uvh nut-2.6.0-2geekery.$(uname -i).rpm nut-cgi-2.6.0-2geekery.$(uname -i).rpm nut-client-2.6.0-2geekery.$(uname -i).rpm powerman-2.3.5-2geekery.$(uname -i).rpm</p>
<p>&nbsp;</p>
<h3>Common Configuration</h3>
<p>This is the configuration for my Eaton Powerware 5115 USB UPS. Edit the driver controller configuration file, choosing the correct driver for your UPS. You can read on the HCL which is the right driver to use. My UPS it isn&#8217;t officially supported, but I found that the bcmxcp_usb driver works well, so I defined a new UPS section that begins with the name of the UPS in brackets (in my case: 5115), followed by the driver (bcmxcp_usb) and the port device (with USB UPSs choose automatic port detection).</p>
<p>vi /etc/ups/ups.conf</p>
<pre>[5115]
        driver = bcmxcp_usb
        port = auto</pre>
<p>Now choose your NUT running mode: I chose standalone mode because the UPS is power supplying only one server, but you can also use NUT in network client/server mode.</p>
<p>vi /etc/ups/nut.conf</p>
<pre>MODE = standalone</pre>
<p>Configure the IP address and port where upsd daemon listens for. The upsd.conf file control access to the server and some other parameters. In a standalone installation you can leave it at default configuration, listening to localhost.</p>
<p>vi /etc/ups/upsd.conf</p>
<pre>LISTEN 127.0.0.1 3493</pre>
<p>Now define a upsmon user/password in upsd.users file. The user I define is &#8220;local_mon&#8221; with password &#8220;PASSWORD&#8221; and upsmon role &#8220;master&#8221;. We will use this user with the upsmon component of NUT.</p>
<p>vi /etc/ups/upsd.users</p>
<pre>[local_mon]
    password = PASSWORD
    upsmon master</pre>
<p>Upsmon is the UPS monitor and shutdown controller that will monitor and tell how to shut down the system when necessary. Edit the MONITOR directive inserting the UPS name defined in ups.conf, followed by the IP address or hostname configured in upsd.conf and by the credentials and upsmon role defined in upsd.users. Leave the other directives to the default values specified.</p>
<p>vi /etc/ups/upsmon.conf</p>
<pre>MONITOR 5115@localhost 1 local_mon PASSWORD master
MINSUPPLIES 1
SHUTDOWNCMD "/sbin/shutdown -h +0"
POLLFREQ 5
POLLFREQALERT 5
HOSTSYNC 15
DEADTIME 15
POWERDOWNFLAG /etc/killpower
RBWARNTIME 43200
NOCOMMWARNTIME 300
FINALDELAY 5</pre>
<p>&nbsp;</p>
<h3>USB Configuration</h3>
<p>If you you installed a NUT rpm release from <a rel="nofollow" target="_blank" href="http://geekery.blog.com/category/linux/nut-ups-rpms/" target="_blank">http://geekery.blog.com/category/linux/nut-ups-rpms/</a> you can find a nut udev rule file for CentOS at this path: /lib/udev/rules.d/62-nut-usbups.rules</p>
<p>If you are installing a USB UPS, softlink this file in udev rules directory:</p>
<p>ln -s /lib/udev/rules.d/62-nut-usbups.rules /etc/udev/rules.d/62-nut-usbups.rules</p>
<p>and reload udev rules and trigger device detection with these commands:</p>
<p>udevcontrol reload_rules</p>
<p>udevtrigger</p>
<h3>UPS Web Monitoring (nut-cgi)</h3>
<div></div>
<p>Configure this file to let CGI programs access the UPS info:</p>
<p>vi /etc/ups/hosts.conf</p>
<pre>MONITOR 5115@localhost 1 local_mon PASSWORD master</pre>
<p>Create a Apache config file for the cgi installed with the nut-cgi package:</p>
<p>vi /etc/httpd/conf.d/ups-cgi.conf</p>
<pre>ScriptAlias /nut-cgi-bin/ "/var/www/nut-cgi-bin/"
&lt;Directory "/var/www/nut-cgi-bin"&gt;
    AllowOverride None
    Options None
    Order allow,deny
    Allow from all
&lt;/Directory&gt;</pre>
<p>&nbsp;</p>
<h3>Start UPS Daemon</h3>
<p>Now you can try to start your NUT installation with this command:</p>
<p>/etc/init.d/ups start</p>
<p>If the start process is OK, check ups info with this command (use your ups.conf ups name instead of 5115):</p>
<p>upsc 5115</p>
<p>You can also check which instant command are supported by your UPS with this command:</p>
<p>upscmd -l 5115@localhost</p>
<pre>Instant commands supported on UPS [5115]:
shutdown.return - Turn off the load and return when power is back
shutdown.stayoff - Turn off the load and remain off
test.battery.start - Start a battery test</pre>
<p>You can start a battery test (if supported) with this command:</p>
<p>upscmd -u local_mon -p PASSWORD 5115 test.battery.start</p>
<p>You can also check the web monitoring page with a web browser: http://&lt;upshost&gt;/nut-cgi-bin/upsstats.cgi</p>
<p>&nbsp;</p>
<h3>Troubleshooting For Common USB Problems</h3>
<p>If nut has problems to start check logs:</p>
<p>cat /var/log/messages</p>
<p>Many problems with USB UPSs are related to udev and device rights permission.</p>
<p>1) If you see these messages in /var/log/messages</p>
<pre>udevd[513]: add_to_rules: unknown key 'ATTR{idProduct}'
udevd[513]: add_to_rules: unknown key 'ATTR{idVendor}'
udevd[513]: add_to_rules: unknown key 'ATTR{idProduct}'
udevd[513]: add_to_rules: unknown key 'SUBSYSTEMS'</pre>
<p>You have a udev rule file that uses directives newer than the udev program version you have.</p>
<p>On CentOS 5.5 try to substitute &#8220;ATTR&#8221; with &#8220;SYSFS&#8221; and &#8220;SUBSYSTEMS&#8221; with &#8220;BUS&#8221;.</p>
<p>In the &#8220;ACTION&#8221; directive use only &#8220;add&#8221; not &#8220;change&#8221;:</p>
<pre>	OK:	ACTION!="add", GOTO="nut-usbups_rules_end"
	ERROR:	ACTION!="add|change", GOTO="nut-usbups_rules_end"</pre>
<p>2) Check usb device right permissions: Run the lsusb command:</p>
<p>lsusb</p>
<pre>Bus 002 Device 001: ID 0000:0000
Bus 001 Device 001: ID 0000:0000
Bus 003 Device 005: ID 06da:0002 Phoenixtec Power Co., Ltd UPS
Bus 003 Device 001: ID 0000:0000
Bus 004 Device 001: ID 0000:0000
Bus 005 Device 001: ID 0000:0000
Bus 006 Device 001: ID 0000:0000
Bus 007 Device 001: ID 0000:0000</pre>
<p>You can see from the preceding output that my usb ups is connected to the usb bus 3 device 5 and has this VendorID=06da and ProductID=0002</p>
<p>Grep VendorID and ProductID from nut udev rule file to see if your ups has already a rule to manage it:</p>
<p>grep &#8220;06da&#8221; /etc/udev/rules.d/62-nut-usbups.rules | grep 0002</p>
<pre>SYSFS{idVendor}=="06da", SYSFS{idProduct}=="0002", MODE="664", GROUP="uucp"</pre>
<p>I found that a rule is already present in the udev rule file: it sets file mode 664 and group ownership to uucp group to the usb device linked to the ups.</p>
<p>If a rule is not present for your device, copy the one above and changing VendorID and ProductID with those you found with lsusb command.</p>
<p>Check that device permissions are set like udev rule specify:</p>
<p>ls -l /dev/bus/usb/003/005</p>
<p>crw-rw-r&#8211; 1 root uucp 189, 260 Mar 23 23:06 /dev/bus/usb/003/005</p>
<h4>Incoming search terms:</h4><ul><li><a href="http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html" title="eaton ups 06da-l">eaton ups 06da-l</a> (3)</li><li><a href="http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html" title="client nut ups">client nut ups</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html" title="eaton 5115 ups linux management">eaton 5115 ups linux management</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html" title="how to ups linux">how to ups linux</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html" title="linux ups">linux ups</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html" title="network ups tools">network ups tools</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html" title="network ups tools windows configuration">network ups tools windows configuration</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html" title="nut windows multiple usb">nut windows multiple usb</a> (1)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://thegioinguonmo.com/os/linux/network-ups-tools-nut-usb-upss-centos-55.html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Set Up WebDAV With Apache2 On CentOS 5.5</title>
		<link>http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html</link>
		<comments>http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html#comments</comments>
		<pubDate>Fri, 20 Jan 2012 10:02:13 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Mysql]]></category>
		<category><![CDATA[webdav]]></category>

		<guid isPermaLink="false">http://thegioinguonmo.com/?p=2212</guid>
		<description><![CDATA[This guide explains how to set up WebDAV with Apache2 on a CentOS 5.5 server. WebDAV stands for Web-based Distributed Authoring and Versioning and is a set of extensions to the HTTP protocol that allow users to directly edit files on the Apache server so that they do not need to be downloaded/uploaded via FTP. [...]]]></description>
			<content:encoded><![CDATA[<p>This guide explains how to set up WebDAV with Apache2 on a CentOS 5.5 server. WebDAV stands for <em>Web-based Distributed Authoring and Versioning</em> and is a set of extensions to the HTTP protocol that allow users to directly edit files on the Apache server so that they do not need to be downloaded/uploaded via FTP. Of course, WebDAV can also be used to upload and download files.</p>
<p>I do not issue any guarantee that this will work for you!</p>
<p>&nbsp;</p>
<h3>1 Preliminary Note</h3>
<p>I&#8217;m using a CentOS 5.5 server with the IP address 192.168.0.100 here.</p>
<p>&nbsp;</p>
<h3>2 Installing WebDAV</h3>
<p>If Apache is not already installed, install it as follows:</p>
<p>yum install httpd</p>
<p>Afterwards, open /etc/httpd/conf/httpd.conf and make sure that the dav and dav_fs modules are enabled in the LoadModule section (they should be enabled by default):</p>
<p>vi /etc/httpd/conf/httpd.conf</p>
<table width="90%" border="1" cellspacing="0" cellpadding="2" align="center" bgcolor="#cccccc">
<tbody>
<tr>
<td>
<pre>[...]
LoadModule dav_module modules/mod_dav.so
[...]
LoadModule dav_fs_module modules/mod_dav_fs.so
[...]</pre>
</td>
</tr>
</tbody>
</table>
<p>Then create the system startup links for Apache and start it:</p>
<p>chkconfig &#8211;levels 235 httpd on<br />
/etc/init.d/httpd start</p>
<p>&nbsp;</p>
<h3>3 Creating A Virtual Host</h3>
<p>I will now create a default Apache vhost in the directory /var/www/web1/web. For this purpose, I will add a default vhost at the end of /etc/httpd/conf/httpd.conf. If you already have a vhost for which you&#8217;d like to enable WebDAV, you must adjust this tutorial to your situation.</p>
<p>First, we create the directory /var/www/web1/web and make the Apache user and group (apache) the owner of that directory:</p>
<p>mkdir -p /var/www/web1/web<br />
chown apache:apache /var/www/web1/web</p>
<p>Then add the new vhost at the end of /etc/httpd/conf/httpd.conf:</p>
<p>vi /etc/httpd/conf/httpd.conf</p>
<table width="90%" border="1" cellspacing="0" cellpadding="2" align="center" bgcolor="#cccccc">
<tbody>
<tr>
<td>
<pre>[...]
NameVirtualHost *:80
&lt;VirtualHost *:80&gt;
        ServerAdmin webmaster@localhost

        DocumentRoot /var/www/web1/web/
        &lt;Directory /var/www/web1/web/&gt;
                Options Indexes MultiViews
                AllowOverride None
                Order allow,deny
                allow from all
        &lt;/Directory&gt;

&lt;/VirtualHost&gt;</pre>
</td>
</tr>
</tbody>
</table>
<p>Then reload Apache:</p>
<p>/etc/init.d/httpd reload</p>
<p>&nbsp;</p>
<h3>4 Configure The Virtual Host For WebDAV</h3>
<p>Now we create the WebDAV password file /var/www/web1/passwd.dav with the user test (the -c switch creates the file if it does not exist):</p>
<p>htpasswd -c /var/www/web1/passwd.dav test</p>
<p>You will be asked to type in a password for the user test.</p>
<p>(Please don&#8217;t use the -c switch if /var/www/web1/passwd.dav is already existing because this will recreate the file from scratch, meaning you lose all users in that file!)</p>
<p>Now we change the permissions of the /var/www/web1/passwd.dav file so that only root and the members of the apache group can access it:</p>
<p>chown root:apache /var/www/web1/passwd.dav<br />
chmod 640 /var/www/web1/passwd.dav</p>
<p>Now we modify our vhost at the end of /etc/httpd/conf/httpd.conf and add the following lines to it:</p>
<p>vi /etc/httpd/conf/httpd.conf</p>
<table width="90%" border="1" cellspacing="0" cellpadding="2" align="center" bgcolor="#cccccc">
<tbody>
<tr>
<td>
<pre>[...]
        Alias /webdav /var/www/web1/web

        &lt;Location /webdav&gt;
           DAV On
           AuthType Basic
           AuthName "webdav"
           AuthUserFile /var/www/web1/passwd.dav
           Require valid-user
       &lt;/Location&gt;
[...]</pre>
</td>
</tr>
</tbody>
</table>
<p>The Alias directive makes (together with &lt;Location&gt;) that when you call /webdav, WebDAV is invoked, but you can still access the whole document root of the vhost. All other URLs of that vhost are still &#8220;normal&#8221; HTTP.</p>
<p>The final vhost should look like this:</p>
<table width="90%" border="1" cellspacing="0" cellpadding="2" align="center" bgcolor="#cccccc">
<tbody>
<tr>
<td>
<pre>[...]
NameVirtualHost *:80
&lt;VirtualHost *:80&gt;
        ServerAdmin webmaster@localhost

        DocumentRoot /var/www/web1/web/
        &lt;Directory /var/www/web1/web/&gt;
                Options Indexes MultiViews
                AllowOverride None
                Order allow,deny
                allow from all
        &lt;/Directory&gt;

        Alias /webdav /var/www/web1/web

        &lt;Location /webdav&gt;
           DAV On
           AuthType Basic
           AuthName "webdav"
           AuthUserFile /var/www/web1/passwd.dav
           Require valid-user
       &lt;/Location&gt;

&lt;/VirtualHost&gt;</pre>
</td>
</tr>
</tbody>
</table>
<p>Reload Apache afterwards:</p>
<p>/etc/init.d/httpd reload</p>
<p>&nbsp;</p>
<h3>5 Testing WebDAV</h3>
<p>We will now install cadaver, a command-line WebDAV client:</p>
<p>yum install cadaver</p>
<p>To test if WebDAV works, type:</p>
<p>cadaver http://localhost/webdav/</p>
<p>You should be prompted for a user name. Type in test and then the password for the user test. If all goes well, you should be granted access which means WebDAV is working ok. Type quit to leave the WebDAV shell:</p>
<p>[root@server1 ~]# cadaver http://localhost/webdav/<br />
Authentication required for webdav on server `localhost&#8217;:<br />
Username: test<br />
Password:<br />
dav:/webdav/&gt; quit<br />
Connection to `localhost&#8217; closed.<br />
[root@server1 ~]#</p>
<h3>6 Configure A Windows XP Client To Connect To The WebDAV Share</h3>
<div></div>
<p>Click on My Network Places on your desktop (I have a German Windows, so the names are a bit different in the screenshots):</p>
<p><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/1.jpg" alt="1 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="118" height="154" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></p>
<p>Select Add a Network Place from the Network Tasks menu (on the left):</p>
<p><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/2.png" alt="2 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="302" height="532" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></p>
<p>The Add Network Place Wizard comes up. Click on the Next button:</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/3.png"><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/3.png" alt="3 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="550" height="455" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/3.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge How To Set Up WebDAV With Apache2 On CentOS 5.5" width="100" height="12" border="0" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /> </a></div>
<p>Select Choose another network location, and click on Next:</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/4.png"><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/4.png" alt="4 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="550" height="456" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/4.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge How To Set Up WebDAV With Apache2 On CentOS 5.5" width="100" height="12" border="0" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /> </a></div>
<p>Enter http://192.168.0.100:80/webdav as the location and click on Next. You must specify the port in the WebDAV URL (:80). For some strange reason this makes Windows XP accept the normal username (e.g. test) &#8211; otherwise Windows XP expects NTLM usernames (that would have the form www.example.com\test).</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/5.png"><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/5.png" alt="5 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="550" height="456" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/5.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge How To Set Up WebDAV With Apache2 On CentOS 5.5" width="100" height="12" border="0" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /> </a></div>
<p>You will be prompted for a user name and a password. Type in the user name test and the password for the user test:</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/6.png"><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/6.png" alt="6 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="550" height="434" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/6.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge How To Set Up WebDAV With Apache2 On CentOS 5.5" width="100" height="12" border="0" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /> </a></div>
<p>Then type in a name for the WebDAV folder:</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/7.png"><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/7.png" alt="7 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="550" height="457" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/7.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge How To Set Up WebDAV With Apache2 On CentOS 5.5" width="100" height="12" border="0" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /> </a></div>
<p>To open the new connection, keep the Open this network place when I click Finish box checked, and click on Finish:</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/8.png"><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/8.png" alt="8 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="550" height="454" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/8.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge How To Set Up WebDAV With Apache2 On CentOS 5.5" width="100" height="12" border="0" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /> </a></div>
<p>The WebDAV folder will then open where you can browse the contents of the /var/www/web1/web directory and its subdirectories on the server, and you will find an icon for your new WebDAV share in the My Network Places folder:</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/9.png"><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/9.png" alt="9 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="550" height="501" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></a></p>
<h3>7 Configure A Linux Client (GNOME) To Connect To The WebDAV Share</h3>
<div></div>
<p>If you want to connect to the WebDAV share from a GNOME desktop, go to Places &gt; Connect to Server&#8230;:</p>
<p><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/10.jpg" alt="10 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="550" height="438" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></p>
<p>Select WebDAV (HTTP) as the Service type, type in the Server (192.168.0.100 in this example) and then the Folder (webdav). Do not fill in a User Name yet because otherwise the connection will fail. Click on Connect afterwards:</p>
<p><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/11.jpg" alt="11 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="360" height="364" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></p>
<p>Now you are being prompted for a user name and password. Type in test along with the password, then click on Connect:</p>
<p><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/12.jpg" alt="12 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="370" height="290" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></p>
<p>You might get the following error&#8230;</p>
<p><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/13.jpg" alt="13 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="368" height="188" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></p>
<p>&#8230; but at the same time the WebDAV share should appear on the desktop, which means you can ignore the error:</p>
<p><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/14.jpg" alt="14 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="148" height="94" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></p>
<p>Double-click on the icon to open the WebDAV share:</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/15.png"><img src="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/15.png" alt="15 How To Set Up WebDAV With Apache2 On CentOS 5.5" width="550" height="440" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/apache2_webdav_fedora_5.5/big/15.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge How To Set Up WebDAV With Apache2 On CentOS 5.5" width="100" height="12" border="0" title="How To Set Up WebDAV With Apache2 On CentOS 5.5" /> </a></div>
<p>&nbsp;</p>
<h3>8 Links</h3>
<ul>
<li>WebDAV: <a rel="nofollow" target="_blank" href="http://www.webdav.org/" target="_blank">http://www.webdav.org/</a></li>
<li>Apache: <a rel="nofollow" target="_blank" href="http://httpd.apache.org/" target="_blank">http://httpd.apache.org/</a></li>
<li>CentOS: <a rel="nofollow" target="_blank" href="http://www.centos.org/" target="_blank">http://www.centos.org/</a></li>
</ul>
<p>&nbsp;</p>
<h4>Incoming search terms:</h4><ul><li><a href="http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html" title="directadmin webdav">directadmin webdav</a> (3)</li><li><a href="http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html" title="webdav directadmin">webdav directadmin</a> (2)</li><li><a href="http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html" title="apache dav">apache dav</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html" title="webdav centos howto">webdav centos howto</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html" title="webdav centos">webdav centos</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html" title="webdav apache http web server windows 7">webdav apache http web server windows 7</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html" title="server dav">server dav</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html" title="how to configure webdav on different centos port">how to configure webdav on different centos port</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html" title="connect to cpanel webdav on centos">connect to cpanel webdav on centos</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html" title="centos upload to webdav">centos upload to webdav</a> (1)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://thegioinguonmo.com/os/linux/set-webdav-apache2-centos-55.html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)</title>
		<link>http://thegioinguonmo.com/os/linux/installing-apache2-php5-mysql-support-centos-55-lamp.html</link>
		<comments>http://thegioinguonmo.com/os/linux/installing-apache2-php5-mysql-support-centos-55-lamp.html#comments</comments>
		<pubDate>Fri, 20 Jan 2012 09:57:25 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[Mysql]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://thegioinguonmo.com/?p=2209</guid>
		<description><![CDATA[LAMP is short for Linux, Apache, MySQL, PHP. This tutorial shows how you can install an Apache2 webserver on a CentOS 5.5 server with PHP5 support (mod_php) and MySQL support. I do not issue any guarantee that this will work for you! &#160; 1 Preliminary Note In this tutorial I use the hostname server1.example.com with [...]]]></description>
			<content:encoded><![CDATA[<p>LAMP is short for <strong>L</strong>inux, <strong>A</strong>pache, <strong>M</strong>ySQL, <strong>P</strong>HP. This tutorial shows how you can install an Apache2 webserver on a CentOS 5.5 server with PHP5 support (mod_php) and MySQL support.</p>
<p>I do not issue any guarantee that this will work for you!</p>
<p>&nbsp;</p>
<h3>1 Preliminary Note</h3>
<p>In this tutorial I use the hostname server1.example.com with the IP address 192.168.0.100. These settings might differ for you, so you have to replace them where appropriate.</p>
<p>&nbsp;</p>
<h3>2 Installing MySQL 5.0</h3>
<p>To install MySQL, we do this:</p>
<p>yum install mysql mysql-server</p>
<p>Then we create the system startup links for MySQL (so that MySQL starts automatically whenever the system boots) and start the MySQL server:</p>
<p>chkconfig &#8211;levels 235 mysqld on<br />
/etc/init.d/mysqld start</p>
<p>Set passwords for the MySQL root account:</p>
<p>mysql_secure_installation</p>
<p>[root@server1 ~]# mysql_secure_installation</p>
<p>NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MySQL<br />
SERVERS IN PRODUCTION USE!  PLEASE READ EACH STEP CAREFULLY!</p>
<p>In order to log into MySQL to secure it, we&#8217;ll need the current<br />
password for the root user.  If you&#8217;ve just installed MySQL, and<br />
you haven&#8217;t set the root password yet, the password will be blank,<br />
so you should just press enter here.</p>
<p>Enter current password for root (enter for none):<br />
OK, successfully used password, moving on&#8230;</p>
<p>Setting the root password ensures that nobody can log into the MySQL<br />
root user without the proper authorisation.</p>
<p>Set root password? [Y/n] &lt;&#8211; ENTER<br />
New password: &lt;&#8211; yourrootsqlpassword<br />
Re-enter new password: &lt;&#8211; yourrootsqlpassword<br />
Password updated successfully!<br />
Reloading privilege tables..<br />
&#8230; Success!</p>
<p>By default, a MySQL installation has an anonymous user, allowing anyone<br />
to log into MySQL without having to have a user account created for<br />
them.  This is intended only for testing, and to make the installation<br />
go a bit smoother.  You should remove them before moving into a<br />
production environment.</p>
<p>Remove anonymous users? [Y/n] &lt;&#8211; ENTER<br />
&#8230; Success!</p>
<p>Normally, root should only be allowed to connect from &#8217;localhost&#8217;.  This<br />
ensures that someone cannot guess at the root password from the network.</p>
<p>Disallow root login remotely? [Y/n] &lt;&#8211; ENTER<br />
&#8230; Success!</p>
<p>By default, MySQL comes with a database named &#8217;test&#8217; that anyone can<br />
access.  This is also intended only for testing, and should be removed<br />
before moving into a production environment.</p>
<p>Remove test database and access to it? [Y/n] &lt;&#8211; ENTER<br />
- Dropping test database&#8230;<br />
&#8230; Success!<br />
- Removing privileges on test database&#8230;<br />
&#8230; Success!</p>
<p>Reloading the privilege tables will ensure that all changes made so far<br />
will take effect immediately.</p>
<p>Reload privilege tables now? [Y/n] &lt;&#8211; ENTER<br />
&#8230; Success!</p>
<p>Cleaning up&#8230;</p>
<p>All done!  If you&#8217;ve completed all of the above steps, your MySQL<br />
installation should now be secure.</p>
<p>Thanks for using MySQL!</p>
<p>[root@server1 ~]#</p>
<p>&nbsp;</p>
<h3>3 Installing Apache2</h3>
<p>Apache2 is available as a CentOS package, therefore we can install it like this:</p>
<p>yum install httpd</p>
<p>Now configure your system to start Apache at boot time&#8230;</p>
<p>chkconfig &#8211;levels 235 httpd on</p>
<p>&#8230; and start Apache:</p>
<p>/etc/init.d/httpd start</p>
<p>Now direct your browser to http://192.168.0.100, and you should see the Apache2 placeholder page:</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/lamp_centos_5.5/big/1.png"><img src="http://static.howtoforge.com/images/lamp_centos_5.5/1.png" alt="1 Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" width="550" height="399" title="Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/lamp_centos_5.5/big/1.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" width="100" height="12" border="0" title="Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" /> </a></div>
<p>Apache&#8217;s default document root is /var/www/html on CentOS, and the configuration file is /etc/httpd/conf/httpd.conf. Additional configurations are stored in the /etc/httpd/conf.d/ directory.</p>
<p>&nbsp;</p>
<h3>4 Installing PHP5</h3>
<p>We can install PHP5 and the Apache PHP5 module as follows:</p>
<p>yum install php</p>
<p>We must restart Apache afterwards:</p>
<p>/etc/init.d/httpd restart</p>
<h3>5 Testing PHP5 / Getting Details About Your PHP5 Installation</h3>
<div></div>
<p>The document root of the default web site is /var/www/html. We will now create a small PHP file (info.php) in that directory and call it in a browser. The file will display lots of useful details about our PHP installation, such as the installed PHP version.</p>
<p>vi /var/www/html/info.php</p>
<table width="90%" border="1" cellspacing="0" cellpadding="2" align="center" bgcolor="#cccccc">
<tbody>
<tr>
<td>
<pre>&lt;?php
phpinfo();
?&gt;</pre>
</td>
</tr>
</tbody>
</table>
<p>Now we call that file in a browser (e.g. http://192.168.0.100/info.php):</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/lamp_centos_5.5/big/2.png"><img src="http://static.howtoforge.com/images/lamp_centos_5.5/2.png" alt="2 Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" width="550" height="399" title="Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/lamp_centos_5.5/big/2.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" width="100" height="12" border="0" title="Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" /> </a></div>
<p>As you see, PHP5 is working, and it&#8217;s working through the Apache 2.0 Handler, as shown in the Server API line. If you scroll further down, you will see all modules that are already enabled in PHP5. MySQL is not listed there which means we don&#8217;t have MySQL support in PHP5 yet.</p>
<p>&nbsp;</p>
<h3>6 Getting MySQL Support In PHP5</h3>
<p>To get MySQL support in PHP, we can install the php-mysql package. It&#8217;s a good idea to install some other PHP5 modules as well as you might need them for your applications. You can search for available PHP5 modules like this:</p>
<p>yum search php</p>
<p>Pick the ones you need and install them like this:</p>
<p>yum install php-mysql php-gd php-imap php-ldap php-odbc php-pear php-xml php-xmlrpc</p>
<p>Now restart Apache2:</p>
<p>/etc/init.d/httpd restart</p>
<p>Now reload http://192.168.0.100/info.php in your browser and scroll down to the modules section again. You should now find lots of new modules there, including the MySQL module:</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/lamp_centos_5.5/big/3.png"><img src="http://static.howtoforge.com/images/lamp_centos_5.5/3.png" alt="3 Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" width="550" height="399" title="Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/lamp_centos_5.5/big/3.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" width="100" height="12" border="0" title="Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" /> </a></div>
<p>&nbsp;</p>
<h3>7 phpMyAdmin</h3>
<p><a rel="nofollow" target="_blank" href="http://www.phpmyadmin.net/" target="_blank">phpMyAdmin</a> is a web interface through which you can manage your MySQL databases.</p>
<p>First we enable the <a rel="nofollow" target="_blank" href="https://rpmrepo.org/RPMforge/Using" target="_blank">RPMforge repository</a> on our CentOS system as phpMyAdmin is not available in the official CentOS 5.5 repositories:</p>
<p>On x86_64 systems:</p>
<p>wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.1-1.el5.rf.x86_64.rpm<br />
rpm -Uhv rpmforge-release-0.5.1-1.el5.rf.x86_64.rpm</p>
<p>On i386 systems:</p>
<p>wget http://packages.sw.be/rpmforge-release/rpmforge-release-0.5.1-1.el5.rf.i386.rpm<br />
rpm -Uhv rpmforge-release-0.5.1-1.el5.rf.i386.rpm</p>
<p>phpMyAdmin can now be installed as follows:</p>
<p>yum install phpmyadmin</p>
<p>Now we configure phpMyAdmin. We change the Apache configuration so that phpMyAdmin allows connections not just from localhost (by commenting out the &lt;Directory &#8220;/usr/share/phpmyadmin&#8221;&gt; stanza):</p>
<p>vi /etc/httpd/conf.d/phpmyadmin.conf</p>
<table width="90%" border="1" cellspacing="0" cellpadding="2" align="center" bgcolor="#cccccc">
<tbody>
<tr>
<td>
<pre>#
#  Web application to manage MySQL
#

#&lt;Directory "/usr/share/phpmyadmin"&gt;
#  Order Deny,Allow
#  Deny from all
#  Allow from 127.0.0.1
#&lt;/Directory&gt;

Alias /phpmyadmin /usr/share/phpmyadmin
Alias /phpMyAdmin /usr/share/phpmyadmin
Alias /mysqladmin /usr/share/phpmyadmin</pre>
</td>
</tr>
</tbody>
</table>
<p>Next we change the authentication in phpMyAdmin from cookie to http:</p>
<p>vi /usr/share/phpmyadmin/config.inc.php</p>
<table width="90%" border="1" cellspacing="0" cellpadding="2" align="center" bgcolor="#cccccc">
<tbody>
<tr>
<td>
<pre>[...]
/* Authentication type */
$cfg['Servers'][$i]['auth_type'] = 'http';
[...]</pre>
</td>
</tr>
</tbody>
</table>
<p>Restart Apache:</p>
<p>/etc/init.d/httpd restart</p>
<p>Afterwards, you can access phpMyAdmin under http://192.168.0.100/phpmyadmin/:</p>
<p><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/lamp_centos_5.5/big/4.png"><img src="http://static.howtoforge.com/images/lamp_centos_5.5/4.png" alt="4 Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" width="550" height="399" title="Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" /></a></p>
<div><a rel="nofollow" target="_blank" href="http://static.howtoforge.com/images/lamp_centos_5.5/big/4.png"><img src="http://static.howtoforge.com/images/click_to_enlarge.png" alt="click to enlarge Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" width="100" height="12" border="0" title="Installing Apache2 With PHP5 And MySQL Support On CentOS 5.5 (LAMP)" /> </a></div>
<p>&nbsp;</p>
<h3>8 Links</h3>
<ul>
<li>Apache: <a rel="nofollow" target="_blank" href="http://httpd.apache.org/" target="_blank">http://httpd.apache.org/</a></li>
<li>PHP: <a rel="nofollow" target="_blank" href="http://www.php.net/" target="_blank">http://www.php.net/</a></li>
<li>MySQL: <a rel="nofollow" target="_blank" href="http://www.mysql.com/" target="_blank">http://www.mysql.com/</a></li>
<li>CentOS: <a rel="nofollow" target="_blank" href="http://www.centos.org/" target="_blank">http://www.centos.org/</a></li>
<li>phpMyAdmin: <a rel="nofollow" target="_blank" href="http://www.phpmyadmin.net/" target="_blank">http://www.phpmyadmin.net/</a></li>
</ul>
<h4>Incoming search terms:</h4><ul><li><a href="http://thegioinguonmo.com/os/linux/installing-apache2-php5-mysql-support-centos-55-lamp.html" title="centos 5 5 phpmyadmin installation">centos 5 5 phpmyadmin installation</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/installing-apache2-php5-mysql-support-centos-55-lamp.html" title="centos vmware installed with php apache mysql and cpanel">centos vmware installed with php apache mysql and cpanel</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/installing-apache2-php5-mysql-support-centos-55-lamp.html" title="centos yum mod_php">centos yum mod_php</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/installing-apache2-php5-mysql-support-centos-55-lamp.html" title="install phpmyadmin in var/www/html folder in centos 5 5">install phpmyadmin in var/www/html folder in centos 5 5</a> (1)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://thegioinguonmo.com/os/linux/installing-apache2-php5-mysql-support-centos-55-lamp.html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Basic Steps to Secure Apache</title>
		<link>http://thegioinguonmo.com/web-server/apache/basic-steps-to-secure-apache.html</link>
		<comments>http://thegioinguonmo.com/web-server/apache/basic-steps-to-secure-apache.html#comments</comments>
		<pubDate>Sun, 15 Jan 2012 09:41:01 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[IP]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[Symbolic Links]]></category>

		<guid isPermaLink="false">http://thegioinguonmo.com/?p=426</guid>
		<description><![CDATA[Here are some basic steps to secure Apache Web Server IMPORTANT NOTE: These suggestions may vary from server to server and modify the values as per your server configurations. It is up to you to determine if any of the changes suggested here are not compatible with your requirements. 1. Hide the Apache Version number, [...]]]></description>
			<content:encoded><![CDATA[<p>Here are some basic steps to secure Apache Web Server</p>
<p><strong>IMPORTANT NOTE:</strong><strong> These suggestions may vary from server to server and modify the values as per your server configurations. It is up to you to determine if any of the changes suggested here are not compatible with your requirements</strong>.</p>
<p><strong>1. Hide the Apache Version number, and other sensitive information.</strong></p>
<p>&nbsp;</p>
<p>By default many Apache installations provides information about version of Apache, operating system/version you’re running, and Apache Modules are installed on the server. Attackers/Hackers can use this information to their advantage when performing an attack.</p>
<p>Open /etc/httpd/conf/httpd.conf file and add OR edit following</p>
<p>&nbsp;</p>
<p><strong>ServerSignature Off<br />
ServerTokens Prod</strong></p>
<p>The <strong>ServerSignature</strong> appears on the bottom of pages generated by apache such as 404 pages, directory listings, etc.</p>
<p>The <strong>ServerTokens</strong> directive is used to determine what Apache will put in the Server HTTP response header. By setting it to Prod it sets the HTTP response header as follows:</p>
<p><strong>Server: Apache</strong></p>
<p><strong><br />
2. Make sure apache is running under its own user account and group</strong></p>
<p>By default apache installations have it run as the user nobody. So suppose both Apache and your mail server were running as nobody and attack through Apache may allow the mail server to also be compromised, and vise versa.</p>
<p>&nbsp;</p>
<p><strong>User apache<br />
Group apache</strong></p>
<p>&nbsp;</p>
<p>In case of CPanel, it set the username as the ftp username of the domain which user set at the time of creating domain.</p>
<p><strong><br />
3. Ensure that files outside the web root are not served</strong></p>
<p>Apache shouldn’t able to access any files out side of its web root. So all your web sites should be placed under one directory (public_html for cPanel and httpdocs incase of Plesk as control panel), you would set it up as follows:</p>
<p><strong>&lt;Directory /&gt;<br />
Order Deny,Allow<br />
Deny from all<br />
Options None<br />
AllowOverride None<br />
&lt;/Directory&gt;<br />
&lt;Directory /public_html&gt;<br />
Order Allow,Deny<br />
Allow from all<br />
&lt;/Directory&gt;</strong></p>
<p>&nbsp;</p>
<p><strong> </strong>Note that because we set Options None and AllowOverride None this will turn off all options and overrides for the server. You now have to add them explicitly for each directory that requires an Option or Override using .htaccess .</p>
<p><strong><br />
4. Turn off directory browsing</strong></p>
<p>You can do this with an Options directive inside a Directory tag. Set Options to either None or –Indexes to disable Directory listing for the domain</p>
<p><strong>Options -Indexes</strong></p>
<p><strong><br />
5. Turn off server side includes</strong></p>
<p><strong>SSI (Server Side Includes)</strong> is directives that are placed in HTML pages, and evaluated on the server while the pages are being served. They let you add dynamically generated content to an existing HTML page, without having to serve the entire page via a CGI program, or other dynamic technology.</p>
<p>This can done with the Options directive inside a Directory tag. Set Options to either None or -Includes</p>
<p><strong>Options -Includes</strong></p>
<p><strong><br />
6. Turn off CGI execution</strong></p>
<p>The <strong>CGI (Common Gateway Interface)</strong> defines a way for a web server to interact with external content-generating programs, which are often referred to as CGI programs or CGI scripts. It is the simplest, and most common, way to put dynamic content on your web site</p>
<p>If you’re not using CGI turn it off with the Options directive inside a Directory tag. Set Options to either None or -ExecCGI</p>
<p><strong>Options -ExecCGI</strong></p>
<p><strong><br />
7. Don’t allow apache to follow Symbolic Links</strong></p>
<p>&nbsp;</p>
<p><strong>Symbolic Link</strong> (also <strong><em>symlink</em></strong> or <strong><em>soft link</em></strong>) is a special type of file that contains a reference to another file or directory in the form of an absolute or relative path and that affects pathname resolution.<strong> </strong></p>
<p><strong>Symbolic Links</strong> can be disabled using the Options directive inside a Directory tag. Set Options to either None or –FollowSymLinks</p>
<p><strong>Options -FollowSymLinks</strong></p>
<p><strong><br />
8.  Turn off support for .htaccess files</strong></p>
<p>&nbsp;</p>
<p><strong><code>.htaccess</code></strong> files (or “distributed configuration files”) provide a way to make configuration changes on a per-directory basis.</p>
<p>This is done in a Directory tag but with the AllowOverride directive. Set it to None.</p>
<p><strong>AllowOverride None</strong></p>
<p><strong><br />
9) Run mod_security</strong></p>
<p><em>ModSecurity</em> is an open source web application firewall. it’s a super handy Apache module written by Ivan Ristic, the author of Apache Security from O’Reilly press.</p>
<p>You can do the following with mod_security:</p>
<p>* Simple filtering<br />
* Regular Expression based filtering<br />
* URL Encoding Validation<br />
* Unicode Encoding Validation<br />
* Auditing<br />
* Null byte attack prevention<br />
* Upload memory limits* Server identity masking<br />
* Built in Chroot support<br />
* And more<br />
<strong><br />
10) Restricting Access by IP</strong></p>
<p>If you have a resource that should only by accessed by a certain network, or IP address you can enforce this in your apache configuration. For instance if you want to restrict access to your intranet to allow only the 92.48 network:</p>
<p>Order Deny,Allow<br />
Deny from all<br />
Allow from 92.48.0.0/16</p>
<p><strong>Or by IP:</strong></p>
<p>Order Deny,Allow<br />
Deny from all<br />
Allow from 127.0.0.1</p>
<h4>Incoming search terms:</h4><ul><li><a href="http://thegioinguonmo.com/web-server/apache/basic-steps-to-secure-apache.html" title="plesk IPCCommTimeout">plesk IPCCommTimeout</a> (2)</li><li><a href="http://thegioinguonmo.com/web-server/apache/basic-steps-to-secure-apache.html" title="centos basic programming">centos basic programming</a> (1)</li><li><a href="http://thegioinguonmo.com/web-server/apache/basic-steps-to-secure-apache.html" title="directadmin rewriteengine">directadmin rewriteengine</a> (1)</li><li><a href="http://thegioinguonmo.com/web-server/apache/basic-steps-to-secure-apache.html" title="mysql remote access 10 0 0 0/8">mysql remote access 10 0 0 0/8</a> (1)</li><li><a href="http://thegioinguonmo.com/web-server/apache/basic-steps-to-secure-apache.html" title="secure apache web server">secure apache web server</a> (1)</li><li><a href="http://thegioinguonmo.com/web-server/apache/basic-steps-to-secure-apache.html" title="working with apache basic steps">working with apache basic steps</a> (1)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://thegioinguonmo.com/web-server/apache/basic-steps-to-secure-apache.html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Manage Apache Resources Limits With mod_slotlimit (Debian Etch)</title>
		<link>http://thegioinguonmo.com/web-server/apache/how-to-manage-apache-resources-limits-with-mod_slotlimit-debian-etch-2.html</link>
		<comments>http://thegioinguonmo.com/web-server/apache/how-to-manage-apache-resources-limits-with-mod_slotlimit-debian-etch-2.html#comments</comments>
		<pubDate>Mon, 09 Jan 2012 09:39:41 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Debian]]></category>
		<category><![CDATA[mod]]></category>
		<category><![CDATA[order]]></category>
		<category><![CDATA[site]]></category>
		<category><![CDATA[web server]]></category>

		<guid isPermaLink="false">http://thegioinguonmo.com/?p=254</guid>
		<description><![CDATA[mod_slotlimit is an Apache module that using dynamic slot allocation algorithm and static rules, can manage resources used for each running site. &#160; 1. Installation In order to compile mod_slotlimit, you will need to have apxs2 (APache eXtension tool) installed and configured with Apache. The follow command will install it: apt-get install apache2-prefork-dev Now we [...]]]></description>
			<content:encoded><![CDATA[<p><a rel="nofollow" target="_blank" href="http://sourceforge.net/projects/mod-slotlimit/" target="_blank">mod_slotlimit</a> is an Apache module that using dynamic slot allocation algorithm and static rules, can manage resources used for each running site.</p>
<p>&nbsp;</p>
<h3>1. Installation</h3>
<p>In order to compile mod_slotlimit, you will need to have apxs2 (APache eXtension tool) installed and configured with Apache.</p>
<p>The follow command will install it:</p>
<p>apt-get install apache2-prefork-dev</p>
<p>Now we download the source package present at http://sourceforge.net/projects/mod-slotlimit/ or download it using wget application and this direct link to the repository:</p>
<p>wget http://kent.dl.sourceforge.net/sourceforge/mod-slotlimit/mod_slotlimit.tar.gz</p>
<p>Next open archive, compile and install module with those commands:</p>
<p>tar zxvf mod_slotlimit.tar.gz<br />
cd mod_slotlimit-1.0<br />
make<br />
make install</p>
<p>Add in the main config file of your web server the following command in order to load mod_slotlimit module.</p>
<p>vi /etc/apache2/httpd.conf</p>
<table width="90%" border="1" cellspacing="0" cellpadding="2" bgcolor="#cccccc">
<tbody>
<tr>
<td>
<blockquote><p>[...]<br />
LoadModule slotlimit_module /usr/lib/apache2/modules/mod_slotlimit.so</p></blockquote>
</td>
</tr>
</tbody>
</table>
<h3>2. Configuration</h3>
<p>Before we are able to write our configuration, we should known what directives are supported by this module.</p>
<p>For more information read mod_slotlimit’s documentation:</p>
<p>AvailableSlotsPercent – Percentage of apache slots available in order to activate dynamic slot allocation algorithm<br />
MaxConnectionsPerSite – Max connections for each running site<br />
LimitSite – Specific site to limit<br />
LimitSiteConnections – Max connections for “LimitSite”<br />
ClientIpLimit – Number of maximum simultaneous connection per IP<br />
ForceVhostName – Force vhost hostname in scoreboard. Useful when vhost hostname do not match site visited, for example if you’re using mod_vhost_alias</p>
<p>Now we open config file of our web server in order to write the configuration:</p>
<p>vi /etc/apache2/apache2.conf</p>
<table width="90%" border="1" cellspacing="0" cellpadding="2" bgcolor="#cccccc">
<tbody>
<tr>
<td>
<blockquote><p>[...]<br />
&lt;IfModule mod_slotlimit.c&gt;<br />
AvailableSlotsPercent 15<br />
MaxConnectionsPerSite 30<br />
LimitSite www.BadSite.xxx<br />
LimitSiteConnections 15<br />
ClientIpLimit 15<br />
ForceVhostName On<br />
&lt;/IfModule&gt;<br />
[...]</p></blockquote>
</td>
</tr>
</tbody>
</table>
<p>Finally we restart Apache:</p>
<p>/etc/init.d/apache2 restart</p>
<h3>3. Links</h3>
<ul>
<li>mod_slotlimit: <a rel="nofollow" target="_blank" href="http://sourceforge.net/projects/mod-slotlimit/" target="_blank">http://sourceforge.net/projects/mod-slotlimit/</a></li>
<li>Apache: <a rel="nofollow" target="_blank" href="http://httpd.apache.org/" target="_blank">http://httpd.apache.org</a></li>
<li>Debian: <a rel="nofollow" target="_blank" href="http://www.debian.org/" target="_blank">http://www.debian.org</a></li>
</ul>
<h4>Incoming search terms:</h4><ul><li><a href="http://thegioinguonmo.com/web-server/apache/how-to-manage-apache-resources-limits-with-mod_slotlimit-debian-etch-2.html" title="centos directadmin apache log">centos directadmin apache log</a> (1)</li><li><a href="http://thegioinguonmo.com/web-server/apache/how-to-manage-apache-resources-limits-with-mod_slotlimit-debian-etch-2.html" title="directadmin custombuild wsgi">directadmin custombuild wsgi</a> (1)</li><li><a href="http://thegioinguonmo.com/web-server/apache/how-to-manage-apache-resources-limits-with-mod_slotlimit-debian-etch-2.html" title="php5-eaccelerator php5-memcache apt-get">php5-eaccelerator php5-memcache apt-get</a> (1)</li><li><a href="http://thegioinguonmo.com/web-server/apache/how-to-manage-apache-resources-limits-with-mod_slotlimit-debian-etch-2.html" title="plesk Apache2::Resource">plesk Apache2::Resource</a> (1)</li><li><a href="http://thegioinguonmo.com/web-server/apache/how-to-manage-apache-resources-limits-with-mod_slotlimit-debian-etch-2.html" title="sc_pcre c: In function âmsc_pregcomp_exâ: msc_pcre c:70: error: invalid application of âsizeofâ to incomplete type âpcre_extraâ msc_pcre c:74: error: invalid application of âsizeofâ to incomplete type âpcre_extraâ">sc_pcre c: In function âmsc_pregcomp_exâ: msc_pcre c:70: error: invalid application of âsizeofâ to incomplete type âpcre_extraâ msc_pcre c:74: error: invalid application of âsizeofâ to incomplete type âpcre_extraâ</a> (1)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://thegioinguonmo.com/web-server/apache/how-to-manage-apache-resources-limits-with-mod_slotlimit-debian-etch-2.html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How To Install OCS Inventory NG Server 2 On CentOS 5.5</title>
		<link>http://thegioinguonmo.com/os/linux/install-ocs-inventory-ng-server-2-centos-55.html</link>
		<comments>http://thegioinguonmo.com/os/linux/install-ocs-inventory-ng-server-2-centos-55.html#comments</comments>
		<pubDate>Sun, 08 Jan 2012 15:37:23 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[ng server]]></category>
		<category><![CDATA[Security]]></category>

		<guid isPermaLink="false">http://thegioinguonmo.com/?p=2205</guid>
		<description><![CDATA[Introduction OCS Inventory is a great software to make inventories. The NG Server is formed by: communication server, deployment server, and administration console. Click here to know how it works. The computers that will be inventoried must run an agent (installed on each computer), to connect to the OCS NG Server. We are using the [...]]]></description>
			<content:encoded><![CDATA[<h3>Introduction</h3>
<p>OCS Inventory is a great software to make inventories. The NG Server is formed by: communication server, deployment server, and administration console. Click <a rel="nofollow" target="_blank" href="http://wiki.ocsinventory-ng.org/index.php/Documentation:Server" target="_blank">here</a> to know how it works.</p>
<p>The computers that will be inventoried must run an agent (installed on each computer), to connect to the OCS NG Server. We are using the CentOS 5.5 (64bits) distribution, but it will probably work on Fedora (and Red Hat, for sure).</p>
<p>&nbsp;</p>
<h3>1 Some Prerequisites</h3>
<h4>Installing MySQL Server</h4>
<p>We need to install it (if it&#8217;s not already installed):</p>
<p>yum install mysql-server php-mysql php-pecl-zip php-gd</p>
<p>Starting MySQL:</p>
<pre class="brush:shell">/etc/init.d/mysqld start
chkconfig --level 35 mysqld on</pre>
<p>Setting a root password on mysql:</p>
<pre class="brush:shell">/usr/bin/mysqladmin -u root password 'secret'</pre>
<p>&nbsp;</p>
<h4>Starting Apache:</h4>
<p>We need to start Apache (OCS uses it):</p>
<pre class="brush:shell">/etc/init.d/httpd start
chkconfig --level 35 httpd on</pre>
<h4>Installing Packages</h4>
<p>Next, we need to install EPEL repository:</p>
<pre class="brush:shell">rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/x86_64/epel-release-5-4.noarch.rpm</pre>
<p>Afterwards, let&#8217;s install the packages:</p>
<pre class="brush:shell">yum install -y perl-XML-Simple perl-Compress-Zlib perl-DBI perl-DBD-MySQL perl-Net-IP perl-XML-Entities perl-Apache-DBI perl-Apache2-SOAP perl-SOAP-Lite mod_perl
</pre>
<p>&nbsp;</p>
<h4>Configure PHP</h4>
<p>Edit the /etc/php.ini file, and change the following lines:</p>
<pre class="brush:shell">vi /etc/php.ini

post_max_size = 200M
upload_max_filesize = 200M</pre>
<p>Restart Apache:</p>
<pre class="brush:shell">/etc/init.d/httpd restart</pre>
<p>&nbsp;</p>
<h3>2 Installing OCS Inventory NG Server 2</h3>
<p>First, we need to download the tarball from OCS Inventory website. Click <a rel="nofollow" target="_blank" href="http://www.ocsinventory-ng.org/index.php?page=downloads" target="_blank">here</a>.</p>
<pre class="brush:shell">mkdir /download
cd /download
wget http://launchpad.net/ocsinventory-server/stable-2.0/2.0rc1/+download/OCSNG_UNIX_SERVER-2.0rc1.tar.gz</pre>
<p>Initiate the installer:</p>
<pre class="brush:shell">tar -zxvf OCSNG_UNIX_SERVER-2.0rc1.tar.gz
cd /download/OCSNG_UNIX_SERVER-2.0rc1
sh setup.sh</pre>
<p>The install script is very simple, it&#8217;s a wizard. Almost all the options, we&#8217;ll select the default option.<br />
These are the questions:</p>
<p><em>If you leave the question in blank, it will select the default option.</em></p>
<p>Do you wish to continue ([y]/n)?y</p>
<p>Your MySQL client seems to be part of MySQL version 5.0.<br />
Your computer seems to be running MySQL 4.1 or higher, good <img src='http://thegioinguonmo.com/wp-includes/images/smilies/icon_wink.gif' alt="icon wink How To Install OCS Inventory NG Server 2 On CentOS 5.5" class='wp-smiley' title="How To Install OCS Inventory NG Server 2 On CentOS 5.5" /><br />
Which host is running database server [localhost] ?localhost</p>
<p>On which port is running database server [3306] ? 3306</p>
<p>Where is Apache daemon binary [/usr/sbin/httpd] ?</p>
<p>Where is Apache main configuration file [/etc/httpd/conf/httpd.conf] ?</p>
<p>Which user account is running Apache web server [apache] ?</p>
<p>Which user group is running Apache web server [apache] ?</p>
<p>Where is Apache Include configuration directory [/etc/httpd/conf.d/] ?</p>
<p>Where is PERL Intrepreter binary [/usr/bin/perl] ?</p>
<p>Do you wish to setup Communication server on this computer ([y]/n)?y</p>
<p>Where to put Communication server log directory [/var/log/ocsinventory-server] ?</p>
<p>OCS setup.sh can install perl module from packages for you<br />
The script will use the native package from your operating system like apt or rpm<br />
Do you wish to continue (y/[n])? y</p>
<p>To ensure Apache loads mod_perl before OCS Inventory NG Communication Server,</p>
<p>Setup can name Communication Server Apache configuration file<br />
&#8216;z-ocsinventory-server.conf&#8217; instead of &#8216;ocsinventory-server.conf&#8217;.<br />
Do you allow Setup renaming Communication Server Apache configuration file<br />
to &#8216;z-ocsinventory-server.conf&#8217; ([y]/n) ?y</p>
<p>Do you wish to setup Administration Server (Web Administration Console)<br />
on this computer ([y]/n)?y</p>
<p>CAUTION: Setup now install files in accordance with Filesystem Hierarchy<br />
Standard. So, no file is installed under Apache root document directory<br />
(Refer to Apache configuration files to locate it).<br />
If you&#8217;re upgrading from OCS Inventory NG Server 1.01 and previous, YOU<br />
MUST REMOVE (or move) directories &#8216;ocsreports&#8217; and &#8216;download&#8217; from Apache<br />
root document directory.<br />
If you choose to move directory, YOU MUST MOVE &#8216;download&#8217; directory to<br />
Administration Server writable/cache directory (by default<br />
/var/lib/ocsinventory-reports), especialy if you use deployement feature.<br />
Do you wish to continue ([y]/n)?y</p>
<p>Where to copy Administration Server static files for PHP Web Console<br />
[/usr/share/ocsinventory-reports] ?</p>
<p>Where to create writable/cache directories for deployement packages,<br />
IPDiscover and SNMP [/var/lib/ocsinventory-reports] ?</p>
<p>&nbsp;</p>
<h3>3 Configuring OCS Inventory NG Server 2</h3>
<h4>Creating a MySQL database:</h4>
<p>First, we need to open mysql shell:</p>
<p>mysql -u root -p&#8221;secret&#8221;</p>
<p>Then create the database named ocsweb, and grant permissions to user ocs, with password ocs:</p>
<p>CREATE DATABASE ocsweb;<br />
GRANT ALL ON ocsweb.* to &#8216;ocs&#8217;@'localhost&#8217; identified by &#8216;ocs&#8217;;</p>
<p><em>If you want, you can change these parameters (database name, username or password). This is the default of ocs.</em></p>
<p>Now, point your browser to ocsreports interface, to manage the server with the administration tool:</p>
<p>http://server-ip/ocsreports/</p>
<p>The default user is &#8220;admin&#8221; and password is &#8220;admin&#8221;.</p>
<p>Finally, we must delete the install script:</p>
<p>rm -f /usr/share/ocsinventory-reports/ocsreports/install.php</p>
<p>Now, all you have to do is configure the server with the machine options. Install the agents on the network computers pointing the server ip on them.<br />
For more information, take a look at the wiki of OCS clicking <a rel="nofollow" target="_blank" href="http://wiki.ocsinventory-ng.org/index.php/Documentation:Main" target="_blank">here</a>.</p>
<p>&nbsp;</p>
<h3>References</h3>
<p>OCS Inventory: <a rel="nofollow" target="_blank" href="http://wiki.ocsinventory-ng.org/index.php/Documentation:Main" target="_blank">http://wiki.ocsinventory-ng.org/index.php/Documentation:Main</a></p>
<h4>Incoming search terms:</h4><ul><li><a href="http://thegioinguonmo.com/os/linux/install-ocs-inventory-ng-server-2-centos-55.html" title="centos apache mysql sysnetpro">centos apache mysql sysnetpro</a> (2)</li><li><a href="http://thegioinguonmo.com/os/linux/install-ocs-inventory-ng-server-2-centos-55.html" title="ocs inventory">ocs inventory</a> (2)</li><li><a href="http://thegioinguonmo.com/os/linux/install-ocs-inventory-ng-server-2-centos-55.html" title="howto ocs inventory debian">howto ocs inventory debian</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/install-ocs-inventory-ng-server-2-centos-55.html" title="instalasi ocs inventory">instalasi ocs inventory</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/install-ocs-inventory-ng-server-2-centos-55.html" title="ocs inventory ng freebsd client">ocs inventory ng freebsd client</a> (1)</li><li><a href="http://thegioinguonmo.com/os/linux/install-ocs-inventory-ng-server-2-centos-55.html" title="ocsinventory centos iptables">ocsinventory centos iptables</a> (1)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://thegioinguonmo.com/os/linux/install-ocs-inventory-ng-server-2-centos-55.html/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Served from: thegioinguonmo.com @ 2012-02-07 10:56:28 -->
