<?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>LAMP Tips!</title>
	<atom:link href="http://lamptips.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://lamptips.com</link>
	<description>Tips for Linux, Apache (and Nginx!), MySQL and PHP!</description>
	<lastBuildDate>Sun, 05 Feb 2012 07:54:10 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>MySQL / General &#8211; Dump all databases</title>
		<link>http://lamptips.com/2012/02/mysql-general-dump-all-databases/</link>
		<comments>http://lamptips.com/2012/02/mysql-general-dump-all-databases/#comments</comments>
		<pubDate>Sun, 05 Feb 2012 07:54:10 +0000</pubDate>
		<dc:creator>LampTips</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://lamptips.com/?p=44</guid>
		<description><![CDATA[Sometimes, you need to do a full dump of your databases to import to another server. First, make sure you are taking no writes to the database (unless EVERY table is InnoDB). If the former is true: mysqldump -uUsername -p &#8230;<p class="read-more"><a href="http://lamptips.com/2012/02/mysql-general-dump-all-databases/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<p>Sometimes, you need to do a full dump of your databases to import to another server.</p>
<p><span id="more-44"></span>First, make sure you are taking no writes to the database (unless EVERY table is InnoDB). If the former is true:</p>
<pre>mysqldump -uUsername -p -A &gt; dump.sql</pre>
<p>If the latter is true (all tables InnoDB, except of course the mysql DB):</p>
<pre>mysqldump -uUser -pPass --single-transaction -A &gt; dump.sql</pre>
]]></content:encoded>
			<wfw:commentRss>http://lamptips.com/2012/02/mysql-general-dump-all-databases/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MySQL/General &#8211; Database + Index + Total Size</title>
		<link>http://lamptips.com/2012/01/mysqlgeneral-database-index-total-size/</link>
		<comments>http://lamptips.com/2012/01/mysqlgeneral-database-index-total-size/#comments</comments>
		<pubDate>Mon, 30 Jan 2012 06:56:10 +0000</pubDate>
		<dc:creator>LampTips</dc:creator>
				<category><![CDATA[MySQL]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[size]]></category>

		<guid isPermaLink="false">http://lamptips.com/?p=29</guid>
		<description><![CDATA[Ever need to find the Data+Index size for your DB?  Try this query: SELECT DBName, CONCAT(LPAD(FORMAT(SDSize/POWER(1024,pw),3),17,' '),' ',SUBSTR(' KMGTP',pw+1,1),'B') "Data Size", CONCAT(LPAD(FORMAT(SXSize/POWER(1024,pw),3),17,' '),' ',SUBSTR(' KMGTP',pw+1,1),'B') "Index Size", CONCAT(LPAD(FORMAT(STSize/POWER(1024,pw),3),17,' '),' ',SUBSTR(' KMGTP',pw+1,1),'B') "Total Size" FROM ( SELECT IFNULL(DB,'All Databases') DBName, SUM(DSize) &#8230;<p class="read-more"><a href="http://lamptips.com/2012/01/mysqlgeneral-database-index-total-size/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<p>Ever need to find the Data+Index size for your DB?<br />
<span id="more-29"></span> Try this query:</p>
<pre>SELECT DBName,
  CONCAT(LPAD(FORMAT(SDSize/POWER(1024,pw),3),17,' '),' ',SUBSTR(' KMGTP',pw+1,1),'B') "Data Size",
  CONCAT(LPAD(FORMAT(SXSize/POWER(1024,pw),3),17,' '),' ',SUBSTR(' KMGTP',pw+1,1),'B') "Index Size",
  CONCAT(LPAD(FORMAT(STSize/POWER(1024,pw),3),17,' '),' ',SUBSTR(' KMGTP',pw+1,1),'B') "Total Size"
FROM (
  SELECT IFNULL(DB,'All Databases') DBName,
  SUM(DSize) SDSize,
  SUM(XSize) SXSize,
  SUM(TSize) STSize
  FROM (
    SELECT table_schema DB,
      data_length DSize,
      index_length XSize,
      data_length+index_length TSize
    FROM information_schema.tables
    WHERE table_schema NOT IN ('mysql','information_schema','performance_schema')) AAA
    GROUP BY DB WITH ROLLUP
) AA,
(SELECT 2 pw) BB
ORDER BY (SDSize+SXSize);</pre>
]]></content:encoded>
			<wfw:commentRss>http://lamptips.com/2012/01/mysqlgeneral-database-index-total-size/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Linux/General &#8211; tar &#8211; Too many arguments</title>
		<link>http://lamptips.com/2012/01/linuxgeneral-tar-too-many-arguments/</link>
		<comments>http://lamptips.com/2012/01/linuxgeneral-tar-too-many-arguments/#comments</comments>
		<pubDate>Mon, 30 Jan 2012 06:40:57 +0000</pubDate>
		<dc:creator>LampTips</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[arg_max]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[tar]]></category>
		<category><![CDATA[too many argument]]></category>

		<guid isPermaLink="false">http://lamptips.com/?p=24</guid>
		<description><![CDATA[Occasionally, when working in directories with large numbers of files and/or directories contained within them, you will get an error stating: Too many arguments. This is not an error from the application. Rather, it is an error from the shell &#8230;<p class="read-more"><a href="http://lamptips.com/2012/01/linuxgeneral-tar-too-many-arguments/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<p>Occasionally, when working in directories with large numbers of files and/or directories contained within them, you will get an error stating: Too many arguments.</p>
<p>This is not an error from the application. Rather, it is an error from the shell erroring on ARG_MAX limit reached.<br />
<span id="more-24"></span> There are a few ways to get around this, none of them are particularly elegant:</p>
<p>Using tar inside of a directory with too many files.</p>
<pre>find . -print | tar -cvzf archive.tar.gz --files-from -</pre>
<p>Using cp to move files, but too many files to work with:</p>
<pre>for x in $( ls ); do cp $x /new/location; done</pre>
<p>These are just some examples of ways to get around that problem. As a rule of thumb, try to keep the number of files in any given directory to &lt; 1024.</p>
]]></content:encoded>
			<wfw:commentRss>http://lamptips.com/2012/01/linuxgeneral-tar-too-many-arguments/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MySQL/Security &#8211; Cleaning up post-install</title>
		<link>http://lamptips.com/2012/01/mysqlsecurity-cleaning-up-post-install/</link>
		<comments>http://lamptips.com/2012/01/mysqlsecurity-cleaning-up-post-install/#comments</comments>
		<pubDate>Mon, 30 Jan 2012 04:42:45 +0000</pubDate>
		<dc:creator>LampTips</dc:creator>
				<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[install]]></category>
		<category><![CDATA[installation]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://lamptips.com/?p=18</guid>
		<description><![CDATA[A default install of MySQL has anonymous users and root users with access via &#8216;%&#8217; (all outside hosts) and a generally useless &#8216;test&#8217; database.  The best method to do this is to execute the following at the shell prompt: mysql_secure_installation &#8230;<p class="read-more"><a href="http://lamptips.com/2012/01/mysqlsecurity-cleaning-up-post-install/">Read more &#187;</a></p>]]></description>
			<content:encoded><![CDATA[<p>A default install of MySQL has anonymous users and root users with access via &#8216;%&#8217; (all outside hosts) and a generally useless &#8216;test&#8217; database.<br />
<span id="more-18"></span> The best method to do this is to execute the following at the shell prompt:</p>
<pre>mysql_secure_installation</pre>
<p>If this feature is not available, simply execute the following set of queries in MySQL:</p>
<pre>DROP DATABASE `test`;
DELETE FROM `mysql`.`user` WHERE `User` = '';
DELETE FROM `mysql`.`user` WHERE `User` = 'root' AND `Host` != 'localhost';
FLUSH PRIVILEGES;</pre>
]]></content:encoded>
			<wfw:commentRss>http://lamptips.com/2012/01/mysqlsecurity-cleaning-up-post-install/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Apache/Security &#8211; Hide Apache Version Number</title>
		<link>http://lamptips.com/2012/01/apachesecurity-hide-apache-version-number/</link>
		<comments>http://lamptips.com/2012/01/apachesecurity-hide-apache-version-number/#comments</comments>
		<pubDate>Mon, 30 Jan 2012 04:38:16 +0000</pubDate>
		<dc:creator>LampTips</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[pci]]></category>
		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://lamptips.com/?p=16</guid>
		<description><![CDATA[Sometimes, you may like a bit of security-through-obscurity. Some PCI providers even require this.  You can disable the display of the Apache version by adding the following to your httpd.conf (Generally in /etc/httpd/conf): ServerSignature Off ServerTokens Prod]]></description>
			<content:encoded><![CDATA[<p>Sometimes, you may like a bit of security-through-obscurity. Some PCI providers even require this.<br />
<span id="more-16"></span> You can disable the display of the Apache version by adding the following to your httpd.conf (Generally in /etc/httpd/conf):</p>
<pre>ServerSignature Off
ServerTokens Prod</pre>
]]></content:encoded>
			<wfw:commentRss>http://lamptips.com/2012/01/apachesecurity-hide-apache-version-number/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Apache/PCI &#8211; Disable Weak Cipher and older TLS Support</title>
		<link>http://lamptips.com/2012/01/apachepci-disable-weak-cipher-and-older-tls-support/</link>
		<comments>http://lamptips.com/2012/01/apachepci-disable-weak-cipher-and-older-tls-support/#comments</comments>
		<pubDate>Sun, 29 Jan 2012 11:13:25 +0000</pubDate>
		<dc:creator>LampTips</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[pci]]></category>
		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://lamptips.com/?p=10</guid>
		<description><![CDATA[PCI compliance tests require you to disable weak ciphers and older TLS support.  You can do that by adding the following to your httpd.conf (Generally under /etc/httpd/conf/): SSLProtocol all -SSLv2 SSLCipherSuite ALL:!ADH:!EXPORT56:+HIGH:+MEDIUM:-SSLv2:-RC4:+EXP]]></description>
			<content:encoded><![CDATA[<p>PCI compliance tests require you to disable weak ciphers and older TLS support.<br />
<span id="more-10"></span> You can do that by adding the following to your httpd.conf (Generally under /etc/httpd/conf/):</p>
<pre>SSLProtocol all -SSLv2
SSLCipherSuite ALL:!ADH:!EXPORT56:+HIGH:+MEDIUM:-SSLv2:-RC4:+EXP</pre>
]]></content:encoded>
			<wfw:commentRss>http://lamptips.com/2012/01/apachepci-disable-weak-cipher-and-older-tls-support/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Apache/PCI &#8211; Disable TRACE Method</title>
		<link>http://lamptips.com/2012/01/apachepci-disable-trace-method/</link>
		<comments>http://lamptips.com/2012/01/apachepci-disable-trace-method/#comments</comments>
		<pubDate>Sun, 29 Jan 2012 11:08:31 +0000</pubDate>
		<dc:creator>LampTips</dc:creator>
				<category><![CDATA[Apache]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[pci]]></category>
		<category><![CDATA[security]]></category>

		<guid isPermaLink="false">http://lamptips.com/?p=7</guid>
		<description><![CDATA[Some PCI tests require that you disable the Apache TRACE method as this can reveal sensitive information about the server.  Doing so is very simple! Add the following to your httpd.conf file (Generally in /etc/httpd/conf/): TraceEnable off]]></description>
			<content:encoded><![CDATA[<p>Some PCI tests require that you disable the Apache TRACE method as this can reveal sensitive information about the server.<br />
<span id="more-7"></span> Doing so is very simple! Add the following to your httpd.conf file (Generally in /etc/httpd/conf/):</p>
<pre>TraceEnable off</pre>
]]></content:encoded>
			<wfw:commentRss>http://lamptips.com/2012/01/apachepci-disable-trace-method/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

