<?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>Racker Hacker &#187; yum</title>
	<atom:link href="http://rackerhacker.com/tag/yum/feed/" rel="self" type="application/rss+xml" />
	<link>http://rackerhacker.com</link>
	<description>Words of wisdom from a server administrator</description>
	<lastBuildDate>Wed, 16 May 2012 12:55:04 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Get notifications instead of automatic updates in Scientific Linux</title>
		<link>http://rackerhacker.com/2012/02/04/get-notifications-instead-of-automatic-updates-in-scientific-linux/</link>
		<comments>http://rackerhacker.com/2012/02/04/get-notifications-instead-of-automatic-updates-in-scientific-linux/#comments</comments>
		<pubDate>Sat, 04 Feb 2012 19:01:54 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[scientific linux]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=2928</guid>
		<description><![CDATA[Scientific Linux installations have a package called yum-autoupdate by default and the package contains two files: # rpm -ql yum-autoupdate /etc/cron.daily/yum-autoupdate /etc/sysconfig/yum-autoupdate The cron job contains the entire script to run automatic updates once a day and the configuration file controls its behavior. However, you can't get the same functionality as Fedora's yum-updatesd package where [...]<p><a href="http://rackerhacker.com/2012/02/04/get-notifications-instead-of-automatic-updates-in-scientific-linux/">Get notifications instead of automatic updates in Scientific Linux</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>Scientific Linux installations have a package called <code>yum-autoupdate</code> by default and the package contains two files:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;"># rpm -ql yum-autoupdate
/etc/cron.daily/yum-autoupdate
/etc/sysconfig/yum-autoupdate</pre></div></div>

<p>The cron job contains the entire script to run automatic updates once a day and the configuration file controls its behavior.  However, you can't get the same functionality as Fedora's <code>yum-updatesd</code> package where you can receive notifications for updates rather than automatically updating the packages.</p>
<p>To get those notifications in Scientific Linux, just make two small edits to this portion of <code>/etc/cron.daily/yum-autoupdate</code>:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000;">173</span>           <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;    Starting Yum with command&quot;</span>
<span style="color: #000000;">174</span>           <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;     /usr/bin/yum -c <span style="color: #007800;">$TEMPCONFIGFILE</span> -e 0 -d 1 -y update&quot;</span>         
<span style="color: #000000;">175</span>   <span style="color: #000000; font-weight: bold;">fi</span>
<span style="color: #000000;">176</span>   <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>yum <span style="color: #660033;">-c</span> <span style="color: #007800;">$TEMPCONFIGFILE</span> <span style="color: #660033;">-e</span> <span style="color: #000000;">0</span> <span style="color: #660033;">-d</span> <span style="color: #000000;">1</span> <span style="color: #660033;">-y</span> update <span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #007800;">$TEMPFILE</span> <span style="color: #000000;">2</span><span style="color: #000000; font-weight: bold;">&gt;&amp;</span><span style="color: #000000;">1</span>
<span style="color: #000000;">177</span>   <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #660033;">-s</span> <span style="color: #007800;">$TEMPFILE</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span> ; <span style="color: #000000; font-weight: bold;">then</span></pre></div></div>

<p>Adjust the <code>update</code> commands to look like this:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000;">173</span>           <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;    Starting Yum with command&quot;</span>
<span style="color: #000000;">174</span>           <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;     /usr/bin/yum -c <span style="color: #007800;">$TEMPCONFIGFILE</span> -e 0 -d 1 -y check-update&quot;</span>         
<span style="color: #000000;">175</span>   <span style="color: #000000; font-weight: bold;">fi</span>
<span style="color: #000000;">176</span>   <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin<span style="color: #000000; font-weight: bold;">/</span>yum <span style="color: #660033;">-c</span> <span style="color: #007800;">$TEMPCONFIGFILE</span> <span style="color: #660033;">-e</span> <span style="color: #000000;">0</span> <span style="color: #660033;">-d</span> <span style="color: #000000;">1</span> <span style="color: #660033;">-y</span> check-update <span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #007800;">$TEMPFILE</span> <span style="color: #000000;">2</span><span style="color: #000000; font-weight: bold;">&gt;&amp;</span><span style="color: #000000;">1</span>
<span style="color: #000000;">177</span>   <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #660033;">-s</span> <span style="color: #007800;">$TEMPFILE</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span> ; <span style="color: #000000; font-weight: bold;">then</span></pre></div></div>

<p>Since you won't be auto-updating with this script any longer, you may want to comment out the <code>EXCLUDE=</code> line in <code>/etc/sysconfig/yum-autoupdate</code> so that you'll receive notifications for all packages with updates.  Also, to avoid having your changes updated with a newer <code>yum-autoupdate</code> package later, add the package to your list of excluded packages in <code>/etc/yum.conf</code>.</p>
<p><a href="http://rackerhacker.com/2012/02/04/get-notifications-instead-of-automatic-updates-in-scientific-linux/">Get notifications instead of automatic updates in Scientific Linux</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2012/02/04/get-notifications-instead-of-automatic-updates-in-scientific-linux/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Automatically upgrading to new point releases of Scientific Linux</title>
		<link>http://rackerhacker.com/2011/11/23/automatically-upgrading-to-new-point-releases-of-scientific-linux/</link>
		<comments>http://rackerhacker.com/2011/11/23/automatically-upgrading-to-new-point-releases-of-scientific-linux/#comments</comments>
		<pubDate>Wed, 23 Nov 2011 13:20:12 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[red hat]]></category>
		<category><![CDATA[scientific linux]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=2672</guid>
		<description><![CDATA[When you install Scientific Linux, it will keep you on the same point release that you installed. For example, if you install it from a 6.0 DVD, you'll stay on 6.0 and get security releases for that point release only. Getting it to behave like Red Hat Enterprise Linux and CentOS is a painless process. [...]<p><a href="http://rackerhacker.com/2011/11/23/automatically-upgrading-to-new-point-releases-of-scientific-linux/">Automatically upgrading to new point releases of Scientific Linux</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>When you install Scientific Linux, it will keep you on the same point release that you installed.  For example, if you install it from a 6.0 DVD, you'll stay on 6.0 and get security releases for that point release only.</p>
<p>Getting it to behave like Red Hat Enterprise Linux and CentOS is a painless process.  Just install the <em>sl6x</em> repository with <code>yum</code>:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum install yum-conf-sl6x</pre></div></div>

<p>Check to ensure that you're getting updates from the new repository:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;"># yum repolist
repo id            repo name                                              status
sl                 Scientific Linux 6.1 - x86_64                          6,251
sl-security        Scientific Linux 6.1 - x86_64 - security updates         548
sl6x               Scientific Linux 6x - x86_64                           6,251
sl6x-security      Scientific Linux 6x - x86_64 - security updates          548
repolist: 13,598</pre></div></div>

<p><a href="http://rackerhacker.com/2011/11/23/automatically-upgrading-to-new-point-releases-of-scientific-linux/">Automatically upgrading to new point releases of Scientific Linux</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2011/11/23/automatically-upgrading-to-new-point-releases-of-scientific-linux/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Live upgrade Fedora 15 to Fedora 16 using yum</title>
		<link>http://rackerhacker.com/2011/11/14/live-upgrading-fedora-15-to-fedora-16-using-yum/</link>
		<comments>http://rackerhacker.com/2011/11/14/live-upgrading-fedora-15-to-fedora-16-using-yum/#comments</comments>
		<pubDate>Tue, 15 Nov 2011 04:37:39 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[command line]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[preupgrade]]></category>
		<category><![CDATA[raid]]></category>
		<category><![CDATA[red hat]]></category>
		<category><![CDATA[scientific linux]]></category>
		<category><![CDATA[sysadmin]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=2623</guid>
		<description><![CDATA[Before we get started, I really ought to drop this here: Upgrading Fedora via yum is not the recommended method. Your first choice for upgrading Fedora should be to use preupgrade. Seriously. This begs the question: When should you use another method to upgrade Fedora? What other methods are there? You have a few other [...]<p><a href="http://rackerhacker.com/2011/11/14/live-upgrading-fedora-15-to-fedora-16-using-yum/">Live upgrade Fedora 15 to Fedora 16 using yum</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>Before we get started, I really ought to drop this here:</p>
<blockquote style="color: red; font-weight: bold;"><p>Upgrading Fedora via yum is <u>not</u> the recommended method.  Your first choice for upgrading Fedora should be to use <code>preupgrade</code>.  Seriously.</p></blockquote>
<p><a href="http://rackerhacker.com/wp-content/uploads/2011/11/Logo_fedoralogo.png"><img src="http://rackerhacker.com/wp-content/uploads/2011/11/Logo_fedoralogo-300x91.png" alt="" title="Logo_fedoralogo" width="300" height="91" class="alignright size-medium wp-image-2662" /></a>This begs the question: <em>When should you use another method to upgrade Fedora? What other methods are there?</em></p>
<p>You have a few other methods to get the upgrade done:</p>
<ul>
<li><strong>Toss in a CD or DVD:</strong> You can upgrade via the anaconda installer provided on the CD, DVD or netinstall media.  My experiences with this method for Fedora (as well as CentOS, Scientific Linux, and Red Hat) haven't been too positive, but your results may vary.</li>
<li><strong>Download the newer release's fedora-release RPM, install it with <code>rpm</code>, and <code>yum upgrade</code>:</strong> This is the really old way of doing things.  Don't try this (read the next bullet).</li>
<li><strong>Use <code>yum</code>'s distro-sync functionality:</strong> If you can't go the <code>preupgrade</code> route, I'd recommend giving this a try.  However, leave plenty of time to fix small glitches after it's done (and after your first reboot).</li>
</ul>
<p><strong>Personal anecdote time</strong> <em>(Keep scrolling for the meat and potatoes)</em><br />
I have a dedicated server at <a href="http://joesdatacenter.com/">Joe's Datacenter</a> (love those folks) with IPMI and KVM-over-LAN access.  The <code>preupgrade</code> method won't work for me because my <code>/boot</code> partition is on a software RAID volume.  There's a <a href="https://bugzilla.redhat.com/show_bug.cgi?id=504826">rat's nest of a Bugzilla ticket</a> over on Red Hat's site about this problem.  I'm really only left with a live upgrade using <code>yum</code>.</p>
<p><strong>Live <code>yum</code> upgrade process</strong><br />
Before even beginning the upgrade, I double-checked that I'd applied all of the available updates for my server.  Once that was done, I realized I was one kernel revision behind and I rebooted to ensure I was in the latest Fedora 15 kernel.</p>
<p>A good practice here is to run <code>package-cleanup --orphans</code> (it's in the <code>yum-utils</code> package) to find any packages which don't exist on any Fedora mirrors.  In my case, I had two old kernels and a JungleDisk package.  I removed the two old kernels (probably wasn't necessary) and left JungleDisk alone (it worked fine after the upgrade).  If you have any external repositories, such as Livna or RPMForge, you may want to disable those until the upgrade is done.  Should the initial upgrade checks bomb out, try adding as few repositories back in as possible to see if it clears up the problem.</p>
<p>Once you make it this far, just follow the instructions available in Fedora's documentation: <a href="http://fedoraproject.org/wiki/Upgrading_Fedora_using_yum#Fedora_15_-.3E_Fedora_16">Upgrading Fedora using yum</a>.  I set SELinux to permissive mode during the upgrade just in case it caused problems.</p>
<p>I'd recommend skipping the <code>grub2-install</code> portion since your original grub installation will still be present after the upgrade.  If your server has EFI (not BIOS), <b>don't use</b> <code>grub2</code> yet.  Keep an eye on the previously mentioned documentation page to see if the problems get ironed out between <code>grub2</code> and EFI.</p>
<p><b>Before you reboot,</b> be sure to get a list of your active processes and daemons.  After your reboot, some old SysVinit scripts will be converted into Systemd service scripts.  They might not start automatically and you might need to enable and/or start some services.</p>
<p>New to Systemd? This will be an extremely handy resource: <a href="http://fedoraproject.org/wiki/SysVinit_to_Systemd_Cheatsheet">SysVinit to Systemd Cheatsheet</a>.</p>
<p>I haven't seen too many issues after cleaning up some daemons that didn't start properly.  There is a problem between <code>asterisk</code> and SELinux that I haven't nailed down yet but it's not a showstopper.</p>
<p>Good luck during your upgrades.  Keep in mind that Fedora 15 could be EOL'd as early as May or June 20102 when Fedora 17 is released.</p>
<p><a href="http://rackerhacker.com/2011/11/14/live-upgrading-fedora-15-to-fedora-16-using-yum/">Live upgrade Fedora 15 to Fedora 16 using yum</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2011/11/14/live-upgrading-fedora-15-to-fedora-16-using-yum/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Receive e-mail reports for SELinux AVC denials</title>
		<link>http://rackerhacker.com/2011/09/15/receive-e-mail-reports-for-selinux-avc-denials/</link>
		<comments>http://rackerhacker.com/2011/09/15/receive-e-mail-reports-for-selinux-avc-denials/#comments</comments>
		<pubDate>Fri, 16 Sep 2011 04:17:04 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[command line]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[messagebus]]></category>
		<category><![CDATA[red hat]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[selinux]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[ssh]]></category>
		<category><![CDATA[sysadmin]]></category>
		<category><![CDATA[systemd]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=2537</guid>
		<description><![CDATA[SELinux isn't a technology that's easy to tackle for newcomers. However, there's been a lot of work to smooth out the rough edges while still keeping a tight grip on what applications and users are allowed to do on a Linux system. One of the biggest efforts has been around setroubleshoot. The purpose behind setroubleshoot [...]<p><a href="http://rackerhacker.com/2011/09/15/receive-e-mail-reports-for-selinux-avc-denials/">Receive e-mail reports for SELinux AVC denials</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>SELinux isn't a technology that's easy to tackle for newcomers.  However, there's been a lot of work to smooth out the rough edges while still keeping a tight grip on what applications and users are allowed to do on a Linux system.  One of the biggest efforts has been around <a href="https://fedorahosted.org/setroubleshoot/wiki/SETroubleShoot%20Overview">setroubleshoot</a>.</p>
<p>The purpose behind setroubleshoot is to let users know when access has been denied, help them resolve it if necessary, and to reduce overall frustration while working through tight security restrictions in the default SELinux policies.  The GUI frontend for setroubleshoot is great for users who run Linux desktops or those who run servers with a display attached.  Don't worry, you can configure setroubleshoot on remote servers to send alerts elsewhere when a GUI alert isn't an option.</p>
<p>Install a few packages to get started:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum install setroubleshoot{-server,-plugins,-doc}</pre></div></div>

<p>Open <code>/etc/setroubleshoot/setroubleshoot.conf</code> in your favorite text editor and adjust the <code>[email]</code> section to fit your server:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">recipients_filepath = /var/lib/setroubleshoot/email_alert_recipients
smtp_port = 25
smtp_host = localhost
from_address = selinux@myserver.com
subject = [MyServer] SELinux AVC Alert</pre></div></div>

<p>You could probably see it coming, but you need to put the e-mail addresses for your recipients into <code>/var/lib/setroubleshoot/email_alert_recipients</code>:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">echo &quot;selinux@mycompany.com&quot; &gt;&gt; /var/lib/setroubleshoot/email_alert_recipients</pre></div></div>

<p>You'll notice that setroubleshoot doesn't have an init script and it doesn't exist in systemd in Fedora 15.  It runs through the <a href="http://en.wikipedia.org/wiki/D-Bus">dbus-daemon</a> and a quick bounce of the messagebus via its init script brings in the necessary components to run setroubleshoot:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">service messagebus restart</pre></div></div>

<p>A really easy (and safe) test is to ask sshd to bind to a non-standard port.  Simply define an additional port on in your <code>/etc/ssh/sshd_config</code> like this:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">Port 22
Port 222</pre></div></div>

<p>When you restart sshd, it will bind to port 22 with success, but it won't be allowed to bind to port 222 (since that's blocked by SELinux as a non-standard port for the <code>ssh_port_t</code> port type).  <strong>DON'T WORRY!</strong> Your sshd server will still be listening on port 22.  If you wait a moment, you'll get an e-mail (perhaps two) that not only notify you of the denial, but they make suggestions for how to fix it:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">SELinux is preventing /usr/sbin/sshd from name_bind access on the tcp_socket port 222.
&nbsp;
*****  Plugin bind_ports (99.5 confidence) suggests  *************************
&nbsp;
If you want to allow /usr/sbin/sshd to bind to network port 222
Then you need to modify the port type.
Do
# semanage port -a -t PORT_TYPE -p tcp 222
   where PORT_TYPE is one of the following: ...</pre></div></div>

<p>For this particular example, the quick fix would be to run:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">semanage port -a -t ssh_port_t -p tcp 222</pre></div></div>

<hr />
<em><br />
Much of this post's information was gathered from the detailed documentation on <a href="http://fedoraproject.org/wiki/Docs/Drafts/SELinux/SETroubleShoot/UserFAQ">Fedora's setroubleshoot User's FAQ</a> as well as <a href="http://danwalsh.livejournal.com/20931.html">Dan Walsh's setroubleshoot blog post</a>.<br />
</em></p>
<p><a href="http://rackerhacker.com/2011/09/15/receive-e-mail-reports-for-selinux-avc-denials/">Receive e-mail reports for SELinux AVC denials</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2011/09/15/receive-e-mail-reports-for-selinux-avc-denials/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Keep all old kernels when upgrading via yum</title>
		<link>http://rackerhacker.com/2011/06/16/keep-all-old-kernels-when-upgrading-via-yum/</link>
		<comments>http://rackerhacker.com/2011/06/16/keep-all-old-kernels-when-upgrading-via-yum/#comments</comments>
		<pubDate>Thu, 16 Jun 2011 12:50:46 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[command line]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[red hat]]></category>
		<category><![CDATA[sysadmin]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=2336</guid>
		<description><![CDATA[Some might call me paranoid, but I get nervous when my package manager automatically removes a kernel. I logged into my Fedora 15 VM this morning and found this: ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: kernel x86_64 2.6.35.13-92.fc14 updates 22 M Removing: kernel x86_64 2.6.35.11-83.fc14 @updates 104 M &#160; Transaction Summary ================================================================================ Install [...]<p><a href="http://rackerhacker.com/2011/06/16/keep-all-old-kernels-when-upgrading-via-yum/">Keep all old kernels when upgrading via yum</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>Some might call me paranoid, but I get nervous when my package manager automatically removes a kernel.  I logged into my Fedora 15 VM this morning and found this:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">================================================================================
 Package        Arch           Version                   Repository        Size
================================================================================
Installing:
 kernel         x86_64         2.6.35.13-92.fc14         updates           22 M
Removing:
 kernel         x86_64         2.6.35.11-83.fc14         @updates         104 M
&nbsp;
Transaction Summary
================================================================================
Install       1 Package(s)
Remove        1 Package(s)</pre></div></div>

<p>Fedora 15's default behavior is to keep three kernels: the latest one and the two previous versions.  However, this behavior may be counter-productive if you compile your own modules, or if you have compatibility issues with subsequent kernel versions.</p>
<p>You can change how yum handles kernel packages with some simple changes to your <code>/etc/yum.conf</code>.  The <code>installonly_limit</code> option controls how many old packages are kept:</p>
<blockquote><p><strong>installonly_limit</strong> Number of packages listed  in  installonlypkgs to  keep  installed at the same time. Setting to 0 disables this feature. Default is '0'.</p></blockquote>
<p>I disabled the functionality altogether by setting <code>installonly_limit</code> to 0:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">#installonly_limit=3
installonly_limit=0</pre></div></div>

<p>It's important to keep in mind that you will need to purge these packages from your system yourself now.  Kernel packages can occupy a fair amount of disk space, so make a note to go back and clean them up when you no longer need them.</p>
<p><a href="http://rackerhacker.com/2011/06/16/keep-all-old-kernels-when-upgrading-via-yum/">Keep all old kernels when upgrading via yum</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2011/06/16/keep-all-old-kernels-when-upgrading-via-yum/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Locate RPM packages which contain a certain file</title>
		<link>http://rackerhacker.com/2010/12/08/locate-rpm-packages-which-contain-a-certain-file/</link>
		<comments>http://rackerhacker.com/2010/12/08/locate-rpm-packages-which-contain-a-certain-file/#comments</comments>
		<pubDate>Thu, 09 Dec 2010 02:30:00 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[red hat]]></category>
		<category><![CDATA[rpm]]></category>
		<category><![CDATA[sysadmin]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=2040</guid>
		<description><![CDATA[It's not easy remembering which RPM packages contain certain files. If I asked you which files you'd find in packages like postfix-2.7.1-1.fc14 and bash-4.1.7-3.fc14, you would be able to name some obvious executables. However, would you be able to do the same if I mentioned a package like util-linux-ng-2.18-4.6.fc14? If the RPM is already installed, [...]<p><a href="http://rackerhacker.com/2010/12/08/locate-rpm-packages-which-contain-a-certain-file/">Locate RPM packages which contain a certain file</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>It's not easy remembering which RPM packages contain certain files.  If I asked you which files you'd find in packages like <code>postfix-2.7.1-1.fc14</code> and <code>bash-4.1.7-3.fc14</code>, you would be able to name some obvious executables.  However, would you be able to do the same if I mentioned a package like <code>util-linux-ng-2.18-4.6.fc14</code>?  If the RPM is already installed, you can quickly use <code>rpm -ql</code> to list the files within it.</p>
<p>However, what if the RPM isn't installed already?  How do you figure out which one to install?</p>
<p>Fedora has well over 20,000 packages in the standard repositories without adding additional repositories like RPM Fusion.  Narrowing that list down to find the package you want can be daunting, but you can use yum to help.</p>
<p>Consider this: you're following a guide online and the author says you need to run <code>deallocvt</code>:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;"># deallocvt
-bash: deallocvt: command not found</pre></div></div>

<p>Perhaps it's in a package with <code>deallocvt</code> in the name:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;"># yum search deallocvt
Warning: No matches found for: deallocvt
No Matches found</pre></div></div>

<p>This is where yum's <code>whatprovides</code> (<code>provides</code> works in recent yum versions) command works really well:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;"># yum whatprovides */deallocvt
kbd-1.15-11.fc14.x86_64 : Tools for configuring the console
Repo        : fedora
Matched from:
Filename    : /usr/bin/deallocvt</pre></div></div>

<p>From there, you can install the <code>kbd</code> RPM package via yum and you'll be on your way.</p>
<p><em>Author's note: Regular readers will probably think this is pretty basic, but I often find people who don't know this functionality exists in yum.</em></p>
<p><strong>UPDATE:</strong> I forgot to include another handy command in this article (thanks to Jason Gill for reminding me).  If you have file on your system already, but you need to know which RPM package it came from, you can do this very quickly:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;"># rpm -qf /usr/bin/free
procps-3.2.8-14.fc14.x86_64</pre></div></div>

<p><a href="http://rackerhacker.com/2010/12/08/locate-rpm-packages-which-contain-a-certain-file/">Locate RPM packages which contain a certain file</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2010/12/08/locate-rpm-packages-which-contain-a-certain-file/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Tap into your Linux system with SystemTap</title>
		<link>http://rackerhacker.com/2010/12/07/tap-into-your-linux-system-with-systemtap/</link>
		<comments>http://rackerhacker.com/2010/12/07/tap-into-your-linux-system-with-systemtap/#comments</comments>
		<pubDate>Wed, 08 Dec 2010 02:27:02 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[advanced]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[command line]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[red hat]]></category>
		<category><![CDATA[sysadmin]]></category>
		<category><![CDATA[systemtap]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=2005</guid>
		<description><![CDATA[One of the most interesting topics I've seen so far during my RHCA training at Rackspace this week is SystemTap. In short, SystemTap allows you to dig out a bunch of details about your running system relatively easily. It takes scripts, converts them to C, builds a kernel module, and then runs the code within [...]<p><a href="http://rackerhacker.com/2010/12/07/tap-into-your-linux-system-with-systemtap/">Tap into your Linux system with SystemTap</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>One of the most interesting topics I've seen so far during my <a href="https://www.redhat.com/courses/rh442_red_hat_enterprise_system_monitoring_and_performance_tuning/">RHCA</a> training at <a href="http://rackspace.com/">Rackspace</a> this week is <a href="http://sourceware.org/systemtap/">SystemTap</a>.  In short, SystemTap allows you to dig out a bunch of details about your running system relatively easily.  It takes scripts, converts them to C, builds a kernel module, and then runs the code within your script.</p>
<p><strong><span style="color: #D42020;">HOLD IT:</span> The steps below are <em>definitely</em> not meant for those who are new to Linux.  Utilizing SystemTap on a production system is a bad idea -- it can chew up significant resources while it runs and it can also cause a running system to kernel panic if you're not careful with the packages you install.</strong></p>
<p>These instructions will work well with Fedora, CentOS and Red Hat Enterprise Linux.  Luckily, the SystemTap folks put together some instructions for <a href="http://sourceware.org/systemtap/wiki/SystemtapOnDebian">Debian</a> and <a href="http://sourceware.org/systemtap/wiki/SystemtapOnUbuntu">Ubuntu</a> as well.</p>
<p>Before you can start working with SystemTap on your RPM-based distribution, you'll need to get some prerequisites together:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum install gcc systemtap systemtap-runtime systemtap-testsuite kernel-devel
yum --enablerepo=*-debuginfo install kernel-debuginfo kernel-debuginfo-common</pre></div></div>

<p><strong><span style="color: #D42020;">WHOA THERE:</span> Ensure that the kernel-devel and kernel-debuginfo* packages that you install via yum match up with your running kernel.  If there's a newer kernel available from your yum repo, yum will pull that one.  If it's been a while since you updated, you'll either need to upgrade your current kernel to the latest and reboot or you'll need to hunt down the corresponding kernel-devel and kernel-debuginfo* packages from a repository.  <em>Installing the wrong package version can lead to kernel panics.</em>  Also, bear in mind that the debuginfo packages are quite large: almost 200MB in Red Hat/CentOS and almost 300MB in Fedora.</strong></p>
<p>You can't write the script in just any language.  SystemTap uses an odd syntax to get things going:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">#! /usr/bin/env stap
probe begin { println(&quot;hello world&quot;) exit () }</pre></div></div>

<p>Just run the script with <code>stap</code>:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;"># stap -v helloworld.stp 
Pass 1: parsed user script and 73 library script(s) using 94380virt/21988res/2628shr kb, in 140usr/30sys/167real ms.
Pass 2: analyzed script: 1 probe(s), 1 function(s), 0 embed(s), 0 global(s) using 94776virt/22516res/2692shr kb, in 10usr/0sys/5real ms.
Pass 3: using cached /root/.systemtap/cache/bc/stap_bc368822da380b943d4e845ee15ed047_773.c
Pass 4: using cached /root/.systemtap/cache/bc/stap_bc368822da380b943d4e845ee15ed047_773.ko
Pass 5: starting run.
hello world
Pass 5: run completed in 0usr/20sys/285real ms.</pre></div></div>

<p>The <code>systemtap-testsuite</code> package gives you a <strong>tubload</strong> of extremely handy SystemTap scripts.  For example:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;"># cd /usr/share/systemtap/testsuite/systemtap.examples/io/
# stap iotime.stp
15138470 6351 (httpd) access /usr/share/cacti/index.php read: 0 write: 0
15142243 6351 (httpd) access /usr/share/cacti/include/auth.php read: 0 write: 0
15143780 6351 (httpd) access /usr/share/cacti/include/global.php read: 0 write: 0
15144099 6351 (httpd) access /etc/cacti/db.php read: 0 write: 0
15187641 6351 (httpd) access /usr/share/cacti/lib/adodb/adodb.inc.php read: 106486 write: 0
15187664 6351 (httpd) iotime /usr/share/cacti/lib/adodb/adodb.inc.php time: 218
15194965 6351 (httpd) access /usr/share/cacti/lib/adodb/adodb-time.inc.php read: 0 write: 0
15195692 6351 (httpd) access /usr/share/cacti/lib/adodb/adodb-iterator.inc.php read: 0 write: 0
   ... output continues ...</pre></div></div>

<p>The <code>iotime.stp</code> script dumps out the reads and writes occurring on the system in real time.  After starting the script above, I accessed my cacti instance on the server and immediately started seeing some reads as apache began picking up PHP files to parse.</p>
<p>Consider a situation in which you need to decrease interrupts on a Linux machine.  This is vital for laptops and systems that need to remain in low power states.  Some might suggest powertop<a href="http://www.lesswatts.org/projects/powertop/"> for that, but why not give SystemTap a try?</a></p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;"># cd /usr/share/systemtap/testsuite/systemtap.examples/interrupt/
# stap interrupts-by-dev.stp 
        ohci_hcd:usb3 :      1
        ohci_hcd:usb4 :      1
            hda_intel :      1
                 eth0 :      2
                 eth0 :      2
                 eth0 :      2
                 eth0 :      2
                 eth0 :      2
                 eth0 :      2</pre></div></div>

<p>On this particular system, it's pretty obvious that the ethernet interface is causing a lot of interrupts.</p>
<p>If you want more examples, keep hunting around in the systemtap-testsuite package (remember <code>rpm -ql systemtap-testsuite</code>) or review the <a href="http://sourceware.org/systemtap/examples/">giant list of examples</a> on SystemTap's site.</p>
<p><em>Thanks again to Phil Hopkins at Rackspace for giving us a detailed explanation of system profiling during training.</em></p>
<p><a href="http://rackerhacker.com/2010/12/07/tap-into-your-linux-system-with-systemtap/">Tap into your Linux system with SystemTap</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2010/12/07/tap-into-your-linux-system-with-systemtap/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Upgrading Fedora 13 to Fedora 14 on Slicehost and Rackspace Cloud Servers</title>
		<link>http://rackerhacker.com/2010/11/03/upgrading-fedora-13-to-fedora-14-on-slicehost-and-rackspace-cloud-servers/</link>
		<comments>http://rackerhacker.com/2010/11/03/upgrading-fedora-13-to-fedora-14-on-slicehost-and-rackspace-cloud-servers/#comments</comments>
		<pubDate>Wed, 03 Nov 2010 20:02:45 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[cloud servers]]></category>
		<category><![CDATA[command line]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[rackspace]]></category>
		<category><![CDATA[rpm]]></category>
		<category><![CDATA[slicehost]]></category>
		<category><![CDATA[sysadmin]]></category>
		<category><![CDATA[xen]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=1840</guid>
		<description><![CDATA[On most systems, using Fedora's preupgrade package is the most reliable way to update to the next Fedora release. However, this isn't the case with Slicehost and Rackspace Cloud Servers. Here are the steps for an upgrade from Fedora 13 to Fedora 14 via yum: yum -y upgrade wget http://mirror.rackspace.com/fedora/releases/14/Fedora/x86_64/os/Packages/fedora-release-14-1.noarch.rpm rpm -Uvh fedora-release-14-1.noarch.rpm yum -y [...]<p><a href="http://rackerhacker.com/2010/11/03/upgrading-fedora-13-to-fedora-14-on-slicehost-and-rackspace-cloud-servers/">Upgrading Fedora 13 to Fedora 14 on Slicehost and Rackspace Cloud Servers</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>On most systems, using Fedora's <a href="http://fedoraproject.org/wiki/PreUpgrade">preupgrade</a> package is the most reliable way to update to the next Fedora release.  However, this isn't the case with Slicehost and Rackspace Cloud Servers.</p>
<p>Here are the steps for an upgrade from Fedora 13 to Fedora 14 via yum:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum -y upgrade
wget http://mirror.rackspace.com/fedora/releases/14/Fedora/x86_64/os/Packages/fedora-release-14-1.noarch.rpm
rpm -Uvh fedora-release-14-1.noarch.rpm
yum -y install yum
yum -y upgrade</pre></div></div>

<p>If you happen to be upgrading a 32-bit instance on Slicehost, simply replace <code>x86_64</code> with <code>i386</code> in the url shown above.</p>
<p><a href="http://rackerhacker.com/2010/11/03/upgrading-fedora-13-to-fedora-14-on-slicehost-and-rackspace-cloud-servers/">Upgrading Fedora 13 to Fedora 14 on Slicehost and Rackspace Cloud Servers</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2010/11/03/upgrading-fedora-13-to-fedora-14-on-slicehost-and-rackspace-cloud-servers/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>A simple guide to redundant cloud hosting</title>
		<link>http://rackerhacker.com/2010/08/17/a-simple-guide-to-redundant-cloud-hosting/</link>
		<comments>http://rackerhacker.com/2010/08/17/a-simple-guide-to-redundant-cloud-hosting/#comments</comments>
		<pubDate>Wed, 18 Aug 2010 00:41:16 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[cloud servers]]></category>
		<category><![CDATA[command line]]></category>
		<category><![CDATA[database]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[filesystem]]></category>
		<category><![CDATA[high availability]]></category>
		<category><![CDATA[iptables]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[load balancing]]></category>
		<category><![CDATA[mysql]]></category>
		<category><![CDATA[network]]></category>
		<category><![CDATA[networking]]></category>
		<category><![CDATA[optimization]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[rackspace]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[slicehost]]></category>
		<category><![CDATA[ssl]]></category>
		<category><![CDATA[sysadmin]]></category>
		<category><![CDATA[web]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=1771</guid>
		<description><![CDATA[Today, on my 28th birthday, I'm finally delivering on a promise to my readers which I made about two months ago. I've written a guide on how to host a web application redundantly in a cloud environment. While it's still a bit of a rough draft, it should be a good starting point for those [...]<p><a href="http://rackerhacker.com/2010/08/17/a-simple-guide-to-redundant-cloud-hosting/">A simple guide to redundant cloud hosting</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>Today, on my 28th birthday, I'm finally delivering on a promise to my readers which I made about two months ago.  I've <a href="/redundant-cloud-hosting-configuration-guide/">written a guide</a> on how to host a web application redundantly in a cloud environment.  While it's still a bit of a rough draft, it should be a good starting point for those who haven't worked in virtualized environments before.  Also, it may show some of the more experienced systems administrators a new way to do things.</p>
<p>The guide: <a href="/redundant-cloud-hosting-configuration-guide/">Redundant Cloud Hosting Guide</a></p>
<p>As always, if you find anything in the guide that needs improvement, I'm all ears. <img src='http://rackerhacker.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p><a href="http://rackerhacker.com/2010/08/17/a-simple-guide-to-redundant-cloud-hosting/">A simple guide to redundant cloud hosting</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2010/08/17/a-simple-guide-to-redundant-cloud-hosting/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Upgrading Fedora 11 to 12 using yum</title>
		<link>http://rackerhacker.com/2009/12/07/upgrading-fedora-11-to-12-using-yum/</link>
		<comments>http://rackerhacker.com/2009/12/07/upgrading-fedora-11-to-12-using-yum/#comments</comments>
		<pubDate>Tue, 08 Dec 2009 02:28:06 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[rpm]]></category>
		<category><![CDATA[upgrade]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=1055</guid>
		<description><![CDATA[As with the Fedora 10 to 11 upgrade, you can upgrade Fedora 11 to Fedora 12 using yum. I find this to be the easiest and most reliable way to upgrade a Fedora installation whether you use it as a server or desktop. To reduce the total data downloaded, I'd recommend installing the yum-presto package [...]<p><a href="http://rackerhacker.com/2009/12/07/upgrading-fedora-11-to-12-using-yum/">Upgrading Fedora 11 to 12 using yum</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>As with the <a href="/2009/06/11/upgrading-from-fedora-10-cambridge-to-fedora-11-leonidas/">Fedora 10 to 11 upgrade</a>, you can upgrade Fedora 11 to Fedora 12 using yum.  I find this to be the easiest and most reliable way to upgrade a Fedora installation whether you use it as a server or desktop.</p>
<p>To reduce the total data downloaded, I'd recommend installing the <code>yum-presto</code> package first.  It downloads delta RPM's and builds them on the fly, which allows you to upgrade packages without having to download the entire RPM's.</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum install yum-presto</pre></div></div>

<p>Now, upgrade your current system to the latest packages and clean up yum's metadata:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum upgrade
yum clean all</pre></div></div>

<p>Get the latest <code>fedora-release</code> package and install it (replace <b>x86_64</b> with <b>x86</b> if you're using a 32-bit system):</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">wget ftp://download.fedora.redhat.com/pub/fedora/linux/releases/12/Fedora/x86_64/os/Packages/fedora-release-*.noarch.rpm
rpm -Uvh fedora-release-*.rpm</pre></div></div>

<p>Now, upgrade your system to Fedora 12:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum upgrade</pre></div></div>

<blockquote><p>For detailed documentation on the entire process, refer to <a href="http://fedoraproject.org/wiki/YumUpgradeFaq">Fedora using yum</a> on the FedoraProject Wiki.</p></blockquote>
<p><a href="http://rackerhacker.com/2009/12/07/upgrading-fedora-11-to-12-using-yum/">Upgrading Fedora 11 to 12 using yum</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2009/12/07/upgrading-fedora-11-to-12-using-yum/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fedora 11 httpd: alloc_listener: failed to get a socket for (null)</title>
		<link>http://rackerhacker.com/2009/08/14/fedora-11-httpd-alloc_listener-failed-to-get-a-socket-for-null/</link>
		<comments>http://rackerhacker.com/2009/08/14/fedora-11-httpd-alloc_listener-failed-to-get-a-socket-for-null/#comments</comments>
		<pubDate>Fri, 14 Aug 2009 17:14:02 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[emergency]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[kernel]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=981</guid>
		<description><![CDATA[If you use Fedora 11 in a virtualized environment, you may have seen this error recently if you've updated to apr-1.3.8-1: [root@f11 ~]# /etc/init.d/httpd start Starting httpd: [Fri Aug 14 17:05:24 2009] [crit] (22)Invalid argument: alloc_listener: failed to get a socket for (null) Syntax error on line 134 of /etc/httpd/conf/httpd.conf: Listen setup failed [FAILED] The [...]<p><a href="http://rackerhacker.com/2009/08/14/fedora-11-httpd-alloc_listener-failed-to-get-a-socket-for-null/">Fedora 11 httpd: alloc_listener: failed to get a socket for (null)</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>If you use Fedora 11 in a virtualized environment, you may have seen this error recently if you've updated to apr-1.3.8-1:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">[root@f11 ~]# /etc/init.d/httpd start
Starting httpd: [Fri Aug 14 17:05:24 2009] [crit] (22)Invalid argument: alloc_listener: failed to get a socket for (null)
Syntax error on line 134 of /etc/httpd/conf/httpd.conf:
Listen setup failed
                                                           [FAILED]</pre></div></div>

<p>The issue is related to three kernel calls that are used in apr-1.3.8-1: accept4(), dup3() and epoll_create1().  Without these calls, apache is unable to start.  </p>
<p><strong><u>Update on August 17, 2009:</u> the Fedora team has <a href="https://bugzilla.redhat.com/show_bug.cgi?id=516331#c12">pushed apr-1.3.8-2 into the stable repositories</a> for Fedora 11, which eliminates the need for the temporary fix shown below.</strong></p>
<p><strong>Deprecated solution:</strong> There is a <a href="https://bugzilla.redhat.com/show_bug.cgi?id=516331">bug open</a> with the Fedora team, and there is a <a href="https://bugzilla.redhat.com/show_bug.cgi?id=516331#c10">temporary fix</a> available:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum --enablerepo=updates-testing update apr</pre></div></div>

<p><a href="http://rackerhacker.com/2009/08/14/fedora-11-httpd-alloc_listener-failed-to-get-a-socket-for-null/">Fedora 11 httpd: alloc_listener: failed to get a socket for (null)</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2009/08/14/fedora-11-httpd-alloc_listener-failed-to-get-a-socket-for-null/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Upgrading from Fedora 10 (Cambridge) to Fedora 11 (Leonidas)</title>
		<link>http://rackerhacker.com/2009/06/11/upgrading-from-fedora-10-cambridge-to-fedora-11-leonidas/</link>
		<comments>http://rackerhacker.com/2009/06/11/upgrading-from-fedora-10-cambridge-to-fedora-11-leonidas/#comments</comments>
		<pubDate>Thu, 11 Jun 2009 17:48:39 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[rpm]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/?p=894</guid>
		<description><![CDATA[There are two main ways to upgrade Fedora 10 (Cambridge) to Fedora 11 (Leonidas): &#187; What the Fedora developers suggest: yum -y upgrade yum -y install preupgrade yum clean all preupgrade-cli &#34;Fedora 11 (Leonidas)&#34; Of course, if you're doing this on a Fedora desktop, you can use preupgrade (rather than preupgrade-cli) to upgrade with a [...]<p><a href="http://rackerhacker.com/2009/06/11/upgrading-from-fedora-10-cambridge-to-fedora-11-leonidas/">Upgrading from Fedora 10 (Cambridge) to Fedora 11 (Leonidas)</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>There are two main ways to upgrade Fedora 10 (Cambridge) to Fedora 11 (Leonidas):</p>
<p><strong>&raquo; What the Fedora developers suggest:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum -y upgrade
yum -y install preupgrade
yum clean all
preupgrade-cli &quot;Fedora 11 (Leonidas)&quot;</pre></div></div>

<p>Of course, if you're doing this on a Fedora desktop, you can use <code>preupgrade</code> (rather than <em>preupgrade-cli</em>) to upgrade with a GUI.</p>
<p><strong>&raquo; The method I prefer (and it works properly on <a href="http://slicehost.com/">Slicehost</a>):</strong></p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum -y upgrade
yum clean all
wget http://download.fedora.redhat.com/pub/fedora/linux/releases/11/Fedora/x86_64/os/Packages/fedora-release-11-1.noarch.rpm
rpm -Uvh fedora-release-11-1.noarch.rpm</pre></div></div>

<p>At this point, you would normally just start upgrading packages, but the Fedora developers threw us a curveball.  Since yum in Fedora 10 doesn't support metalinks, your upgrades will fail with something like this:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;"># yum -y upgrade
YumRepo Error: All mirror URLs are not using ftp, http[s] or file.
 Eg. /
removing mirrorlist with no valid mirrors: //var/cache/yum/updates/mirrorlist.txt
Error: Cannot retrieve repository metadata (repomd.xml) for repository: updates. Please verify its path and try again</pre></div></div>

<p>It's easily fixed, however.  Open up <code>/etc/yum.repos.d/fedora.repo</code> and <code>/etc/yum.repos.d/fedora-updates.repo</code> in your favorite text editor and change the <code>mirrorlist</code> URL's like so:</p>
<p><strong>Fedora Repository</strong></p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">#mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=fedora-$releasever&amp;arch=$basearch
mirrorlist=https://mirrors.fedoraproject.org/mirrorlist?repo=fedora-$releasever&amp;arch=$basearch</pre></div></div>

<p><strong>Fedora Updates Repository</strong></p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">#mirrorlist=https://mirrors.fedoraproject.org/metalink?repo=updates-released-f$releasever&amp;arch=$basearch
mirrorlist=https://mirrors.fedoraproject.org/mirrorlist?repo=updates-released-f$releasever&amp;arch=$basearch</pre></div></div>

<p>Once you make those changes, finish out the upgrade:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">yum -y upgrade</pre></div></div>

<p>This process will take a little while to complete, but there shouldn't be any interaction required.  Once it's done, change the <code>mirrorlist</code> lines back to the original values so you can benefit from the speedups provided by the metalink format.</p>
<p><a href="http://rackerhacker.com/2009/06/11/upgrading-from-fedora-10-cambridge-to-fedora-11-leonidas/">Upgrading from Fedora 10 (Cambridge) to Fedora 11 (Leonidas)</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2009/06/11/upgrading-from-fedora-10-cambridge-to-fedora-11-leonidas/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>rpmdb: Lock table is out of available locker entries</title>
		<link>http://rackerhacker.com/2007/05/27/rpmdb-lock-table-is-out-of-available-locker-entries/</link>
		<comments>http://rackerhacker.com/2007/05/27/rpmdb-lock-table-is-out-of-available-locker-entries/#comments</comments>
		<pubDate>Sun, 27 May 2007 16:38:32 +0000</pubDate>
		<dc:creator>Major Hayden</dc:creator>
				<category><![CDATA[Blog Posts]]></category>
		<category><![CDATA[bdb]]></category>
		<category><![CDATA[command line]]></category>
		<category><![CDATA[emergency]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[python]]></category>
		<category><![CDATA[red hat]]></category>
		<category><![CDATA[rpm]]></category>
		<category><![CDATA[up2date]]></category>
		<category><![CDATA[yum]]></category>

		<guid isPermaLink="false">http://rackerhacker.com/2007/05/27/rpmdb-lock-table-is-out-of-available-locker-entries/</guid>
		<description><![CDATA[If up2date throws some horrible Python errors and rpm says "rpmdb: Lock table is out of available locker entries", you can restore your system to normality with the following: The errors: rpmdb: Lock table is out of available locker entries error: db4 error(22) from db-&#62;close: Invalid argument error: cannot open Packages index using db3 - [...]<p><a href="http://rackerhacker.com/2007/05/27/rpmdb-lock-table-is-out-of-available-locker-entries/">rpmdb: Lock table is out of available locker entries</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></description>
			<content:encoded><![CDATA[<p>If up2date throws some horrible Python errors and rpm says "rpmdb: Lock table is out of available locker entries", you can restore your system to normality with the following:</p>
<p>The errors:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">rpmdb: Lock table is out of available locker entries
error: db4 error(22) from db-&gt;close: Invalid argument
error: cannot open Packages index using db3 - Cannot allocate memory (12)
error: cannot open Packages database in /var/lib/rpm</pre></div></div>

<p>Make a backup of /var/lib/rpm in case you break something:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">tar cvzf rpmdb-backup.tar.gz /var/lib/rpm</pre></div></div>

<p>Remove the Berkeley databases that rpm uses:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">rm /var/lib/rpm/__db.00*</pre></div></div>

<p>Make rpm rebuild the databases from scratch (may take a short while):</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">rpm --rebuilddb</pre></div></div>

<p>Now, check rpm to make sure everything is okay:</p>

<div class="wp_syntax"><div class="code"><pre class="html" style="font-family:monospace;">rpm -qa | sort</pre></div></div>

<p><b>Why does this happen?</b><br />
When rpm accesses the Berkeley database files, it makes temporary locker entries within the tables while it searches for data.  If you control-c your rpm processes often, this issue will occur much sooner because the locks are never cleared.</p>
<p><a href="http://rackerhacker.com/2007/05/27/rpmdb-lock-table-is-out-of-available-locker-entries/">rpmdb: Lock table is out of available locker entries</a> is a post from: Major Hayden's <a href="http://rackerhacker.com">Racker Hacker</a> blog. 
<p>Thanks for following the blog via the RSS feed. Please don't copy my posts or quote portions of them without attribution.</p></p>
]]></content:encoded>
			<wfw:commentRss>http://rackerhacker.com/2007/05/27/rpmdb-lock-table-is-out-of-available-locker-entries/feed/</wfw:commentRss>
		<slash:comments>58</slash:comments>
		</item>
	</channel>
</rss>

