<?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>systemBash &#187; MySQL</title>
	<atom:link href="http://systembash.com/tags/system-administration/mysql/feed/" rel="self" type="application/rss+xml" />
	<link>http://systembash.com</link>
	<description>Technology and System Administration</description>
	<lastBuildDate>Sat, 12 May 2012 13:13:12 +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>PostgreSQL pg_dumpall error message</title>
		<link>http://systembash.com/content/postgresql-pg_dumpall-error-message/</link>
		<comments>http://systembash.com/content/postgresql-pg_dumpall-error-message/#comments</comments>
		<pubDate>Wed, 20 Feb 2008 15:51:47 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[System Administration]]></category>
		<category><![CDATA[backup]]></category>
		<category><![CDATA[postgresql]]></category>

		<guid isPermaLink="false">http://systembash.com/content/postgresql-pg_dumpall-error-message/</guid>
		<description><![CDATA[When doing a PostgreSQL database server upgrade, you first need to backup all of the databases because the format changes from version to version. Postgresql documentation states you need to run the command: 1pg_dumpall &#62; outputfile I ran this, and received the error message: 1pg_dumpall: could not connect to database &#34;template1&#34;: FATAL: &#160;role &#34;root&#34; does [...]]]></description>
			<content:encoded><![CDATA[<p>When doing a <a href="http://www.postgresql.org">PostgreSQL</a> database server upgrade, you first need to backup all of the databases because the format changes from version to version.</p>
<p><a href="http://www.postgresql.org/docs/8.3/static/install-upgrading.html">Postgresql documentation</a> states you need to run the command:</p>
<div class="codecolorer-container text mac-classic" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">pg_dumpall &gt; outputfile</div></td></tr></tbody></table></div>
<p>I ran this, and received the error message:</p>
<div class="codecolorer-container text mac-classic" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">pg_dumpall: could not connect to database &quot;template1&quot;: FATAL: &nbsp;role &quot;root&quot; does not exist</div></td></tr></tbody></table></div>
<p>So after some head scratching and googling without any results; I noticed that I had created a user for postgres; namely &#8216;postgres&#8217;. I <em>su</em>ed to that user and ran the command &#8211; what do you know &#8211; it works fine! I&#8217;m glad that error message was so clear.</p>
<p>So, the thing that the documentation does not state &#8211; make sure you are running under the Postgresql user before running the backup command.</p>
]]></content:encoded>
			<wfw:commentRss>http://systembash.com/content/postgresql-pg_dumpall-error-message/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>My MySQL Binary Log files are taking up all my disk space!</title>
		<link>http://systembash.com/content/mysql-binary-log-file-size-huge/</link>
		<comments>http://systembash.com/content/mysql-binary-log-file-size-huge/#comments</comments>
		<pubDate>Tue, 14 Aug 2007 14:40:39 +0000</pubDate>
		<dc:creator>Dave</dc:creator>
				<category><![CDATA[Configurations]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[System Administration]]></category>
		<category><![CDATA[database server]]></category>

		<guid isPermaLink="false">http://systembash.com/content/mysql-binary-log-file-size-huge/</guid>
		<description><![CDATA[&#8230;and other MySQL Oddities. If your MySQL binary log files are a &#8220;Growing&#8221; problem&#8230; there are a few simple steps you can use to curtail their growth and save your disk space from these huge files. They probably look like: mysql-bin.000001 mysql-bin.000002 mysql-bin.000003 mysql-bin.000004 mysql-bin.000005 &#8230; And around 1 gig in size each. These files [...]]]></description>
			<content:encoded><![CDATA[<p>&#8230;and other MySQL Oddities. </p>
<p>If your MySQL binary log files are a &#8220;Growing&#8221; problem&#8230; there are a few simple steps you can use to curtail their growth and save your disk space from these huge files.</p>
<p>They probably look like:</p>
<blockquote><p>mysql-bin.000001<br />
mysql-bin.000002<br />
mysql-bin.000003<br />
mysql-bin.000004<br />
mysql-bin.000005<br />
&#8230;</p></blockquote>
<p>And around 1 gig in size each.</p>
<p>These files are generated when you have log-bin=mysql-bin or other log-bin= line in your /etc/my.cnf configuration file.</p>
<p>There are two ways to fix this problem:</p>
<p>The first is to stop the MySQL server from creating these binary files. The only reason you would need the binary log files is if you are doing mysql replication from a master to a slave. In this case, these files are necessary, at least until the slave(s) has caught up with the master. To stop this from logging, comment out (using #) the line containing &#8216;log-bin&#8217;.</p>
<p>The second is to continue logging &#8211; this is necessary as stated above if you are performing SQL replication.</p>
<p>You can add a line to your /etc/my.cnf file which will only keep these files around as long as necessary. The line is:</p>
<div class="codecolorer-container text mac-classic" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><table cellspacing="0" cellpadding="0"><tbody><tr><td style="padding:5px;text-align:center;color:#888888;background-color:#EEEEEE;border-right: 1px solid #9F9F9F;font: normal 12px/1.4em Monaco, Lucida Console, monospace;"><div>1<br /></div></td><td><div class="text codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">expire_logs_days = X</div></td></tr></tbody></table></div>
<p>Where X is the number of days you&#8217;d like to keep them around. I would recommend 10, but this depends on how busy your MySQL server is and how fast these log files grow. Just make sure it is longer than the slowest slave takes to replicate the data from your master.</p>
<p><em>Just a side note: </em>You know that you should do this anyway, but make sure you back up your mysql database. The binary log can be used to recover the database in certain situations; so having a backup ensures that if your database server does crash, you will be able to recover the data.</p>
]]></content:encoded>
			<wfw:commentRss>http://systembash.com/content/mysql-binary-log-file-size-huge/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
	</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Page Caching using disk: enhanced
Database Caching 15/22 queries in 0.006 seconds using disk: basic

Served from: systembash.com @ 2012-05-23 23:43:47 -->
