<?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>totalnetsolutions.net &#187; Unix</title>
	<atom:link href="http://www.totalnetsolutions.net/category/unix/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.totalnetsolutions.net</link>
	<description>totalnetsolutions.net - Complete Networking Solutions for business</description>
	<lastBuildDate>Thu, 26 Jan 2012 04:05:18 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>What date is XX days from today?</title>
		<link>http://www.totalnetsolutions.net/2012/01/25/what-date-is-xx-days-from-today/</link>
		<comments>http://www.totalnetsolutions.net/2012/01/25/what-date-is-xx-days-from-today/#comments</comments>
		<pubDate>Thu, 26 Jan 2012 03:30:27 +0000</pubDate>
		<dc:creator>Robert</dc:creator>
				<category><![CDATA[HowTo]]></category>
		<category><![CDATA[Open Source Software]]></category>
		<category><![CDATA[Unix]]></category>
		<category><![CDATA[linux]]></category>
		<category><![CDATA[perl]]></category>

		<guid isPermaLink="false">http://www.totalnetsolutions.net/?p=89</guid>
		<description><![CDATA[A quick CLI reference for perl people&#8230; perl -e ' my @t=localtime(time() + $ARGV[0]*24*60*60); $t[4]++; $t[5]+=1900; print "$t[4]/$t[3]/$t[5]\n";' XX I&#8217;ve needed this 2x today already, and hope it helps you! Edit: Someone made a comment, as people on the internet are prone to do, so here&#8217;s the long-form non-one-liner version: #!/usr/bin/perl my $addDays = shift; [...]]]></description>
			<content:encoded><![CDATA[<p>A quick CLI reference for perl people&#8230;<br />
<code><br />
perl -e ' my @t=localtime(time() + $ARGV[0]*24*60*60); $t[4]++; $t[5]+=1900; print "$t[4]/$t[3]/$t[5]\n";' XX<br />
</code><br />
I&#8217;ve needed this 2x today already, and hope it helps you!</p>
<p>Edit:<br />
Someone made a comment, as people on the internet are prone to do, so here&#8217;s the long-form non-one-liner version:</p>
<p><code><br />
#!/usr/bin/perl<br />
my $addDays = shift;<br />
my ($second, $minute, $hour, $day, $month, $year, $dayOfWeek, $dayOfYear, $daylightSavings) = localtime(time());<br />
my ($fsecond, $fminute, $fhour, $fday, $fmonth, $fyear, $fdayOfWeek, $fdayOfYear, $fdaylightSavings) = localtime(time() + $addDays*24*60*60);</p>
<p>#fix 0 = 1 values, and "0 = 1900" problem:<br />
$month++;<br />
$fmonth++;<br />
$year+=1900;<br />
$fyear+=1900;</p>
<p>print "today is:                    $month/$day/$year\n";<br />
print "$addDays days from today is: $fmonth/$fday/$fyear\n";<br />
</code></p>
<p>Run it as:<br />
<code><br />
rob@laptop:~$ fdate.pl 50<br />
today is:              1/25/2012<br />
50 days from today is: 3/15/2012<br />
</code></p>
]]></content:encoded>
			<wfw:commentRss>http://www.totalnetsolutions.net/2012/01/25/what-date-is-xx-days-from-today/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>HowTo: Create a dummy / empty / blank krb5.keytab file</title>
		<link>http://www.totalnetsolutions.net/2011/07/07/howto-create-a-dummy-empty-blank-krb5-keytab-file/</link>
		<comments>http://www.totalnetsolutions.net/2011/07/07/howto-create-a-dummy-empty-blank-krb5-keytab-file/#comments</comments>
		<pubDate>Fri, 08 Jul 2011 03:29:39 +0000</pubDate>
		<dc:creator>Robert</dc:creator>
				<category><![CDATA[HowTo]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Unix]]></category>
		<category><![CDATA[howto technology linux]]></category>

		<guid isPermaLink="false">http://www.totalnetsolutions.net/?p=80</guid>
		<description><![CDATA[We had an issue recently where we needed a dummy krb5.keytab file for an operation prior to creating the real keytab: echo -e "\0005\0002\c" >/etc/krb5.keytab]]></description>
			<content:encoded><![CDATA[<p>We had an issue recently where we needed a dummy krb5.keytab file for an operation prior to creating the real keytab:<br />
<code>echo -e "\0005\0002\c" >/etc/krb5.keytab</code></p>
]]></content:encoded>
			<wfw:commentRss>http://www.totalnetsolutions.net/2011/07/07/howto-create-a-dummy-empty-blank-krb5-keytab-file/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Solaris 10 and DHCP (AKA but, I know this system!)</title>
		<link>http://www.totalnetsolutions.net/2008/06/18/solaris-10-and-dhcp-aka-but-i-know-this-system/</link>
		<comments>http://www.totalnetsolutions.net/2008/06/18/solaris-10-and-dhcp-aka-but-i-know-this-system/#comments</comments>
		<pubDate>Wed, 18 Jun 2008 19:26:00 +0000</pubDate>
		<dc:creator>Robert</dc:creator>
				<category><![CDATA[HowTo]]></category>
		<category><![CDATA[Unix]]></category>

		<guid isPermaLink="false">http://www.totalnetsolutions.net/?p=62</guid>
		<description><![CDATA[I’ve been working on something completely new for the past 2 months which has involved a lot of travel. 95% travel, which leaves precious little time to write new articles, especially as I’ve been spending my off-hours learning HP-UX 11 and Solaris 8 and 10. And I still have AIX 5 to learn too. Apperantly [...]]]></description>
			<content:encoded><![CDATA[<p>I’ve been working on something completely new for the past 2 months  which has involved a lot of travel.  95% travel, which leaves precious  little time to write new articles, especially as I’ve been spending my  off-hours learning HP-UX 11 and Solaris 8 and 10.  And I still have AIX 5  to learn too.</p>
<p>Apperantly Solaris 10 and OpenSolaris have a little quirk around how  they work with DHCP and setting the system’s DNS name.  In our test lab,  all our systems are assigned addresses via Microsoft DHCP, which then  registers (and un-registers) non-Windows systems in DNS properly.   However, the x86 Solaris systems we built for a customer test came up  with name “unknown”, every single reboot.  Changing /etc/hosts and  /etc/hostname.pcn0 or /etc/hostname.vmxnet0 (physical or VMWare) to  reflect the new proper hostname, however, didn’t affect the server on  reboot – the settings would still be there, but not reflected in the OS,  in /etc/hosts, or in DNS.</p>
<p>A bit of searching turns out a bunch of posts talking about editing  /etc/nodename to put in the system name, but that file doesn’t exist out  of the box on a “complete” or “minimal” install, and I’m always  hesitant to create new files by hand in /etc/ unless I’m 100% sure  that’s what’s needed.  According to <a href="http://forum.java.sun.com/thread.jspa?threadID=5073295&amp;messageID=9268470" target="_blank">this post on Sun.com</a>, some logic, and some testing, I think what’s going on is:</p>
<ol>
<li>Solaris expects DHCP to set the hostname of a system based on MAC address</li>
<li>In case DHCP does not set a hostname via MAC address, or if that  hostname is wrong, Solaris provides an override mechanism called  /etc/nodename</li>
<li>Because it’s an override, /etc/nodename is not created as a blank  file, since that could be construed as “override DHCP with nothing”</li>
<li>Therefore, every new box I build needs touching after final login</li>
</ol>
<p>I’m not a huge fan of this, but I’m also not a fan of the number of  times I need to click a mouse on an OS Install using software from the  last year.  The short version of all this is:</p>
<p>If you have a Solaris 10 box on DHCP named “unknown”, best practices is to set the hostname on the DHCP server.  Otherwise <code>echo newservername &gt; tee /etc/nodename</code> and reboot.  (with “tee” in the pipeline, you can “sudo” this command as well).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.totalnetsolutions.net/2008/06/18/solaris-10-and-dhcp-aka-but-i-know-this-system/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

