<?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>George Lantz</title>
	<atom:link href="http://georgelantz.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://georgelantz.com</link>
	<description>Nature, science, photography and other things that interest me.</description>
	<lastBuildDate>Sat, 11 Jun 2011 00:04:31 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Pluteus plautus as Art</title>
		<link>http://georgelantz.com/2011/06/07/mushrooms-as-art/</link>
		<comments>http://georgelantz.com/2011/06/07/mushrooms-as-art/#comments</comments>
		<pubDate>Tue, 07 Jun 2011 23:13:53 +0000</pubDate>
		<dc:creator>glantz</dc:creator>
				<category><![CDATA[Art]]></category>
		<category><![CDATA[Fungi]]></category>
		<category><![CDATA[Photography]]></category>

		<guid isPermaLink="false">http://georgelantz.com/?p=51</guid>
		<description><![CDATA[Being a mycophile and recently beginning my hobby as a photographer I thought I would experiment with mushrooms as my subject. This photo was taken May 15th on my property. I thought the lighting and texture of the photo would make a pleasing black and white. I have identified the mushroom as Plutieus plautus. Not [...]]]></description>
			<content:encoded><![CDATA[<p><a href="http://georgelantz.com/?attachment_id=52" rel="attachment wp-att-52"><img src="http://georgelantz.com/wp-content/uploads/2011/06/pluteus_plautus-150x150.jpg" alt="" title="pluteus_plautus" width="150" height="150" class="alignleft size-thumbnail wp-image-52" /></a> Being a mycophile and recently beginning my hobby as a photographer I thought I would experiment with mushrooms as my subject. This photo was taken May 15th on my property. I thought the lighting and texture of the photo would make a pleasing black and white. I have identified the mushroom as <em>Plutieus plautus</em>. Not a particularly interesting species but beautiful nontheless.</p>
]]></content:encoded>
			<wfw:commentRss>http://georgelantz.com/2011/06/07/mushrooms-as-art/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Tumbling Creek Cave Restoration &#8211; Ozark Underground Laboratory</title>
		<link>http://georgelantz.com/2011/06/01/tumbling-creek-cave-ozark-underground-laboratory/</link>
		<comments>http://georgelantz.com/2011/06/01/tumbling-creek-cave-ozark-underground-laboratory/#comments</comments>
		<pubDate>Wed, 01 Jun 2011 12:40:04 +0000</pubDate>
		<dc:creator>glantz</dc:creator>
				<category><![CDATA[Caving]]></category>

		<guid isPermaLink="false">http://georgelantz.com/?p=35</guid>
		<description><![CDATA[This article featured in Subterranean Journeys &#8211; a publication by Springfield Plateau Grotto In the beautiful Ozark hills of Southwest Missouri lays a hidden gem of spectacular beauty, rare wildlife and immeasurable speleological importance. Surrounded by thousands of acres of rugged land and national forest is Tumbling Creek Cave at the Ozark Underground Laboratory. Described [...]]]></description>
			<content:encoded><![CDATA[<p><small>This article featured in Subterranean Journeys &#8211; a publication by Springfield Plateau Grotto</small></p>
<p>In the beautiful Ozark hills of Southwest Missouri lays a hidden gem of spectacular beauty, rare wildlife and immeasurable speleological importance. Surrounded by thousands of acres of rugged land and national forest is Tumbling Creek Cave at the Ozark Underground Laboratory. Described as the most biologically diverse cave west of the Mississippi River, over 130 different species of cave life have been recorded so far. Besides the diversity of life, this cave contains miles of almost perfectly preserved cave formations. A visit to the cave is an educational experience not found anywhere else. The organization provides short courses, field trips and educational tours for college groups, biologists, hydrologists, geologists, and engineers. These courses and programs have educated a large number on the importance of protecting </p>
<p><span id="more-35"></span></p>
<p>cave and karst resources. Any opportunity to visit this cave is a special privilege.</p>
<p>When it was mentioned that the Ozark Underground Laboratory needed assistance with cave restoration, I jumped at the chance. Having missed all earlier field trips,  this would be a great opportunity to visit the cave as well as give back to an organization that has done so much for speleology and cave conservation. Excited about the idea to help, and of course, see the cave, I presented the idea of a cleanup effort to the members of SPG and Tom Aley, owner of Ozark Underground Laboratory. The members of SPG responded well to the idea and Tom was thrilled to have volunteers. He made a special request for us to repair a rather large speleothem and some other various tasks. Tom generously offered the use of the bunkhouse for an overnight stay. The plan was set, we would have an overnight group trip. I could hardly wait!</p>
<p>The day had finally arrived. Five members of Springfield Plateau Grotto graciously gave up their Saturdays and Sundays to help with our volunteer project. Members included Jon Beard, Roy Gold, Charley Young, Charley&#8217;s granddaughter Abby and myself. We assembled at our meeting place to carpool and caravan the ninety minute drive. We followed one another through beautiful and scenic Ozarks landscape. Record rainfalls were recorded the previous week. The recent flooding could be seen all along our journey, evident by the excessively high waters of lakes and streams. It was a remarkable sight. Thankfully it didn&#8217;t hamper our travels.</p>
<p>At last we had arrived. Tom greeted us as we parked our vehicles and introduced himself to the group. His personality and sense of humor are larger than life. It&#8217;s nearly impossible to capture Tom&#8217;s persona in writing. After a few minutes of introductions and pleasantries, Tom asked “Want to see the cave?”. We quickly gathered only the necessary gear such as helmets and headlamps and followed Tom.</p>
<p>As we hiked down the foot path leading to the cave we came upon a small stone building proudly displaying a  <em>National Natural Landmark</em> emblem. ”There is very high water at the natural entrance of the cave right now, so we will go in through the second entrance.” Tom said. “But you should visit the entrance before you leave. I don&#8217;t think I have ever seen the water this high.”  As we gathered around the door of the stone building, he  presented us with a key and continued. “I say this to everyone that enters the cave. Stay on the trail, be careful where you step and watch for cave critters.”. Tom opened the door and we entered single file following him down the flight of stairs leading to the darkness underground.</p>
<p>Once inside the cave we immediately came to the first item on our to-do list and the main reason for our visit, the stalagmite repair. “Here is the stalagmite I was talking about.” Tom said. “I hope you guys will be able to get it reattached.” Looking at the broken speleothem, I thought this would be an easy task. I would soon learn that appearances can be deceiving.</p>
<p>Trying to keep up with Tom who had made this walk literally thousands of times, we progressed further into the cave. We arrived at a portion of the trail that was partially obstructed by neatly stacked lumber. “If you feel up to it, I would like to see this wood make its way out of here.” Tom said as we passed the fungus and decay covered stacks. “It used to be an observation deck for research. It will be a hard job so if you can&#8217;t get to it, I can hire someone to come and get it.” We continued to follow Tom as he led us to the next assignment. “This is the next thing I would like to have done. Somehow cave mud has managed to fall onto the trail. The mud is getting tracked all around.” We passed the mud watching carefully to not track it even further.</p>
<p>We followed the trail through enormous breakdown and gigantic walls of cave decoration. We eventually approached the “Big Room” where the underground creek roared through the darkness. “This is Tumbling Creek, the underground stream that gives this cave its name.”, explained Tom. “This stream eventually exits the natural entrance.”</p>
<p>The cave became more interesting and revealed more of its secrets as we moved deeper. Tom motioned to a large mound of rock and bat guano. “Here is a great spot to find pseudo-scorpions.” We all stopped for a moment to try and catch a glimpse, but no one managed to spot one. We continued on   making our way around a bend. We stopped again as Tom pointed at four small pieces of wood. “This is a wood study station. We observe what happens to the pieces over time. This is also the location where we find <em>Chaetaspis aleyorum</em>, a very small millipede found only in this cave.” He lifted one of the pieces and turned it over to show the bottom. Tom studied it through his glasses for a moment before pointing to a tiny white arthropod. “Here&#8217;s one.” He said as he passed around the wood piece. The millipede was tiny, about 3 to 5mm long and about the width of a pencil lead. I was simply amazed! I truly felt honored to observe this unique species that is found no where else in the world.</p>
<p>We made one last stop to see a the final item on our list. This was a removing of a coating of mud splatter on the walls and ceilings left over from the blasting during the construction of the trail. “Unfortunately, we can&#8217;t go too much further today. When I was down here last time there was a strong guano odor which means bats are present. We don&#8217;t want to disturb them. I don&#8217;t mind if you want to explore past this point, but please turn around when you detect the odor.”</p>
<p>Eager to get started, we turned around and headed to the surface to gather the rest of our gear and restoration equipment. We grabbed a few buckets, brushes, tarps, adhesives and sprayers. The first item of business, the broken stalagmite.</p>
<p>We all surrounded Jon as he assessed the broken speleothem. “It appears that this stalagmite has been damaged before.” he sad as he examined the broken surface. “You can see a layer of  old adhesive. I will need to remove it and prepare the surface before we can apply fresh adhesive position it into place.”</p>
<p>While Jon prepared the surfaces, the rest of us began the difficult job of carrying the stacks of lumber out of the cave. The stacks were roughly three hundred yards, and a large flight of stairs, from the surface. Once above ground there was another one hundred yards of foot trail to their final resting place. Needless to say, this was a strenuous job. Luckily we had a winch and pulley to lift small loads of lumber up the stairs. We divided into two groups, two people above ground and two below ground. We made several back and forth trips until all the lumber was removed.</p>
<p>By the time we were finished removing the lumber,  Jon had the stalagmite surface prepared. A tarp was positioned over the damaged structures to protect from moisture from of the dripping ceiling overhead. We were ready to begin. Jon liberally applied epoxy to both surfaces. Charlie and I climbed down to the small pit to help lift the giant into place. We assembled into our positions. “Ready? One, two, three”, we chanted together and lifted with all our strength. Despite our effort we only managed to lift the hefty beast  six inches off the ground. The positioning was awkward and only two people could comfortably fit in the tight space. We needed a different plan. Luckily, Charlie brought some nylon rope. We secured two ropes to each end of the formation. Charley and I climbed out of the pit and positioned ourselves above the formation. Roy and Jon arranged themselves below the formation. Together, we gathered all our strength and moved the massive calcite structure up onto its broken base. We made a few minor adjustments before we stepped back and viewed our achievement. The repair was almost perfect!</p>
<p>The afternoon was dwindling but we decided we had time for one last project. Charlie had already gathered the mud from the trail. All that was left was rinsing the final residue. This job went rather quickly. As we finished this task it was nearly dinnertime. While the others explored and photographed the cave, I went above ground to start the grill and begin cooking our well deserved meal.</p>
<p>As dinner time announced itself with sweet smoky aroma, the remainder of the group surfaced with perfect timing. We piled around a table full of burgers, bratwurst and all the fixings. The hard work left us all with a huge appetite! Tom came to join us during dinner. He entertained us with myriad of humorous stories. As the afternoon turned to evening, part of the group departed to make the long drive back. Jon and I stayed and continued to enjoy Tom&#8217;s conversation. We talked and exchanged stories and before we knew it, it was past ten! <span style="color: #000000;">Completely exhausted, Jon and I climbed into our bunks and surrendered to sleep.</span></p>
<p>After we rose out of bed and had a quick breakfast, Jon and I decided to work a few hours before leaving to see how much we could accomplish with mud removal from the ceiling and walls that Tom pointed out the previous day. Once again, we gathered our supplies and headed back into the cave. It was both tedious and time consuming. First we spread a tarp below our work area so we didn&#8217;t contaminate the cave floor. Next, we used our hands and brushes to remove the peanut butter-like mud. Using a large hand pump backpack sprayer, we sprayed off the residual mud with water collected from Tumbling Creek. We used toothbrushes to scrub and detail between the crevices. After three hours we only managed to complete a ten foot section. The work was slow but we uncovered a beautiful ribbon formation and a nice stalactite which made our efforts rewarding.</p>
<p>Before we departed, Jon and I explored more of the cave. We walked the trail and admired the beautiful formations. Jon showed me the large formation called the saguaro, named for obvious reasons. I managed to snap a few photographs before we headed out.</p>
<p>Although the majority of our trip was spent working, I thoroughly enjoyed our stay.  This special place was an experience rewarding, fascinating and wondrous and one that I will never forget.</p>
]]></content:encoded>
			<wfw:commentRss>http://georgelantz.com/2011/06/01/tumbling-creek-cave-ozark-underground-laboratory/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Honey Locust</title>
		<link>http://georgelantz.com/2011/05/31/locust-thorns/</link>
		<comments>http://georgelantz.com/2011/05/31/locust-thorns/#comments</comments>
		<pubDate>Tue, 31 May 2011 23:18:31 +0000</pubDate>
		<dc:creator>glantz</dc:creator>
				<category><![CDATA[Nature]]></category>

		<guid isPermaLink="false">http://georgelantz.com/?p=19</guid>
		<description><![CDATA[The Honey locust, Gleditsia triacanthos, is a deciduous tree native to eastern North America. It is mostly found in the moist soil near rivers and streams. A notable characteristic is the large ominous looking thorns.]]></description>
			<content:encoded><![CDATA[<p><a rel="attachment wp-att-20" href="http://georgelantz.com/?attachment_id=20"><img class="alignleft size-thumbnail wp-image-20" title="locust" src="http://georgelantz.com/wp-content/uploads/2011/05/locust1-150x150.jpg" alt="" width="150" height="150" /></a></p>
<p>The Honey locust, Gleditsia triacanthos, is a deciduous tree native to eastern North America. It is mostly found in the moist soil near rivers and streams. A notable characteristic is the large ominous looking thorns.</p>
]]></content:encoded>
			<wfw:commentRss>http://georgelantz.com/2011/05/31/locust-thorns/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Scarlet Cup Fungus</title>
		<link>http://georgelantz.com/2011/05/31/scarlet-cup-fungus/</link>
		<comments>http://georgelantz.com/2011/05/31/scarlet-cup-fungus/#comments</comments>
		<pubDate>Tue, 31 May 2011 23:14:36 +0000</pubDate>
		<dc:creator>glantz</dc:creator>
				<category><![CDATA[Fungi]]></category>
		<category><![CDATA[Nature]]></category>

		<guid isPermaLink="false">http://georgelantz.com/?p=14</guid>
		<description><![CDATA[I found this specimen in late May near Springfield, MO. These are fairly common in spring, but are one of my favorites to photograph. According to Michael Kuo of mushroomexpert.com: Field guides typically treat this mushroom as &#8220;Sarcoscypha coccinea,&#8221; though that species is actually found only in the Pacific Northwest. Sarcoscypha dudleyi and Sarcoscypha austriaca [...]]]></description>
			<content:encoded><![CDATA[<p><a rel="attachment wp-att-15" href="http://georgelantz.com/?attachment_id=15"><img class="alignleft size-thumbnail wp-image-15" title="scarlet_cup" src="http://georgelantz.com/wp-content/uploads/2011/05/scarlet_cup-150x150.jpg" alt="" width="150" height="150" /></a></p>
<p>I found this specimen in late May near Springfield, MO. These are fairly common in spring, but are one of my favorites to photograph.</p>
<p>According to Michael Kuo of mushroomexpert.com:</p>
<p>Field guides typically treat this mushroom as &#8220;Sarcoscypha coccinea,&#8221; though that species is actually found only in the Pacific Northwest. Sarcoscypha dudleyi and Sarcoscypha austriaca are the eastern species&#8211;but separating them, unfortunately, requires a microscope. See the gory details below, under &#8220;Microscopic Features.&#8221;</p>
]]></content:encoded>
			<wfw:commentRss>http://georgelantz.com/2011/05/31/scarlet-cup-fungus/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Regal Moth</title>
		<link>http://georgelantz.com/2011/05/31/imperial-moth/</link>
		<comments>http://georgelantz.com/2011/05/31/imperial-moth/#comments</comments>
		<pubDate>Tue, 31 May 2011 23:07:28 +0000</pubDate>
		<dc:creator>glantz</dc:creator>
				<category><![CDATA[Nature]]></category>

		<guid isPermaLink="false">http://georgelantz.com/?p=7</guid>
		<description><![CDATA[The beautiful Regal Moth (Citheronia regalis), is found throughout the deciduous forest areas of the eastern U.S. from Missouri to Massachusetts and southward to Texas and central Florida. It is more common in the southern part of its distribution. Common among walnut and hickory trees, the larva is typically called hickory horned devil. The color [...]]]></description>
			<content:encoded><![CDATA[<p><a rel="attachment wp-att-8" href="http://georgelantz.com/?attachment_id=8"><img class="alignleft size-thumbnail wp-image-8" title="imperial_moth" src="http://georgelantz.com/wp-content/uploads/2011/05/imperial_moth-150x150.jpg" alt="" width="150" height="150" /></a>The beautiful Regal Moth (Citheronia regalis), is found throughout the deciduous forest areas of the eastern U.S. from Missouri to Massachusetts and southward to Texas and central Florida. It is more common in the southern part of its distribution. Common among walnut and hickory trees, the larva is typically called hickory horned devil. The color and pattern of male and female regal moths are identical, however the males are slightly smaller in size and have wings that are more narrow. Although these moths are mostly nocturnal, this one was photographed early afternoon.</p>
]]></content:encoded>
			<wfw:commentRss>http://georgelantz.com/2011/05/31/imperial-moth/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Virtualbox Host Interface Networking &#8211; Windows host, Ubuntu guest</title>
		<link>http://georgelantz.com/2007/11/27/virtualbox-host-interface-networking-windows-host-ubuntu-guest/</link>
		<comments>http://georgelantz.com/2007/11/27/virtualbox-host-interface-networking-windows-host-ubuntu-guest/#comments</comments>
		<pubDate>Tue, 27 Nov 2007 22:35:37 +0000</pubDate>
		<dc:creator>glantz</dc:creator>
				<category><![CDATA[Open Source]]></category>
		<category><![CDATA[Technology]]></category>

		<guid isPermaLink="false">http://georgelantz.com/2007/11/27/virtualbox-host-interface-networking-windows-host-ubuntu-guest/</guid>
		<description><![CDATA[So I needed a way of running a couple test servers. Each needed to accept connections from the network including the host operating system. The connections needed to also be static for server testing. As a reminder to myself, here is a brief rundown on how to do it. I am using VirtualBox 1.5.2 with [...]]]></description>
			<content:encoded><![CDATA[<p>So I needed a way of running a couple test servers. Each needed to accept connections from the network including the host operating system. The connections needed to also be static for server testing. As a reminder to myself, here is a brief rundown on how to do it. <span id="more-88"></span></p>
<p>I am using  VirtualBox 1.5.2 with Windows Vista (XP will work with this method as well). For the Guest I am using Ubuntu 6.06 Server. This will work with other Debian based flavors.</p>
<p><strong>Host Setup </strong></p>
<p>1. Create a new virtual machine.</p>
<p>2. Click on Network to configfure network settings for your VM</p>
<p>3. Add a new host interface by click the add button next to the Host Interfaces select box. Name it anything you like.</p>
<p>4.  Change the Attached to option to Host Interface. Choose your new host interface in the Interface name option.</p>
<p>5.  This will create a virtual interface TAP adapter in the Windows Network Connections.</p>
<p>6. Go to the Windows Network Connections. Highlight your main connection and the new virtual interface, right click and choose Bridge Connections.</p>
<p>Now all packets sent to or from the virtual interface will be routed through your main network connection. Now to set up the client.</p>
<p><strong>Client Setup</strong></p>
<p>1. Start the virtual machine with Ubuntu Installed</p>
<p>2. Set up your  network interface</p>
<p>sudo nano /etc/network/interfaces</p>
<p>iface eth0 inet static<br />
address 192.168.0.2<br />
netmask 255.255.255.0<br />
network 192.168.0.0<br />
broadcast 192.168.0.266<br />
gateway 192.168.0.1</p>
<p>3. Set up your nameservers</p>
<p>sudo nano /etc/resolv.conf</p>
<p>nameserver xx.xx.xx.xx<br />
nameserver xx.xx.xx.xx</p>
<p>4. Restart the network</p>
<p>sudo /etc/init.d/networking restart</p>
<p>5. Test</p>
<p>ifconfig &#8211; should see the address set in the /etc/network/interfaces</p>
<p>ping -c3 192.168.0.1</p>
<p>Alright that&#8217;s it. I will show you how to bridge your connection on Linux next time.</p>
]]></content:encoded>
			<wfw:commentRss>http://georgelantz.com/2007/11/27/virtualbox-host-interface-networking-windows-host-ubuntu-guest/feed/</wfw:commentRss>
		<slash:comments>22</slash:comments>
		</item>
		<item>
		<title>Ruby On Rails acts_as_tree select menu</title>
		<link>http://georgelantz.com/2007/10/15/ruby-on-rails-acts_as_tree-select-menu/</link>
		<comments>http://georgelantz.com/2007/10/15/ruby-on-rails-acts_as_tree-select-menu/#comments</comments>
		<pubDate>Mon, 15 Oct 2007 14:17:15 +0000</pubDate>
		<dc:creator>glantz</dc:creator>
				<category><![CDATA[Ruby]]></category>
		<category><![CDATA[Ruby on Rails]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://georgelantz.com/2007/10/15/ruby-on-rails-acts_as_tree-select-menu/</guid>
		<description><![CDATA[This time I would like to share a helper I wrote for rails. I was trying to write a form to add categories and I wanted to present a neatly formatted select box of existing categories to select as the parent category. It also needed infinite nested subcategories. I could not find a tutorial or [...]]]></description>
			<content:encoded><![CDATA[<p>This time I would like to share a helper I wrote for rails. I was trying to write a form to add categories and I wanted to present a neatly formatted select box of existing categories to select as the parent category. It also needed infinite nested subcategories. I could not find a tutorial or example code anywhere for what I was trying to do. So I wrote this little snippet. <span id="more-86"></span></p>
<p><strong> application_helper.rb:</strong></p>
<pre lang="ruby">
  def tree_select(categories, model, name, selected=0, level=0, init=true)
    html = ""
    # The "Root" option is added
    # so the user can choose a parent_id of 0
    if init
        # Add "Root" to the options
        html << "
<select name=\\"#{model}[#{name}]\\" id=\\"#{model}_#{name}\\">\\n"
        html << "\\t
<option value=\\"0\\""
        html << " selected=\\"selected\\"" if selected.parent_id == 0
        html << ">Root</option>

\\n"
    end

    if categories.length > 0
      level += 1 # keep position
      categories.collect do |cat|
        html << "\\t
<option value=\\"#{cat.id}\\" style=\\"padding-left:#{level * 10}px\\""
        html << ' selected="selected"' if cat.id == selected.parent_id
        html << ">#{cat.name}</option>

\\n"
        html << tree_select(cat.children, model, name, selected, level, false)
      end
    end
    html << "</select>

\\n" if init
    return html
  end
</pre>
<p><strong>View:</strong></p>
<pre lang="ruby">
<%= tree_select(Category.find(:all, :conditions => "parent_id = 0"),
                        'category', 'parent_id', @category) %>
</pre>
<p><img src="http://georgelantz.com/wp-includes/images/tree_select.jpg" title="Tree Select Menu" alt="Tree Select Menu" border="1" height="650" width="400" /></p>
]]></content:encoded>
			<wfw:commentRss>http://georgelantz.com/2007/10/15/ruby-on-rails-acts_as_tree-select-menu/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>Latest World Wind Java Release</title>
		<link>http://georgelantz.com/2007/09/27/latest-world-wind-java-release/</link>
		<comments>http://georgelantz.com/2007/09/27/latest-world-wind-java-release/#comments</comments>
		<pubDate>Thu, 27 Sep 2007 13:38:37 +0000</pubDate>
		<dc:creator>glantz</dc:creator>
				<category><![CDATA[GIS]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Open Source]]></category>
		<category><![CDATA[Technology]]></category>
		<category><![CDATA[World Wind]]></category>

		<guid isPermaLink="false">http://georgelantz.com/2007/09/27/latest-world-wind-java-release/</guid>
		<description><![CDATA[I downloaded and ran the latest released version of the WWJ SDK available for download at the World Wind Java site &#8211; 20070817. I was pleasantly surprised when I saw the 2D location map and the distance meter added to the window by default. Cool less that I have to do. I was thinking of [...]]]></description>
			<content:encoded><![CDATA[<p>I downloaded and ran the latest released version of the WWJ SDK available for download at the <a href="http://worldwind.arc.nasa.gov/java/" title="World Wind Java">World Wind Java</a> site &#8211; 20070817. I was pleasantly surprised when I saw the 2D location map and the distance meter added to the window by default. Cool less that I have to do. I was thinking of doing a tutorial on how to add those things.</p>
<p>Also, I should add that if you want to find even later releases and release announcements head over to the forum <a href="http://forum.worldwindcentral.com/forumdisplay.php?f=43" title="WWJ Release announcements">http://forum.worldwindcentral.com/forumdisplay.php?f=43</a>. This will have the latest releases for you to try out.<span id="more-84"></span></p>
<p><img src="http://georgelantz.com/wp-includes/images/new-wwj.jpg" title="Latest WWJ SDK" alt="Latest WWJ SDK" border="0" height="335" width="400" /></p>
]]></content:encoded>
			<wfw:commentRss>http://georgelantz.com/2007/09/27/latest-world-wind-java-release/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>My Contribution on the NetBeans Welcome Screen</title>
		<link>http://georgelantz.com/2007/09/19/my-contribution-on-the-netbeans-welcome-screen/</link>
		<comments>http://georgelantz.com/2007/09/19/my-contribution-on-the-netbeans-welcome-screen/#comments</comments>
		<pubDate>Wed, 19 Sep 2007 21:00:36 +0000</pubDate>
		<dc:creator>glantz</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Technology]]></category>

		<guid isPermaLink="false">http://georgelantz.com/2007/09/19/my-contribution-on-the-netbeans-welcome-screen/</guid>
		<description><![CDATA[So, I was having a rough day today. I won&#8217;t get into that, but my spirits where cheered a little when I saw the article I contributed to the NetBeans Wiki, on the NetBeans Welcome Screen. I know this is not a big deal, but I thought it was pretty neat. Especially because I have [...]]]></description>
			<content:encoded><![CDATA[<p>So, I was having a rough day today. I won&#8217;t get into that, but my spirits where cheered a little when I saw the article I contributed to the NetBeans Wiki, on the NetBeans Welcome Screen.<span id="more-83"></span></p>
<p>I know this is not a big deal, but I thought it was pretty neat. Especially because I have been contemplating lately writing as a career choice. Maybe write for a website, blog (beside this one), or, even perhaps a book. Is this a sign?</p>
<p><a href="http://georgelantz.com/wp-includes/images/meonnb.jpg" title="NetBeans Screenshot" target="_blank"><img src="http://georgelantz.com/wp-includes/images/meonnb-sm.jpg" title="My Article on NetBeans" alt="My Article on NetBeans" border="0" height="320" width="400" /></a></p>
<p>Click for full size.</p>
]]></content:encoded>
			<wfw:commentRss>http://georgelantz.com/2007/09/19/my-contribution-on-the-netbeans-welcome-screen/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Access MySQL Through SSH Tunnel in a Windows .NET Application</title>
		<link>http://georgelantz.com/2007/09/10/access-mysql-through-ssh-tunnel-in-a-windows-net-application/</link>
		<comments>http://georgelantz.com/2007/09/10/access-mysql-through-ssh-tunnel-in-a-windows-net-application/#comments</comments>
		<pubDate>Mon, 10 Sep 2007 22:08:50 +0000</pubDate>
		<dc:creator>glantz</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Technology]]></category>

		<guid isPermaLink="false">http://georgelantz.com/2007/09/10/access-mysql-through-ssh-tunnel-in-a-windows-net-application/</guid>
		<description><![CDATA[In this tutorial I will explain how I managed to access MySQL through SSH tunnel in my .NET application. This could come in handy for many reasons and is not limited to just MySQL. You could potentially tunnel almost any remote server daemon running behind a firewall. I originally created this technique for a Windows [...]]]></description>
			<content:encoded><![CDATA[<p>In this tutorial I will explain how I managed to access MySQL through SSH tunnel in my .NET application. This could come in handy for many reasons and is not limited to just MySQL. You could potentially tunnel almost any remote server daemon running behind a firewall. I originally created this technique for a Windows Desktop application so I could sync our company website inventory with the ERP software. For security reasons I only left the SSH and Apache ports open when I originally setup the web server.<span id="more-78"></span></p>
<p><strong>Explanation of SSH</strong><br />
First, maybe I should explain a little about SSH (secure Shell). SSH is a network protocol that allows you to make a secure encrypted connection between two computers on a network or over the internet. SSH uses public-key cryptography to authenticate the remote computer and allow the remote computer to authenticate the user. Normally SSH is used to execute commands on the remote computer from an SSH client installed on the client computer, however, it also allows tunneling, forwarding of TCP posts and X11 connections as well as secure file transfer. The SSH server running on the remote computer listens for remote connections on port 22 by default. A client then establishes a connection and is authenticated using a username/password and/or shared key. SSH is most commonly used on unix/Linux operating systems, but because it&#8217;s open source, it can run on most operating systems.</p>
<p><strong>How the tunneling technique works</strong><br />
So how do we access a server daemon behind a firewall? We will need to create a tunnel through SSH. In order to connect our .NET app to the SSH server our application needs make an SSH connection to the to the remote computer, authenticate using password or shared key, then tunnel the MySQL port back to our client computer. Once we have done that our application can connect to the remote MySQL server just as if it was a port listening locally on our client computer.</p>
<p><strong>How to use SSH in your application</strong><br />
I used the sharpSSH library for .NET to make SSH connections. This library is a C# port of the JSch project from JCraft Inc. Which means you could duplicate this same technique for Java as well. Here is how to do it.</p>
<ol>
<li><strong>Download sharpSSH and MySql Connector/Net 5.0</strong><br />
A. First we need to download and unzip sharpSSH &#8211; http://sourceforge.net/projects/sharpssh. There are two versions to download, either the binary or source. For this tutorial you only need the binary version.<br />
B. We also need the MySql Connector/Net 5.0 &#8211; http://dev.mysql.com/downloads/connector/net/5.0.html</li>
<li><strong>Create a new project</strong><br />
Open Visual Studio and create a new Windows Application. I used C# for this demonstration. Since it is a .NET lib, you can use VB if you prefer. I named my project SSHTunnel.</li>
<li><strong>Add the DLL Library References</strong><br />
Right click on References in the Solution Explorer and click on Add Reference, Click on the Browse tab. Browse first to the sharpSSH directory. There are three dll&#8217;s &#8211; DiffieHellman.dll, Org.Mentalis.Security, and Tamir.SharpSSH. Next browse to bin in the MySql Connector directory and add the MySql.Data.dll.</li>
<li><strong>Add UI component.<br />
</strong>A. Add two TextBoxes and two Labels to the form. The text for the first label should be remote port. The socond should be local port. Name your TextBoxes &#8220;textBoxRemote&#8221; and &#8220;textBoxLocal&#8221;.<br />
B. Add two buttons to the form. Set the text of one button to Connect, the other disconnect.<br />
C. Add a StatusStrip to the bottom of the form. Add a status label to the StatusStrip. Change the text to &#8220;Not Connected&#8221;.<br />
D. Add a label and change the text to &#8220;SQL QUery&#8221;<br />
E. Add a Textbox and name it &#8220;textBoxSQL.<br />
F. Add a Button and change the text to &#8220;Execute&#8221;<br />
G. Add a DataGridView to the form and resize to fit.</p>
<p>You should have a screen like below.<br />
<img src="http://georgelantz.com/wp-includes/images/sshtunnel-form.jpg" title="Form Example" alt="Form Example" border="0" height="404" width="500" /></li>
<li><strong>Add the code.<br />
</strong> A. Import the libraries.</p>
<pre lang="csharp">	using System.Net;
	using System.Net.Sockets;
	using System.Globalization;
	using Tamir.SharpSsh.jsch;
	using MySql.Data.MySqlClient;</pre>
<p>B. Add a UserInfo class for handling login information it extends the sharpSSH UserInfo Class.</p>
<pre lang="csharp"> 	public class MyUserInfo : UserInfo
	{
		/// &lt;summary&gt;
		/// Holds the user password
		/// &lt;/summary&gt;
		private String passwd;

		/// &lt;summary&gt;
		/// Returns the user password
		/// &lt;/summary&gt;
		public String getPassword() { return passwd; }

		/// &lt;summary&gt;
	 	/// Prompt the user for a Yes/No input
	 	/// &lt;/summary&gt;
	 	public bool promptYesNo(String str)
		{
	 		return true;
	 	}

		/// &lt;summary&gt;
	 	/// Returns the user passphrase (passwd for the private key file)
	 	/// &lt;/summary&gt;
	 	public String getPassphrase() { return null; }

		/// &lt;summary&gt;
	 	/// Prompt the user for a passphrase (passwd for the private key file)
	 	/// &lt;/summary&gt;
	 	public bool promptPassphrase(String message) { return true; }

		/// &lt;summary&gt;
	 	/// Prompt the user for a password
	 	/// &lt;/summary&gt;
	 	public bool promptPassword(String message) { return true; }

		/// &lt;summary&gt;
	 	/// Shows a message to the user
	 	/// &lt;/summary&gt;
	 	public void showMessage(String message) { }

 	}</pre>
<p>C. Add the class variables to store the connections</p>
<pre lang="csharp">
	private Session session;
	private MySqlConnection conn;</pre>
<p>D. Add the connection button event handler code</p>
<pre lang="csharp">	private void button1_Click(object sender, EventArgs e)
	{
		try
		{
			//Create a new JSch instance
			JSch jsch = new JSch();//Create a new SSH session
			string host = "yoururl.com"; //url
			string user = "sshuser"; //ssh username
			string pass = "sshpass"; //ssh password
			int sshPort = 22; //ssh port
			int rPort = Convert.ToInt32(textBoxRemote.Text);
			int lPort = Convert.ToInt32(textBoxLocal.Text);
			int port = Convert.ToInt32(sshPort);

			session = jsch.getSession(user, host, port);
			session.setHost(host);
			session.setPassword(pass);
			UserInfo ui = new MyUserInfo();
			session.setUserInfo(ui);
			session.connect();

			//Set port forwarding on the opened session
			session.setPortForwardingL(lPort, "localhost", rPort);
			if (session.isConnected())
			{
				this.toolStripStatusLabel1.Text = "Connected";
				this.button2.Enabled = true;
				this.button1.Enabled = false;
				try
				{
					string dbhost = "localhost";
					string dbuser = "dbuser";
					string dbpass = "dbpassword";
					string dbdatabase = "dbname";
					string connStr = String.Format("server={0};user id={1};
						password={2}; database={3}; pooling=false",
						dbhost, dbuser, dbpass, dbdatabase);

					// Create a MySql Connection
					conn = new MySqlConnection(connStr);
					conn.Open();
					conn.ChangeDatabase(dbdatabase);
				}
				catch (Exception ex)
				{
					MessageBox.Show(ex.Message);
					session.disconnect();
					this.toolStripStatusLabel1.Text = "Ready";
					this.button1.Enabled = true;
					this.button2.Enabled = false;
				}
				finally
				{
					conn.Close();
				}
			}
		}
		catch (Exception ex)
		{
			this.toolStripStatusLabel1.Text = "Error";
			this.button1.Enabled = true;
			this.button2.Enabled = false;
			MessageBox.Show(ex.Message);
		}
	}</pre>
<p>E. Add the Disconnect event handler code</p>
<pre lang="csharp">	private void button2_Click(object sender, EventArgs e)
	{
		session.disconnect();
		this.toolStripStatusLabel1.Text = "Not Connected";
		this.button1.Enabled = true;
		this.button2.Enabled = false;
	}</pre>
<p>F. Add the Execute query button event handler code</p>
<pre lang="csharp">	private void button3_Click(object sender, EventArgs e)
	{
		try
		{
			//MySql Example
			MySqlDataReader reader = null;
			MySqlDataAdapter da = new MySqlDataAdapter(textBoxSQL.Text, conn);
			MySqlCommandBuilder cb = new MySqlCommandBuilder(da);
			DataTable data = new DataTable();da.Fill(data);
			dataGridView1.DataSource = data;
		}
		catch (Exception ex)
		{
			MessageBox.Show(ex.Message);
		}
	}</pre>
</li>
<li> <strong>Run the project.</strong><br />
MySQL listens on 3306 by default, unless you have changed the port your MySQL server listens on then set the remote port to 3306. For this example set the local port to 3306. Click connect and wait for the status to say connected. Type in a simple SQL query and click execute.Note: I was getting a Unable to convert MySQL date/time value to System.DateTime exception. This can be remedied by formatting the date in the query. SELECT products_id, products_quantity, products_model, products_price, DATE_FORMAT(products_date_available, &#8216;%m/%d/%Y&#8217;) AS products_date_available from poducts;</li>
</ol>
<p>You can download the sample I have in it&#8217;s entirety &#8211; <a href="http://georgelantz.com/files/SSHTunnel.zip" title="SSHTunnel Download">SSHTunnel.zip</a></p>
]]></content:encoded>
			<wfw:commentRss>http://georgelantz.com/2007/09/10/access-mysql-through-ssh-tunnel-in-a-windows-net-application/feed/</wfw:commentRss>
		<slash:comments>39</slash:comments>
		</item>
	</channel>
</rss>

