<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>Advogato blog for skvidal</title>
    <link>http://www.advogato.org/person/skvidal/</link>
    <description>Advogato blog for skvidal</description>
    <language>en-us</language>
    <generator>mod_virgule</generator>
    <pubDate>Fri, 24 May 2013 19:03:23 GMT</pubDate>
    <item>
      <pubDate>Thu, 23 May 2013 21:12:15 GMT</pubDate>
      <title>documenting for posterity &#x2013; ansible &#x2013; wait for a dir to exist before continuing</title>
      <link>http://www.advogato.org/person/skvidal/diary.html?start=465</link>
      <guid>http://skvidal.wordpress.com/2013/05/23/documenting-for-posterity-ansible-wait-for-a-dir-to-exist-before-continuing/</guid>
      <description>&lt;p&gt;Got a ridiculous process **cough**Jenkins**Cough** that you have to wait to create a dir before doing things?&lt;/p&gt;
&lt;p&gt;This might help you as godawful ugly as it is.&lt;/p&gt;
&lt;blockquote&gt;
  &lt;p&gt;  &#x2013; name: wait for a dir to exist &#x2013; this is just ugly&lt;br/&gt;
    shell: while `true`; do [ -d /var/lib/jenkins/plugins/openid/WEB-INF/lib/ ] &amp;amp;&amp;amp; break; sleep 5; done&lt;br/&gt;
    async: 1800&lt;br/&gt;
    poll: 20
&lt;/p&gt;
&lt;/blockquote&gt;
&lt;br/&gt;&lt;a href="http://feeds.wordpress.com/1.0/gocomments/skvidal.wordpress.com/1094/" &gt;
  &lt;img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skvidal.wordpress.com/1094/"/&gt;&lt;/a&gt; &lt;img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skvidal.wordpress.com&amp;amp;blog=579402&amp;amp;post=1094&amp;amp;subd=skvidal&amp;amp;ref=&amp;amp;feed=1" width="1" height="1"/&gt;</description>
    </item>
    <item>
      <pubDate>Fri, 17 May 2013 19:10:33 GMT</pubDate>
      <title>sorting srpms by buildorder</title>
      <link>http://www.advogato.org/person/skvidal/diary.html?start=464</link>
      <guid>http://skvidal.wordpress.com/2013/05/17/sorting-srpms-by-buildorder/</guid>
      <description>&lt;p&gt;Hey folks,&lt;br/&gt;
 Working on something for Spot I revived some code I had written a&lt;br/&gt;
few years ago and then discovered that other people had made much more&lt;br/&gt;
robust leveled topological sorts than I had written &lt;img src="http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif" alt=":)" class="wp-smiley"/&gt;&lt;/p&gt;
&lt;p&gt;Anyway &#x2013; if you grab the files from:&lt;/p&gt;
&lt;p&gt;
  &lt;a href="http://skvidal.fedorapeople.org/misc/buildorder/" &gt;http://skvidal.fedorapeople.org/misc/buildorder/&lt;/a&gt;
&lt;/p&gt;
&lt;p&gt;And run:&lt;/p&gt;
&lt;p&gt;python buildorder.py /path/to/*.src.rpm&lt;/p&gt;
&lt;p&gt;it will look up the interdependencies of the src.rpm to figure out a&lt;br/&gt;
build order. It outputs a bunch of different things:&lt;br/&gt;
1. a flat build order&lt;br/&gt;
2. a build order broken out by groups &#x2013; you can build all the pkgs in&lt;br/&gt;
any group in parallel provided that all the pkgs in the previous group&lt;br/&gt;
have finished building.&lt;br/&gt;
3. outputs lists of direct loops between srpms.&lt;br/&gt;
4. probably will output A LOT of noise and garbage from the rpm&lt;br/&gt;
specfile parsing from the rpm.spec() module&lt;/p&gt;
&lt;p&gt;But it might be worth a look at and, ideally, patches to make it a bit&lt;br/&gt;
more robust.&lt;/p&gt;
&lt;p&gt;If you have a set of pkgs which you need to build but you can&#x2019;t figure&lt;br/&gt;
out the buildorder this might help you out.&lt;/p&gt;
&lt;p&gt;I&#x2019;d love to know how often it is right or &#x2018;right enough&#x2019;.&lt;/p&gt;
&lt;p&gt;Known Issues:&lt;br/&gt;
1. some spec files make the rpm.spec() parsing break in interesting&lt;br/&gt;
ways &#x2013; sometimes tracing back &lt;img src="http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif" alt=":)" class="wp-smiley"/&gt;&lt;br/&gt;
2. if a pkg is not dependent on any other pkg and nothing else depends&lt;br/&gt;
on it &#x2013; they get lumped in the last grouping. Not really an issue -&lt;br/&gt;
just something someone noticed and was surprised.&lt;br/&gt;
3. It will handle file-buildreqs not at all, it will handle virtual&lt;br/&gt;
provide buildreqs, not at all, if your buildreqs are REALLY picky about&lt;br/&gt;
 requiring &amp;lt;= Version &#x2013; it will ignore all of that. &lt;img src="http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif" alt=":)" class="wp-smiley"/&gt;&lt;br/&gt;
4. I fully expect that 2 or more level circular build deps (foo req bar&lt;br/&gt;
   req baz req quux) will not be detected but will make the topological&lt;br/&gt;
   sort function die). If so&#x2026;. tough&#x2026; go fix your packaging.&lt;/p&gt;
&lt;p&gt;Anyway &#x2013; give it a run and see if it helps you solve a problem.&lt;/p&gt;
&lt;p&gt;If it does let me know about it. Some of us are curious if this could&lt;br/&gt;
fit well in mockchain or wrapped around/in mockchain.&lt;/p&gt;
&lt;br/&gt;&lt;a href="http://feeds.wordpress.com/1.0/gocomments/skvidal.wordpress.com/1092/" &gt;
  &lt;img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skvidal.wordpress.com/1092/"/&gt;&lt;/a&gt; &lt;img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skvidal.wordpress.com&amp;amp;blog=579402&amp;amp;post=1092&amp;amp;subd=skvidal&amp;amp;ref=&amp;amp;feed=1" width="1" height="1"/&gt;</description>
    </item>
    <item>
      <pubDate>Mon, 29 Apr 2013 23:04:30 GMT</pubDate>
      <title>adding an openstack cinder volume server to an existing cloud with an existing cinder setup</title>
      <link>http://www.advogato.org/person/skvidal/diary.html?start=463</link>
      <guid>http://skvidal.wordpress.com/2013/04/29/adding-an-openstack-cinder-volume-server-to-an-existing-cloud-with-an-existing-cinder-setup/</guid>
      <description>&lt;p&gt;We needed more space for cinder and had no nice way to expand it on our existing cinder server so after banging my head a bit I got assistance from&#xA0;Giulio Fidente who was able to show me a working config that let me figure out what I was missing. Below I document it so others might be able to find it, too.&lt;/p&gt;
&lt;p&gt;NOTE: this works under folsom on rhel 6.4. I cannot vouch for anything else -but Giulio had it running on grizzly I think so&#x2026;&lt;/p&gt;
&lt;p&gt;Usage:&lt;/p&gt;
&lt;p&gt;You have an existing cinder server setup and running &#x2013; which includes&lt;br/&gt;
a volume server, an api service and a scheduler service. You need to&lt;br/&gt;
add more space and you have a system where that can run.&lt;/p&gt;
&lt;p&gt;Here&#x2019;s all you need to do:&lt;/p&gt;
&lt;p&gt;1. install openstack-cinder on the server you want to be a new volume server&lt;/p&gt;
&lt;p&gt;2. make sure your new system can access the mysql server on your primary&lt;br/&gt;
controller system&lt;/p&gt;
&lt;p&gt;3. make sure tgtd knows to import the files /etc/cinder/volumes&lt;/p&gt;
&lt;p&gt;add&lt;br/&gt;&lt;b&gt;include /etc/cinder/volumes/*&lt;/b&gt;&lt;br/&gt;
to:&lt;br/&gt;&lt;b&gt;/etc/tgt/targets.conf&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;4. make sure your other computer nodes can access the iscsi-target port&lt;br/&gt;&lt;b&gt;iscsi-target 3260/tcp&lt;/b&gt; on the system you want to add as an cinder-volume server&lt;/p&gt;
&lt;p&gt;5. setup your /etc/cinder/cinder.conf&lt;br/&gt;
example:&lt;/p&gt;
&lt;blockquote&gt;
  &lt;p&gt;
    &lt;b&gt;[DEFAULT]&lt;br/&gt;
sql_connection = mysql://cinder_user:cinder_pass@mysqlhost/cinder&lt;br/&gt;
api_paste_config=/etc/cinder/api-paste.ini&lt;br/&gt;
auth_strategy = keystone&lt;br/&gt;
rootwrap_config = /etc/cinder/rootwrap.conf&lt;br/&gt;
rpc_backend = cinder.openstack.common.rpc.impl_qpid&lt;br/&gt;
qpid_hostname = qpid_hostname_ip_here&lt;br/&gt;
volume_group = cinder-volumes&lt;br/&gt;
iscsi_helper = tgtadm&lt;br/&gt;
iscsi_ip_address = my_volume_ip&lt;br/&gt;
logdir = /var/log/cinder&lt;br/&gt;
state_path = /var/lib/cinder&lt;br/&gt;
lock_path = /var/lib/cinder/tmp&lt;br/&gt;
volumes_dir = /etc/cinder/volumes&lt;/b&gt;
  &lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;6. start tgtd and openstack-cinder-volume&lt;/p&gt;
&lt;blockquote&gt;
  &lt;p&gt;
    &lt;b&gt;service tgtd start&lt;br/&gt;
service openstack-cinder-volume start&lt;/b&gt;
  &lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;7. check out &lt;b&gt;/var/log/cinder/volume.log&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;8. Verifying it worked:&lt;br/&gt;
on your cloud controller run:&lt;br/&gt;&lt;b&gt;cinder-manage host list&lt;/b&gt;&lt;br/&gt;
you should see all of your volume servers there.&lt;/p&gt;
&lt;p&gt;9. creating a volume. &#x2013; just make a volume as usual &#x2013; the scheduler&lt;br/&gt;
should default to the volume server with the most space available&lt;/p&gt;
&lt;p&gt;10. on your new cinder-volume server run lvs to look for the new volume.&lt;/p&gt;
&lt;br/&gt;&lt;a href="http://feeds.wordpress.com/1.0/gocomments/skvidal.wordpress.com/1088/" &gt;
  &lt;img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skvidal.wordpress.com/1088/"/&gt;&lt;/a&gt; &lt;img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skvidal.wordpress.com&amp;amp;blog=579402&amp;amp;post=1088&amp;amp;subd=skvidal&amp;amp;ref=&amp;amp;feed=1" width="1" height="1"/&gt;</description>
    </item>
    <item>
      <pubDate>Sat, 27 Apr 2013 03:09:06 GMT</pubDate>
      <title>Things I Learned while building f19alpha imgs for our openstack cloud</title>
      <link>http://www.advogato.org/person/skvidal/diary.html?start=462</link>
      <guid>http://skvidal.wordpress.com/2013/04/27/things-i-learned-while-building-f19alpha-imgs-for-our-openstack-cloud/</guid>
      <description>&lt;p&gt;Things I learned today:&lt;/p&gt;
&lt;p&gt;1. the predictable network device naming stuff in systemd is kinda arbitrary when it comes to cloud imgs that may run on a variety of virt systems &#x2013; so to turn it off just add this to your %post in your kickstart:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;&lt;span style="font-family:Consolas, Monaco, monospace;font-size:12px;line-height:18px;"&gt;# disable systemd &#x2018;predictable&#x2019; device names for networks w/a hammer&lt;/span&gt;&lt;/p&gt;
&lt;pre&gt;ln -s /dev/null /etc/udev/rules.d/80-net-name-slot.rules

cat &amp;gt; /etc/sysconfig/network-scripts/ifcfg-eth0 &amp;lt;&amp;lt; EOF
DEVICE="eth0"
BOOTPROTO="dhcp"
ONBOOT="yes"
TYPE="Ethernet"
EOF&lt;/pre&gt;
&lt;/blockquote&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;pre&gt;
&lt;span style="font-family:Georgia, 'Times New Roman', 'Bitstream Charter', Times, serif;font-size:13px;line-height:19px;"&gt;That last bit is just to make a generic ifcfg-eth0 so ifup eth0 works normally.

2. the hostonly initramfs that dracut makes now plays up when you are moving an image around. make sure you add&lt;/span&gt;&lt;/pre&gt;
&lt;blockquote&gt;
&lt;pre&gt;dracut-nohostonly&lt;/pre&gt;
&lt;/blockquote&gt;
&lt;p&gt;to %packages to get it to behave as you&#x2019;d expect&lt;/p&gt;
&lt;p&gt;3. if you don&#x2019;t have a lot of memory then you may not &#xA0;want tmpfs for /tmp &#xA0;- to turn that off just do:&lt;/p&gt;
&lt;blockquote&gt;
&lt;pre&gt;systemctl mask tmp.mount&lt;/pre&gt;
&lt;/blockquote&gt;
&lt;p&gt;in %post and it will be as you&#x2019;d expect.&lt;/p&gt;
&lt;p&gt;4. syslinux-extlinux is WAY nicer and simpler to use than grub2 &lt;img src="http://s0.wp.com/wp-includes/images/smilies/icon_smile.gif" alt=":)" class="wp-smiley"/&gt;&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;p&gt;Thanks to Mattdm for making the syslinux-extlinux option for anaconda happen.&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;br/&gt;&lt;a href="http://feeds.wordpress.com/1.0/gocomments/skvidal.wordpress.com/1085/" &gt;
  &lt;img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skvidal.wordpress.com/1085/"/&gt;&lt;/a&gt; &lt;img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skvidal.wordpress.com&amp;amp;blog=579402&amp;amp;post=1085&amp;amp;subd=skvidal&amp;amp;ref=&amp;amp;feed=1" width="1" height="1"/&gt;</description>
    </item>
    <item>
      <pubDate>Thu, 25 Apr 2013 04:08:20 GMT</pubDate>
      <title>ansible rpm compare</title>
      <link>http://www.advogato.org/person/skvidal/diary.html?start=461</link>
      <guid>http://skvidal.wordpress.com/2013/04/25/ansible-rpm-compare/</guid>
      <description>&lt;p&gt;A while back&#xA0;I wrote this for func &#x2013; and I found I needed it ported to ansible.&lt;/p&gt;
&lt;p&gt;I enhanced it to make it take more than just 2 systems. It can now compare any number of systems to the base system&lt;/p&gt;
&lt;p&gt;
  &lt;a href="http://fedorapeople.org/cgit/skvidal/public_git/scripts.git/tree/ansible/ans_rpm_compare.py" &gt;http://fedorapeople.org/cgit/skvidal/public_git/scripts.git/tree/ansible/ans_rpm_compare.py&lt;/a&gt;
&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;p&gt;Takes a first argument of your &#x2018;baseline&#x2019; host that&#x2019;s the host all the other hosts package sets will be compared to.&lt;/p&gt;
&lt;p&gt;It grabs the list of rpms installed on each system (just using rpm -qa, I&#x2019;m lazy, or I could have used the yum list=installed option)&lt;/p&gt;
&lt;p&gt;It transforms that output into a set &#x2013; then does a difference on them each way.&lt;/p&gt;
&lt;p&gt;Output looks like this&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;$ ans_rpm_compare.py app01.phx2.fedoraproject.org app02.phx2.fedoraproject.org&lt;br/&gt;
Packages on app01.phx2.fedoraproject.org not on app02.phx2.fedoraproject.org&lt;br/&gt;
words-3.0-17.el6.noarch&lt;br/&gt;
fedmsg-relay-0.6.8-1.el6.noarch&lt;br/&gt;
gdb-7.2-60.el6.i686&lt;/p&gt;
&lt;p&gt;Packages on app02.phx2.fedoraproject.org not on app01.phx2.fedoraproject.org&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;p&gt;Trivial but should be straightforward to follow how it works in the code.&lt;/p&gt;
&lt;p&gt;No idea where else to put it so it goes into my scripts git repo.&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;br/&gt;&lt;a href="http://feeds.wordpress.com/1.0/gocomments/skvidal.wordpress.com/1083/" &gt;
  &lt;img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skvidal.wordpress.com/1083/"/&gt;&lt;/a&gt; &lt;img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skvidal.wordpress.com&amp;amp;blog=579402&amp;amp;post=1083&amp;amp;subd=skvidal&amp;amp;ref=&amp;amp;feed=1" width="1" height="1"/&gt;</description>
    </item>
    <item>
      <pubDate>Mon, 22 Apr 2013 18:04:50 GMT</pubDate>
      <title>mailman archiver failure</title>
      <link>http://www.advogato.org/person/skvidal/diary.html?start=460</link>
      <guid>http://skvidal.wordpress.com/2013/04/22/mailman-archiver-failure/</guid>
      <description>&lt;p&gt;If you see this traceback in your /var/log/mailman/error file&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;div&gt;
&lt;blockquote&gt;&lt;p&gt;File &#x201C;/usr/lib/mailman/Mailman/Queue/Runner.py&#x201D;, line 120, in _oneloop&lt;br/&gt;
self._onefile(msg, msgdata)&lt;br/&gt;
File &#x201C;/usr/lib/mailman/Mailman/Queue/Runner.py&#x201D;, line 191, in _onefile&lt;br/&gt;
keepqueued = self._dispose(mlist, msg, msgdata)&lt;br/&gt;
File &#x201C;/usr/lib/mailman/Mailman/Queue/ArchRunner.py&#x201D;, line 73, in _dispose&lt;br/&gt;
mlist.ArchiveMail(msg)&lt;br/&gt;
File &#x201C;/usr/lib/mailman/Mailman/Archiver/Archiver.py&#x201D;, line 216, in ArchiveMail&lt;br/&gt;
h.processUnixMailbox(f)&lt;br/&gt;
File &#x201C;/usr/lib/mailman/Mailman/Archiver/pipermail.py&#x201D;, line 583, in processUnixMailbox&lt;br/&gt;
self.add_article(a)&lt;br/&gt;
File &#x201C;/usr/lib/mailman/Mailman/Archiver/pipermail.py&#x201D;, line 635, in add_article&lt;br/&gt;
article.parentID = parentID = self.get_parent_info(arch, article)&lt;br/&gt;
File &#x201C;/usr/lib/mailman/Mailman/Archiver/pipermail.py&#x201D;, line 669, in get_parent_info&lt;br/&gt;
if parentID and not self.database.hasArticle(archive, parentID):&lt;br/&gt;
File &#x201C;/usr/lib/mailman/Mailman/Archiver/HyperDatabase.py&#x201D;, line 273, in hasArticle&lt;br/&gt;
self.__openIndices(archive)&lt;br/&gt;
File &#x201C;/usr/lib/mailman/Mailman/Archiver/HyperDatabase.py&#x201D;, line 251, in __openIndices&lt;br/&gt;
t = DumbBTree(os.path.join(arcdir, archive + &#x2018;-&#x2019; + i))&lt;br/&gt;
File &#x201C;/usr/lib/mailman/Mailman/Archiver/HyperDatabase.py&#x201D;, line 65, in __init__&lt;br/&gt;
self.load()&lt;br/&gt;
File &#x201C;/usr/lib/mailman/Mailman/Archiver/HyperDatabase.py&#x201D;, line 170, in load&lt;br/&gt;
self.dict = marshal.load(fp)&lt;br/&gt;
ValueError: bad marshal data&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;It is due to a corrupted archive database. Those live in /var/lib/mailman/archives/private/$list/database/*&lt;/p&gt;
&lt;p&gt;In order to figure out which one it is &#x2013; you have to run this:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;p&gt;#!/usr/bin/python&lt;/p&gt;
&lt;p&gt;import os, sys&lt;br/&gt;
sys.path.insert(0, &#x2018;/usr/lib/mailman&#x2019;)&lt;/p&gt;
&lt;p&gt;import Mailman.Archiver&lt;br/&gt;
import marshal&lt;br/&gt;
for fn in sys.argv[1:]:&lt;br/&gt;
if os.path.exists(fn):&lt;br/&gt;
c = marshal.load(open(fn))&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;p&gt;against the files in the dir I mentioned above.&lt;/p&gt;
&lt;p&gt;like this&lt;/p&gt;
&lt;p&gt;python thatscript /var/lib/mailman/archives/private/$list/database/2013-April*&lt;/p&gt;
&lt;p&gt;That will tell you if a file is busted, (it will print out an exception) but it won&#x2019;t fix it.&lt;/p&gt;
&lt;p&gt;You will probably need to run it against all of the current files for all the lists you have &lt;img src="http://s0.wp.com/wp-includes/images/smilies/icon_sad.gif" alt=":(" class="wp-smiley"/&gt;&lt;/p&gt;
&lt;p&gt;Once you figure out which lists are broken you SHOULD be able to run&lt;/p&gt;
&lt;p&gt;bin/arch &#x2013;wipe listname /var/lib/archives/private/$list.mbox/$list.mbox&lt;/p&gt;
&lt;p&gt;and have it recreate the whole thing.&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;/div&gt;
&lt;br/&gt;&lt;a href="http://feeds.wordpress.com/1.0/gocomments/skvidal.wordpress.com/1081/" &gt;
  &lt;img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skvidal.wordpress.com/1081/"/&gt;&lt;/a&gt; &lt;img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skvidal.wordpress.com&amp;amp;blog=579402&amp;amp;post=1081&amp;amp;subd=skvidal&amp;amp;ref=&amp;amp;feed=1" width="1" height="1"/&gt;</description>
    </item>
    <item>
      <pubDate>Wed, 27 Mar 2013 05:04:53 GMT</pubDate>
      <title>polling/diffing instances in openstack</title>
      <link>http://www.advogato.org/person/skvidal/diary.html?start=459</link>
      <guid>http://skvidal.wordpress.com/2013/03/27/pollingdiffing-instances-in-openstack/</guid>
      <description>&lt;p&gt;I&#x2019;m trying to produce a simple list of instances on the fedora&lt;/p&gt;
&lt;p&gt;openstack instance. I want to produce a list every 10m or so and diff&lt;/p&gt;
&lt;p&gt;it against the last copy of that list and output the changes.&lt;/p&gt;
&lt;p&gt;Here&#x2019;s what I came up with:&lt;br/&gt;&lt;a href="http://fedorapeople.org/cgit/skvidal/public_git/scripts.git/tree/openstack/gather-diff-instances.py" &gt;http://fedorapeople.org/cgit/skvidal/public_git/scripts.git/tree/openstack/gather-diff-instances.py&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;it is based originally on nova-manage. It runs as root on the head&#xA0;system in our cloud and just dumps out json, then diffs the json.&lt;/p&gt;
&lt;p&gt;Everything works but I&#x2019;m trying to figure out if this is the &#x2018;right&#x2019;&lt;br/&gt;
way of going about this.&lt;br/&gt;
I thought about doing it via nova instead of using the nova-manage&lt;br/&gt;
direct-to-db api but I had 2 problems:&lt;/p&gt;
&lt;p&gt;1. I would need to save the plaintext admin pw somewhere on disk to&lt;br/&gt;
poll for that info&lt;/p&gt;
&lt;p&gt;2. or get a token which I would have to renew every 24 hours&lt;/p&gt;
&lt;p&gt;We&#x2019;re using the above the script as a simple cron job that lets us know&lt;br/&gt;
what things are changing in our cloud (who is bringing up new&lt;br/&gt;
instances, how many, what ips they are attaching to them, etc)&lt;/p&gt;
&lt;p&gt;Additionally, is there a way in the db api to easily query the tenant and user info from keystone? I&#x2019;d like to expand out the user uuid into username/project name.&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;br/&gt;&lt;a href="http://feeds.wordpress.com/1.0/gocomments/skvidal.wordpress.com/1079/" &gt;
  &lt;img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skvidal.wordpress.com/1079/"/&gt;&lt;/a&gt; &lt;img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skvidal.wordpress.com&amp;amp;blog=579402&amp;amp;post=1079&amp;amp;subd=skvidal&amp;amp;ref=&amp;amp;feed=1" width="1" height="1"/&gt;</description>
    </item>
    <item>
      <pubDate>Fri, 22 Mar 2013 22:10:41 GMT</pubDate>
      <title>gitproxy</title>
      <link>http://www.advogato.org/person/skvidal/diary.html?start=458</link>
      <guid>http://skvidal.wordpress.com/2013/03/22/gitproxy/</guid>
      <description>&lt;p&gt;gitproxy:&lt;br/&gt;&lt;a href="http://skvidal.fedorapeople.org/misc/gitproxy" &gt;http://skvidal.fedorapeople.org/misc/gitproxy&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Dealing with a potential problem we were trying to figure out a way to proxy/redirect git:// calls from one server to another one. This is a fairly ridiculous script I hacked up in the wee-small hours of thursday morning after talking to+&lt;a href="https://plus.google.com/115609618223925128756" &gt;Sitaram Chamarty&lt;/a&gt;&#xA0;on&#xA0;&lt;a href="https://plus.google.com/s/%23git" &gt;#git&lt;/a&gt;&#xA0;&#xA0;for a while.&lt;/p&gt;
&lt;p&gt;I fully expect this won&#x2019;t work well under load but it does seem to function in my small tests here.&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;br/&gt;&lt;a href="http://feeds.wordpress.com/1.0/gocomments/skvidal.wordpress.com/1076/" &gt;
  &lt;img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skvidal.wordpress.com/1076/"/&gt;&lt;/a&gt; &lt;img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skvidal.wordpress.com&amp;amp;blog=579402&amp;amp;post=1076&amp;amp;subd=skvidal&amp;amp;ref=&amp;amp;feed=1" width="1" height="1"/&gt;</description>
    </item>
    <item>
      <pubDate>Fri, 22 Mar 2013 17:04:33 GMT</pubDate>
      <title>diffing two ini files</title>
      <link>http://www.advogato.org/person/skvidal/diary.html?start=457</link>
      <guid>http://skvidal.wordpress.com/2013/03/22/diffing-two-ini-files/</guid>
      <description>&lt;p&gt;Ever need to diff 2 ini files but their sections and options aren&#x2019;t in the right order?&lt;/p&gt;
&lt;p&gt;Well, I do. I googled but I couldn&#x2019;t find anything trivially available that did this.&lt;/p&gt;
&lt;p&gt;I swear I wrote this once before but I couldn&#x2019;t find it when I looked through my dirs of misc scripts so:&lt;/p&gt;
&lt;p&gt;
  &lt;a href="http://fedorapeople.org/cgit/skvidal/public_git/scripts.git/tree/inidiff" &gt;http://fedorapeople.org/cgit/skvidal/public_git/scripts.git/tree/inidiff&lt;/a&gt;
&lt;/p&gt;
&lt;p&gt;hope it is useful to someone.&lt;/p&gt;
&lt;br/&gt;&lt;a href="http://feeds.wordpress.com/1.0/gocomments/skvidal.wordpress.com/1072/" &gt;
  &lt;img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skvidal.wordpress.com/1072/"/&gt;&lt;/a&gt; &lt;img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skvidal.wordpress.com&amp;amp;blog=579402&amp;amp;post=1072&amp;amp;subd=skvidal&amp;amp;ref=&amp;amp;feed=1" width="1" height="1"/&gt;</description>
    </item>
    <item>
      <pubDate>Thu, 7 Mar 2013 01:04:40 GMT</pubDate>
      <title>async actions in ansible playbooks</title>
      <link>http://www.advogato.org/person/skvidal/diary.html?start=456</link>
      <guid>http://skvidal.wordpress.com/2013/03/07/async-actions-in-ansible-playbooks/</guid>
      <description>&lt;p&gt;A number of people have been surprised by this feature, even though it is documented, so I thought I&#x2019;d mention it.&lt;/p&gt;
&lt;p&gt;Ansible can run actions async. This means it connects to the client system, starts the process and disconnects.&lt;/p&gt;
&lt;p&gt;In general you would want all your plays to be synchronous (do thing X, wait for it to be done/watch it, do thing Y).&lt;/p&gt;
&lt;p&gt;However, there are times when what you want to do will take a VERY long time or could kill your ssh connection off.&lt;/p&gt;
&lt;p&gt;An example is a yum update:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;tasks:&lt;/p&gt;
&lt;p&gt;- name: yum update&lt;/p&gt;
&lt;p&gt;action: command yum -y update&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;That can take a long time, depending on what&#x2019;s going on. You want to monitor what it does, but you don&#x2019;t want a timeout or a reset ssh session/network to kill off that process.&lt;/p&gt;
&lt;p&gt;So what do you do? You make it async:&lt;/p&gt;
&lt;blockquote&gt;&lt;p&gt;tasks:&lt;/p&gt;
&lt;p&gt;- name: yum update&lt;/p&gt;
&lt;p&gt;action: command yum -y update&lt;/p&gt;
&lt;p&gt;async: 7200&lt;/p&gt;
&lt;p&gt;poll: 15&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;That means &#x2013; run yum -y update &#x2013; wait for up to 7200s and poll every 15s to check on the status of the action.&lt;/p&gt;
&lt;p&gt;Here&#x2019;s where we&#x2019;re using it in fedora:&lt;/p&gt;
&lt;p&gt;
  &lt;a href="http://infrastructure.fedoraproject.org/cgit/ansible.git/tree/playbooks/package-update.yml#n11" &gt;http://infrastructure.fedoraproject.org/cgit/ansible.git/tree/playbooks/package-update.yml#n11&lt;/a&gt;
&lt;/p&gt;
&lt;p&gt;However, this means if your ssh or network were to die &#x2013; the yum update process would still run to completion.&lt;/p&gt;
&lt;p&gt;But if your connection does die and you cannot check on the status of the job what do you do?&lt;/p&gt;
&lt;p&gt;Well -you can connect to any system as the user who was running the job and look in ~/.ansible_async&lt;/p&gt;
&lt;p&gt;there will be a file in there for each job that was being run. It may just be a place holder and empty (if the job is still running) or it made be filled with the results if the job is finished.&lt;/p&gt;
&lt;p&gt;Pretty handy for a variety of tasks.&lt;/p&gt;
&lt;p&gt;&#xA0;&lt;/p&gt;
&lt;br/&gt;&lt;a href="http://feeds.wordpress.com/1.0/gocomments/skvidal.wordpress.com/1069/" &gt;
  &lt;img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/skvidal.wordpress.com/1069/"/&gt;&lt;/a&gt; &lt;img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=skvidal.wordpress.com&amp;amp;blog=579402&amp;amp;post=1069&amp;amp;subd=skvidal&amp;amp;ref=&amp;amp;feed=1" width="1" height="1"/&gt;</description>
    </item>
  </channel>
</rss>
