<?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>Silas Sewell - RPM</title>
        <atom:link href="http://www.silassewell.com/blog/tag/rpm/rss2.xml" rel="self" type="application/rss+xml" />
        <link>http://www.silassewell.com/blog/tag/rpm</link>
        <description>Infrastructure Development</description>
        <lastBuildDate>Sat, 08 Jan 2011 00:00:00 GMT</lastBuildDate>
        <generator>http://www.silassewell.com/</generator>
        <language>en</language>
        <sy:updatePeriod>hourly</sy:updatePeriod>
        <sy:updateFrequency>1</sy:updateFrequency>

        <item>
            <title>Qpid on CentOS 5</title>
            <link>http://www.silassewell.com/blog/2009/06/16/qpid-on-centos-5/</link>
            <pubDate>Tue, 16 Jun 2009 00:00:00 GMT</pubDate>
            <dc:creator>silas</dc:creator>
            <category><![CDATA[CentOS]]></category><category><![CDATA[Fedora]]></category><category><![CDATA[Qpid]]></category><category><![CDATA[RPM]]></category><category><![CDATA[Systems Administration]]></category>
            <guid isPermaLink="true">http://www.silassewell.com/blog/2009/06/16/qpid-on-centos-5/</guid>
            <description><![CDATA[<h3>Build using Fedora</h3>

<ol>
<li><p>Install the RPM development tools</p>

<pre><code class="prettyprint">sudo yum install rpmdevtools mock
</code></pre></li>
<li><p>Add yourself to the <code class="prettyprint">mock</code> group</p>

<pre><code class="prettyprint">sudo /usr/sbin/usermod --groups mock --append $USER
</code></pre></li>
<li><p>Setup build directories</p>

<pre><code class="prettyprint">rpmdev-setuptree
</code></pre></li>
<li><p>Install spec and source files (or get latest <a href="ftp://ftp.redhat.com/pub/redhat/linux/enterprise/5Server/en/RHEMRG/SRPMS/" title="RHEMRG SRPMS">here</a>)</p>

<pre><code class="prettyprint">rpm -i ftp://ftp.redhat.com/pub/redhat/linux/enterprise/5Server/en/RHEMRG/SRPMS/qpidc-0.5.752581-17.el5.src.rpm
rpm -i ftp://ftp.redhat.com/pub/redhat/linux/enterprise/5Server/en/RHEMRG/SRPMS/amqp-1.0.750054-1.el5.src.rpm
rpm -i ftp://ftp.redhat.com/pub/redhat/linux/enterprise/5Server/en/RHEMRG/SRPMS/python-qpid-0.5.752581-3.el5.src.rpm
</code></pre></li>
<li><p>Build qpidc</p>

<pre><code class="prettyprint">rpmbuild -bs --nodeps ~/rpmbuild/SRPM/qpidc.spec
mock -vr epel-5-x86_64 ~/rpmbuild/SRPMS/qpidc-*.src.rpm
scp /var/lib/mock/epel-5-x86_64/result/*.rpm CENTOS_HOST:SOME_PATH
</code></pre></li>
<li><p>Build amqp</p>

<pre><code class="prettyprint">rpmbuild -bs --nodeps ~/rpmbuild/SPECS/amqp.spec
mock -vr epel-5-x86_64 ~/rpmbuild/SRPMS/amqp-*.src.rpm
scp /var/lib/mock/epel-5-x86_64/result/*.rpm CENTOS_HOST:SOME_PATH
</code></pre></li>
<li><p>Build python-qpid</p>

<pre><code class="prettyprint">rpmbuild -bs --nodeps ~/rpmbuild/SPECS/python-qpid.spec
mock -vr epel-5-x86_64 ~/rpmbuild/SRPMS/python-qpid-*.src.rpm
scp /var/lib/mock/epel-5-x86_64/result/*.rpm CENTOS_HOST:SOME_PATH
</code></pre></li>
</ol>

<h3>Install on CentOS</h3>

<ol>
<li><p>Become root</p>

<pre><code class="prettyprint">sudo su -
</code></pre></li>
<li><p>Install Qpid server and Python client packages</p>

<pre><code class="prettyprint">cd SOME_PATH
yum localinstall --nogpgcheck qpidc-*.el5.x86_64.rpm qpidd-*.el5.x86_64.rpm amqp-*.el5.noarch.rpm python-qpid-*.el5.noarch.rpm
</code></pre></li>
<li><p>Disable auth for testing</p>

<pre><code class="prettyprint">echo 'auth=no' &gt;&gt; /etc/qpidd.conf
</code></pre></li>
<li><p>Start qpidd</p>

<pre><code class="prettyprint">service qpidd start
</code></pre></li>
<li><p>Test using these <a href="http://www.silassewell.com/blog/2009/03/29/getting-started-with-amqp-qpid-python-fedora/" title="Getting Started with AMQP with Python">instructions</a>.</p></li>
</ol>

<p>NOTE: I realize you can build the SRPMs without installing them.</p>]]></description>
        </item>

        <item>
            <title>Python Line-by-line Profiler (line_profiler and kernprof)</title>
            <link>http://www.silassewell.com/blog/2009/05/28/python-line-by-line-profiler-line_profiler-and-kernprof/</link>
            <pubDate>Thu, 28 May 2009 00:00:00 GMT</pubDate>
            <dc:creator>silas</dc:creator>
            <category><![CDATA[Fedora]]></category><category><![CDATA[kernprof]]></category><category><![CDATA[line_profiler]]></category><category><![CDATA[Programming]]></category><category><![CDATA[Python]]></category><category><![CDATA[RPM]]></category>
            <guid isPermaLink="true">http://www.silassewell.com/blog/2009/05/28/python-line-by-line-profiler-line_profiler-and-kernprof/</guid>
            <description><![CDATA[<p>The following is a quick and dirty guide to getting started with
<a href="http://packages.python.org/line_profiler/" title="line profiler">line_profiler</a>, a Python line-by-line profiler, on Fedora.</p>

<ol>
<li><a href="http://code.google.com/p/silassewell/wiki/PackagingRPMs" title="Packaging RPMS">Build</a> and install the <a href="http://silassewell.googlecode.com/files/python-line_profiler-1.0-0.1.b2.fc10.src.rpm" title="line profiler SRPM">python-line_profiler</a> package</li>
<li><p>Create a file called <code class="prettyprint">test.py</code> with the code below</p>

<pre><code class="prettyprint">import random, time

def sleep():
    seconds = random.randint(0, 5)
    print 'Sleeping %s seconds' % seconds
    time.sleep(seconds)

@profile
def test():
    sleep()
    sleep()
    sleep()

test()
</code></pre></li>
<li><p>Profile <code class="prettyprint">test.py</code></p>

<pre><code class="prettyprint">[silas@silas ~]$ kernprof.py -l test.py
Sleeping 4 seconds
Sleeping 5 seconds
Sleeping 2 seconds
Wrote profile results to test.py.lprof
</code></pre></li>
<li><p>View the results</p>

<pre><code class="prettyprint">[silas@silas ~]$ python -m line_profiler test.py.lprof
Timer unit: 1e-06 s

File: test.py
Function: test at line 8
Total time: 10.9994 s

Line #      Hits         Time  Per Hit   % Time  Line Contents
==============================================================
     8                                           @profile
     9                                           def test():
    10         1      3999416 3999416.0     36.4      sleep()
    11         1      4999982 4999982.0     45.5      sleep()
    12         1      1999990 1999990.0     18.2      sleep()
</code></pre></li>
</ol>

<p>NOTE: I have a <a href="https://bugzilla.redhat.com/show_bug.cgi?id=502978" title="Package Review">package review</a> up for line_profiler and it should be
available via yum eventually.</p>]]></description>
        </item>

        <item>
            <title>Scribe – Scalable Real Time Log Aggregation for CentOS 5 / RHEL 5</title>
            <link>http://www.silassewell.com/blog/2009/05/07/scribe-scalable-real-time-log-aggregation-for-centos-5-rhel-5/</link>
            <pubDate>Thu, 07 May 2009 00:00:00 GMT</pubDate>
            <dc:creator>silas</dc:creator>
            <category><![CDATA[CentOS]]></category><category><![CDATA[CentOS 5]]></category><category><![CDATA[Facebook]]></category><category><![CDATA[fb303]]></category><category><![CDATA[Fedora]]></category><category><![CDATA[Logging]]></category><category><![CDATA[RPM]]></category><category><![CDATA[Scribe]]></category><category><![CDATA[Systems Administration]]></category><category><![CDATA[Thrift]]></category>
            <guid isPermaLink="true">http://www.silassewell.com/blog/2009/05/07/scribe-scalable-real-time-log-aggregation-for-centos-5-rhel-5/</guid>
            <description><![CDATA[<p>"<a href="http://developers.facebook.com/scribe/" title="Scribe">Scribe</a> is a server for aggregating log data streamed in real time
from a large number of servers. It is designed to be scalable, extensible
without client-side modification, and robust to failure of the network or any
specific machine. Scribe was developed at Facebook and
<a href="http://www.facebook.com/note.php?note_id=32008268919&#038;id=9445547199&#038;index=0" title="Scribe Released as Open Source">released as open source</a>."</p>

<p>I've packaged <a href="http://incubator.apache.org/thrift/" title="Thrift">Thrift</a>, <a href="http://svn.apache.org/repos/asf/incubator/thrift/trunk/contrib/fb303/README">fb303</a> and <a href="http://developers.facebook.com/scribe/" title="Scribe">Scribe</a> for CentOS 5 / RHEL 5.</p>

<h3>SRPM</h3>

<ul>
<li><a href="http://silassewell.googlecode.com/files/thrift-0.0-0.el5.20090505svn770888.src.rpm">Thrift</a> (<a href="http://silassewell.googlecode.com/svn/trunk/2009/05/05/scribe-for-el5/thrift/" title="Thrift Source">Source</a>)</li>
<li><a href="http://silassewell.googlecode.com/files/fb303-0.0-0.el5.20090505svn770888.src.rpm" title="fb303 SRPM">fb303</a> (<a href="http://silassewell.googlecode.com/svn/trunk/2009/05/05/scribe-for-el5/fb303/" title="fb303 Source">Source</a>)</li>
<li><a href="http://silassewell.googlecode.com/files/scribe-2.01-2.el5.src.rpm" title="Scribe SRPM">Scribe</a> (<a href="http://silassewell.googlecode.com/svn/trunk/2009/05/05/scribe-for-el5/scribe/" title="Scribe Source">Source</a>)</li>
</ul>

<p>Scribe depends on fb303 which in turns depends on Thrift so you'll need to
setup a local repository and build them in that order. To build the above
packages for Fedora 9+ you'll need to tweak the Python sub-packages to include
the egg files.</p>

<p>Both fb303 and Scribe need some tweaks upstream before they're suitable for a
package review, but I'd like to get them in Fedora shortly (I've already
<a href="https://bugzilla.redhat.com/show_bug.cgi?id=498873" title="Thrift Review">submitted Thrift</a>).</p>

<p>If you'd like to hack around with my latest Fedora specs you can grab them <a href="http://github.com/silas/rpms" title="GitHub RPM">here</a>.</p>]]></description>
        </item>

        <item>
            <title>Adobe Flash 10 64-bit SPEC File for Fedora 9</title>
            <link>http://www.silassewell.com/blog/2008/11/18/adobe-flash-10-64-bit-spec-file-for-fedora-9/</link>
            <pubDate>Tue, 18 Nov 2008 00:00:00 GMT</pubDate>
            <dc:creator>silas</dc:creator>
            <category><![CDATA[Adobe Flash]]></category><category><![CDATA[Fedora]]></category><category><![CDATA[RPM]]></category><category><![CDATA[Systems Administration]]></category>
            <guid isPermaLink="true">http://www.silassewell.com/blog/2008/11/18/adobe-flash-10-64-bit-spec-file-for-fedora-9/</guid>
            <description><![CDATA[<p>I hacked up a quick SPEC file for the alpha release of
<a href="http://labs.adobe.com/technologies/flashplayer10/releasenotes_64bit.html">Adobe Flash 10 64-bit</a> for Linux.</p>

<pre><code class="prettyprint">Name:           adobe-flash
Version:        10.0.d20.7
Release:        1%{?dist}
Summary:        Adobe Flash player.

Group:          Application/Internet
License:        Proprietary
URL:            http://labs.adobe.com/technologies/flashplayer10/
Source0:        http://download.macromedia.com/pub/labs/flashplayer10/libflashplayer-10.0.d20.7.linux-x86_64.so.tar.gz
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)

BuildArch:      x86_64
Requires:       firefox &gt;= 3
Requires:       mozilla-filesystem

%description
The Adobe Flash player.

%prep
%setup -T -c -a 0

%install
install -D -m 644 libflashplayer.so $RPM_BUILD_ROOT%{_usr}/lib64/mozilla/plugins/libflashplayer.so

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%{_usr}/lib64/mozilla/plugins/libflashplayer.so

%changelog
* Tue Nov 18 2008 Silas Sewell &lt;silas@sewell.ch&gt; - 10.0.d20.7
- Created package.
</code></pre>]]></description>
        </item>

    </channel>
</rss>
