<?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>Magoo &#187; Linux</title>
	<atom:link href="http://morgangoose.com/blog/category/the-operating-system/feed/" rel="self" type="application/rss+xml" />
	<link>http://morgangoose.com/blog</link>
	<description>affiliated with the society of blog bloggables</description>
	<lastBuildDate>Thu, 03 Jun 2010 12:58:38 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Fedora KVM with simple network forwards</title>
		<link>http://morgangoose.com/blog/2010/06/fedora-kvm-with-simple-network-forwards/</link>
		<comments>http://morgangoose.com/blog/2010/06/fedora-kvm-with-simple-network-forwards/#comments</comments>
		<pubDate>Thu, 03 Jun 2010 03:52:43 +0000</pubDate>
		<dc:creator>Morgan</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Webservers]]></category>

		<guid isPermaLink="false">http://morgangoose.com/blog/2010/06/fedora-kvm-with-simple-netowrk-forward/</guid>
		<description><![CDATA[Recently I&#8217;ve been teaching python to some high school students. It has been going well, but the development environment we had access to left a little bit to be desired. We were working with ages old solaris, vi only, and no real access to newer gnu (or other) tools. So a new setup was required, [...]]]></description>
			<content:encoded><![CDATA[<p>Recently I&#8217;ve been teaching python to some high school students. It has been going well, but the development environment we had access to left a little bit to be desired. We were working with ages old solaris, vi only, and no real access to newer gnu (or other) tools. So a new setup was required, I went off to investigate.</p>
<p>I started with chroot, since a buddy, Daniel Thau, had used it extensively for running <a href="http://opensource.osu.edu/sites/default/files/chroottalk_0.pdf">multiple operating systems side by side</a>. He&#8217;d pointed me in the directions of <a href="http://people.redhat.com/~rjones/febootstrap/" target="_blank">febootstrap</a> and that seemed like it&#8217;d work fine. I was able to make a sandbox, get ssh running on 2022 and then have my dlink route that to my box. Success!</p>
<p>But I found that a bit messy, and a bit limited. I wanted to lock down how much of my resources they could use, and I didn&#8217;t want to have to give access to some of my root file systems directly; /proc, /dev, etc. So I looked around a bit more, and stumbled on using KVM indirectly via the new virt-manager toolset that fedora 12 and 13 provide. Installation was as simple as:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">yum <span style="color: #c20cb9; font-weight: bold;">install</span> qemu-kvm virt-manager virt-viewer python-virtinst</div></div>
<p>But it also seems that from the <a href="http://www.techotopia.com/index.php/Installing_and_Configuring_Fedora_KVM_Virtualization">techotopia article</a> I followed for some of this that one could also just do:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">yum groupinstall <span style="color: #ff0000;">'Virtualization'</span></div></div>
<p>I have to say it&#8217;s a pretty swank set of tools. It&#8217;s free, it works on KVM or Xen. KVM usage requires no special kernel and as such, no reboot. The setup was simple, and gave out a vnc port to connect to from the get go. It is also trivial to connect to a setup on machine A with virt-manager on machine B over ssh. If you want more information, <a href="http://fedoraproject.org/wiki/Virtualization_Quick_Start">fedora has a nice writeup</a>, and libvirt has a more <a href="http://wiki.libvirt.org/page/Main_Page">distro agnostic set of docs</a>.</p>
<p>Problem was though that the networking was virtual, and didn&#8217;t pull an IP address from my router, so it wasn&#8217;t public. There were a few sections here and there describing how to switch to bridged, and I tried them. They didn&#8217;t work for me, either I suck at following directions, or they just won&#8217;t work how I expect them to. You can see for yourself <a href="http://wiki.libvirt.org/page/Networking#Fedora.2FRHEL_Bridging">here</a> at how I attempted network bridging.</p>
<p>What I did was much more in my realm of knowledge, is simpler than all the other options, and is something I can make changes to w/o killing my network connectivity. iptables! I just used NAT forwarding. It was 2 lines, put in my pre-existing firewall script. So to get my local box 192.168.1.199 on port 2022 to forward to its internal virtual network of 192.168.100.2 at port 22 was as plain as this:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">iptables <span style="color: #660033;">-t</span> nat <span style="color: #660033;">-I</span> PREROUTING <span style="color: #660033;">-p</span> tcp <span style="color: #660033;">--dport</span> <span style="color: #000000;">2022</span> <span style="color: #660033;">-j</span> DNAT <span style="color: #660033;">--to-destination</span> 192.168.100.2:<span style="color: #000000;">22</span><br />
iptables <span style="color: #660033;">-I</span> FORWARD <span style="color: #660033;">-p</span> tcp <span style="color: #660033;">--dport</span> <span style="color: #000000;">22</span> <span style="color: #660033;">-d</span> 192.168.100.2 <span style="color: #660033;">-j</span> ACCEPT</div></div>
<p>One preroute rule to grab the port incoming, and one forward rule to pass said packets along. Now I have connectivity into my class virtual machine, and I don&#8217;t have to do much to add more ports as needed. I am pretty happy with the setup so far. It&#8217;s really nice to be able to connect remotely, vnc or ssh now, as well as know that I&#8217;ve limited the ram and cpu time the class can use on my box. I am interested to hear if anyone else is doing similar things with virtualization on their desktops.</p>
]]></content:encoded>
			<wfw:commentRss>http://morgangoose.com/blog/2010/06/fedora-kvm-with-simple-network-forwards/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Fedora with awesome window manager</title>
		<link>http://morgangoose.com/blog/2010/05/fedora-with-awesome-window-manager/</link>
		<comments>http://morgangoose.com/blog/2010/05/fedora-with-awesome-window-manager/#comments</comments>
		<pubDate>Sat, 29 May 2010 16:57:56 +0000</pubDate>
		<dc:creator>Morgan</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://morgangoose.com/blog/2010/05/fedora-with-awesome-window-manager/</guid>
		<description><![CDATA[I have recently gotten into tiling window managers. Awesome being the one I&#8217;ve found I like to use the most. There are others and they all have their merits, I just settled on this one, and then got comfortable. I also am a bit of a mutt in what distro&#8217;s I use. Work they put [...]]]></description>
			<content:encoded><![CDATA[<p>I have recently gotten into tiling window managers. Awesome being the one I&#8217;ve found I like to use the most. There are others and they all have their merits, I just settled on this one, and then got comfortable. I also am a bit of a mutt in what distro&#8217;s I use. Work they put ubuntu on my box, home I have usually used fedora but now it&#8217;s fedora on the desktop and arch on the laptop.</p>
<p>So the issue was arch and ubuntu both had awesome in the package repos, and fedora did not. There is discussion out there as to why this was, and you might be interested in it. Me, I just wanted to use awesome. So using the directions from the awesome wiki and grabbing the required source rpms cairo-1.8.8-3.fc12.src.rpm and awesome-3.4.4-1.fc12.src.rpm, I now have awesome on my desktop.</p>
<p><strong>Here are some of the docs and sources I used:</strong></p>
<ul>
<li><a href="http://awesome.naquadah.org/wiki/Awesome-3-fedora">directions from awesome&#8217;s wiki</a></li>
<li><a href="http://mnowak.fedorapeople.org/awesome/">awesome src.rpms for fedora</a></li>
<li><a href="http://rpm.pbone.net/index.php3/stat/26/dist/69/size/6660576/name/cairo-1.8.8-3.fc12.src.rpm">the cario src.rpm</a></li>
<li><a href="https://bugzilla.redhat.com/show_bug.cgi?id=452427">discussion on package inclusion</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://morgangoose.com/blog/2010/05/fedora-with-awesome-window-manager/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How fabric gets it right</title>
		<link>http://morgangoose.com/blog/2010/02/how-fabric-gets-it-right/</link>
		<comments>http://morgangoose.com/blog/2010/02/how-fabric-gets-it-right/#comments</comments>
		<pubDate>Thu, 11 Feb 2010 05:56:33 +0000</pubDate>
		<dc:creator>Morgan</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Tools]]></category>
		<category><![CDATA[fabric]]></category>
		<category><![CDATA[pyohio]]></category>
		<category><![CDATA[python]]></category>
		<category><![CDATA[rst]]></category>

		<guid isPermaLink="false">http://morgangoose.com/blog/?p=76</guid>
		<description><![CDATA[I like fabric. A lot. Its a easy to use tool that continually makes my life simpler, and my projects smarter and more automated. Not much out there can really say that. At least nothing I use daily, without noticing, and dependably. I used to use vellum, and that did what I needed. But fabric [...]]]></description>
			<content:encoded><![CDATA[<p>I like <a href="http://docs.fabfile.org/0.9.0/">fabric</a>. A lot. Its a easy to use tool that continually makes my life simpler, and my projects smarter and more automated. Not much out there can really say that. At least nothing I use daily, without noticing, and dependably.</p>
<p>I used to use vellum, and that did what I needed. But fabric being under active development, and getting new features each version it seems is a huge plus. That and it does the network stuff for you, along with the nitty gritty.</p>
<p>Recently I have been giving presentations to the <a href="http://opensource.osu.edu/">Ohio State University&#8217;s Open Source Club</a> about <a href="http://morgangoose.com/p/gnu_tools/">gnu tools</a>, <a href="http://morgangoose.com/p/tool_oriented_python/">python tools</a>, and soon some cli apps. Fabric really helped make this simple for me to get a whole system down for making and uploading these.</p>
<p>I made all of those presentations in restrctured text, and compiled them into their final formats. All of which was scripted in fabric. I became really attached to ReST after getting introduced to it watching <a href="http://catherinedevlin.pythoneers.com/">Catherine Devlin</a> give a <a href="http://catherinedevlin.pythoneers.com/presentations/rst/olf.html">talk about restructured text</a> at Ohio Linux Fest. I ended up finding a cool rst2s5 command that makes nice presentations and with a little tweaking it now also has syntax highlighted code blocks, and can make nice pdfs.</p>
<p>In starting to use fabric you&#8217;ll notice the basic idea is that you&#8217;d make a fabfile that works a lot like a Makefile or a SConstruct file would, with make and scons respectively. You&#8217;ll make calls with the fab command in the directory the fabfile is located and it will supply the targets.</p>
<p>Below in this example, two targets are made, pack and deploy. The pack target will just makes a tarball, using the local function fabric provides. The deploy target calls pack to make this tarball, then using the put function will place the tarball into the tmp directory, then change into the web dir provided, and extract the archive. It knows automaticly to do this to both hosts I provided, and since I am using an ssh key does all this trickery autonomously.</p>
<p><strong>fabfile.py</strong></p>
<div class="codecolorer-container python vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="python codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #ff7700;font-weight:bold;">from</span> fabric.<span style="color: black;">api</span> <span style="color: #ff7700;font-weight:bold;">import</span> <span style="color: #66cc66;">*</span><br />
<br />
env.<span style="color: #dc143c;">user</span> = <span style="color: #483d8b;">'username'</span><br />
env.<span style="color: black;">hosts</span> = <span style="color: black;">&#91;</span><span style="color: #483d8b;">'host1.com'</span>, <span style="color: #483d8b;">'host2.com'</span><span style="color: black;">&#93;</span><br />
<br />
<span style="color: #ff7700;font-weight:bold;">def</span> pack<span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>:<br />
&nbsp; &nbsp; local<span style="color: black;">&#40;</span><span style="color: #483d8b;">'tar czf /tmp/project_foo.tgz project_foo/'</span>, capture=<span style="color: #008000;">False</span><span style="color: black;">&#41;</span><br />
<br />
<span style="color: #ff7700;font-weight:bold;">def</span> deploy<span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>:<br />
&nbsp; &nbsp; pack<span style="color: black;">&#40;</span><span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; put<span style="color: black;">&#40;</span><span style="color: #483d8b;">'/tmp/project_foo.tgz'</span>, <span style="color: #483d8b;">'/tmp/'</span><span style="color: black;">&#41;</span><br />
<br />
&nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">with</span> <span style="color: #dc143c;">cd</span><span style="color: black;">&#40;</span><span style="color: #483d8b;">'/var/www/foo/'</span><span style="color: black;">&#41;</span>:<br />
&nbsp; &nbsp; &nbsp; &nbsp; run<span style="color: black;">&#40;</span><span style="color: #483d8b;">'tar xzf /tmp/project_foo.tgz'</span><span style="color: black;">&#41;</span></div></div>
<p>Fabric can do a lot more than just this, and its <a href="http://docs.fabfile.org/0.9.0/">docs</a> have a lot of detail, and explain most everything well. </p>
<p>A last example of some a cool fabric config would be the one I use to publish my presentations to this site.</p>
<p><strong>fabfile.py</strong></p>
<div class="codecolorer-container python vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="python codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #808080; font-style: italic;">#!/usr/bin/env python</span><br />
<br />
<span style="color: #ff7700;font-weight:bold;">from</span> fabric.<span style="color: black;">api</span> <span style="color: #ff7700;font-weight:bold;">import</span> <span style="color: #66cc66;">*</span><br />
<br />
env.<span style="color: black;">roledefs</span> = <span style="color: black;">&#123;</span><br />
&nbsp; &nbsp; <span style="color: #483d8b;">'production'</span>: <span style="color: black;">&#91;</span><span style="color: #483d8b;">&quot;morgangoose.com&quot;</span><span style="color: black;">&#93;</span>,<br />
&nbsp; &nbsp; <span style="color: black;">&#125;</span><br />
<br />
<br />
<span style="color: #ff7700;font-weight:bold;">def</span> setup_vars<span style="color: black;">&#40;</span>project<span style="color: black;">&#41;</span>: &nbsp; &nbsp;<br />
&nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">global</span> presentation<br />
&nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">global</span> presentation_archive<br />
&nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">global</span> rst_source<br />
&nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">global</span> pdf<br />
<br />
&nbsp; &nbsp; project = project.<span style="color: black;">strip</span><span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;/&quot;</span><span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; presentation = project<br />
&nbsp; &nbsp; presentation_archive = <span style="color: #483d8b;">&quot;%s.tar.gz&quot;</span> <span style="color: #66cc66;">%</span> presentation<br />
&nbsp; &nbsp; rst_source = <span style="color: #483d8b;">&quot;%s.rst&quot;</span> <span style="color: #66cc66;">%</span> presentation<br />
&nbsp; &nbsp; pdf = <span style="color: #483d8b;">&quot;%s.pdf&quot;</span> <span style="color: #66cc66;">%</span> presentation<br />
<br />
@roles<span style="color: black;">&#40;</span><span style="color: #483d8b;">'production'</span><span style="color: black;">&#41;</span><br />
<span style="color: #ff7700;font-weight:bold;">def</span> upload<span style="color: black;">&#40;</span>project<span style="color: black;">&#41;</span>:<br />
&nbsp; &nbsp; env.<span style="color: #dc143c;">user</span> = <span style="color: #483d8b;">&quot;username&quot;</span><br />
&nbsp; &nbsp; p_dir = <span style="color: #483d8b;">&quot;/var/www/html/p/&quot;</span><br />
<br />
&nbsp; &nbsp; package<span style="color: black;">&#40;</span>project<span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; put<span style="color: black;">&#40;</span>presentation_archive, p_dir<span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; put<span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;%s/%s&quot;</span> <span style="color: #66cc66;">%</span> <span style="color: black;">&#40;</span>presentation, pdf<span style="color: black;">&#41;</span>, p_dir<span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">with</span> <span style="color: #dc143c;">cd</span><span style="color: black;">&#40;</span>p_dir<span style="color: black;">&#41;</span>:<br />
&nbsp; &nbsp; &nbsp; &nbsp; run<span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;rm -rf %s/&quot;</span> <span style="color: #66cc66;">%</span> presentation<span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; run<span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;tar zxvf %s&quot;</span> <span style="color: #66cc66;">%</span> presentation_archive<span style="color: black;">&#41;</span><br />
<br />
&nbsp; &nbsp; local<span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;rm -f %s&quot;</span> <span style="color: #66cc66;">%</span> presentation_archive<span style="color: black;">&#41;</span> &nbsp; &nbsp; &nbsp; &nbsp;<br />
<br />
<span style="color: #ff7700;font-weight:bold;">def</span> package<span style="color: black;">&#40;</span>project<span style="color: black;">&#41;</span>:<br />
&nbsp; &nbsp; setup_vars<span style="color: black;">&#40;</span>project<span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; make_presentation<span style="color: black;">&#40;</span><span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; local<span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;tar zcvf %s %s&quot;</span> <span style="color: #66cc66;">%</span> <span style="color: black;">&#40;</span>presentation_archive, presentation<span style="color: black;">&#41;</span><span style="color: black;">&#41;</span><br />
<br />
<span style="color: #ff7700;font-weight:bold;">def</span> make_presentation<span style="color: black;">&#40;</span><span style="color: black;">&#41;</span>:<br />
&nbsp; &nbsp; <span style="color: #808080; font-style: italic;">#PDF first</span><br />
&nbsp; &nbsp; local<span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;rst2pdf %s/%s -o %s/%s&quot;</span> <span style="color: #66cc66;">%</span> <span style="color: black;">&#40;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; presentation, rst_source, presentation, pdf, <span style="color: black;">&#41;</span><span style="color: black;">&#41;</span><br />
<br />
&nbsp; &nbsp; <span style="color: #808080; font-style: italic;">#Then s5 html presentation</span><br />
&nbsp; &nbsp; local<span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;python rst-directive.py <span style="color: #000099; font-weight: bold;">\</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; --stylesheet=pygments.css <span style="color: #000099; font-weight: bold;">\</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; --theme=small-black <span style="color: #000099; font-weight: bold;">\</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; --quiet <span style="color: #000099; font-weight: bold;">\</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; %s/%s &gt; %s/index.html&quot;</span> <span style="color: #66cc66;">%</span> <span style="color: black;">&#40;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; presentation, rst_source, presentation, <span style="color: black;">&#41;</span><span style="color: black;">&#41;</span><br />
<br />
<span style="color: #ff7700;font-weight:bold;">def</span> <span style="color: #dc143c;">new</span><span style="color: black;">&#40;</span>project<span style="color: black;">&#41;</span>:<br />
&nbsp; &nbsp; setup_vars<span style="color: black;">&#40;</span>project<span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; local<span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;mkdir -p %s/{,files}&quot;</span> <span style="color: #66cc66;">%</span> presentation<span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; local<span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;cp -R ui %s/&quot;</span> <span style="color: #66cc66;">%</span> presentation<span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; local<span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;touch %s/%s&quot;</span> <span style="color: #66cc66;">%</span> <span style="color: black;">&#40;</span>presentation, rst_source<span style="color: black;">&#41;</span><span style="color: black;">&#41;</span></div></div>
<p>This has some more complicated bits, where it uses the role decorator to specify only to use the hosts listed in the production role definitions. </p>
<p>It also takes advantage of an awesome feature I didn&#8217;t know fabric had where, one can send arguments to a fabric target. So the project parameter in the targets here can be, and is, supplied via the command line. </p>
<p>For example, I used this to deploy the updates to my most recent presentation:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$ fab upload:tool_oriented_python</div></div>
<p>That&#8217;s telling fabric to run the upload target, and send the string &#8220;tool_oriented_python&#8221; as an argument to the function. </p>
<p>If you forget the targets you have just do:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">$ fab <span style="color: #660033;">-l</span></div></div>
]]></content:encoded>
			<wfw:commentRss>http://morgangoose.com/blog/2010/02/how-fabric-gets-it-right/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>GNU tools presentation</title>
		<link>http://morgangoose.com/blog/2010/02/gnu-tools-presentation/</link>
		<comments>http://morgangoose.com/blog/2010/02/gnu-tools-presentation/#comments</comments>
		<pubDate>Mon, 01 Feb 2010 15:41:17 +0000</pubDate>
		<dc:creator>Morgan</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[awk]]></category>
		<category><![CDATA[find]]></category>
		<category><![CDATA[gnu]]></category>
		<category><![CDATA[osc]]></category>
		<category><![CDATA[presentation]]></category>
		<category><![CDATA[sed]]></category>

		<guid isPermaLink="false">http://morgangoose.com/blog/2010/02/gnu-tools-presentation/</guid>
		<description><![CDATA[The other day, I gave a presentation to the Ohio State University, Open Source Club. It was on a smattering of command line utilities that I use on a daily basis, as well as a quick intro to regex usage. It is all accessible on my site here and in pdf form. It was pretty [...]]]></description>
			<content:encoded><![CDATA[<p>The other day, I gave a presentation to the Ohio State University, Open Source Club. It was on a smattering of command line utilities that I use on a daily basis, as well as a quick intro to regex usage.</p>
<p>It is all accessible on <a href="http://morgangoose.com/p/gnu_tools/">my site here</a> and in <a href="http://morgangoose.com/p/gnu_tools/gnu_tools.pdf">pdf form.</a></p>
<p>It was pretty long, and presenting it took a little over an hour. I plan on distilling the parts I liked talking about into more concise presentations, and also a blog post or two.</p>
<p>Awk and find will most likely be their own posts/presentations. I think I need to learn some more of the advanced uses of sed, and revisit that section to make it a bit more clear.</p>
]]></content:encoded>
			<wfw:commentRss>http://morgangoose.com/blog/2010/02/gnu-tools-presentation/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Logitech MX Revolution configuration</title>
		<link>http://morgangoose.com/blog/2009/08/logitech-mx-revolution-configuration/</link>
		<comments>http://morgangoose.com/blog/2009/08/logitech-mx-revolution-configuration/#comments</comments>
		<pubDate>Tue, 25 Aug 2009 03:44:22 +0000</pubDate>
		<dc:creator>Morgan</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[btnx]]></category>
		<category><![CDATA[button]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[gnome-terminal]]></category>
		<category><![CDATA[logitech]]></category>

		<guid isPermaLink="false">http://morgangoose.com/blog/2009/08/logitech-mx-revolution-configuration/</guid>
		<description><![CDATA[The other day @shuckins mentioned that I&#8217;m finding the MX Revolution quite awesome except that I really miss my scroll wheel click button. This was an issue that I had when I started using this mouse as well. The key feature of the mouse being that a middle click will switch the scroll wheel from [...]]]></description>
			<content:encoded><![CDATA[<p>The other day <a href="http://twitter.com/shuckins">@shuckins</a> mentioned that </p>
<blockquote><p>I&#8217;m finding the MX Revolution quite awesome except that I really miss my scroll wheel click button.</p></blockquote>
<p>This was an issue that I had when I started using this mouse as well. The key feature of the mouse being that a middle click will switch the scroll wheel from smooth movement to discrete (chunky?) movement and back again. This is actually very cool to use once you&#8217;ve gotten accustomed to having the option of scrolling down a page with fine control of speed/distance and then click once to then flick back up to the top of a page.</p>
<p>What I did to make my life easier with this mouse was setup the thumb scroll wheel to act as my middle click that I was accustomed to having. I accomplished this via the btnx-config program as available from the <a href="http://www.ollisalonen.com/btnx/">btnx website</a>. </p>
<p><a href="http://morgangoose.com/blog/wp-content/uploads/2009/08/Screenshot-btnx-config-1.png"><br />
<div id="attachment_63" class="wp-caption aligncenter" style="width: 310px"><img src="http://morgangoose.com/blog/wp-content/uploads/2009/08/Screenshot-btnx-config-1-300x203.png" alt="ThumbPress" title="Screenshot-btnx-config-1" width="300" height="203" class="size-medium wp-image-63" /><p class="wp-caption-text">ThumbPress</p></div><br />
</a></p>
<p>Once I found out how easy it was to get the middle click from the thumb wheel I decided to make the thumb up/down also have some functionality. If you use firefox and/or gnome terminal I find the most useful thing to map was thumb up to shift pageup and thumb down to shift pagedown. </p>
<p><a href="http://morgangoose.com/blog/wp-content/uploads/2009/08/Screenshot-btnx-config1.png"><br />
<div id="attachment_62" class="wp-caption aligncenter" style="width: 310px"><img src="http://morgangoose.com/blog/wp-content/uploads/2009/08/Screenshot-btnx-config1-300x203.png" alt="ThumbDown" title="Screenshot-btnx-config" width="300" height="203" class="size-medium wp-image-62" /><p class="wp-caption-text">ThumbDown</p></div><br />
</a></p>
<p>With these set this way I can switch tabs on both firefox and gnome-terminal w/o moving back to the keyboard. The other neat thing I found (when I actually noticed) was that this mapping holds even when using synergy to control two (or more) machines.</p>
<p>The mouse works great, and I haven&#8217;t in recent memory ever like a mouse as much as I have this one. Couple the nice manufacturing with the ease of button configuration provided by the great programmers of btnx  and I think its the perfect mouse for a programmer. Especially one who doesn&#8217;t like to have to constantly switch between using the mouse and keyboard.</p>
]]></content:encoded>
			<wfw:commentRss>http://morgangoose.com/blog/2009/08/logitech-mx-revolution-configuration/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Getting stfl working on fedora 11 x64</title>
		<link>http://morgangoose.com/blog/2009/07/getting-stfl-working-on-fedora-11-x64/</link>
		<comments>http://morgangoose.com/blog/2009/07/getting-stfl-working-on-fedora-11-x64/#comments</comments>
		<pubDate>Thu, 30 Jul 2009 16:14:11 +0000</pubDate>
		<dc:creator>Morgan</dc:creator>
				<category><![CDATA[Linux]]></category>

		<guid isPermaLink="false">http://morgangoose.com/blog/2009/07/getting-stfl-working-on-fedora-11-x64/</guid>
		<description><![CDATA[Newbeuter is my preferred way to browse RSS feeds. Its a great CLI app that is &#8216;Mutt Of Feed Readers&#8217;, and being a user of mutt I love this app for being so similar. I wanted to use the newest version of newbeuter, because recently I have been on a kick to get all of [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://www.newsbeuter.org/">Newbeuter</a> is my preferred way to browse RSS feeds. Its a great CLI app that is &#8216;Mutt Of Feed Readers&#8217;, and being a user of <a href="http://www.mutt.org/">mutt</a> I love this app for being so similar. I wanted to use the newest version of newbeuter, because recently I have been on a kick to get all of my apps: screen, vim, mutt, and now newsbuter; setup with 256 colours.</p>
<p>I read on the <a href="http://newsbeuter.wordpress.com/">development blog</a> that the newest version in the git repo was able to use 256 colours, so I immediately cloned the repo and started the install process. I was stopped immediately at the config.sh. It wanted the stfl libraries and wasn&#8217;t able to find them, and neither could yum.</p>
<p>Looking into the config.sh I saw that it was querying pkg-config for the flags to use on compilation to see if the library was present. It wasn&#8217;t, and so I also read further on the notes for the git repo version, and saw the bit about using the latest svn copy of stfl. So I checked that out, made it and installed it onto my machine. But this didn&#8217;t get me any further into making newsbueter, because pkg-config was still unable to find libstfl.</p>
<p>So I decided to try and figure out what the issue was with stfl and pkg-config. First thing I saw was that the stfl.pc file that pkg-config uses to make its responses was in the wrong place for my system. It was in /usr/local/lib/pkgconfig, instead of with the other libraries on my system in /usr/lib64/pkgconfig. This resolved the issue of pkg-config not knowing where the pc file for stfl was, and pkg-config was now returning actual data about libstfl. A recompilation of newsbeuter did show that there was still a problem. I now received: error while loading shared libraries: libstfl.so.0: cannot open shared object file: No such file or directory.</p>
<p>I did another updatedb, and ran a locate for all stfl files, and found that the make install for stfl was putting the libs in a strange place as well. I then updated both the Makefile.cfg and the stfl.so.in to reflect the locations of other libs:</p>
<p><strong>Makefile.cfg</strong> changed lines</p>
<div class="codecolorer-container make vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="make codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #666622; font-weight: bold;">export</span> libdir ?<span style="color: #004400;">=</span> lib64<br />
<span style="color: #666622; font-weight: bold;">export</span> prefix ?<span style="color: #004400;">=</span> usr <br />
<span style="color: #666622; font-weight: bold;">export</span> DESTDIR ?<span style="color: #004400;">=</span> <span style="color: #004400;">/</span></div></div>
<p><strong>stfl.pc.in</strong> changes lines</p>
<div class="codecolorer-container make vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="make codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">prefix<span style="color: #004400;">=/</span>usr<br />
exec_prefix<span style="color: #004400;">=/</span>usr<br />
libdir<span style="color: #004400;">=/</span>usr<span style="color: #004400;">/</span>lib64<br />
includedir<span style="color: #004400;">=/</span>usr<span style="color: #004400;">/</span><span style="color: #666622; font-weight: bold;">include</span></div></div>
<p>This got me pretty far I think, because now the system looked like the other libraries. The stfl.pc lines were taken almost verbatim from the sqlite3.pc file in fact. I was still getting the shared library issue though, and after not thinking about the problem for a bit I realized that the stfl makefile had made libstfl.so.0.21 and the error message was not able to find libstfl.so.0, so I too the logical leap and made a symlink named libstfl.so.0 that pointed to libstfl.so.0.21 in the /usr/lib64/ directory. After making sure that this worked, I made a change to the makefile for stfl, and added another line to make a second symlink, that ended in 0:</p>
<p><strong>Makefile</strong></p>
<div class="codecolorer-container make vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="make codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">ln <span style="color: #004400;">-</span>fs libstfl<span style="color: #004400;">.</span>so<span style="color: #004400;">.$</span><span style="color: #004400;">&#40;</span><span style="color: #000088;">VERSION</span><span style="color: #004400;">&#41;</span> <span style="color: #004400;">$</span><span style="color: #004400;">&#40;</span><span style="color: #000088;">DESTDIR</span><span style="color: #004400;">&#41;</span><span style="color: #004400;">$</span><span style="color: #004400;">&#40;</span><span style="color: #000088;">prefix</span><span style="color: #004400;">&#41;</span><span style="color: #004400;">/$</span><span style="color: #004400;">&#40;</span><span style="color: #000088;">libdir</span><span style="color: #004400;">&#41;</span><span style="color: #004400;">/</span>libstfl<span style="color: #004400;">.</span>so<span style="color: #004400;">.</span>0</div></div>
<p>I do admit that there may be a better way to do this, and some of it may be done with command line config or make flags. I don&#8217;t know them, and was able to successfully build with these changes.</p>
]]></content:encoded>
			<wfw:commentRss>http://morgangoose.com/blog/2009/07/getting-stfl-working-on-fedora-11-x64/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Decouple with kwargs</title>
		<link>http://morgangoose.com/blog/2009/07/decouple-with-kwargs/</link>
		<comments>http://morgangoose.com/blog/2009/07/decouple-with-kwargs/#comments</comments>
		<pubDate>Wed, 22 Jul 2009 22:26:42 +0000</pubDate>
		<dc:creator>Morgan</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[kwargs]]></category>
		<category><![CDATA[mutliprocessing]]></category>
		<category><![CDATA[optparse]]></category>
		<category><![CDATA[python]]></category>

		<guid isPermaLink="false">http://morgangoose.com/blog/?p=45</guid>
		<description><![CDATA[So I&#8217;ve been attempting to make a suite of cli scripts for work. I recently discovered the multiprocessing module for python, and really liked its simplicity, and started using it, with great success. Everything was faster. This then spurred me to take the scripts that were for the most part, copy common-ish bits and then [...]]]></description>
			<content:encoded><![CDATA[<p>So I&#8217;ve been attempting to make a suite of cli scripts for work. I recently discovered the <a href="http://docs.python.org/library/multiprocessing.html">multiprocessing</a> module for python, and really liked its simplicity, and started using it, with great success. Everything was faster.</p>
<p>This then spurred me to take the scripts that were for the most part, copy common-ish bits and then modify to suite, and turn them into a library of sorts. The neat part then arose when I wanted to import a argument parser, as well as pass off to a proc creation component.  </p>
<p>In doing this I had in mind that the &#8216;script&#8217; would need to only define a function to make a list of commands to run on a given server, and a __main__ section that would pass in a list of servers, the function to make a command list and some other info. This way the script itself would only be two definition sections, and only the parts that were going to be unique for the most part.</p>
<p>The problem that came up in doing this is when I wanted the function that makes the command list to have more arguments that normal. How would I pass them in, and how would I define them so that I don&#8217;t have to edit my libraries to accommodate this argument passing.  It was kwargs that saved me there, that and some <a href="http://docs.python.org/library/optparse.html">optparse</a> tweaking.</p>
<p>Here is a basic example:</p>
<p><strong>script.py</strong></p>
<div class="codecolorer-container python vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="python codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #ff7700;font-weight:bold;">def</span> get_commands<span style="color: black;">&#40;</span>host, <span style="color: #66cc66;">**</span>kwargs<span style="color: black;">&#41;</span>:<br />
&nbsp; &nbsp; command_list = <span style="color: black;">&#91;</span><span style="color: black;">&#93;</span><br />
<br />
&nbsp; &nbsp; <span style="color: #dc143c;">user</span> = kwargs<span style="color: black;">&#91;</span><span style="color: #483d8b;">'user'</span><span style="color: black;">&#93;</span><br />
&nbsp; &nbsp; key_file = kwargs<span style="color: black;">&#91;</span><span style="color: #483d8b;">'key_file'</span><span style="color: black;">&#93;</span><br />
<br />
&nbsp; &nbsp; command_list.<span style="color: black;">append</span><span style="color: black;">&#40;</span><span style="color: #483d8b;">&quot;echo %s&quot;</span> <span style="color: #66cc66;">%</span> <span style="color: #dc143c;">user</span><span style="color: black;">&#41;</span><br />
<br />
&nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">return</span> command_list &nbsp; &nbsp;<br />
<br />
<span style="color: #ff7700;font-weight:bold;">if</span> __name__ == <span style="color: #483d8b;">'__main__'</span>:<br />
&nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">import</span> automation<br />
<br />
&nbsp; &nbsp; hosts = <span style="color: black;">&#91;</span><span style="color: black;">&#93;</span><br />
<br />
&nbsp; &nbsp; <span style="color: black;">&#40;</span>hosts, options<span style="color: black;">&#41;</span> = automation.<span style="color: black;">process_args</span><span style="color: black;">&#40;</span><span style="color: #dc143c;">sys</span>.<span style="color: black;">argv</span><span style="color: black;">&#41;</span><br />
<br />
&nbsp; &nbsp; automation.<span style="color: black;">thread_hosts</span><span style="color: black;">&#40;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; hosts,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; get_commands,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; options,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: #dc143c;">user</span>=<span style="color: #483d8b;">&quot;test&quot;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: black;">&#41;</span></div></div>
<p><strong>automation.py</strong> (library w/ functions)</p>
<div class="codecolorer-container python vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="python codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #ff7700;font-weight:bold;">def</span> thread_hosts<span style="color: black;">&#40;</span>hosts, get_commands, options=<span style="color: black;">&#123;</span><span style="color: black;">&#125;</span>, <span style="color: #66cc66;">**</span>kwargs<span style="color: black;">&#41;</span>:<br />
&nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">import</span> multiprocessing<br />
&nbsp;<br />
&nbsp; &nbsp; kwargs.<span style="color: black;">update</span><span style="color: black;">&#40;</span>options<span style="color: black;">&#41;</span><br />
<br />
&nbsp; &nbsp; jobs = <span style="color: black;">&#91;</span><span style="color: black;">&#93;</span><br />
<br />
&nbsp; &nbsp; <span style="color: #ff7700;font-weight:bold;">for</span> host <span style="color: #ff7700;font-weight:bold;">in</span> hosts:<br />
&nbsp; &nbsp; &nbsp; &nbsp; p = multiprocessing.<span style="color: black;">Process</span><span style="color: black;">&#40;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; target=run_commands, <br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; args=<span style="color: black;">&#40;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; host,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; get_commands<span style="color: black;">&#40;</span>host, <span style="color: #66cc66;">**</span>kwargs<span style="color: black;">&#41;</span>,<br />
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <span style="color: black;">&#41;</span>, <span style="color: black;">&#41;</span><br />
<br />
&nbsp; &nbsp; &nbsp; &nbsp; jobs.<span style="color: black;">append</span><span style="color: black;">&#40;</span>p<span style="color: black;">&#41;</span><br />
&nbsp; &nbsp; &nbsp; &nbsp; p.<span style="color: black;">start</span><span style="color: black;">&#40;</span><span style="color: black;">&#41;</span></div></div>
<p>So this example is a script that defines the function to return a command list, and provides an options var, and list of hosts. The thread hosts then loops over the hosts each time  passing the host and the get_commands function to another library function that connects to said host, and loops over the returned command list.</p>
<p>A part that might be confusing is that the parse_args function returns optparse&#8217;s options variable but the options.__dict__ representation specifically. This then allows me to be able to update kwargs with any options that I allow to be set at the command line. The example in the script being the key_file variable.</p>
<p>The neat part of all this is being able to take the kwargs for one function and pass it right along to the next. This is key, because it allows for the library function in this case to be able to be entirely decoupled from the script itself. </p>
<p>With this implementation I am able to write a script that defines extra args to use, and only the script need know what they are. In the examples the library will just dumbly pass them along in the kwargs dict, I never have to tell it that I want to pass a user variable to it, and it makes the script a nice self contained unit.</p>
]]></content:encoded>
			<wfw:commentRss>http://morgangoose.com/blog/2009/07/decouple-with-kwargs/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Trac makes my life easy</title>
		<link>http://morgangoose.com/blog/2009/07/trac-makes-my-life-easy/</link>
		<comments>http://morgangoose.com/blog/2009/07/trac-makes-my-life-easy/#comments</comments>
		<pubDate>Wed, 22 Jul 2009 22:15:23 +0000</pubDate>
		<dc:creator>Morgan</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Webservers]]></category>
		<category><![CDATA[apache]]></category>
		<category><![CDATA[bitten]]></category>
		<category><![CDATA[python]]></category>
		<category><![CDATA[trac]]></category>

		<guid isPermaLink="false">http://morgangoose.com/blog/?p=43</guid>
		<description><![CDATA[The project management app Trac is something that was new to me a while back. I’d just installed t for a side project, and used the yum install without any issues. It took care of all the grunt work, and got me to the point where I could now create and use a trac project. [...]]]></description>
			<content:encoded><![CDATA[<p>The project management app <a href="http://trac.edgewall.org">Trac</a> is something that was new to me a while back. I’d just installed t for a side project, and used the yum install without any issues. It took care of all the grunt work, and got me to the point where I could now create and use a trac project.</p>
<p>Trac is set up like what I see web frameworks go with. A main program that will install the framework in a project directory. In this case trac-admin , which is killer when you want to make multiple projects, and offers a cli interface to the project’s framework configuration, etc.</p>
<p>This setup becomes awesome I found when you want to upgrade. Yum installed what it had packaged, the .10 version, but I had decided that I wanted to toy with <a href="http://bitten.edgewall.org">bitten</a> their automated build tool, which required .11 and up. So an upgrade was needed, yum couldn’t be used, but I found that trac-admin has an upgrade command.</p>
<p>So I was poised to make the fun and scary transition into mixing a package managed install with a source install, not something that always goes well. I’ve found that sometimes packagers change to install location from where the src install goes (looking at you nagios), and make some conflicts or at least confusion.</p>
<p>The upgrade process for the server then my app was as simple as:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">wget</span> http:<span style="color: #000000; font-weight: bold;">//</span>ftp.edgewall.com<span style="color: #000000; font-weight: bold;">/</span>pub<span style="color: #000000; font-weight: bold;">/</span>trac<span style="color: #000000; font-weight: bold;">/</span>Trac-0.11.5.tar.gz<br />
<span style="color: #c20cb9; font-weight: bold;">tar</span> zxvf http:<span style="color: #000000; font-weight: bold;">//</span>ftp.edgewall.com<span style="color: #000000; font-weight: bold;">/</span>pub<span style="color: #000000; font-weight: bold;">/</span>trac<span style="color: #000000; font-weight: bold;">/</span>Trac-0.11.5.tar.gz<br />
<span style="color: #7a0874; font-weight: bold;">cd</span> Trac-0.11.5<br />
python setup.py <span style="color: #c20cb9; font-weight: bold;">install</span><br />
trac-admin <span style="color: #000000; font-weight: bold;">/</span>path<span style="color: #000000; font-weight: bold;">/</span>to<span style="color: #000000; font-weight: bold;">/</span>project upgrade<br />
trac-admin <span style="color: #000000; font-weight: bold;">/</span>path<span style="color: #000000; font-weight: bold;">/</span>to<span style="color: #000000; font-weight: bold;">/</span>project wiki upgrade<br />
<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>httpd restart</div></div>
<p>This blew me away. I’ve have never had a complicated app (relativily of course) upgrade so simply, and without any issues. The main install of trac from empty folder to working project manager was simple too, so perhaps I should have expected this, but really I think it is a testimony to how well the developers of Trac have though of the whole process of using their framework.</p>
<p>Links:<br />
<a href="http://trac.edgewall.org/">http://trac.edgewall.org/</a><br />
<a href="http://bitten.edgewall.org/">http://bitten.edgewall.org/</a></p>
]]></content:encoded>
			<wfw:commentRss>http://morgangoose.com/blog/2009/07/trac-makes-my-life-easy/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Fedora 10 on the eeePC 900</title>
		<link>http://morgangoose.com/blog/2009/05/fedora-10-on-the-eeepc-900/</link>
		<comments>http://morgangoose.com/blog/2009/05/fedora-10-on-the-eeepc-900/#comments</comments>
		<pubDate>Tue, 05 May 2009 00:22:09 +0000</pubDate>
		<dc:creator>Morgan</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[eeepc]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[woot]]></category>

		<guid isPermaLink="false">http://morgangoose.com/blog/?p=5</guid>
		<description><![CDATA[Recently got the woot.com deal on the eeepc 900, sans webcam. I tried to use the xanadros os that was bundled with it for a few days, but the lack of normal gnu tools and normal packages made me want to switch. So I decided to to look into putting my os of choice fedora [...]]]></description>
			<content:encoded><![CDATA[<p>Recently got the woot.com deal on the eeepc 900, sans webcam. I tried to use the xanadros os that was bundled with it for a few days, but the lack of normal gnu tools and normal packages made me want to switch. So I decided to to look into putting my os of choice fedora onto it.</p>
<p><strong>Installing:</strong></p>
<p>Found that is was a <a href="http://fedoraproject.org/wiki/EeePc#Eee_PC_90x.2F1000_Series">dooable</a> <a href="http://idolinux.blogspot.com/2009/02/fedora-10-on-eee-pc-1000.html" target="_blank">project</a>, exciting and surprising.  Since the netbook doesn&#8217;t have a dvd-rom drive, and I lent out my external, I decided to go the usb live stick route.</p>
<p><a href="http://fedoraproject.org/wiki/FedoraLiveCD/USBHowTo" target="_blank">Directions</a> for this were easy to find, I did have to use the command line version of them, and found through trial and error that only my name brand Kingston drive would get the netbook to boot.</p>
<p>To get the usb drive to boot, hit escape while booting or hit f2 and set the main drive to be the usb drive.  After it boots and finishes and installs, everything pretty much works.</p>
<p>When I brought up the machine I started to follow <a href="http://idolinux.blogspot.com/2009/02/fedora-10-on-eee-pc-1000.html" target="_blank">Gavin&#8217;s directions</a> and run a general update. This failed, only because it filled the small hard drive up. I then had to find the /var/cache/yum/updates/packages/ directory and clear it by hand, because yum didn&#8217;t have the room to run and remove the rpms itself.</p>
<p><strong>Removing things to make space:</strong></p>
<p>So now I had to sleuth around to find out what was taking up all the space on the drive. Using</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">du</span> <span style="color: #660033;">-Hs</span> <span style="color: #660033;">-si</span> <span style="color: #000000; font-weight: bold;">/*</span></div></div>
<p>found that the largest folder in the root dir was usr. And walking down that path structure I found that the three largest folders, that I could do something about, were:</p>
<ul>
<li>/usr/share/locale @332MB</li>
<li>/usr/share/doc @106MB</li>
<li>/usr/share/fonts @223MB</li>
</ul>
<p>So I really went through and removed a whole lot of this stuff, which depending on ones needs, may not be advisable.</p>
<p>I removed all fonts that could using yum instead of just deleting them, as that just really seemed like a bad idea. It took a bit of grep&#8217;ing, so this line is a little long, but it basically strips out all the extra fonts, and keeps liberation as well as core font tools and libs. I personally use Anonymous, for all my coding, and terminal work, and I put that in .fonts dir, so really even this is a bit liberal for me.</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap">rpm <span style="color: #660033;">-qa</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> font \<br />
<span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-ve</span><span style="color: #ff0000;">'xorg'</span> <span style="color: #660033;">-ve</span><span style="color: #ff0000;">'core'</span> <span style="color: #660033;">-ve</span><span style="color: #ff0000;">'liberation'</span> <span style="color: #660033;">-ve</span><span style="color: #ff0000;">'fontconfig'</span> <span style="color: #660033;">-ve</span><span style="color: #ff0000;">'lib'</span> <span style="color: #660033;">-ve</span><span style="color: #ff0000;">'bitmapfonts'</span> <span style="color: #660033;">-ve</span><span style="color: #ff0000;">'ghostscript'</span> \<br />
<span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">xargs</span> yum <span style="color: #660033;">-y</span> erase</div></div>
<p>Note also that this removes these apps:</p>
<ul>
<li>gimp</li>
<li>abiword</li>
<li>evince</li>
<li>ghostscript (even though I tried not to)</li>
</ul>
<p>This frees up most of the 200MB that the fonts dir takes up, so we&#8217;re off to a good start.</p>
<p>The locale directory I was unfamiliar with, but some searching found that this is where data for other language support is stored. I only speak one, and found that removing these doesn&#8217;t cause irreparable harm. So delete them I did.  Since these are installed with every program, and the language packs don&#8217;t have their own RPMs yum wasn&#8217;t useful in this case.</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #c20cb9; font-weight: bold;">ls</span> <span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>share<span style="color: #000000; font-weight: bold;">/</span>locale<span style="color: #000000; font-weight: bold;">/*</span> <span style="color: #660033;">-d</span> \<br />
<span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #660033;">-ve</span><span style="color: #ff0000;">'locale.alias'</span> <span style="color: #660033;">-ve</span><span style="color: #ff0000;">'default'</span> <span style="color: #660033;">-ve</span><span style="color: #ff0000;">'en'</span> \<br />
<span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">xargs</span> <span style="color: #c20cb9; font-weight: bold;">rm</span> <span style="color: #660033;">-rf</span></div></div>
<p>This frees up about another 300MB. But it is also something that will crop up again, since any new program you install will add it own locale information. For apt-get there is a nice plug-in that will automatically strip out this information for you on install, but in my shallow searching for this for yum there didn&#8217;t seem to be a substitute. Might be a good weekend project.</p>
<p>The share doc directory I just cd&#8217;ed into and wiped out its contents. This is a netbook, and I can ssh into my home machine to read those if I need to, so I freed up another 100 or so MB with this wipe.</p>
<p>This brings us a lot closer to a good  1 GB of free space. I went further and removed a few apps I won&#8217;t be using:</p>
<ul>
<li>evolution</li>
<li>rhythmbox</li>
<li>cheese</li>
</ul>
<p><strong>Now to try and get the services under control. </strong></p>
<p>Found this great <a href="http://mjmwired.net/resources/mjm-services-f10.html" target="_blank">listing of what each service does</a>, so if you&#8217;re unsure if you want to stop as many as I chose to, look it up and make sure. I also chose to use the command line service conf tool:</p>
<div class="codecolorer-container bash vibrant" style="overflow:auto;white-space:nowrap;border:1px solid #9F9F9F;width:435px;"><div class="bash codecolorer" style="padding:5px;font:normal 12px/1.4em Monaco, Lucida Console, monospace;white-space:nowrap"><span style="color: #000000; font-weight: bold;">/</span>sbin<span style="color: #000000; font-weight: bold;">/</span>chkconfig &nbsp;<span style="color: #660033;">--list</span></div></div>
<p>  So its a bit time consuming but I went through the chkconfig list and grepped out the 5:on states and checked them against my list below and set them to off one at a time for every run time level.  There might be a quicker way, but I couldn&#8217;t think of one that didn&#8217;t involve making a script, so I let it be, and stuck with manual.</p>
<ul>
<li>cron, atd, anacron</li>
<li>auditd (also disabled SELinux)</li>
<li>avahi-daemon</li>
<li>bluetooth</li>
<li>btseed, bttrack</li>
<li>capi</li>
<li>cups[*]</li>
<li>firstboot</li>
<li>ip6tables</li>
<li>irda</li>
<li>irqbalance</li>
<li>isdn</li>
<li>kerneloops</li>
<li>lm_sensors</li>
<li>mdmonitor</li>
<li>multipathd</li>
<li>netconsole</li>
<li>netfs</li>
<li>nfs</li>
<li>nfslock</li>
<li>nmbd</li>
<li>nscd</li>
<li>pcscd</li>
<li>portreserve</li>
<li>restorecond</li>
<li>rpcbind</li>
<li>rpcgssd*</li>
<li>sendmail</li>
<li>smb</li>
<li>ypbind</li>
</ul>
<p>Now not all of those services were up, but I just made the list of what I would remove, and didn&#8217;t take note of what was not running in that list.</p>
<p>Then I installed my must haves: xfce, vim, htop, all the dvcs&#8217; , tilda, and tomboy. I rsync&#8217;ed over my dot dirs that I wanted, and I was good.</p>
<p><strong>Links:</strong><br />
<a href="http://fedoraproject.org/wiki/EeePc#Eee_PC_90x.2F1000_Series">http://fedoraproject.org/wiki/EeePc#Eee_PC_90x.2F1000_Series</a><br />
<a href="http://idolinux.blogspot.com/2009/02/fedora-10-on-eee-pc-1000.html">http://idolinux.blogspot.com/2009/02/fedora-10-on-eee-pc-1000.html</a><br />
<a href="http://fedoraproject.org/wiki/FedoraLiveCD/USBHowTo">http://fedoraproject.org/wiki/FedoraLiveCD/USBHowTo</a><br />
<a href="http://www.mjmwired.net/resources/mjm-services-f10.html">http://www.mjmwired.net/resources/mjm-services-f10.html</a></p>
]]></content:encoded>
			<wfw:commentRss>http://morgangoose.com/blog/2009/05/fedora-10-on-the-eeepc-900/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>
