<?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>techslaves.org &#187; server</title>
	<atom:link href="http://techslaves.org/tag/server/feed/" rel="self" type="application/rss+xml" />
	<link>http://techslaves.org</link>
	<description>Owned (and fascinated) by technology!</description>
	<lastBuildDate>Thu, 23 Feb 2012 04:55:07 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>(De)Centralized</title>
		<link>http://techslaves.org/2011/10/07/de-centralizing/</link>
		<comments>http://techslaves.org/2011/10/07/de-centralizing/#comments</comments>
		<pubDate>Fri, 07 Oct 2011 23:11:59 +0000</pubDate>
		<dc:creator>rthomson</dc:creator>
				<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[datacenter]]></category>
		<category><![CDATA[neural emesis]]></category>
		<category><![CDATA[rant]]></category>
		<category><![CDATA[server]]></category>

		<guid isPermaLink="false">http://techslaves.org/?p=166</guid>
		<description><![CDATA[&#8220;The primary motivation for the decentralized model is to give the individual departments better or more customized service through having a stronger relationship with the SAs and more control over the work that they do. The primary motivation for centralizing system administration is to control costs through tracking costs centrally and then reducing them by [...]
No related posts.]]></description>
			<content:encoded><![CDATA[<p>&#8220;<em>The primary motivation for the decentralized model is to give the individual departments better or more customized service through having a stronger relationship with the SAs and more control over the work that they do. The primary motivation for centralizing system administration is to control costs through tracking costs centrally and then reducing them by eliminating redundancy and taking advantage of economies of scale</em>&#8221;</p>
<p>&#8211; <span style="text-decoration: underline;">The Practice of System and Network Administration</span>, Thomas A. Limoncelli and Christine Hogan.</p>
<p>Bingo. But can there be a third hybrid model?</p>
<p>I currently represent the decentralized model and I must agree with these two fine authors that the benefit of my close working relationship with the individual department/group is that the service provided is highly customized and focused. The central IT department(s) are understandably focused on large-scale issues (&#8220;Infrastructure&#8221;, &#8220;Communications&#8221;, &#8220;Collaboration&#8221;, &#8220;Applications&#8221;) and as such do not always represent the most ideal channel for delivery of IT services to the various research groups and departments on campus, often with more nuanced, specialized and micro-level issues.</p>
<p>One of my developing long-term goals is to (warning: business jargon) &#8220;bridge the gap&#8221; between the focused local support that I currently represent and the value proposition(s) of centralized IT services. I&#8217;m not yet entirely certain of how to accomplish this but I am certain that there is a way to improve the delivery of IT services to researchers across all our campuses and I want to be involved.</p>
<p>Does such an approach warrant the definition of a third hybrid model or is this so-called bridging of the gap already encapsulated in the model of centralized vs. decentralized?</p>
<p>Some of the challenges I face specifically as a &#8220;standalone&#8221; decentralized sysadmin on campus are:</p>
<ul>
<li>Dealing with <em>all</em> IT needs from desktop support to infrastructure development to data security</li>
<li>Developing and maintaining vendor contacts and relationships</li>
<li>No immediate peers in our environment to bounce specific ideas around with</li>
<li>Weak purchasing power and negotiation leverage</li>
<li>Duplication of effort</li>
<li>Career progression is potentially limited</li>
<li>All too easy to develop a &#8220;King of the Castle&#8221; attitude</li>
<li>Complacency</li>
</ul>
<p>Some of the concerns I hear about when introducing researchers to the idea of centralized IT support:</p>
<ul>
<li>General lack of trust/faith in the centralized IT department</li>
<li>Perceived lack of personal attention and focus (turn around times, site knowledge, etc.)</li>
<li>Perceived lack of &#8220;control&#8221; over their environment (and data!) under the centralized model</li>
<li>Charge-back models for IT services are viewed as grant-unfriendly</li>
<li>Physical hardware ownership appears to remain important for many researchers</li>
</ul>
<p>Of course, this is but a snapshot of the challenges I face and the concerns I&#8217;ve been hearing but they do serve as decent examples. It must also be noted that I am seeing great progress is many of these areas already because there are very bright people here already working on these challenges. My interest in this field is absolutely not unique.</p>
<p>For the immediate future, I&#8217;m focusing on improving my collaborations and communication with centralized IT services by helping them out where I can and leaning on them more often for our localized problems. My hope is that by constantly forging a closer working relationship will increasingly expose me (and in turn, our group) to the benefits of the centralized IT model while providing the central IT group with greater insight into our environment and how we work.</p>
<p>The next steps are still a mystery to me but I&#8217;m keeping my eyes open for new opportunities to bring better IT to research.</p>
<p>No related posts.</p>]]></content:encoded>
			<wfw:commentRss>http://techslaves.org/2011/10/07/de-centralizing/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>FreeIPA and Samba 3 Integration</title>
		<link>http://techslaves.org/2011/08/24/freeipa-and-samba-3-integration/</link>
		<comments>http://techslaves.org/2011/08/24/freeipa-and-samba-3-integration/#comments</comments>
		<pubDate>Thu, 25 Aug 2011 05:06:28 +0000</pubDate>
		<dc:creator>rthomson</dc:creator>
				<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[freeipa]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[redhat]]></category>
		<category><![CDATA[samba]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://techslaves.org/?p=169</guid>
		<description><![CDATA[FreeIPA makes a pretty excellent backend for Samba 3. While all the information one needs to set this up is available online, I wasn&#8217;t able to find it all  in one location so I&#8217;ve decided to try my best at filling that gap here on techslaves.org. Hopefully this short guide will aid those trying to piece [...]
Related posts:<ol>
<li><a href='http://techslaves.org/2010/10/05/ldap-user-management-tools-and-user-private-groups/' rel='bookmark' title='LDAP User Management Tools and User Private Groups'>LDAP User Management Tools and User Private Groups</a></li>
<li><a href='http://techslaves.org/2010/08/04/life-support/' rel='bookmark' title='Life Support!'>Life Support!</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>FreeIPA makes a pretty excellent backend for Samba 3. While all the information one needs to set this up is available online, I wasn&#8217;t able to find it all  in one location so I&#8217;ve decided to try my best at filling that gap here on techslaves.org. Hopefully this short guide will aid those trying to piece together the various parts necessary to integrate FreeIPA v2 and Samba 3, at least until FreeIPA v3 where there is talk of enabling Samba integration with a simple command line argument to the &#8220;ipa-server-install&#8221; script.</p>
<h1>Not for Domains</h1>
<p>It&#8217;s important to keep in mind that these instructions are not for a integrating FreeIPA with a Samba domain controller but merely a Samba file server. My understanding is that FreeIPA will never conveniently/properly support the necessary bits to make it a suitable backend for a Samba 3 PDC. I believe FreeIPA will eventually look towards Samba 4 integration (using Domain trusts) for this kind of integration but don&#8217;t quote me on that. Either way, these instructions are not for Samba domain controllers, just Samba file servers.</p>
<h1>The Assumptions</h1>
<p>There are some basic assumptions that these instructions make.</p>
<ul>
<li>FreeIPA is installed and functional</li>
<li>You have a general idea of how to use LDAP command line tools</li>
<li>If you have a nice GUI LDAP browser, you can use it to apply the example LDIFs and edit the tree instead of the ldap CLI tools</li>
<li>The LDAP commands are executed on the FreeIPA server</li>
<li>Samba and FreeIPA are installed on the same server (although it shouldn&#8217;t be difficult to use TLS encryption with separate servers)</li>
<li>Your LDAP suffix is <em>&#8220;dc=domain,dc=tld&#8221;</em></li>
<li>You know the difference between the &#8220;admin&#8221; account and the directory manager and their passwords</li>
</ul>
<h1>The Goods</h1>
<p>Let&#8217;s not beat around the bush any further.</p>
<p>1. Determine your Samba server SID by executing the following command while <em>smbd</em> is running and jot it down:</p>
<pre>root@ipaserver:~
# net getlocalsid
SID for IPASERVER domain  is: S-1-5-21-3180075094-3458813485-3821849995</pre>
<p>2. With the &#8220;admin&#8221; kerberos ticket, add two attributes to &#8220;<em>cn=ipaConfig,dc=etc,dc=domain,dc=tld&#8221;</em> that tell FreeIPA to setup each account as a Samba account and each group as a Samba group:</p>
<pre>ldapmodify -Y GSSAPI &lt;&lt;EOF
dn: cn=ipaconfig,cn=etc,dc=domain,dc=tld
changetype: modify
add: ipaUserObjectClasses
ipaUserObjectClasses: sambaSAMAccount
-
add: ipaGroupObjectClasses
ipaGroupObjectClasses: sambaGroupMapping
EOF</pre>
<p>3. With the directory manager password and the Samba SID you jotted down from above, create an instance of the 389 DS DNA plugin that will automatically generate SIDs for your users and groups which are necessary for use with Samba:</p>
<pre>ldapadd -x -D "cn=Directory Manager" -W &lt;&lt;EOF
dn: cn=SambaGroupSid,cn=Distributed Numeric Assignment Plugin,cn=plugins,cn=config
objectClass: top
objectClass: extensibleObject
dnatype: sambaSID
dnaprefix: S-1-5-21-3180075094-3458813485-3821849995-
dnainterval: 1
dnamagicregen: assign
dnafilter: (|(objectclass=sambasamaccount)(objectclass=sambagroupmapping))
dnascope: dc=domain,dc=tld
cn: SambaSid
dnanextvalue: 15277
EOF</pre>
<p>The thing to note here is that the <em>&#8220;dnaprefix&#8221;</em> is set to the SID your jotted down… <em>PLUS</em> a hyphen (&#8220;-&#8221;) appended to the end!</p>
<p>4. Now we have to start modifying the FreeIPA API, CLI and WebUI to allow us to specify the <em>&#8220;sambaGroupType&#8221;</em> attribute at group creation time. We have to set <em>&#8220;sambaGroupType&#8221;</em> because it is a required attribute for the objectClass <em>&#8220;sambaGroupMapping&#8221;</em> which we are automatically adding to every group with the <em>&#8220;ipaGroupObjectClasses&#8221;</em> setting from earlier.</p>
<p>Although the value is going to be &#8220;4&#8243; for every conceivable case in this non-domain configuration, I was not able to figure out how to make the DNA plugin insert static values like it can set incrementing values so I decided to allow setting it through the CLI and WebUS with defaults enabled instead. If anyone knows how to setup 389 to automatically add an attribute with a static value upon DN creation of DNs with specific objectClasses, please tell me.</p>
<p>There are a few steps required to make this CLI/UI stuff happen but the FreeIPA developers have actually made this quite simple.</p>
<p>The rule is: Extend the FreeIPA schema first, then the CLI, then the WebUI.</p>
<p>4.1. Extend the FreeIPA schema with a custom field by adding the attribute <em>&#8220;ipaCustomFields&#8221;</em> with a value of <em>&#8220;Samba Group Type,sambagrouptype,true&#8221;</em> to <em>&#8220;cn=ipaConfig,dc=etc,dc=domain,dc=tld&#8221;</em> with an &#8220;admin&#8221; kerberos ticket:</p>
<pre>ldapmodify -Y GSSAPI &lt;&lt;EOF
dn: cn=ipaconfig,cn=etc,dc=domain,dc=tld
changetype: add
add: ipaCustomFields
ipaCustomFields: "Samba Group Type,sambagrouptype,true"
EOF</pre>
<p>As there can only be one <em>&#8220;ipaCustomFields&#8221;</em> attribute, if you have multiple custom fields you need to separate each definition with a &#8220;$&#8221; like so: <em>&#8220;Samba Group Type,sambagrouptype,true$Description,attrname,isrequiredboolean&#8221;</em>.</p>
<p>4.2. Extend the CLI for groups by editing the python file &#8220;/&#8230;/site-packages/ipalib/plugins/group.py&#8221; to define the custom field and specify a default if not implicitly defined (diff):</p>
<pre>--- group.py.orig	2011-08-15 14:59:48.570715207 -0700
+++ group.py	2011-08-16 12:43:43.493236507 -0700
@@ -118,6 +118,13 @@
             label=_('GID'),
             doc=_('GID (use this option to set it manually)'),
         ),
+        Int('sambagrouptype',
+            cli_name='sgt',
+            label=_('Samba Group Type'),
+            doc=_('Samba Group Type (default is 4)'),
+            default=4,
+            autofill=True,
+        ),
     )

 api.register(group)</pre>
<p><strong>Important</strong>: Restart &#8220;httpd&#8221; at this point!</p>
<p>4.3. Test the CLI. With an &#8220;admin&#8221; (or equivalent priv) kerberos ticket, try creating a new group:</p>
<pre>account@ipaserver:~
$ ipa group-add testgrp --desc="Testing the group.py CLI mods"
---------------------
Added group "testgrp"
---------------------
  Group name: testgrp
  Description: Testing the group.py CLI mods
  GID: 1234500010
  Samba Group Type: 4</pre>
<p>4.4 With the CLI functioning properly, we can move on to extending the WebUI. To extend the WebUI for group attributes, edit &#8220;/usr/share/ipa/ui/group.js&#8221; like so (diff):</p>
<pre>--- group.js.orig	2011-08-15 10:01:28.515209121 -0700
+++ group.js	2011-08-16 13:52:59.587352034 -0700
@@ -34,6 +34,7 @@
                 column({name: 'cn'}).
                 column({name: 'gidnumber'}).
                 column({name: 'description'}).
+                column({name: 'sambagrouptype'}).
                 dialog(
                     IPA.add_dialog({
                         'name': 'add',
@@ -41,6 +42,7 @@
                     }).
                         field(IPA.text_widget({name: 'cn', undo: false})).
                         field(IPA.text_widget({name: 'description', undo: false})).
+                        field(IPA.select_widget({name: 'sambagrouptype', undo: false, options: [{label: 'Local', value: 4}, {label: 'Domain', value: 2}]})).
                         field(IPA.checkbox_widget({
                             name: 'posix',
                             label: IPA.messages.objects.group.posix,
@@ -56,6 +58,7 @@
                     }).
                         input({name: 'cn' }).
                         input({name: 'description'}).
+                        input({name: 'sambagrouptype'}).
                         input({name: 'gidnumber' }))).
         facet(
             IPA.group_member_user_facet({</pre>
<p>And then these the WebUI to ensure that you can both see the attribute in the group list, but also add it via the select widget added to the new/edit group dialog.</p>
<p>That should be it. Questions, comments, suggestions, correction and more… all are welcome!</p>
<p>Related posts:<ol>
<li><a href='http://techslaves.org/2010/10/05/ldap-user-management-tools-and-user-private-groups/' rel='bookmark' title='LDAP User Management Tools and User Private Groups'>LDAP User Management Tools and User Private Groups</a></li>
<li><a href='http://techslaves.org/2010/08/04/life-support/' rel='bookmark' title='Life Support!'>Life Support!</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://techslaves.org/2011/08/24/freeipa-and-samba-3-integration/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Which Distro for PPC64 Server?</title>
		<link>http://techslaves.org/2011/03/08/which-distro-for-ppc64-server/</link>
		<comments>http://techslaves.org/2011/03/08/which-distro-for-ppc64-server/#comments</comments>
		<pubDate>Tue, 08 Mar 2011 08:02:43 +0000</pubDate>
		<dc:creator>rthomson</dc:creator>
				<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[crux ppc]]></category>
		<category><![CDATA[cruxppc]]></category>
		<category><![CDATA[debian]]></category>
		<category><![CDATA[distribution]]></category>
		<category><![CDATA[distro]]></category>
		<category><![CDATA[gentoo]]></category>
		<category><![CDATA[ibm]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[p505]]></category>
		<category><![CDATA[p505 express]]></category>
		<category><![CDATA[ppc]]></category>
		<category><![CDATA[ppc64]]></category>
		<category><![CDATA[pseries]]></category>
		<category><![CDATA[server]]></category>

		<guid isPermaLink="false">http://techslaves.org/?p=131</guid>
		<description><![CDATA[We (work) have two IBM p505 Express Servers. Right now one machine is running an old way out of support RHEL4 installation and the other is on Fedora 12, which is no longer supported by the Fedora Project. Paid support/subscription is not a consideration yet for this project, but I do want to run a [...]
No related posts.]]></description>
			<content:encoded><![CDATA[<p>We (work) have two IBM p505 Express Servers.</p>
<p>Right now one machine is running an old way out of support RHEL4 installation and the other is on Fedora 12, which is no longer supported by the Fedora Project. Paid support/subscription is not a consideration yet for this project, but I do want to run a modern Linux distribution for the associated modern application software and maintenance.</p>
<p>I basically need to move these servers to something free and supportable. I&#8217;m finding out that there aren&#8217;t a lot of options in PPC Linux as when I was last interested in this architecture. It&#8217;s pretty much just:</p>
<ul>
<li><a href="http://www.debian.org/ports/powerpc/">Debian</a></li>
<li><a href="http://cruxppc.org">CRUX PPC</a></li>
<li><a href="http://www.gentoo.org/proj/en/base/ppc64/">Gentoo</a></li>
</ul>
<p>I realize there is RHEL and SuSE Enterprise for PPC64 but those are subscription products without free binaries available. I&#8217;m not prepared to build an RPM-based distro from source at this point so I need something with binaries or something where building from source is highly automated and integrated, such as Gentoo. Digression&#8230;</p>
<p>The question is which of these distros do I go with? To answer the question I suppose I need to define the roles.</p>
<p>These two pSeries servers a redundant pair running LDAP/Auth Service, NTP, DNS and DHCP. The load is low but I want a solid modern software platform on both these servers from now until they are replaced with in the future (which is likely to be integration into a centralized architecture).</p>
<p>With that said, and with my familiarity level of these distros, I would first lean towards Debian and then to Gentoo and finally to CRUX PPC.</p>
<p>Debian is a binary distribution, which is nice for maintaining a server. Debian is more familiar to me. What are the arguments for Gentoo or CRUX PPC?</p>
<p>Agree or Disagree?</p>
<p>No related posts.</p>]]></content:encoded>
			<wfw:commentRss>http://techslaves.org/2011/03/08/which-distro-for-ppc64-server/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Interesting New Developments&#8230;</title>
		<link>http://techslaves.org/2010/11/10/interesting-new-developments/</link>
		<comments>http://techslaves.org/2010/11/10/interesting-new-developments/#comments</comments>
		<pubDate>Wed, 10 Nov 2010 06:43:24 +0000</pubDate>
		<dc:creator>rthomson</dc:creator>
				<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[aiglx]]></category>
		<category><![CDATA[amd]]></category>
		<category><![CDATA[centos]]></category>
		<category><![CDATA[chroot]]></category>
		<category><![CDATA[fedora]]></category>
		<category><![CDATA[gdm]]></category>
		<category><![CDATA[kvm]]></category>
		<category><![CDATA[ldm]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[localdev]]></category>
		<category><![CDATA[ltsp]]></category>
		<category><![CDATA[magny cours]]></category>
		<category><![CDATA[radeon]]></category>
		<category><![CDATA[rhel]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[virtualization]]></category>
		<category><![CDATA[windows]]></category>
		<category><![CDATA[xdmcp]]></category>

		<guid isPermaLink="false">http://techslaves.org/?p=104</guid>
		<description><![CDATA[There have been some interesting new developments lately! Here&#8217;s a shrunken summary. At present I&#8217;m doing a technology review for implementing a new terminal server. Our existing terminal server is a 4-way AMD Opteron 848 system that&#8217;s about 5 years old right now. It runs CentOS 4 and has been so mega-customized over those 5 [...]
Related posts:<ol>
<li><a href='http://techslaves.org/2010/11/23/ltsp-5-and-aiglx/' rel='bookmark' title='LTSP 5 and AIGLX'>LTSP 5 and AIGLX</a></li>
<li><a href='http://techslaves.org/2010/11/15/a-correction/' rel='bookmark' title='A Correction'>A Correction</a></li>
<li><a href='http://techslaves.org/2011/01/07/fresh-win2k-install-and-windows-update-error/' rel='bookmark' title='Fresh Win2k Install and Windows Update Error'>Fresh Win2k Install and Windows Update Error</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>There have been some interesting new developments lately! Here&#8217;s a shrunken summary.</p>
<p>At present I&#8217;m doing a technology review for implementing a new terminal server. Our existing terminal server is a 4-way AMD Opteron 848 system that&#8217;s about 5 years old right now. It runs CentOS 4 and has been so mega-customized over those 5 years, I&#8217;ve never wanted to go through the pain of in-place upgrading to CentOS 5. We also have a simple IBM 1U server running Windows 2003 Server for windows purposes. It&#8217;s ok but also about 5 years old.</p>
<p>The idea is to roll both these servers into a large single physical server with some kind of virtualization. The large system would also have the resources to run other VMs, as necessary. Development/test boxes or what not.</p>
<p><span id="more-104"></span></p>
<h2>Hardware and Virtualization</h2>
<p>The server is a 48 core AMD 6172 (2.1GHz) with 64GB of DDR3 ECC RAM with a bunch of 15K RPM SAS drives. I&#8217;m not sure whether the AMD solution is entirely the right solution. Intel does score amazingly well on virtualization workload benchmarks&#8230; but our workload is different than the benchmark workloads. What we need is one huge guest with a crap-ton of VCPUs and one guest with 2 VCPU and 4GB of RAM. The last NUMA node/cell is pinned to the Windows (smaller) VM and the Linux (large) VM is pinned across several NUMA cells. The Linux VM is a multi-user system where many users will want to run intensive computation but desktop as well. The existing server would sometimes be starved of resources when too many users would start intensive programs simultaneously.</p>
<p>What I can&#8217;t quite seem to figure out regarding this whole KVM this yet is if the guest is smart enough and if KVM allows for mapping the VCPUs and the guest memory according to physical NUMA topology thus reducing likelyhood of slow inter-cell memory access?</p>
<h2>Software</h2>
<p>Anyways&#8230; now that the server has arrived, I&#8217;ve started out with RHEL6 beta2 as the &#8220;hypervisor&#8221;, if you will. I&#8217;m obviously using KVM and libvirt as this is what RedHat is backing. So far, so good. I&#8217;ve only used virt-manager and virtsh thus far, I&#8217;ll explore other tools a little later. Fedora 14 is being used as the Linux VM and Windows 7 Enterprise for the guest&#8230; I&#8217;m going to try out using the Terminal Server multi-user hack and see how that goes. If it won&#8217;t go, I&#8217;ll recommend actually buying the correct Windows Server license, I suppose. Or buy into the VDI stuff that&#8217;s going on around me. I&#8217;ll check out the pricing I suppose&#8230; but I digress.</p>
<h2>Linux Terminal Server: LTSP5</h2>
<p>Fedora 14 with LTSP5 works pretty well. But there are some caveats.</p>
<h3>1. The chroot</h3>
<p>The current ltsp* packages in Fedora14 aren&#8217;t able to build Fedora 14 chroots. You can currently only build Fedora 13 or older because it takes some work to make a complete kickstart LTSP chroot from a new release. Instead of  invoking &#8220;ltsp-build-client&#8221; blindly, you&#8217;ll need to do something like:</p>
<pre># ltsp-build-client --release 13</pre>
<p>This isn&#8217;t a huuuuuuge deal, but in an ideal world I would prefer to use the same release for clients and servers. It&#8217;s just cleaner and makes maintaing everything a bit come congruent for me. It also has some troubleshooting benefits. Bah!</p>
<h3>2. The Display Manager Situation</h3>
<p>LDM, the LTSP5 display manager is both wonderful and woeful. There are some really nice things that LTSP5 can tout due to LDM, but it&#8217;s also a step backwards compared to GDM (yes, even the new all-gtk GDM with reduced XDMCP functionality) or KDM in many ways.</p>
<p>What LDM does so well is proper setup and teardown of LOCALDEV and sound via pulse. It&#8217;s actually pretty slick, especially in GNOME where it gives the users desktop drive icons for portable USB drives/keys. The automatic unmounting of the drive is actually pretty slick but initially it was highly counterintuitive to someone like me who expects to require ejection/unmounting of the drive before pulling it out.</p>
<p>What LDM does poorly is&#8230; well frankly a few things. First off, the feedback from password prompt is poor. It can&#8217;t tell WHY your password failed due to the way it interacts with SSH. It&#8217;s a hard problem to solve, apparently but it&#8217;s a terrible user experience. Second, when you type your password incorrectly, it pauses for some time, tells you it can&#8217;t connect to the server and X restarts to load LDM again. Again, bad user experience. It&#8217;s also not highly customizable. As an example, the login box will span multiple monitors by default so it&#8217;s split across the bezels of your sweet dual monitor thin client. While you can &#8220;hack&#8221; it by providing a wide logo to force the login box off to the right, it&#8217;s not exactly super slick that way.</p>
<p>The last thing LDM doesn&#8217;t seem to do at all is allow for AIGLX/DRI2. If I login using LDM, glxinfo/glxgears barfs on a BadRequest related to DRI2/DRI2Connect. With an XDMCP connection to GDM on the same server, with the same client chroot, lts.conf and xorg configuration and glxinfo displays software rendering but that&#8217;s a different story. Even using a X11 forwarding to another server provides yet more different results. Either way, it appears LDM basically breaks functionality where it would otherwise run, but run fairly slowly. Could be the open source &#8220;radeon&#8221; driver I&#8217;m using on the test box, I suppose. I hear the intel driver works well&#8230;</p>
<p>Since the LOCALDEV and sound routing stuff is tightly integrated to LDM, it appears to be some work to get it working through GDM or KDM&#8230; then there is the problem that I haven&#8217;t had any success making the new GDM (~ &gt;=2.30, I think) to act as an XDMCP chooser. I do have other XDMCP hosts that I want to connect to&#8230;</p>
<p>There is some hope to be had from <a href="https://help.ubuntu.com/community/Updated_Version_For_Feisty">this interesting post</a> on the Ubuntu help/documentation wiki. It details how to install GDM on the LTSP chroot and get LOCALDEV working with it. They claim sound just works on that older version of Ubuntu but I don&#8217;t recall my sound device showing up when using XDMCP and remote GDM. Either way, LOCALDEV is more important.</p>
<h2>Windows Terminal Server: Windows 7 Enterprise</h2>
<p>I can&#8217;t start without saying that Windows 7 via RDP feels &#8220;slower&#8221; than Windows 2003 over RDP. I detect more mouse and menu lag from the same client systems and versions. I disabled aero and it helped but only a very little bit. I&#8217;m not ready to give up yet, there may be more things I can do here.</p>
<p>As mentioned, I&#8217;m trying the termsrv.dll hack that allows for multiple RDP users to non-Windows Server Terminal Services hosts. I wonder if it&#8217;s part of the performance issue I&#8217;m seeing&#8230; I should quickly revert the hack to test that possibility.</p>
<p>On the terminal server and with dual 4:3 monitors, not much of the GUI pizzaz in Windows 7 is all that interesting or useful. Some UI changes compared to XP make things a tad unfamiliar for me but overall it&#8217;s the same experience with a few nice things and seemingly better stability and driver support.</p>
<p>Related posts:<ol>
<li><a href='http://techslaves.org/2010/11/23/ltsp-5-and-aiglx/' rel='bookmark' title='LTSP 5 and AIGLX'>LTSP 5 and AIGLX</a></li>
<li><a href='http://techslaves.org/2010/11/15/a-correction/' rel='bookmark' title='A Correction'>A Correction</a></li>
<li><a href='http://techslaves.org/2011/01/07/fresh-win2k-install-and-windows-update-error/' rel='bookmark' title='Fresh Win2k Install and Windows Update Error'>Fresh Win2k Install and Windows Update Error</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://techslaves.org/2010/11/10/interesting-new-developments/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>LDAP User Management Tools and User Private Groups</title>
		<link>http://techslaves.org/2010/10/05/ldap-user-management-tools-and-user-private-groups/</link>
		<comments>http://techslaves.org/2010/10/05/ldap-user-management-tools-and-user-private-groups/#comments</comments>
		<pubDate>Tue, 05 Oct 2010 23:08:58 +0000</pubDate>
		<dc:creator>rthomson</dc:creator>
				<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[ldap openldap]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://techslaves.org/?p=92</guid>
		<description><![CDATA[Is it just me or are there no LDAP user management tools that support User Private Groups (UPG)? I&#8217;m well aware of the FreeIPA project and that project does in fact support UPG, probably because it&#8217;s a RedHat project but I&#8217;ve determined that FreeIPA is too comprehensive for my needs. Despite Kerberos being the &#8220;right&#8221; [...]
Related posts:<ol>
<li><a href='http://techslaves.org/2011/03/08/which-distro-for-ppc64-server/' rel='bookmark' title='Which Distro for PPC64 Server?'>Which Distro for PPC64 Server?</a></li>
<li><a href='http://techslaves.org/2011/08/24/freeipa-and-samba-3-integration/' rel='bookmark' title='FreeIPA and Samba 3 Integration'>FreeIPA and Samba 3 Integration</a></li>
<li><a href='http://techslaves.org/2010/09/08/migration-weekend-success/' rel='bookmark' title='Migration Weekend: Success'>Migration Weekend: Success</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>Is it just me or are there no LDAP user management tools that support User Private Groups (UPG)?</p>
<p>I&#8217;m well aware of the <a href="http://www.freeipa.org/">FreeIPA</a> project and that project does in fact support UPG, probably because it&#8217;s a RedHat project but I&#8217;ve determined that FreeIPA is too comprehensive for my needs. Despite Kerberos being the &#8220;right&#8221; solution in every sense of the term, I&#8217;d rather have the simplicity of binding to the LDAP server for authentication, even though I know that using LDAP as an authentication service is &#8220;wrong&#8221;.</p>
<p>My question, loyalty challenged readers, is: Are there any LDAP user management tools out there that support UPG?</p>
<p>Let me start the list:</p>
<ul>
<li>LAM &#8211; NO</li>
<li>phpLDAPadmin &#8211; NO</li>
<li>Luma &#8211; NO</li>
<li>LAT &#8211; NO</li>
<li>Gosa &#8211; NO</li>
<li>smbldap-tools &#8211; Maybe?</li>
</ul>
<p>Not to bash any of those tools, but I&#8217;ve decided to start writing my own simple &#8220;useradd&#8221; script for now because the workflow for creating a user with the UPG scheme with any of these tools is an annoying multi-step process. While my solution is site-specific and non-comprehensive, it just exactly the job I need done, done. And fast. I used perl and Net::LDAP, among other modules. Once I figured out if I want to it keep it on the console or move it to the web, I&#8217;ll post the results&#8230; even if it won&#8217;t be useful to anyone as-is.</p>
<p>Related posts:<ol>
<li><a href='http://techslaves.org/2011/03/08/which-distro-for-ppc64-server/' rel='bookmark' title='Which Distro for PPC64 Server?'>Which Distro for PPC64 Server?</a></li>
<li><a href='http://techslaves.org/2011/08/24/freeipa-and-samba-3-integration/' rel='bookmark' title='FreeIPA and Samba 3 Integration'>FreeIPA and Samba 3 Integration</a></li>
<li><a href='http://techslaves.org/2010/09/08/migration-weekend-success/' rel='bookmark' title='Migration Weekend: Success'>Migration Weekend: Success</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://techslaves.org/2010/10/05/ldap-user-management-tools-and-user-private-groups/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Cfengine 3 Snippets Part 2: sudo</title>
		<link>http://techslaves.org/2010/10/02/cfengine-3-snippets-part-2-sudo/</link>
		<comments>http://techslaves.org/2010/10/02/cfengine-3-snippets-part-2-sudo/#comments</comments>
		<pubDate>Sat, 02 Oct 2010 02:59:42 +0000</pubDate>
		<dc:creator>rthomson</dc:creator>
				<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[cfengine]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[policy]]></category>
		<category><![CDATA[script]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[sudo]]></category>

		<guid isPermaLink="false">http://techslaves.org/?p=87</guid>
		<description><![CDATA[It&#8217;s been a while since I&#8217;ve really had time to delve too much further into cfengine 3 since my previous post on the subject way back in May but I do have another simple example to share. This time it&#8217;s about managing your sudo policy via the sudoers file. The example is that of a very, [...]
Related posts:<ol>
<li><a href='http://techslaves.org/2010/05/18/cfengine-3-snippets-part-1-denyhosts/' rel='bookmark' title='Cfengine 3 Snippets Part 1: DenyHosts'>Cfengine 3 Snippets Part 1: DenyHosts</a></li>
<li><a href='http://techslaves.org/2010/03/29/nanorcs/' rel='bookmark' title='Nanorcs: Ultrasimplistic Configuration File Revision Control'>Nanorcs: Ultrasimplistic Configuration File Revision Control</a></li>
<li><a href='http://techslaves.org/2010/05/07/rhelcentos-nfs-and-firewalls/' rel='bookmark' title='RHEL/CentOS, NFS and Firewalls'>RHEL/CentOS, NFS and Firewalls</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been a while since I&#8217;ve really had time to delve too much further into cfengine 3 since my <a href="http://techslaves.org/2010/05/18/cfengine-3-snippets-part-1-denyhosts/">previous post</a> on the subject way back in May but I do have another simple example to share. This time it&#8217;s about managing your sudo policy via the <em>sudoers</em> file.</p>
<p>The example is that of a very, very basic <em>sudoers</em> policy but the principles are easily extended to create much more complex policy. The general idea here is that we want cfengine to ensure that specific rules are always in place. Instructed properly, cfengine accomplishes this very well.</p>
<p>Warning: I don&#8217;t know anything. I&#8217;m just someone learning cfengine 3 and posting about it. If I&#8217;m wrong about something, let me know! If you find this at all useful, be my guest. That is all.</p>
<p><span id="more-87"></span></p>
<pre>################################################################################
##
## FILE: sudo.cf
## DESC: Control /etc/sudoers file on various servers
##
################################################################################

bundle agent sudo
{

vars:

  "sudoers" string =&gt; "/etc/sudoers";

  "sudo"     slist =&gt; {
                      "%admin ALL = ALL",
                      "%sysadmin ALL = /sbin/mount",
                      "%devel ALL = /sbin/mount"
                      };

packages:

  Night::

  "sudo" -&gt; "Security policy"
    comment               =&gt; "Ensure sudo is up to date every 24 hours (and only at night)",
    package_policy        =&gt; "update",
    package_method        =&gt; yum,
    package_architectures =&gt; { "$(sys.arch)" },
    action                =&gt; if_elapsed("1440");

files:

  "$(sudoers)" -&gt; "Security Policy"
    comment      =&gt; "Append common configuration to sudoers",
    edit_line    =&gt; append_if_no_lines("$(sudo)");

}</pre>
<p>As with last snippet I posted, the above does not even resemble a complete cfengine policy/configuration, just a small portion that can be contained in it&#8217;s own bundle. It can be put in a separate .cf file, imported by promises.cf and added to the bundle sequence, inheriting variables and classes! Also, just like last time I&#8217;m using cfengine&#8217;s built in interface for package management systems to ensure &#8220;sudo&#8221; is always installed via yum at night, every 24 hours.</p>
<p>What&#8217;s new here is file editing with <em>edit_line</em> and the use of iteration which proves to be very powerful in cfengine 3.</p>
<h2>Editing Files</h2>
<p>Editing files with cfengine is supposed to be easy but initially it seemed a bit awkward to me.</p>
<p>First you have the promise file promise:</p>
<pre>files:

  "$(sudoers)" -&gt; "Security Policy"
    comment      =&gt; "Append common configuration to sudoers",
    edit_line    =&gt; append_if_no_lines("$(sudo)");</pre>
<p>Which makes some reference to the <em>edit_line</em> facility and what looks like a function name with <em>append_if_no_lines(&#8230;)</em>.</p>
<p>Then you have the <em>edit_line</em> bundle defined elsewhere:</p>
<pre>bundle edit_line append_if_no_lines(list)
{
insert_lines:

 "$(list)";
}</pre>
<p>Which describes what &#8220;append_if_no_lines&#8221; actually does.</p>
<p>Of course I&#8217;m just learning cfengine and new things can often seem strange and scary but I am finally warming up to editing files with cfengine&#8230; I think. What I seemed to have initial trouble with was with the <em>bundles</em> necessary for <em>edit_lines</em>, as described above. The bundle within a bundle concept. The <em>append_if_no_lines</em> and <em>append_if_no_line</em> bundles I&#8217;m using are implemented in the <a href="http://www.cfengine.org/manuals/cfengine_stdlib.cf">cfengine std library</a>, which is highly recommended so that you may avoid re-inventing the wheel a little bit.</p>
<p>For basic promises, to add or remove, comment or uncomments lines and the such there are good <em>edit_lines</em> bundles available in the stdlib. For other more complex or customized file editing, writing your own bundles will be necessary. Either way, understanding what a <em>bundle</em> is and how to create your own is key to fully grasping file editing and getting the most out of it. This seems obvious in retrospect but something I didn&#8217;t pickup instantly.</p>
<p>See the cfengine documentation for more about editing files, check the cfengine documentation. There&#8217;s waaaaay more good information over there and it&#8217;s from the cfengine team, not some random newb.</p>
<h2><strong>Iteration</strong></h2>
<p>Iteration is powerful mechanism within cfengine that harnesses the power of lists to express a large possible number of actions/operations with very little amount of code. When lists are used, single actions can be made to repeat for every item in a list by using the <em>$(varname)</em> syntax to refer to the list&#8230; which as it turns out is the same for scalar values! Funny that!</p>
<p>So cfengine allows us to define X different lines of code to ensure are in a file using only a single <em>file:</em> promise all with the same simple syntax as scalar variables? Brilliant!</p>
<p>A demonstration of iteration can be seen with the <em>$(sudo)</em> slist and the &#8220;Append common configuration to sudoers&#8221; <em>file:</em> promise. With this single promise definition, <em>up to</em> 6 actual promises are made because the <em>$(sudo)</em> variable is an slist. Each element or item in the list is iterated over in sequence and the promise is evaluated and acted upon, if necessary. The reason that <em>up to</em> 6 promises will be evaluated is the <em>ifvarclass</em> property of promise, ensuring the promise will only be kept if we&#8217;re in the context of the class&#8230; and looking at the promise to find out which class, we see another example of iteration using the <em>$(sudo)</em> list and the <em>canonify</em> function that turns a string into a class. Thusly, if the host currently running this policy defines all the classes that are tested by the <em>ifvarclass</em> iteration, 6 promises will be made. If the host defines 3 of the classes, then 3 promises will be made and so on, and so forth.</p>
<p>As a beginner, using lists and iteration effectively and creatively seems fairly important to getting the most out of cfengine 3.</p>
<h2>Editing Files vs. Copying Files</h2>
<p>In my previous snippet, I demonstrated how to promise to copy a file from a secure remote server if the local file does not match the server&#8217;s file in order to manage a configuration with cfengine. This time, I&#8217;m promising to add lines to a configuration file if they do not already exist exactly as provided.</p>
<p>This represents two rather different takes on policy. The first says: &#8220;The configuration must always be exactly like this file, byte per byte!&#8221; the second says &#8220;These lines must exist but I don&#8217;t care about anything else in the file&#8221;. The file copy method is what I would call hard policy and the second is soft policy. In the cfengine community solutions, they recommend managing sudo by copying an <em>/etc/sudoers</em> from a remote server. That way is great (just like my DenyHosts example) but this is just another way if you have a use case for cfengine not owning every byte of your configuration file.</p>
<h2>Conclusion</h2>
<p>Yeah, that&#8217;s about it. Enjoy.</p>
<p>Related posts:<ol>
<li><a href='http://techslaves.org/2010/05/18/cfengine-3-snippets-part-1-denyhosts/' rel='bookmark' title='Cfengine 3 Snippets Part 1: DenyHosts'>Cfengine 3 Snippets Part 1: DenyHosts</a></li>
<li><a href='http://techslaves.org/2010/03/29/nanorcs/' rel='bookmark' title='Nanorcs: Ultrasimplistic Configuration File Revision Control'>Nanorcs: Ultrasimplistic Configuration File Revision Control</a></li>
<li><a href='http://techslaves.org/2010/05/07/rhelcentos-nfs-and-firewalls/' rel='bookmark' title='RHEL/CentOS, NFS and Firewalls'>RHEL/CentOS, NFS and Firewalls</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://techslaves.org/2010/10/02/cfengine-3-snippets-part-2-sudo/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>Migration Weekend: Success</title>
		<link>http://techslaves.org/2010/09/08/migration-weekend-success/</link>
		<comments>http://techslaves.org/2010/09/08/migration-weekend-success/#comments</comments>
		<pubDate>Wed, 08 Sep 2010 18:00:50 +0000</pubDate>
		<dc:creator>rthomson</dc:creator>
				<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[backup]]></category>
		<category><![CDATA[hardware]]></category>
		<category><![CDATA[ibm]]></category>
		<category><![CDATA[iscsi]]></category>
		<category><![CDATA[ldap]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[migration]]></category>
		<category><![CDATA[restore]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[tina]]></category>

		<guid isPermaLink="false">http://techslaves.org/?p=80</guid>
		<description><![CDATA[It was a long weekend of watching tape restores and restarting them as necessary but it&#8217;s finally over and everything appears to be mostly hunky dory! I did discovery yet more small misconfigurations and strange behaviour along the way: OpenLDAP&#8217;s syncrepl using &#8220;refereshAndPersist&#8221; wasn&#8217;t working how I expected it to, no new changes were replicating [...]
Related posts:<ol>
<li><a href='http://techslaves.org/2010/09/04/migration-weekend/' rel='bookmark' title='Migration Weekend'>Migration Weekend</a></li>
<li><a href='http://techslaves.org/2010/09/01/when-using-syncrepl/' rel='bookmark' title='When using Syncrepl&#8230;'>When using Syncrepl&#8230;</a></li>
<li><a href='http://techslaves.org/2010/05/05/atempo-time-navigator-4-2-archive-media-selection-tunable/' rel='bookmark' title='Atempo Time Navigator 4.2 Archive Media Selection Tunable'>Atempo Time Navigator 4.2 Archive Media Selection Tunable</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>It was a long weekend of watching tape restores and restarting them as necessary but it&#8217;s finally over and everything appears to be mostly hunky dory!</p>
<p>I did discovery yet more small misconfigurations and strange behaviour along the way:</p>
<ol>
<li>OpenLDAP&#8217;s syncrepl using &#8220;refereshAndPersist&#8221; wasn&#8217;t working how I expected it to, no new changes were replicating to the slave LDAP server! I changed the directive to &#8220;refreshOnly&#8221; and set a 10 minute interval. I made several changes and monitored the slave LDAP server. Changes propagated in about 10 minutes, every time.</li>
<li>Despite iSCSI&#8217;s maturity and the maturity of QLogic&#8217;s HBAs I still noticed strange, unexplained target drop outs. Two HBAs per server, two controllers in the IBM DS3300 and just one target out of four was dropping. At first, I couldn&#8217;t figure out how to properly reconnect the target on a live system so I rebooted. Later, I discovered you can &#8220;disable&#8221; and then &#8220;enable&#8221; the specific target in SANsurfer or iscli, which worked to bring back the dropped target on a live system. Multipath picked up the &#8220;new&#8221; path right away, as expected.</li>
<li>Always remember to leave free physical extents in any LVM Volume Group in which you are taking snapshots of the Logical Volumes. It&#8217;s freakin&#8217; obvious but I forgot and when I went to do snapshot backups, the snapshots were failing. Now I&#8217;m growing some LUNs on the DS3300 so that my VGs have room for snapshots.</li>
</ol>
<p>All in all, a good weekend that was mostly filled with success.</p>
<p>Related posts:<ol>
<li><a href='http://techslaves.org/2010/09/04/migration-weekend/' rel='bookmark' title='Migration Weekend'>Migration Weekend</a></li>
<li><a href='http://techslaves.org/2010/09/01/when-using-syncrepl/' rel='bookmark' title='When using Syncrepl&#8230;'>When using Syncrepl&#8230;</a></li>
<li><a href='http://techslaves.org/2010/05/05/atempo-time-navigator-4-2-archive-media-selection-tunable/' rel='bookmark' title='Atempo Time Navigator 4.2 Archive Media Selection Tunable'>Atempo Time Navigator 4.2 Archive Media Selection Tunable</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://techslaves.org/2010/09/08/migration-weekend-success/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>IT Watchdogs SuperGoose (WxGoos-2) Review</title>
		<link>http://techslaves.org/2010/08/25/it-watchdogs-supergoose-wxgoos-2-review/</link>
		<comments>http://techslaves.org/2010/08/25/it-watchdogs-supergoose-wxgoos-2-review/#comments</comments>
		<pubDate>Wed, 25 Aug 2010 18:36:14 +0000</pubDate>
		<dc:creator>rthomson</dc:creator>
				<category><![CDATA[Reviews]]></category>
		<category><![CDATA[datacenter]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[network]]></category>
		<category><![CDATA[server]]></category>

		<guid isPermaLink="false">http://techslaves.org/?p=46</guid>
		<description><![CDATA[Some time ago it became apparent that we would require environmental monitoring in our server room. The primary reason being that our server room was never initially intended to be a server room and the after-the-fact A/C unit installation (size, vent placement, etc.) is definitely less than optimal. Not to mention the A/C unit is likely [...]
Related posts:<ol>
<li><a href='http://techslaves.org/2010/03/30/ibm-change-ups-vendors/' rel='bookmark' title='IBM Changed UPS Vendors'>IBM Changed UPS Vendors</a></li>
<li><a href='http://techslaves.org/2010/03/30/opengear-cm4116-review/' rel='bookmark' title='OpenGear CM4116 Review'>OpenGear CM4116 Review</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>Some time ago it became apparent that we would require environmental monitoring in our server room. The primary reason being that our server room was never initially intended to be a server room and the after-the-fact A/C unit installation (size, vent placement, etc.) is definitely less than optimal. Not to mention the A/C unit is likely overloaded as well, judging by some of the data we gathered after installing the environmental monitoring equipment and software. Basically, I needed to be made aware of any potential problems with the environment in that room so that should anything go wrong, I can act quickly. A secondary use of the data is to trend the environment changes in order to reveal specific patterns that may help with long-term planning.</p>
<div id="_mcePaste">
<p><span id="more-46"></span>The monitoring product I decided upon is the SuperGoose (WxGoos-2) from <a href="http://www.itwatchdogs.com/"><span style="color: #000000;"><span style="text-decoration: none;">IT Watchdogs</span></span></a>. In this review I hope to provide a overview of the device and what my personal thoughts on the device are.</p>
</div>
<p>NOTE: IT Watchdogs has since released the SuperGoose II. Since I haven&#8217;t compared the two products, I can&#8217;t comment on any differences.</p>
<h3>IT Watchdogs</h3>
<p>I really don&#8217;t know a lot about these guys but they appear to be a fairly small company. Their name came up several times during my searches for environmental monitoring solutions. What I do know is that their support people get back to you fairly quickly and they aren&#8217;t demanding a product serial number before assisting you with your IT Watchdogs related product questions. Their support gives you the impression you&#8217;re speaking with people that understand the product very well.</p>
<p>They provide firmware upgrades on their website where you can download them and get instructions on the upgrade process. There is no service contract necessary to continue getting firmware updates, which is very nice considering one of the main points they seem to be competing on is price and thus you not only get good initial value for your dollar, you get long term value in the software improvements over the lifetime of the device.</p>
<h3>It&#8217;s a plane, it&#8217;s a bird, it&#8217;s a SuperGoose!</h3>
<p>IT Watchdogs have a wide range of monitoring products but the SuperGoose (also known as the WxGoos-2) is (was) their flagship product. With a $499 price tag, it&#8217;s not dirt cheap but comparing it&#8217;s feature list to much of the competition out there and it really does start to look like a bargain.</p>
<p>The unit itself is a tiny litte 1U rackmount box that is no deeper than it is tall. That is, it&#8217;s about 1U deep. The unit has an LCD on the front that will cycle through readings from your various attached sensors that provide visual stimulus for those lonely nights in the server room. The unit also has a audible alarm which is of no use to me, but we&#8217;ll come to that later.</p>
<p>The build quality of the SuperGoose is good. It&#8217;s made out of metal, which is always nice. Everything is solid and well manufactured. There is just one design feature of the SuperGoose that I just don&#8217;t get: It requires an external power adapter (included), the kind you use to charge your cellphone or to power your crappy D-Link hub you&#8217;ve got installed in your office that the IT guys keep ragging on you about. It really isn&#8217;t a big deal but I just don&#8217;t see why they couldn&#8217;t have integrated the power transformer (A/C to D/C) into the chassis of the device and allowed the common and standard IEC C13 plug for power. Such a solution would have been cleaner and more compliant with the existing power infrastructure in the average server room/data center. Not to mention that the current power adapter plugs into the front of the SuperGoose, another little design issue I don&#8217;t fully understand. Either way, this is a minor gripe but something worth noting regardless as you&#8217;ll need to have a suitable PDU or extension cable to power the thing.</p>
<p>The SuperGoose allows for two kinds of external sensors to be added in addition to the full set of built-in sensors. The first kind of sensor is connected via RJ-12 jacks. The sensors supported in the RJ-12 jacks are digital sensors which means there is some kind of tiny microchip in the sensor itself. It&#8217;s not &#8220;passive&#8221;, if you will. While only five physical RJ-12 ports are included, the SuperGoose supports up to 16 sensors by using an RJ-12 splitter. The second kind of sensor is analog. In our case, we&#8217;re only using digital sensors so I cannot comment on the analog sensor functionality at this point, unfortunately.</p>
<h3>Setting up the SuperGoose</h3>
<p>Setup is really quite easy:</p>
<ol>
<li>Mount the SuperGoose in your rack (and cable it up).</li>
<li>Grab the MAC address from the front of the device and setup a DHCP address for it (or just leave the default IP and setup a host on that subnet to initially configure it).</li>
<li>Power it up.</li>
<li>Point your browser to the SuperGoose&#8217;s IP address and begin configuring!</li>
</ol>
<p>Of course, you can add many sensors as well at this point, which is key to a general purpose environmental monitoring solution.</p>
<p>The SuperGoose has a robust web server where you can view the collected data and graphs and configure various things such as networking, NTP, email, SNMP, camera setting and the device information. You can also configure alarm thresholds for your sensors so that you can get an email or SNMP trap fired off in case of abnormal readings. While useful for smaller shops lacking a centralized monitoring solution, these built-in alerts are not a factor when integrating the SuperGoose into a larger environments where a centralized monitoring solution has been implemented. It&#8217;s nice to have them, but you might not need them.</p>
<p>The configuration page is clear and straight forward. The language used to describe configuration options should be totally familiar to anyone with cursory knowledge of the various technologies, standards and protocols in use. The SuperGoose provides three level of access to the device: View-only, Control and Administrative. Each access level has a configurable account name and password. The SuperGoose unfortunately does not support multiple accounts of the same level. That said, enterprise use of the SuperGoose will often involve SNMP data collection instead of users and admins logging into the SuperGoose web server directly and so, more fine grained per-user/admin accounts can be configured in the SNMP monitoring solution to control access to data while at the same time locking out access to the SuperGoose directly to all but the SNMP/env administrators in order to achieve &#8220;lock down&#8221; and logging on who can see/do what.</p>
<h3>Digital Sensors &amp; SNMP Monitoring</h3>
<p>Digital sensors have unique IDs to which names can be assigned within the configuration interface. This means that when you connect/disconnect your digital sensors, or the SuperGoose reboots, the graphs produced by the SuperGoose and the data it has collected remain valid and consistent.</p>
<p>One snag I did run into momentarily is that although the SuperGoose will internally track the digital sensors correctly, the SNMP OIDs for each sensor were not consistent upon reboot of the SuperGoose! My SNMP monitoring station would collect false data when the SuperGoose was rebooted because the sensors were detected in a different order and thus the OIDs for each sensor changed! The reason this happened is because I was monitoring the OIDs in static fashion by associating a sensor definition in the monitoring software with a particular, static OID. When the OID for the any sensor changed (as it often does upon reboot), the monitoring station would be collecting information for a particular item in the monitoring database from the wrong physical sensor. The solution is to use SNMP monitoring software that supports using dynamic SNMP indexes. <a href="http://www.zabbix.com">Zabbix</a> is such an open source monitoring solution. It took me a little while to configure Zabbix correctly for dynamics SNMP indexes but it was worth it: no more collecting data from the wrong sensor and thus more consistent and correct long term trending data is collected.</p>
<p>For what it&#8217;s worth the following is an example of the &#8220;OID&#8221; string I use within a Zabbix &#8220;item&#8221; to implement the dynamic index feature:</p>
<pre>IT-WATCHDOGS-MIB::tempSensorTempC[index,IT-WATCHDOGS-MIB::tempSensorName,Ambient Front]</pre>
<p>Where &#8220;Ambient Front&#8221; is the name of the sensor, as set in the SuperGoose configuration.</p>
<h3>Well Folks, that&#8217;s Part 1</h3>
<p>Well, that&#8217;s part 1 of the review. Part 2 of the review will arrive sometime in the future&#8230; I&#8217;ve just been sitting on this much of the review for too long now and it needs to be posted. I hope everyone enjoys half reviews (for now)!</p>
<p>Related posts:<ol>
<li><a href='http://techslaves.org/2010/03/30/ibm-change-ups-vendors/' rel='bookmark' title='IBM Changed UPS Vendors'>IBM Changed UPS Vendors</a></li>
<li><a href='http://techslaves.org/2010/03/30/opengear-cm4116-review/' rel='bookmark' title='OpenGear CM4116 Review'>OpenGear CM4116 Review</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://techslaves.org/2010/08/25/it-watchdogs-supergoose-wxgoos-2-review/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Time Navigator HA Cluster Agent Configuration</title>
		<link>http://techslaves.org/2010/08/05/time-navigator-ha-cluster-agent-configuration/</link>
		<comments>http://techslaves.org/2010/08/05/time-navigator-ha-cluster-agent-configuration/#comments</comments>
		<pubDate>Thu, 05 Aug 2010 22:40:53 +0000</pubDate>
		<dc:creator>rthomson</dc:creator>
				<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[atempo]]></category>
		<category><![CDATA[backup]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[tina]]></category>
		<category><![CDATA[unix]]></category>

		<guid isPermaLink="false">http://techslaves.org/?p=68</guid>
		<description><![CDATA[I&#8217;ve been wanting to post about a configuration that allows for seamless file-level backup of storage attached to an active/passive high availability cluster in an uninterrupted fashion using Atempo&#8217;s Time Navigator and I&#8217;m finally going to do it. The Problem The initial difficulty lies in the requirement that the data must be consistently backed up [...]
Related posts:<ol>
<li><a href='http://techslaves.org/2010/05/05/atempo-time-navigator-4-2-archive-media-selection-tunable/' rel='bookmark' title='Atempo Time Navigator 4.2 Archive Media Selection Tunable'>Atempo Time Navigator 4.2 Archive Media Selection Tunable</a></li>
<li><a href='http://techslaves.org/2010/03/29/nanorcs/' rel='bookmark' title='Nanorcs: Ultrasimplistic Configuration File Revision Control'>Nanorcs: Ultrasimplistic Configuration File Revision Control</a></li>
<li><a href='http://techslaves.org/2010/09/08/migration-weekend-success/' rel='bookmark' title='Migration Weekend: Success'>Migration Weekend: Success</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been wanting to post about a configuration that allows for seamless file-level backup of storage attached to an active/passive high availability cluster in an uninterrupted fashion using Atempo&#8217;s Time Navigator and I&#8217;m finally going to do it.</p>
<h3>The Problem</h3>
<p>The initial difficulty lies in the requirement that the data must be consistently backed up at every interval, no matter which cluster node is currently the active node with the backend storage mounted. To do this, an agent is required to be configured as a cluster resource in order to &#8220;follow&#8221; the mounting/exporting of the storage to any cluster node. So in order to accomplish this,  N + 1 tina agents are required. That is, if you have two cluster nodes, you need three agents to successfully backup each node with the local agent and the storage, as it floats about the cluster nodes depending on failure or migration events.</p>
<p>Luckily for me, the good people at Atempo have engineered the agent in such a way that multiple agents can be ran on a single node, each binding to it&#8217;s own IP address and each individually controlled via it&#8217;s own init script. Of course, we need to make some file edits to make all this happen and that&#8217;s what I&#8217;m going share!</p>
<p><span id="more-68"></span></p>
<h3>System Configuration</h3>
<p>This configuration is based on CentOS 5.x and Time Navigator 4.2 but should the concepts should be mostly portable to other popular Linux or UNIX distributions. The underlying cluster software used for the majority of my experience with this configuration is Heartbeat 2.1.3, right before the Pacemaker split but has also been more recently tested on Pacemaker 1.0 / Heartbeat 3.0.x. DRBD is used to provide the active/passive cluster-aware state and configuration information to where I&#8217;ve installed the Atempo Time Navigator agent but it is possible to install a second agent on each cluster node and configure it identically but this just seems like more work. DRBD does a great job of making sure the latest cluster-aware tina agent is consistently configured and available on the active cluster node, no matter which node that actually is.</p>
<p>For the purpose of this post, I&#8217;m going to assume you already have a working Heartbeat/Pacemaker/DRBD configuration up and running with proper STONITH and all that good jazz. Maybe some other time.</p>
<h3>Installing and Configuring the Agent on DRBD</h3>
<p>The first thing that needs to be done is the tina agent must be installed to a filesystem hosted on DRBD. I generally just SSH around the Linux-X64.tar or Linux-X86.tar Time Navigator installation archive and then decompress and run the install script.</p>
<p>Assuming the dedicated (to this agent resource) DRBD filesystem is mounted as <em>/cluster/tina</em> on the active cluster node:</p>
<pre>$ cd /cluster/tina
$ scp user@remote.fqdn:/path/to/Linux-X86.tar ./
$ tar -xf Linux-X86.tar
$ cd Linux-X86
$ ./install.sh</pre>
<p>This will bring up the GUI installer. Alternatively use the batch install method, whatever works for you.</p>
<p>Set <em>/cluster/tina </em>as the installation directory and otherwise proceed normally as per site configuration. Unique ports do not need to be used for the second cluster agent as this configuration bind to a floating cluster resource IP address while the local agent binds to (one of) the servers &#8220;real&#8221; IP address(es).</p>
<p>Once installed, there is one important edit to make in the tina agent environment configuration scripts named <em>.tina.sh (sh/bash) </em>and <em>.tina.csh (csh/tcsh) </em>located in the installation directory (<em>/cluster/tina</em>). The key change to make in the relevant script<em> </em>is to modify the value where the $<em>TINA</em> environment variable is being set. In <em>.tina.sh</em> that would be changing the line:</p>
<pre>TINA=tina</pre>
<p>to instead read something like this:</p>
<pre>TINA=tina_ha</pre>
<p>where <em>tina_ha</em> is a unique identifier for this instance of the agent. Basically, it needs to be anything BUT <em>tina</em>. This is one of two key components that had me tricked for a while. I had first tried modifying the $<em>TINA_SERVICE_NAME</em> environment variable but that was a giant red herring because uniquely setting that variable to something other than <em>tina</em> does not produce the desired effect, despite what the looking through the tina environment scripts and init scripts might have you believe.</p>
<p>The second thing we must do is to create an LSB-compliant init script for the cluster-aware tina agent. The LSB compliance is very important to ensure the cluster can manage the resource properly. If any return codes are out of the LSB spec, the cluster will behave erratically and unpredictably when dealing with starting, stopping and monitoring the tina agent.</p>
<p>Since the installation creates a good init script for us, we can copy that script with a new name and edit it.</p>
<pre>$ cp /etc/init.d/tina.tina /etc/init.d/tina.tina_ha
$ nano /etc/init.d/tina.tina_ha</pre>
<p>First, replace every instance of the path to the local agent&#8217;s tina install path with that of the cluster agent&#8217;s installation path. A simple search (Ctrl-W) then replace (Cntrl-R) in nano should suffice.</p>
<p>Additionally, we need a small section at the top that will exit the script in case the DRBD filesystem is not mounted. The HA cluster will do resource status checks on all nodes in the cluster and we need the init script to be able to exit with a sane exit code, even if the DRBD filesystem is not accessible (as it is on all passive nodes). Something like this:</p>
<pre>if [ -f /cluster/tina/.tina.sh ] ; then
  . /cluster/tina/.tina.sh &gt; /dev/null 2&gt;&amp;1
else
  echo "Unable to start Time Navigator daemon"
  echo "because the \"/cluster/tina/.tina.sh\" file does not exist"
  retval=3
fi</pre>
<p>In order to make the script LSB compliant, we need to ensure the correct exit status is returned during the correct operations. Instead of pointing out each specific place I had to edit in order for this to happen, I will simply post my entire &#8220;<em>/etc/init.d/tina.tina_ha</em>&#8221; init script:</p>
<pre>#!/bin/sh
# UPDATED BY SETUP - BEGIN
########################################################
#WARNING :
#THIS FILE IS GENERATED AUTOMATICALLY
#AND WILL BE OVERWRITTEN WHEN UPGRADING
#YOUR VERSION OF Time Navigator PRODUCT
########################################################
PATH="$PATH:/bin:/usr/bin:/sbin:/usr/sbin:/etc:/usr/etc"
export PATH
if [ "${TINA_HOME:+$TINA_HOME}" != "" ] ; then
	if [ "/cluster/tina" != "$TINA_HOME" ] ; then
		echo "Unable to start Time Navigator daemon for \"/cluster/tina\""
		echo "because the Time Navigator environment is already set by \"$TINA_HOME\""
		retval=3
	fi
fi
if [ -f /cluster/tina/.tina.sh ] ; then
	. /cluster/tina/.tina.sh &gt; /dev/null 2&gt;&amp;1
else
	echo "Unable to start Time Navigator daemon"
	echo "because the \"/cluster/tina/.tina.sh\" file does not exist"
	retval=3
fi
# UPDATED BY SETUP - END
# @(#) $Id: rc.tina.orig,v 1.1.6.10.4.4.2.4 2007/09/20 16:26:50 dle Exp $
#
# Time Navigator startup script
# (C) 1999-2005 - Atempo
# tina_daemon starting...
#

OS_TYPE=`uname -s`

if echo "\c" | grep "c"&gt;/dev/null ; then
	ECHOMODE=Bsd
else
	ECHOMODE=Sys5
fi

ECHONOCR() {
	if [ "$ECHOMODE" = Bsd ] ; then
		echo -n "$*"
	else
		echo "$*\c"
	fi
}

PING() {
    os_type=`uname -s`
    case $os_type in
        HP-UX) result=`ping $1 -n 2 2&gt;/dev/null`; return $?;;
        *) result=`ping -c 2 $1 2&gt;/dev/null`; return $?;;
    esac
}

ISREDHATLIKE=1
# Source function library.
if [ -f /etc/init.d/functions ] ; then
	. /etc/init.d/functions
elif [ -f /etc/rc.d/init.d/functions ] ; then
	. /etc/rc.d/init.d/functions
else
	ISREDHATLIKE=0
fi

ISSUSE=1
if [ -f /etc/rc.status ] ; then
	. /etc/rc.status
else
	ISSUSE=0
fi

RCStart()
{
	if [ -x ${TINA_HOME}/Bin/ndmpd ] ; then
		echo "Starting NDMP Data Server..."
		${TINA_HOME}/Bin/ndmpd
	elif [ -x ${TINA_HOME}/Bin/tina_nts ] ; then
		echo "Starting NDMP Tape Server..."
		${TINA_HOME}/Bin/tina_nts
	fi

	TINA_DAEMON=$TINA_HOME/Bin/tina_daemon
	if [ -x "$TINA_DAEMON" ]; then
		ECHONOCR "Starting Time Navigator ($TINA_SERVICE_NAME)..."
		if [ -d /var/lock/subsys ] ; then
			touch /var/lock/subsys/tina.$TINA_SERVICE_NAME
		fi
		i=1
		while [ $i -le 60 ] ; do
			if [ $OS_TYPE = "Darwin" ] ; then
				echo `date` "Trying to start tina_daemon ($TINA_SERVICE_NAME) daemon" &gt;&gt; /var/log/system.log
			fi
			echo `date` "Trying to start tina_daemon ($TINA_SERVICE_NAME) daemon $i" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
			hostname=`hostname 2&gt;/dev/null`
			if [ ! -z "$hostname" ] ; then
				echo `date` "Trying to start tina_daemon ($TINA_SERVICE_NAME) daemon: hostname $hostname is defined" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
				PING $hostname
				status=$?
				if [ $status -eq 0 ] ; then
					echo `date` "Trying to start tina_daemon ($TINA_SERVICE_NAME) daemon: ping $hostname is ok" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
					$TINA_DAEMON
					sleep 2
					RCStatus no_mess
					if [ ! -z "$is_running" ] ; then
						if [ $OS_TYPE = "Darwin" ] ; then
							echo `date` "tina_daemon ($TINA_SERVICE_NAME) daemon is started" &gt;&gt; /var/log/system.log
						fi
						echo `date` "tina_daemon ($TINA_SERVICE_NAME) daemon is started" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
						break
					else
						echo `date` "tina_daemon ($TINA_SERVICE_NAME) daemon is not started" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
					fi
				else
					echo `date` "Trying to start tina_daemon ($TINA_SERVICE_NAME) daemon: ping $hostname is ko" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
				fi
			else
				echo `date` "Trying to start tina_daemon ($TINA_SERVICE_NAME) daemon: hostname is not defined" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
			fi
			sleep 5
			i=`expr $i + 1`
		done

		if [ $ISREDHATLIKE -eq 1 ]; then
			echo_success
			echo
		elif [ $ISSUSE -eq 1 ]; then
			rc_status -v
		else
			echo
		fi

		# Start ACSLS daemons (mini_el and ssi)
		if [ -d "$TINA_HOME/Vtl" ] ; then
			for VL_path in $TINA_HOME/Vtl/*
			do
				[ ! -d $VL_path ] &amp;&amp; continue
				VL_name=`basename $VL_path`
				if [ $VL_name = "Install" -o $VL_name = "Bin" -o $VL_name = "Log" -o $VL_name = "Tmp" ] ; then
					continue
				fi

				# If there is no tina_stk.conf, give up
				[ ! -f "$VL_path/tina_stk.conf" ] &amp;&amp; continue

				[ ! -x "$TINA_HOME/Vtl/Bin/ACSLS/start.sh" ] &amp;&amp; continue

				ECHONOCR "Starting ACSLS client daemon for $VL_name virtual library ..."
				$TINA_HOME/Vtl/Bin/ACSLS/start.sh $VL_name
				echo
			done
		fi
	elif [ ! -f ${TINA_HOME}/.ndmp.sh ] ; then
		if [ $ISREDHATLIKE -eq 1 ]; then
			ECHONOCR "Starting Time Navigator (${TINA_SERVICE_NAME})..."
			echo_failure
			echo
		elif [ $ISSUSE -eq 1 ]; then
			rc_failed 1
		else
			echo
		fi
	fi
}

RCStop()
{
	#Stop ndmp daemon
	NDMPDAEMON=""
	if [ -x ${TINA_HOME}/Bin/ndmpd ] ; then
		NDMPDAEMON="ndmpd"
	elif [ -x ${TINA_HOME}/Bin/tina_nts ] ; then
		NDMPDAEMON="tina_nts"
	fi
	if [ ! -z "$NDMPDAEMON" ] ; then
		file="/var/tmp/$NDMPDAEMON.pid"
		if [ -f $file ] ; then
			if [ "$NDMPDAEMON" = ndmpd ] ; then
				echo "Shutting down NDMP Data Server..."
			elif [ "$NDMPDAEMON" = tina_nts ] ; then
				echo "Shutting down NDMP Tape Server..."
			fi
			kill `cat $file`
		fi
	fi

	#Stop Time Navigator daemon
	if [ -x ${TINA_HOME}/Bin/tina_stop ]; then
		if [ -d /var/lock/subsys ] ; then
			rm -f /var/lock/subsys/tina.$TINA_SERVICE_NAME
		fi
		ECHONOCR "Shutting down Time Navigator ($TINA_SERVICE_NAME)..."
		if [ $OS_TYPE = "Darwin" ] ; then
			echo `date` "Stopping tina_daemon ($TINA_SERVICE_NAME) daemon" &gt;&gt; /var/log/system.log
		fi
		echo `date` "Stopping tina_daemon ($TINA_SERVICE_NAME) daemon" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
		$TINA_HOME/Bin/tina_stop &gt; /dev/null
		retval=0
		if [ $ISREDHATLIKE -eq 1 ]; then
			echo_success
			echo
		elif [ $ISSUSE -eq 1 ]; then
			rc_status -v
		else
			echo
		fi
	elif [ ! -f ${TINA_HOME}/.ndmp.sh ] ; then
		if [ $ISREDHATLIKE -eq 1 ]; then
			echo "Shutting down Time Navigator ($TINA_SERVICE_NAME)..."
			echo_failure
			echo
		elif [ $ISSUSE -eq 1 ]; then
			rc_failed 1
		else
			echo
		fi
	fi
}

RCStatus()
{
	## Check status with checkproc(8), if process is running
	## checkproc will return with exit status 0.

	# Status has a slightly different for the status command:
	# 0 - service running
	# 1 - service dead, but /var/run/ pid file exists
	# 2 - service dead, but /var/lock/ lock file exists
	# 3 - service not running

	if [ -f $TINA_HOME/Conf/hosts ] ; then
		host_to_ping=`cat $TINA_HOME/Conf/hosts | grep ^localhostname | awk '{print $2}' 2&gt;/dev/null`
		if [ $? != 0 -o -z "$host_to_ping" ] ; then
			host_to_ping="127.0.0.1"
		fi
	else
		host_to_ping="127.0.0.1"
	fi

	is_running=`$TINA_HOME/Bin/tina_ping -host $host_to_ping -language English | grep "is running"`
	if [ $# -eq 0 ] ; then
		ECHONOCR "Checking for Time Navigator ($TINA_SERVICE_NAME): "
		if [ $OS_TYPE = "Darwin" ] ; then
			echo `date` "Checking tina_daemon ($TINA_SERVICE_NAME) daemon" &gt;&gt; /var/log/system.log
		fi
		echo `date` "Checking tina_daemon ($TINA_SERVICE_NAME) daemon" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
		if [ ! -z "$is_running" ] ; then
			echo "tina_daemon is running"
			echo `date` "Checking tina_daemon ($TINA_SERVICE_NAME) daemon: tina_daemon is running" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
			retval=0
		else
			echo "tina_daemon is stopped"
			echo `date` "Checking tina_daemon ($TINA_SERVICE_NAME) daemon: tina_daemon is stopped" &gt;&gt; ${TINA_HOME}/Adm/auto_start.log
                        retval=3
		fi
	fi
}

test "$ISSUSE" -eq 1 &amp;&amp; rc_reset

case "$1" in
start)
	RCStart
	retval=0
	;;

stop)
	RCStop
	retval=0
	;;

start_msg)
	echo "Starting Time Navigator ($TINA_SERVICE_NAME)" ;;

stop_msg)
	echo "Shutting down Time Navigator ($TINA_SERVICE_NAME)" ;;

restart)
	RCStop
	sleep 3
	RCStart ;;

status)
	RCStatus ;;

*)
	echo "usage: /etc/init.d/tina {start|stop|restart|status}" ;;
esac

exit $retval</pre>
<p>One final Time Navigator configuration change must be made. The tina agent &#8220;hosts&#8221; file must be configured to set the &#8220;localhostname&#8221; of our agent to the FQDN of the floating or virtual IP address service so that the agent will only try to bind to that IP address instead of all IP addresses on the system.</p>
<pre>$ cd /cluster/tina/Conf
$ cp hosts.sample hosts
$ nano hosts</pre>
<p>Add a line to the file specifying the &#8220;localhostname&#8221; like so:</p>
<pre>localhostname myserver.company.com</pre>
<p>For this to work properly, you must also set any other tina agents running on the cluster nodes to also have a &#8220;localhostname&#8221; set in their respective &#8220;hosts&#8221; file to prevent other host-based agents from binding to all IP addresses on the host, including the virtual IP address.</p>
<p>That&#8217;s it! The tina service can be added to the HA cluster as an LSB resource agent, grouped with your storage resource agents so it will always be running on the same node as your storage.</p>
<p><strong>Conclusion</strong></p>
<p>Ok, so I rushed the end. Big deal. Sue me. I doubt anyone cares anyways!</p>
<p>Related posts:<ol>
<li><a href='http://techslaves.org/2010/05/05/atempo-time-navigator-4-2-archive-media-selection-tunable/' rel='bookmark' title='Atempo Time Navigator 4.2 Archive Media Selection Tunable'>Atempo Time Navigator 4.2 Archive Media Selection Tunable</a></li>
<li><a href='http://techslaves.org/2010/03/29/nanorcs/' rel='bookmark' title='Nanorcs: Ultrasimplistic Configuration File Revision Control'>Nanorcs: Ultrasimplistic Configuration File Revision Control</a></li>
<li><a href='http://techslaves.org/2010/09/08/migration-weekend-success/' rel='bookmark' title='Migration Weekend: Success'>Migration Weekend: Success</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://techslaves.org/2010/08/05/time-navigator-ha-cluster-agent-configuration/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Cfengine 3 Snippets Part 1: DenyHosts</title>
		<link>http://techslaves.org/2010/05/18/cfengine-3-snippets-part-1-denyhosts/</link>
		<comments>http://techslaves.org/2010/05/18/cfengine-3-snippets-part-1-denyhosts/#comments</comments>
		<pubDate>Tue, 18 May 2010 22:02:09 +0000</pubDate>
		<dc:creator>rthomson</dc:creator>
				<category><![CDATA[Sysadmin]]></category>
		<category><![CDATA[cfengine]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[denyhosts]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[snippet]]></category>
		<category><![CDATA[software]]></category>

		<guid isPermaLink="false">http://techslaves.org/?p=63</guid>
		<description><![CDATA[I&#8217;ve recently begun looking into configuration management with cfengine 3. I&#8217;ve ignored this growing sub-field of system administration for too long and I just can&#8217;t ignore it anymore. After spending quite some time researching the philosophies, methods and different tools out there, I settled on starting out with cfengine 3. There&#8217;s no special reason that [...]
Related posts:<ol>
<li><a href='http://techslaves.org/2010/10/02/cfengine-3-snippets-part-2-sudo/' rel='bookmark' title='Cfengine 3 Snippets Part 2: sudo'>Cfengine 3 Snippets Part 2: sudo</a></li>
<li><a href='http://techslaves.org/2010/05/07/rhelcentos-nfs-and-firewalls/' rel='bookmark' title='RHEL/CentOS, NFS and Firewalls'>RHEL/CentOS, NFS and Firewalls</a></li>
<li><a href='http://techslaves.org/2010/03/29/nanorcs/' rel='bookmark' title='Nanorcs: Ultrasimplistic Configuration File Revision Control'>Nanorcs: Ultrasimplistic Configuration File Revision Control</a></li>
</ol>]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve recently begun looking into configuration management with <a href="http://cfengine.org">cfengine 3</a>. I&#8217;ve ignored this growing sub-field of system administration for too long and I just can&#8217;t ignore it anymore. After spending quite some time researching the philosophies, methods and different tools out there, I settled on starting out with cfengine 3. There&#8217;s no special reason that I chose cfengine instead of puppet, bcfg2, chef or AutomateIT. I haven&#8217;t used any of these tools and thus I cannot pass judgement on them or their methods. All these projects seem to have intelligent and highly motivated people behind them. I simply gravitated towards cfengine because of its strong academic background and the fact that version 3 now represents the most recent and modern research in the field by Mark Burgess et. al.</p>
<p>As part of my learning experience with cfengine, I&#8217;ve decided to start posting some of the code that I&#8217;ve begun developing in the hopes that by writing about it, I can learn better, faster and maybe even receive some helpful comments from readers along the way. Beware, I&#8217;m a cfengine newbie and so what I post here should NOT be copy and pasted into your environment unless you&#8217;re ok with the potential of wildly breaking things!</p>
<p>The first snippet of code I want to discuss is related to managing our <a href="http://denyhosts.sourceforge.net/">DenyHosts</a> configuration. As part of our &#8220;security policy&#8221;, I would like to ensure that every RedHat/CentOS system is running a properly configured DenyHosts instance. Here is what I&#8217;ve come up with so far.</p>
<p><span id="more-63"></span></p>
<pre>################################################################################
#
# FILE: denyhosts.cf
# DESC: Install, update, configure and ensure DenyHosts is running
# DATE: May 2010
#
#################################################################################

bundle agent denyhosts
{

packages:

  "denyhosts" -&gt; "Security policy"
    comment               =&gt; "Ensure denyhosts is installed once a week",
    package_policy        =&gt; "add",
    package_method        =&gt; yum,
    package_architectures =&gt; { "noarch" },
    action                =&gt; if_elapsed("10080");

  Night::

  "denyhosts" -&gt; "Security policy"
    comment               =&gt; "Check for update to denyhosts every 24 hours (and only at night)",
    package_policy        =&gt; "update",
    package_method        =&gt; yum,
    package_architectures =&gt; { "noarch" },
    action                =&gt; if_elapsed("1440");

files:

  "/etc/denyhosts.conf" -&gt; "Security policy"
    comment   =&gt; "Standard base DenyHosts configuration",
    copy_from =&gt; mycopy("$(g.confdir)/denyhosts/denyhosts.conf", "$(g.cfserver)"),
    classes   =&gt; cdefine("denyhosts_restart", "denyhosts_conf_copy_failed"),
    perms     =&gt; mo("400", "root"),
    action    =&gt; if_elapsed("1440");

processes:

  "python /usr/bin/denyhosts.py" -&gt; "Security policy"
    comment       =&gt; "Define denyhosts_restart class if denyhost is NOT running",
    restart_class =&gt; canonify("denyhosts_restart");

commands:

  "/sbin/service denyhosts restart" -&gt; "Security policy"
     comment    =&gt; "Restarting DenyHosts after configuration change or death",
     ifvarclass =&gt; canonify("denyhosts_restart");

}</pre>
<p>If you&#8217;re familiar with cfengine at all, you&#8217;ll quickly realize this is not a complete configuration. I am relying on the cfengine standard library for several body definitions as well as custom site variables defined in the common bundle named &#8220;g&#8221; (not shown). And of course, there are no control bodies, bundlesequence or many other things that make up a complete cfengine configuration, hence &#8220;snippet&#8221;.</p>
<p>Let&#8217;s ignore what&#8217;s lacking for now and focus on the meat of the promises.</p>
<h3>Packages</h3>
<p>The first part of the denyhosts bundle is dealing with packages. I&#8217;m making two promises regarding the &#8220;denyhosts&#8221; package. The first promise is that the package has been added to the system via yum and the second is that the package is up to date via yum. I&#8217;m not entirely clear on how to best manage promises like this yet so perhaps I&#8217;m missing some cute shorthand for both adding and keeping packages up to date. For now, I&#8217;ll stick with two separate promises.</p>
<p>You&#8217;ll also notice that I&#8217;m only checking to see if the package is installed once a week (via action =&gt; if_elapsed) and only checking to see if the package is up to date once every 24 hours (if_elapsed, again). The update promise is also subject to the Night class to ensure that package updates only occur at night and not during the work day. This is just a matter of preference. I&#8217;d prefer if updates occur at night, you may not.</p>
<p>Since I&#8217;m using a &#8220;smart&#8221; package manager to ensure that denyhosts is installed, I can count on having yum resolve any dependencies (such as python) for me automatically. I would loath to describe every dependency for every package I want control over by hand.</p>
<h3>Files</h3>
<p>There is only one file that I&#8217;m concerned with when it comes to denyhosts and that is the denyhosts configuration file in /etc/denyhosts.conf. Instead of doing file edits on the default denyhosts.conf file provided in the denyhosts packages that I&#8217;ve promised to install, I simply copy a pre-defined configuration from my cfengine server. This file has our site&#8217;s default denyhosts configuration all ready to go. If I needed to customize the configuration on a per-host or per-host-type basis, I could copy the base file to a temporary location then perform edits on the temp file and write out the changes to the final location of the default configuration file or simply maintain several pre-configured versions of denyhosts.conf and copy the appropriate file.</p>
<p>Also of note about files is that if the file promise must be repaired (if the file must be copied because it&#8217;s changed), I&#8217;m setting a class to be defined so that DenyHosts can be restarted. More on that later.</p>
<h3>Processes</h3>
<p>In this case, I&#8217;m only checking to see if the DenyHosts python process is running or not. If DenyHosts is running, we do nothing. If DenyHosts is not running, we define a class using the same name as the class we define if we have to copy the configuration file.</p>
<h3>Commands</h3>
<p>Finally, in the commands section we tell cfengine how and when to restart DenyHosts. If the &#8220;denyhosts_restart&#8221; class is defined, we instruct cfengine to restart DenyHosts with the &#8220;/sbin/service denyhosts restart&#8221; command. The canonify and cdefine special functions in cfengine provide a very powerful way of defining some rather complex relationships.</p>
<h3>What is Missing?</h3>
<p>Well, probably <em>a lot</em> of stuff. One obvious thing is that I&#8217;m not promising that DenyHosts is set to startup at boot time using the hosts&#8217; native init system. Of course, this shouldn&#8217;t be a big deal because cfengine will start it up if it&#8217;s not running at the next cf-agent run, but perhaps it would be nice to make that promise anyways.</p>
<p>I&#8217;m also not using many (or any!) classes to limit the scope of where (to what hosts) these promises will apply. Right now, I&#8217;m just working with a test environment so it&#8217;s easy to get away with that but I&#8217;m learning that it&#8217;s good to be as explicit at possible from the start when building promises.</p>
<p><strong>UPDATE:</strong> Ah, how could I forget.. Reporting is totally missing! I knew I was setting some of those classes for a reason. In the next installment, I&#8217;ll include the most basic of reporting functionality.</p>
<p>I think that&#8217;s all for now. Please critique my amateur use of cfengine 3 in the comments, I want to hear from you!</p>
<p>Related posts:<ol>
<li><a href='http://techslaves.org/2010/10/02/cfengine-3-snippets-part-2-sudo/' rel='bookmark' title='Cfengine 3 Snippets Part 2: sudo'>Cfengine 3 Snippets Part 2: sudo</a></li>
<li><a href='http://techslaves.org/2010/05/07/rhelcentos-nfs-and-firewalls/' rel='bookmark' title='RHEL/CentOS, NFS and Firewalls'>RHEL/CentOS, NFS and Firewalls</a></li>
<li><a href='http://techslaves.org/2010/03/29/nanorcs/' rel='bookmark' title='Nanorcs: Ultrasimplistic Configuration File Revision Control'>Nanorcs: Ultrasimplistic Configuration File Revision Control</a></li>
</ol></p>]]></content:encoded>
			<wfw:commentRss>http://techslaves.org/2010/05/18/cfengine-3-snippets-part-1-denyhosts/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

