<?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>Fritz Thomas &#187; how-to</title>
	<atom:link href="http://fritzthomas.com/tags/how-to/feed/" rel="self" type="application/rss+xml" />
	<link>http://fritzthomas.com</link>
	<description></description>
	<lastBuildDate>Fri, 23 Jul 2010 08:02:28 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>How-To: Cleaning up Gentoo to get more free disk space</title>
		<link>http://fritzthomas.com/overall/491-how-to-cleaning-up-gentoo-to-get-more-free-disk-space/</link>
		<comments>http://fritzthomas.com/overall/491-how-to-cleaning-up-gentoo-to-get-more-free-disk-space/#comments</comments>
		<pubDate>Thu, 20 Aug 2009 10:33:03 +0000</pubDate>
		<dc:creator>Thomas</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Overall]]></category>
		<category><![CDATA[cleaning]]></category>
		<category><![CDATA[gentoo]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[xfs]]></category>

		<guid isPermaLink="false">http://fritzthomas.com/?p=491</guid>
		<description><![CDATA[You can safely empty some directory`s in Gentoo. But as always &#8211; first make sure if my suggestions are OK for YOU too! # As superuser gentoo ~ # emerge --sync gentoo ~ # emerge -av gentoolkit gentoo ~ # emerge -av --newuse --deep --update world gentoo ~ # emerge -av --depclean gentoo ~ # [...]]]></description>
			<content:encoded><![CDATA[<p>You can safely empty some directory`s in Gentoo. But as always &#8211; first make sure if my suggestions are OK for YOU too!</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># As superuser</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># emerge --sync</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># emerge -av gentoolkit</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># emerge -av --newuse --deep --update world</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># emerge -av --depclean</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># revdep-rebuild</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># rm -rf /var/tmp/portage/*</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># rm -rf /var/tmp/ccache/*</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># rm -rf /var/tmp/binpkgs/*</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># rm -rf /var/tmp/genkernel/*</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># rm -rf /usr/portage/distfiles/*</span>
gentoo ~ <span style="color: #666666; font-style: italic;"># rm -rf /tmp/*</span></pre></div></div>

<p>First, you have to install gentoolkit if you haven done this already. Then we remerge or update all packages where USE flags have changed. Then we are searching for unneeded dependencies and remove them. Finally we check if there are any packages with unresolved link dependencies, let them emerge and then clean up some directories.</p>
<p>Optionally you can defrag some of your partitions if this is neccessary. In case of XFS you can do this by:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">gentoo ~ <span style="color: #666666; font-style: italic;"># xfs_db -r /dev/hda2</span></pre></div></div>

</p>
<p>After this you should have a cleaned up gentoo environment, with no broken dependencies and no unneeded packages or libraries.</p>

	Tags: <a href="http://fritzthomas.com/tags/cleaning/" title="cleaning" rel="tag">cleaning</a>, <a href="http://fritzthomas.com/tags/gentoo/" title="gentoo" rel="tag">gentoo</a>, <a href="http://fritzthomas.com/tags/how-to/" title="how-to" rel="tag">how-to</a>, <a href="http://fritzthomas.com/tags/xfs/" title="xfs" rel="tag">xfs</a><br />

	<h4>&Auml;hnliche Beitr&auml;ge:</h4>
	<ul class="st-related-posts">
	<li><a href="http://fritzthomas.com/open-source/linux/12-aendern-oder-setzen-eines-statischen-netzwerk-device-namen-unter-gentoo-eth0-eth1ethn/" title="Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;) (December 27, 2007)">Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;)</a> (0)</li>
	<li><a href="http://fritzthomas.com/open-source/linux/22-7zip-unter-gentoo-linux-verwenden/" title="7zip unter Gentoo Linux verwenden (January 11, 2008)">7zip unter Gentoo Linux verwenden</a> (1)</li>
	<li><a href="http://fritzthomas.com/php/24-zend-framework-web-developer-appliance/" title="Zend Framework Web Developer Appliance (January 15, 2008)">Zend Framework Web Developer Appliance</a> (1)</li>
</ul>

]]></content:encoded>
			<wfw:commentRss>http://fritzthomas.com/overall/491-how-to-cleaning-up-gentoo-to-get-more-free-disk-space/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>How to vertically align text and block elements</title>
		<link>http://fritzthomas.com/overall/418-how-to-vertically-align-text-and-block-elements/</link>
		<comments>http://fritzthomas.com/overall/418-how-to-vertically-align-text-and-block-elements/#comments</comments>
		<pubDate>Wed, 18 Feb 2009 12:42:56 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Overall]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[CSS3]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[howto]]></category>
		<category><![CDATA[HTML]]></category>
		<category><![CDATA[inline-block]]></category>
		<category><![CDATA[vertical-align]]></category>

		<guid isPermaLink="false">http://fritzthomas.com/?p=418</guid>
		<description><![CDATA[You may know the CSS declarations text-align and vertical-align. Perhaps you tried alredy to vertically align inline span elements within a div block element but did not succeed yet. I will try explain how to achieve this with a simple button example. Before: After: Lets begin with the markup for the buttons: 1 2 3 [...]]]></description>
			<content:encoded><![CDATA[<p>You may know the CSS declarations text-align and vertical-align. Perhaps you tried alredy to vertically align inline span elements within a div block element but did not succeed yet. I will try explain how to achieve this with a simple button example.<br />
Before:<img style="vertical-align:middle" class="alignnone size-full wp-image-420" title="screenshot14" src="http://fritzthomas.com/wp-content/uploads/2009/02/screenshot14.png" alt="screenshot14" width="115" height="24" /><br />
After: <img style="vertical-align:middle" class="alignnone size-full wp-image-419" title="screenshot13" src="http://fritzthomas.com/wp-content/uploads/2009/02/screenshot13.png" alt="screenshot13" width="112" height="25" /><br />
<span id="more-418"></span><br />
 Lets begin with the markup for the buttons:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
</pre></td><td class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;buttons&quot;</span>&gt;</span>
  <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;add button&quot;</span>&gt;</span>
    <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">span</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;icon&quot;</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">img</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;add.png&quot;</span> <span style="color: #000066;">alt</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;&quot;</span> <span style="color: #66cc66;">/</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">span</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">span</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text&quot;</span>&gt;</span>Add<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">span</span>&gt;</span>
  <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
  <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;delete button&quot;</span>&gt;</span>
    <span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">span</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;icon&quot;</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">img</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;delete.png&quot;</span> <span style="color: #000066;">alt</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;&quot;</span> <span style="color: #66cc66;">/</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">span</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">span</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text&quot;</span>&gt;</span>Delete<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">span</span>&gt;</span>
  <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span></pre></td></tr></table></div>

<p>Each Button is within a single div. Every button has its icon and a button text. Image and Text are in a span tag. the &#8220;add&#8221; and &#8220;delete&#8221; class is added to differentiate the buttons. This is useful if you want to add some behavior in JavaScript.<br />
<div style="width:100%;text-align:center;padding:0;margin:0;border:0;overflow:hidden;clear:both;"><script type="text/javascript"><!--
google_ad_client = "pub-1963733382421272";
google_ui_features = "rc:0";
google_ad_width = 234;
google_ad_height = 60;
google_ad_format = "234x60_as";
google_ad_type = "text_image";
google_alternate_ad_color = "ffffff";
google_color_border = "ffffff";
google_color_bg = "ffffff";
google_color_link = "319BD8";
google_color_text = "666666";
google_color_url = "319BD8";

//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div></p>
<p>Next, the CSS styles:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
</pre></td><td class="code"><pre class="css" style="font-family:monospace;"><span style="color: #6666ff;">.buttons</span> <span style="color: #6666ff;">.button</span> <span style="color: #00AA00;">&#123;</span>
  <span style="color: #000000; font-weight: bold;">line-height</span><span style="color: #00AA00;">:</span><span style="color: #933;">16px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/** important **/</span>
  <span style="color: #000000; font-weight: bold;">height</span><span style="color: #00AA00;">:</span> <span style="color: #933;">16px</span><span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">padding</span><span style="color: #00AA00;">:</span> <span style="color: #933;">1px</span><span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">padding-right</span><span style="color: #00AA00;">:</span><span style="color: #933;">5px</span><span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">margin-right</span><span style="color: #00AA00;">:</span><span style="color: #933;">4px</span><span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">background-color</span><span style="color: #00AA00;">:</span><span style="color: #cc00cc;">#a1a1a1</span><span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span> <span style="color: #cc00cc;">#ffffff</span><span style="color: #00AA00;">;</span>
  border-radius<span style="color: #00AA00;">:</span> <span style="color: #933;">2px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/** CSS3 **/</span>
  -moz-border-radius<span style="color: #00AA00;">:</span> <span style="color: #933;">2px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/** Mozilla specific **/</span>
  -webkit-border-radius<span style="color: #00AA00;">:</span> <span style="color: #933;">2px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/** Make a guess ;-) **/</span>
  <span style="color: #000000; font-weight: bold;">float</span><span style="color: #00AA00;">:</span> <span style="color: #000000; font-weight: bold;">left</span><span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">cursor</span><span style="color: #00AA00;">:</span> hand<span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">cursor</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">pointer</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #6666ff;">.buttons</span> <span style="color: #6666ff;">.button</span> <span style="color: #6666ff;">.icon</span> <span style="color: #00AA00;">&#123;</span>
  <span style="color: #000000; font-weight: bold;">display</span><span style="color: #00AA00;">:</span> inline-<span style="color: #993333;">block</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/** important **/</span>
  <span style="color: #000000; font-weight: bold;">vertical-align</span><span style="color: #00AA00;">:</span><span style="color: #993333;">middle</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/** important **/</span>
  <span style="color: #000000; font-weight: bold;">padding</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">margin-right</span><span style="color: #00AA00;">:</span><span style="color: #933;">2px</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span>
&nbsp;
<span style="color: #6666ff;">.buttons</span> <span style="color: #6666ff;">.button</span> <span style="color: #6666ff;">.text</span> <span style="color: #00AA00;">&#123;</span>
  <span style="color: #000000; font-weight: bold;">display</span><span style="color: #00AA00;">:</span> inline-<span style="color: #993333;">block</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/** important **/</span>
  <span style="color: #000000; font-weight: bold;">vertical-align</span><span style="color: #00AA00;">:</span><span style="color: #993333;">middle</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/** important **/</span>
  <span style="color: #000000; font-weight: bold;">padding</span><span style="color: #00AA00;">:</span><span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
  <span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span></pre></td></tr></table></div>

<p><div style="float:left;margin-left:0,margin-right:4px;margin-top:4px;margin-bottom:0;padding:4px;border:0;"><script type="text/javascript"><!--
google_ad_client = "pub-1963733382421272";
google_ad_slot = "3802836967";
google_ad_width = 120;
google_ad_height = 240;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div>
<p>The important css declarations and attributes are &#8220;display: inline-block&#8221;, &#8220;vertical-align: middle&#8221; and &#8220;line-height: XXpx&#8221;. The line-height tells every .button block the exact height of the inline elements underneath. The inline elements .icon and .text are handled and displayed as an &#8220;inline-block&#8221;. Firefox 3 and most of the other major browsers supporting it so it is safe to use it. <a href="http://www.quirksmode.org/css/display.html">Read more on this.</a><br />
<br />
The result should look like this:<img style="vertical-align:middle" class="alignnone size-full wp-image-419" title="screenshot13" src="http://fritzthomas.com/wp-content/uploads/2009/02/screenshot13.png" alt="screenshot13" width="112" height="25" /><br />
I think the example is simple enough to adapt it to your needs and other use cases. Please keep in mind that in the example i use -moz-border-radius. This declaration is mozilla specific. So if you want rounded corners in IE you have to wait until IE is implementing this. Take <a href="http://a.deveria.com/caniuse/#feat=roundedcorners">a look</a> when this is scheduled and <a href="http://fritzthomas.com/overall/407-charts-of-when-we-can-use-features-of-html-svg-and-css3/#refuse-internet-explorer">follow my suggestion.</a></p>

	Tags: <a href="http://fritzthomas.com/tags/css/" title="css" rel="tag">css</a>, <a href="http://fritzthomas.com/tags/css3/" title="CSS3" rel="tag">CSS3</a>, <a href="http://fritzthomas.com/tags/how-to/" title="how-to" rel="tag">how-to</a>, <a href="http://fritzthomas.com/tags/howto/" title="howto" rel="tag">howto</a>, <a href="http://fritzthomas.com/tags/html/" title="HTML" rel="tag">HTML</a>, <a href="http://fritzthomas.com/tags/inline-block/" title="inline-block" rel="tag">inline-block</a>, <a href="http://fritzthomas.com/tags/vertical-align/" title="vertical-align" rel="tag">vertical-align</a><br />

	<h4>&Auml;hnliche Beitr&auml;ge:</h4>
	<ul class="st-related-posts">
	<li><a href="http://fritzthomas.com/overall/415-css-browser-compatiblity/" title="CSS Browser Compatiblity (February 18, 2009)">CSS Browser Compatiblity</a> (0)</li>
	<li><a href="http://fritzthomas.com/php/zend-framework/33-how-to-teil-1-projektaufbau-konventionen-und-modulare-verzeichnisstruktur/" title="Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur (January 28, 2008)">Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur</a> (13)</li>
	<li><a href="http://fritzthomas.com/open-source/linux/12-aendern-oder-setzen-eines-statischen-netzwerk-device-namen-unter-gentoo-eth0-eth1ethn/" title="Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;) (December 27, 2007)">Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;)</a> (0)</li>
</ul>

]]></content:encoded>
			<wfw:commentRss>http://fritzthomas.com/overall/418-how-to-vertically-align-text-and-block-elements/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Adobe releases AIR 1.5 for Linux</title>
		<link>http://fritzthomas.com/open-source/linux/351-adobe-releases-air-15-for-linux/</link>
		<comments>http://fritzthomas.com/open-source/linux/351-adobe-releases-air-15-for-linux/#comments</comments>
		<pubDate>Thu, 18 Dec 2008 10:58:49 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Air]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Adobe]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[Release]]></category>

		<guid isPermaLink="false">http://fritzthomas.com/?p=351</guid>
		<description><![CDATA[A few weeks ago Adobe announced to release new versions of the Flash player and Air simultaneously for the 3 major operating systems Linux, Mac and Windows. Today Adobe released AIR for Linux in Version 1.5 to catch up with the others. So in future Linux Users of AIR do not have to wait for [...]]]></description>
			<content:encoded><![CDATA[<p>A few weeks ago Adobe announced to release new versions of the Flash player and Air simultaneously for the 3 major operating systems Linux, Mac and Windows.</p>
<p>Today Adobe released AIR for Linux in Version 1.5 to catch up with the others. So in future Linux Users of AIR do not have to wait for new version. I think this is just another step of Adobe in the Linux world. I hope they will release also other Software simultaneously for Linux in future. For example Photoshop or other foto related programs of Adobe.</p>
<p><a href="http://fritzthomas.com/open-source/linux/351-adobe-releases-air-15-for-linux/"><img class="alignnone size-full wp-image-352" title="bildschirmfoto-adobe-adobe-air-mozilla-firefox" src="http://fritzthomas.com/wp-content/uploads/2008/12/bildschirmfoto-adobe-adobe-air-mozilla-firefox.png" alt="bildschirmfoto-adobe-adobe-air-mozilla-firefox" width="445" height="242" /></a></p>
<p><span id="more-351"></span></p>
<p><div style="width:100%;text-align:center;padding:0;margin:0;border:0;overflow:hidden;clear:both;"><script type="text/javascript"><!--
google_ad_client = "pub-1963733382421272";
google_ui_features = "rc:0";
google_ad_width = 234;
google_ad_height = 60;
google_ad_format = "234x60_as";
google_ad_type = "text_image";
google_alternate_ad_color = "ffffff";
google_color_border = "ffffff";
google_color_bg = "ffffff";
google_color_link = "319BD8";
google_color_text = "666666";
google_color_url = "319BD8";

//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div>
<p>
Install Adobe Air on Linux is really simple. Here some Screenshots of the steps:
</p>

<a href='http://fritzthomas.com/open-source/linux/351-adobe-releases-air-15-for-linux/attachment/bildschirmfoto-adobe-adobe-air-mozilla-firefox/' title='bildschirmfoto-adobe-adobe-air-mozilla-firefox'><img width="120" height="65" src="http://fritzthomas.com/wp-content/uploads/2008/12/bildschirmfoto-adobe-adobe-air-mozilla-firefox-120x65.png" class="attachment-thumbnail" alt="bildschirmfoto-adobe-adobe-air-mozilla-firefox" title="bildschirmfoto-adobe-adobe-air-mozilla-firefox" /></a>
<a href='http://fritzthomas.com/open-source/linux/351-adobe-releases-air-15-for-linux/attachment/screenshot41/' title='Make it executeable'><img width="120" height="67" src="http://fritzthomas.com/wp-content/uploads/2008/12/screenshot41-120x67.png" class="attachment-thumbnail" alt="Make it executeable" title="Make it executeable" /></a>
<a href='http://fritzthomas.com/open-source/linux/351-adobe-releases-air-15-for-linux/attachment/screenshot5-2/' title='Execute it'><img width="120" height="67" src="http://fritzthomas.com/wp-content/uploads/2008/12/screenshot5-120x67.png" class="attachment-thumbnail" alt="Execute it" title="Execute it" /></a>
<a href='http://fritzthomas.com/open-source/linux/351-adobe-releases-air-15-for-linux/attachment/screenshot6/' title='Follow the Clicks - Step1'><img width="120" height="100" src="http://fritzthomas.com/wp-content/uploads/2008/12/screenshot6-120x100.png" class="attachment-thumbnail" alt="Follow the Clicks - Step1" title="Follow the Clicks - Step1" /></a>
<a href='http://fritzthomas.com/open-source/linux/351-adobe-releases-air-15-for-linux/attachment/screenshot7-2/' title='Watching the progress'><img width="120" height="59" src="http://fritzthomas.com/wp-content/uploads/2008/12/screenshot7-120x59.png" class="attachment-thumbnail" alt="Watching the progress" title="Watching the progress" /></a>
<a href='http://fritzthomas.com/open-source/linux/351-adobe-releases-air-15-for-linux/attachment/screenshot8/' title='Adobe Air for Linux is installed'><img width="120" height="60" src="http://fritzthomas.com/wp-content/uploads/2008/12/screenshot8-120x60.png" class="attachment-thumbnail" alt="Adobe Air for Linux is installed" title="Adobe Air for Linux is installed" /></a>


	Tags: <a href="http://fritzthomas.com/tags/adobe/" title="Adobe" rel="tag">Adobe</a>, <a href="http://fritzthomas.com/tags/air/" title="Air" rel="tag">Air</a>, <a href="http://fritzthomas.com/tags/how-to/" title="how-to" rel="tag">how-to</a>, <a href="http://fritzthomas.com/tags/linux/" title="Linux" rel="tag">Linux</a>, <a href="http://fritzthomas.com/tags/release/" title="Release" rel="tag">Release</a><br />

	<h4>&Auml;hnliche Beitr&auml;ge:</h4>
	<ul class="st-related-posts">
	<li><a href="http://fritzthomas.com/open-source/linux/292-adobe-air-11-for-linux-beta-released/" title="Adobe AIR 1.1 for Linux Beta released (September 18, 2008)">Adobe AIR 1.1 for Linux Beta released</a> (0)</li>
	<li><a href="http://fritzthomas.com/overall/298-adobe-released-flash-player-10/" title="Adobe released Flash Player 10 (October 16, 2008)">Adobe released Flash Player 10</a> (0)</li>
	<li><a href="http://fritzthomas.com/open-source/linux/46-adobe-hat-erste-air-alpha-fur-linux-angekundigt/" title="Adobe hat erste Air Alpha für Linux angekündigt (March 31, 2008)">Adobe hat erste Air Alpha für Linux angekündigt</a> (0)</li>
</ul>

]]></content:encoded>
			<wfw:commentRss>http://fritzthomas.com/open-source/linux/351-adobe-releases-air-15-for-linux/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>No space left on device error with sshfs &#8211; how to fix it</title>
		<link>http://fritzthomas.com/open-source/linux/343-no-space-left-on-device-error-with-sshfs-how-to-fix-it/</link>
		<comments>http://fritzthomas.com/open-source/linux/343-no-space-left-on-device-error-with-sshfs-how-to-fix-it/#comments</comments>
		<pubDate>Thu, 27 Nov 2008 14:08:54 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[error]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[sshfs]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://fritzthomas.com/?p=343</guid>
		<description><![CDATA[After upgrading to Ubuntu 8.10 Intrepid you may get some error on sshfs mounted directories, when you tried to copy something on this places. This fix seems to be fixed in sshfs 2.1. If you need a fast fix on this install sshfs 2.1 manually from here: http://packages.ubuntu.com/jaunty/sshfs Select the right Architecture and download the [...]]]></description>
			<content:encoded><![CDATA[<p>After upgrading to Ubuntu 8.10 Intrepid you may get some error on sshfs mounted directories, when you tried to copy something on this places. This fix seems to be fixed in sshfs 2.1. If you need a fast fix on this install sshfs 2.1 manually from here: <a href="http://packages.ubuntu.com/jaunty/sshfs">http://packages.ubuntu.com/jaunty/sshfs</a></p>
<p>Select the right Architecture and download the .deb file from one of the locations on the next site. You can open the deb file directly with GDebi Package Manager.</p>
<p>Ignore warnings that an older version was found in your package manager.</p>

	Tags: <a href="http://fritzthomas.com/tags/error/" title="error" rel="tag">error</a>, <a href="http://fritzthomas.com/tags/how-to/" title="how-to" rel="tag">how-to</a>, <a href="http://fritzthomas.com/tags/sshfs/" title="sshfs" rel="tag">sshfs</a>, <a href="http://fritzthomas.com/tags/ubuntu/" title="ubuntu" rel="tag">ubuntu</a><br />

	<h4>&Auml;hnliche Beitr&auml;ge:</h4>
	<ul class="st-related-posts">
	<li><a href="http://fritzthomas.com/php/zend-framework/33-how-to-teil-1-projektaufbau-konventionen-und-modulare-verzeichnisstruktur/" title="Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur (January 28, 2008)">Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur</a> (13)</li>
	<li><a href="http://fritzthomas.com/open-source/linux/475-swiftfox-an-optimized-up-to-date-firefox-build/" title="Swiftfox &#8211; an optimized up-to-date firefox build (August 16, 2009)">Swiftfox &#8211; an optimized up-to-date firefox build</a> (0)</li>
	<li><a href="http://fritzthomas.com/open-source/linux/12-aendern-oder-setzen-eines-statischen-netzwerk-device-namen-unter-gentoo-eth0-eth1ethn/" title="Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;) (December 27, 2007)">Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;)</a> (0)</li>
</ul>

]]></content:encoded>
			<wfw:commentRss>http://fritzthomas.com/open-source/linux/343-no-space-left-on-device-error-with-sshfs-how-to-fix-it/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Rekursiv für bestimmte Dateien Dateioperation durchführen</title>
		<link>http://fritzthomas.com/open-source/linux/45-rekursiv-fur-bestimmte-dateien-dateioperation-durchfuhren/</link>
		<comments>http://fritzthomas.com/open-source/linux/45-rekursiv-fur-bestimmte-dateien-dateioperation-durchfuhren/#comments</comments>
		<pubDate>Fri, 21 Mar 2008 14:26:44 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[bash]]></category>
		<category><![CDATA[dos2unix]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[svn propset]]></category>

		<guid isPermaLink="false">http://fritzthomas.com/linux/45-rekursiv-fur-bestimmte-dateien-dateioperation-durchfuhren/</guid>
		<description><![CDATA[Ich hatte das Problem das ich über ein ganzes Projektverzeichnis bei bestimmten Dateien (.php, .phtml, .js, .css) ein svn propset ausführen wollte. Unter Windows und TortoiseSVN hat man zwar die Möglichkeit über ein ganzes Verzeichnis rekursiv ein Property zu setzen, jedoch nicht nach Dateiendungen zu entscheiden ob es gesetzt werden soll. Eine einfache und schnelle [...]]]></description>
			<content:encoded><![CDATA[<p>Ich hatte das Problem das ich über ein ganzes Projektverzeichnis bei bestimmten Dateien (.php, .phtml, .js, .css) ein svn propset ausführen wollte. Unter Windows und TortoiseSVN hat man zwar die Möglichkeit über ein ganzes Verzeichnis rekursiv ein Property zu setzen, jedoch nicht nach Dateiendungen zu entscheiden ob es gesetzt werden soll. Eine einfache und schnelle Möglichkeit ist dazu das Unix/Linux Tool &#8216;find&#8217;.</p>
<p><span id="more-45"></span></p>
<p>Nach Dateien suchen und dabei Dateien in einem .svn Verzeichnis nicht durchsuchen. Auf jedes gefundene File ein svn propset anwenden:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
</pre></td><td class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">find</span> \<span style="color: #000000; font-weight: bold;">!</span> <span style="color: #660033;">-wholename</span> \<span style="color: #000000; font-weight: bold;">*</span>.svn\<span style="color: #000000; font-weight: bold;">*</span> <span style="color: #660033;">-type</span> f  \<span style="color: #7a0874; font-weight: bold;">&#40;</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.php <span style="color: #660033;">-o</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.phtml <span style="color: #660033;">-o</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.css <span style="color: #660033;">-o</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.js <span style="color: #660033;">-o</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.ini \<span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #660033;">-exec</span> <span style="color: #c20cb9; font-weight: bold;">svn</span> propset <span style="color: #c20cb9; font-weight: bold;">svn</span>:keywords <span style="color: #ff0000;">'Date Revision Author HeadURL Id'</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span><span style="color: #7a0874; font-weight: bold;">&#125;</span> \;</pre></td></tr></table></div>

<p><div style="width:100%;text-align:center;padding:0;margin:0;border:0;overflow:hidden;clear:both;"><script type="text/javascript"><!--
google_ad_client = "pub-1963733382421272";
google_ui_features = "rc:0";
google_ad_width = 234;
google_ad_height = 60;
google_ad_format = "234x60_as";
google_ad_type = "text_image";
google_alternate_ad_color = "ffffff";
google_color_border = "ffffff";
google_color_bg = "ffffff";
google_color_link = "319BD8";
google_color_text = "666666";
google_color_url = "319BD8";

//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div>
<p>Das ganze kann natuerlich auch fuer andere Dateioperationen angewandt werden wir zum Beispiel dos2unix:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
</pre></td><td class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">find</span> \<span style="color: #000000; font-weight: bold;">!</span> <span style="color: #660033;">-wholename</span> \<span style="color: #000000; font-weight: bold;">*</span>.svn\<span style="color: #000000; font-weight: bold;">*</span> <span style="color: #660033;">-type</span> f  \<span style="color: #7a0874; font-weight: bold;">&#40;</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.php <span style="color: #660033;">-o</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.phtml <span style="color: #660033;">-o</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.css <span style="color: #660033;">-o</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.js <span style="color: #660033;">-o</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.html <span style="color: #660033;">-o</span> <span style="color: #660033;">-name</span> \<span style="color: #000000; font-weight: bold;">*</span>.ini \<span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #660033;">-exec</span> dos2unix <span style="color: #7a0874; font-weight: bold;">&#123;</span><span style="color: #7a0874; font-weight: bold;">&#125;</span> \;</pre></td></tr></table></div>

<p>Bei den Beispielen werden alle &#8216;.svn&#8217; Verzeichnisse nicht durchsucht: \! -wholename \*.svn\*<br />
Es wird nur nach Dateien gesucht: -type f<br />
Und nur nach Dateien mit der Endung .php .phtml .css .js .html .ini : \( -name \*.php -o -name \*.phtml -o -name \*.css -o -name \*.js -o -name \*.html -o -name \*.ini \)</p>

	Tags: <a href="http://fritzthomas.com/tags/bash/" title="bash" rel="tag">bash</a>, <a href="http://fritzthomas.com/tags/dos2unix/" title="dos2unix" rel="tag">dos2unix</a>, <a href="http://fritzthomas.com/tags/how-to/" title="how-to" rel="tag">how-to</a>, <a href="http://fritzthomas.com/tags/svn-propset/" title="svn propset" rel="tag">svn propset</a><br />

	<h4>&Auml;hnliche Beitr&auml;ge:</h4>
	<ul class="st-related-posts">
	<li><a href="http://fritzthomas.com/open-source/linux/12-aendern-oder-setzen-eines-statischen-netzwerk-device-namen-unter-gentoo-eth0-eth1ethn/" title="Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;) (December 27, 2007)">Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;)</a> (0)</li>
	<li><a href="http://fritzthomas.com/php/zend-framework/33-how-to-teil-1-projektaufbau-konventionen-und-modulare-verzeichnisstruktur/" title="Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur (January 28, 2008)">Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur</a> (13)</li>
	<li><a href="http://fritzthomas.com/gentoo-php-web-development-vmware-appliance/" title="Web Dev Appliance (January 13, 2008)">Web Dev Appliance</a> (16)</li>
</ul>

]]></content:encoded>
			<wfw:commentRss>http://fritzthomas.com/open-source/linux/45-rekursiv-fur-bestimmte-dateien-dateioperation-durchfuhren/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>How-To: Alle oder bestimmte Tabellen einer Datenbank löschen</title>
		<link>http://fritzthomas.com/overall/35-how-to-alle-tabellen-einer-datenbank-loeschen/</link>
		<comments>http://fritzthomas.com/overall/35-how-to-alle-tabellen-einer-datenbank-loeschen/#comments</comments>
		<pubDate>Sat, 09 Feb 2008 10:39:00 +0000</pubDate>
		<dc:creator>Thomas</dc:creator>
				<category><![CDATA[Overall]]></category>
		<category><![CDATA[Datenbank]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[Tutorial]]></category>

		<guid isPermaLink="false">http://fritzthomas.com/allgemein/35-how-to-alle-tabellen-einer-datenbank-lschen/</guid>
		<description><![CDATA[Alle Tabellen l&#246;schen Will man alle Tabellen einer Datenbank l&#246;schen so gibt es daf&#252;r keine native SQL Anweisung wie TRUNCATE DATABASE oder so. Man kann sich mit einem one-liner behelfen: 1 mysqldump -u&#91;USERNAME&#93; -p&#91;PASSWORD&#93; --add-drop-table --no-data &#91;DATABASE&#93; &#124; grep ^DROP &#124; mysql -u&#91;USERNAME&#93; -p&#91;PASSWORD&#93; &#91;DATABASE&#93; Mittels mysqldump wird die Datenbank ohne Daten und mit der [...]]]></description>
			<content:encoded><![CDATA[<h2>Alle Tabellen l&ouml;schen</h2>
<p>Will man alle Tabellen einer Datenbank l&ouml;schen so gibt es daf&uuml;r keine native SQL Anweisung wie TRUNCATE DATABASE oder so. Man kann sich mit einem one-liner behelfen:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
</pre></td><td class="code"><pre class="bash" style="font-family:monospace;">mysqldump -u<span style="color: #7a0874; font-weight: bold;">&#91;</span>USERNAME<span style="color: #7a0874; font-weight: bold;">&#93;</span> -p<span style="color: #7a0874; font-weight: bold;">&#91;</span>PASSWORD<span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #660033;">--add-drop-table</span> <span style="color: #660033;">--no-data</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span>DATABASE<span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> ^DROP <span style="color: #000000; font-weight: bold;">|</span> mysql -u<span style="color: #7a0874; font-weight: bold;">&#91;</span>USERNAME<span style="color: #7a0874; font-weight: bold;">&#93;</span> -p<span style="color: #7a0874; font-weight: bold;">&#91;</span>PASSWORD<span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span>DATABASE<span style="color: #7a0874; font-weight: bold;">&#93;</span></pre></td></tr></table></div>

<p><div style="width:100%;text-align:center;padding:0;margin:0;border:0;overflow:hidden;clear:both;"><script type="text/javascript"><!--
google_ad_client = "pub-1963733382421272";
google_ui_features = "rc:0";
google_ad_width = 234;
google_ad_height = 60;
google_ad_format = "234x60_as";
google_ad_type = "text_image";
google_alternate_ad_color = "ffffff";
google_color_border = "ffffff";
google_color_bg = "ffffff";
google_color_link = "319BD8";
google_color_text = "666666";
google_color_url = "319BD8";

//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div>
<p>
Mittels mysqldump wird die Datenbank ohne Daten und mit der Option &#8216;&#8211;add-drop-table&#8217; gedumped. Mit grep werden dann nur diese Anweisungen wieder an den mysql Client weitergeleitet der dann wiederum die alle Tabellen aus der Datenbank dropt.
</p>
<h2>Nur bestimmte Tabellen einer Datenbank l&ouml;schen</h2>
<p><div style="float:left;margin-left:0,margin-right:4px;margin-top:4px;margin-bottom:0;padding:4px;border:0;"><script type="text/javascript"><!--
google_ad_client = "pub-1963733382421272";
google_ad_slot = "3802836967";
google_ad_width = 120;
google_ad_height = 240;
//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div>
<p>
Oft hat man auch das Problem das man nur bestimmte Tabellen aus einer Datenbank l&ouml;schen m&ouml;chte. Zum Beispiel wenn man mehrere Applikationen installiert und eine davon jetzt l&ouml;schen m&ouml;chte. Wichtig ist das die Tabellen der Applikation einen Tabellen Prefix haben. Bei WordPress w&auml;re das zum Beispiel &#8216;wp_&#8217; als Prefix. Um nur diese aus der Datenbank zu l&ouml;schen muss die obere Anweisung nur mit einem weiteren grep erweitert werden:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
</pre></td><td class="code"><pre class="bash" style="font-family:monospace;">mysqldump -u<span style="color: #7a0874; font-weight: bold;">&#91;</span>USERNAME<span style="color: #7a0874; font-weight: bold;">&#93;</span> -p<span style="color: #7a0874; font-weight: bold;">&#91;</span>PASSWORD<span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #660033;">--add-drop-table</span> <span style="color: #660033;">--no-data</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span>DATABASE<span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> ^DROP <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> <span style="color: #ff0000;">'wp_.*'</span> <span style="color: #000000; font-weight: bold;">|</span> mysql -u<span style="color: #7a0874; font-weight: bold;">&#91;</span>USERNAME<span style="color: #7a0874; font-weight: bold;">&#93;</span> -p<span style="color: #7a0874; font-weight: bold;">&#91;</span>PASSWORD<span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span>DATABASE<span style="color: #7a0874; font-weight: bold;">&#93;</span></pre></td></tr></table></div>

<p>Es empfiehlt sich das Ergebnis zuerst mal zu kontrollieren und sich die Drop Statements nur ausgeben zu lassen &#8211; also den letzten Teil (mysql -u[USERNAME]&#8230;..) einfach weglassen.</p>

	Tags: <a href="http://fritzthomas.com/tags/datenbank/" title="Datenbank" rel="tag">Datenbank</a>, <a href="http://fritzthomas.com/tags/how-to/" title="how-to" rel="tag">how-to</a>, <a href="http://fritzthomas.com/tags/mysql/" title="MySQL" rel="tag">MySQL</a>, <a href="http://fritzthomas.com/tags/tutorial/" title="Tutorial" rel="tag">Tutorial</a><br />

	<h4>&Auml;hnliche Beitr&auml;ge:</h4>
	<ul class="st-related-posts">
	<li><a href="http://fritzthomas.com/php/zend-framework/33-how-to-teil-1-projektaufbau-konventionen-und-modulare-verzeichnisstruktur/" title="Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur (January 28, 2008)">Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur</a> (13)</li>
	<li><a href="http://fritzthomas.com/gentoo-php-web-development-vmware-appliance/" title="Web Dev Appliance (January 13, 2008)">Web Dev Appliance</a> (16)</li>
	<li><a href="http://fritzthomas.com/open-source/13-was-google-so-erfolgreich-macht/" title="Was Google so erfolgreich macht. (January 1, 2008)">Was Google so erfolgreich macht.</a> (0)</li>
</ul>

]]></content:encoded>
			<wfw:commentRss>http://fritzthomas.com/overall/35-how-to-alle-tabellen-einer-datenbank-loeschen/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur</title>
		<link>http://fritzthomas.com/php/zend-framework/33-how-to-teil-1-projektaufbau-konventionen-und-modulare-verzeichnisstruktur/</link>
		<comments>http://fritzthomas.com/php/zend-framework/33-how-to-teil-1-projektaufbau-konventionen-und-modulare-verzeichnisstruktur/#comments</comments>
		<pubDate>Mon, 28 Jan 2008 14:57:07 +0000</pubDate>
		<dc:creator>Thomas</dc:creator>
				<category><![CDATA[Zend Framework]]></category>
		<category><![CDATA[application library]]></category>
		<category><![CDATA[application modules]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Programmierpraktiken]]></category>
		<category><![CDATA[Tutorial]]></category>
		<category><![CDATA[use case]]></category>
		<category><![CDATA[Verzeichnisstruktur]]></category>
		<category><![CDATA[Zend Framework Tutorial 1]]></category>

		<guid isPermaLink="false">http://fritzthomas.com/zend-framework/33-how-to-teil-1-projektaufbau-konventionen-und-modulare-verzeichnisstruktur/</guid>
		<description><![CDATA[Das ist der erste Teil meiner Tutorial oder How-To Serie für das Zend Framework. Dieser erste Artikel wird etwas früher als mit der Implementierung des bootstrapping Prozesses oder dem Erstellen neuer Controller, Models oder Views beginnen. Ich werde hier als erstes grundlegende Gedanken und Überlegungen in den Raum stellen, die man sich vor der Implementierung [...]]]></description>
			<content:encoded><![CDATA[<p>Das ist der erste Teil meiner Tutorial oder How-To Serie für das Zend Framework.<br />
Dieser erste Artikel wird etwas früher als mit der Implementierung des bootstrapping Prozesses oder dem Erstellen neuer Controller, Models oder Views beginnen. Ich werde hier als erstes grundlegende Gedanken und Überlegungen in den Raum stellen, die man sich vor der Implementierung stellen sollte &#8211;  wie zum Beispiel die Wahl der richtigen Verzeichnisstruktur und die Ausarbeitung eigener Konventionen.</p>
<h2>Wozu die ganze Theorie?</h2>
<p>Die Wahl der Verzeichnisstruktur oder das überlegen und / oder aufschreiben eigener Konventionen mag im ersten Moment vielleicht etwas nebensächlich erscheinen und auch so behandelt werden, doch will man eine Applikation von vorn herein so modular wie möglich aufbauen um später nicht mehr Arbeit zu haben um neue Features (Module, Plugins, Controller, I18N, Caching, Suche, etc..) zu implementieren sollte man sich etwas mehr Zeit nehmen um über die jetzigen und auch die zukünftigen Anforderungen an die Applikation, nachzudenken. Die Wichtigkeit dessen steigt, um so mehr Entwickler an einem Projekt beteiligt sind, da darauf um so mehr zu achten ist, dass jeder Entwickler weiß welche <a href="http://de.wikipedia.org/wiki/Code_Convention">Code Conventions</a> einzuhalten sind, und vor allem <strong>WIE</strong> (und nicht ob!!!) dokumentiert werden muss.</p>
<p><span id="more-33"></span></p>
<h2>Analyse der Anforderungen</h2>
<p>Jeder Entwickler, der das eine oder andere größere Projekt fertig gestellt hat, weiß das genaue ausgedehnte Analysen zu Beginn der Entwicklung nicht verschwendete Zeit ist. Vorausgesetzt man nutzte die Zeit auch wirklich produktiv! <img src='http://fritzthomas.com/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </p>
<p>Als erstes sollte man darüber nachdenken welche Anforderungen an das Projekt gestellt werden:</p>
<ul>
<li> Soll das Projekt über eine Suche verfügen?</li>
<li>Soll sie Mehrsprachige Texte zur Verfügung stellen (Stichwort &#8211; Internationalisation oder I18N)?</li>
<li>Wenn es eine im Internet öffentlich zugängliche Seite ist, wieviele Hits werden erwartet (Stichwort: Caching)?</li>
<li>Welche Features sind für die Zukunft geplant?</li>
<li>Wer und wieviele Entwickler werden an dem Projekt arbeiten?</li>
<li>Wie soll daher der Sourcecode verwaltet werden?</li>
</ul>
<p>Keine Sorge, ich werde nicht auf jede einzelne Frage eingehen. Sie sollten eher als Gedankenanstoß gedacht sein. Es macht aber durchaus Sinn sich zu Beginn solche Fragen zu stellen und im Team zu besprechen und dazu alle Ideen, Bedenken und Vorschläge aufzuschreiben. Einige im Team sind optimistisch, andere wieder pessimistisch &#8211; genau die Mischung finde ich kann sich sehr positiv auf ein Projekt auswirken. Was das Brainstorming in einem Team betrifft habe ich <a href="http://www.theopenforce.com/2006/08/brainstorm.html">die</a> <a href="http://www.theopenforce.com/2006/08/more_brainstorm.html">Ratschläge</a> von <a href="http://theopenforce.com">Zack Urlocker</a> sehr nützlich gefunden.</p>
<h2>Programmierpraktiken und Konventionen</h2>
<p>Aufgrund der gewonnen Erkenntnisse die man aus den Überlegungen zu Beginn und aus vorigen Projekten erlangt hat sollte man, auch wenn man alleine entwickelt, sich einerseits über <a href="http://framework.zend.com/manual/en/coding-standard.html">vorhandene</a> Konventionen informieren und andererseits sich eigene Programmierpraktiken (Best Practices) und Konventionen aneignen.</p>
<p>Dabei sollte man sich die in der Praxis als gut bewährten stets behalten und an denen, die sich als schlecht herausgestellt haben, arbeiten und verbessern. Das klingt schon wieder so theoretisch, aber ich denke Ihr wisst was ich meine.</p>
<p>Natürlich sollte man das ganze nicht übertreiben und jedes einzelne Detail bestimmen und festlegen. Vor allem in einem Team von Entwicklern muss es auch gestattet sein Ausnahmen von den Konventionen zu machen sofern sie die Lesbarkeit und Wartbarkeit des Codes nicht verschlechtern.</p>
<p>Eine konkrete &#8216;Konvention&#8217; wäre zum Beispiel das man die Konfiguration für eine Komponente (Action_Helper, View_Helper, etc&#8230;) immer mit dem Klassennamen als Key in der Zend_Config oder in der Zend_Registry speichert oder aber auch das man jedes Modul als geschlossene Einheit betrachtet und es auch so entwickelt das man sie in anderen Applikationen wieder verwenden kann.</p>
<p>Ein andere Konvention an die man sich in seinen Projekten durchgehend halten sollte wäre die Verzeichnisstruktur.</p>
<h2>Verzeichnisstruktur</h2>
<p>Die Verzeichnisstruktur macht es unter anderem (&#8220;Programmierpraktiken und Konventionen&#8221;) leichter vorhandene Module in weiteren Projekten mit wenig oder gar keinem Aufwand wieder zu verwenden. Und das sollte doch das Ziel eines jeden Entwicklers sein, oder wer erfindet schon gerne das Rad immer wieder neu? <img src='http://fritzthomas.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>Eine solche modulare Verzeichnisstruktur könnte so aussehen:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">application<span style="color: #000000; font-weight: bold;">/</span>
htdocs<span style="color: #000000; font-weight: bold;">/</span>
library<span style="color: #000000; font-weight: bold;">/</span></pre></div></div>

<p>Der Document_Root des WebServers ist hier &#8216;htdocs/&#8217;. Das Zend Framework und evtl. andere Librarys sind im Verzeichnis &#8216;library/&#8217; zu finden. Der include_path sollte auch entsprechend für dieses Verzeichnis gesetzt sein und muss nicht zwingend im selben Verzeichnis wie htdocs und application sein. Die eigentlichen Dateien und Verzeichnisse der Applikation liegen in &#8216;application/&#8217;. Das erleichtert es auch den Sourcecode zu verwalten und später das Aktualisieren der fertigen Applikation.</p>
<p>Der Inhalt des <strong>&#8216;application/&#8217;</strong> Verzeichnisses:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">bootstrap.php
config<span style="color: #000000; font-weight: bold;">/</span>
layouts<span style="color: #000000; font-weight: bold;">/</span>
library<span style="color: #000000; font-weight: bold;">/</span>
log<span style="color: #000000; font-weight: bold;">/</span>
modules<span style="color: #000000; font-weight: bold;">/</span>
temp<span style="color: #000000; font-weight: bold;">/</span></pre></div></div>

<h3>bootstrap.php</h3>
<p>In der bootstrap.php findet das eigentliche Initialisieren der Applikation statt. In der index.php im &#8216;htdocs/&#8217; Verzeichnis wird &#8216;bootstrap.php&#8217; lediglich &#8216;required&#8217;:</p>
<p><strong>htdocs/index.php:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> ?php
<span style="color: #b1b100;">require</span> <span style="color: #0000ff;">'../application/bootstrap.php'</span><span style="color: #339933;">;</span></pre></div></div>

<p>wie schon erwähnt, in der bootstrap.php findet das eigentlich bootstrapping statt:</p>
<p><strong>application/bootstrap.php:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> ?php
<span style="color: #000088;">$applicationPath</span> <span style="color: #339933;">=</span> <span style="color: #990000;">dirname</span><span style="color: #009900;">&#40;</span><span style="color: #009900; font-weight: bold;">__FILE__</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #990000;">define</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'APPLICATION_PATH'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$applicationPath</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #990000;">unset</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$applicationPath</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #b1b100;">require_once</span> <span style="color: #0000ff;">'Zend/Loader.php'</span><span style="color: #339933;">;</span>
Zend_Loader<span style="color: #339933;">::</span><span style="color: #004000;">registerAutoload</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000088;">$front</span> <span style="color: #339933;">=</span> Zend_Controller_Front<span style="color: #339933;">::</span><span style="color: #004000;">getInstance</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$front</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span>addModuleDirectory<span style="color: #009900;">&#40;</span>APPLICATION_PATH <span style="color: #339933;">.</span> <span style="color: #009900; font-weight: bold;">DIRECTORY_SEPARATOR</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'modules'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$front</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span>dispatch<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>In Zeile 3 wird eine Konstante mit dem absolute Pfad des application Verzeihnisses angelegt. Das ermöglicht es anderen Komponenten oder Modulen im Kontext des application Verzeichnisses zu arbeiten. Zum Beispiel Log Dateien schreiben, Ausgaben cachen, oder aber auch in einem Modul Unterverzeichnis Dateien auszulesen. Um zum Beispiel im Modul &#8216;Filesystem&#8217; ein Unterverzeichnis &#8216;files/&#8217; auszulesen:</p>
<p>Da in der index.php nur eine einzige Zeile PHP Code, im einzigen nach aussen offenen Verzeichnis &#8216;htdocs/&#8217;, zu finden ist, wird ausserdem bei einem nicht richtig funktionierenden Webserver, der den Inhalt von php Dateien ausgibt anstatt den Code auszuführen, verhindert das viele Informationen preisgegeben werden.</p>
<p><strong>modules/filesystem/controllers/IndexController.php:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> ?php
<span style="color: #b1b100;">require_once</span> <span style="color: #0000ff;">'Zend/Controller/Action.php'</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">class</span> Filesystem_IndexController <span style="color: #000000; font-weight: bold;">extends</span> Zend_Controller_Action
<span style="color: #009900;">&#123;</span>
&nbsp;
    <span style="color: #009933; font-style: italic;">/**
     * The default action - show the home page
     */</span>
    <span style="color: #000000; font-weight: bold;">public</span> <span style="color: #000000; font-weight: bold;">function</span> indexAction <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
    <span style="color: #009900;">&#123;</span>
        <span style="color: #000088;">$directory</span> <span style="color: #339933;">=</span> APPLICATION_PATH <span style="color: #339933;">.</span> <span style="color: #009900; font-weight: bold;">DIRECTORY_SEPARATOR</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'modules'</span> <span style="color: #339933;">.</span> <span style="color: #009900; font-weight: bold;">DIRECTORY_SEPARATOR</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'filesystem'</span> <span style="color: #339933;">.</span> <span style="color: #009900; font-weight: bold;">DIRECTORY_SEPARATOR</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'files'</span><span style="color: #339933;">;</span>
        <span style="color: #000088;">$res</span> <span style="color: #339933;">=</span> <span style="color: #990000;">opendir</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$directory</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #000088;">$contents</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array</span><span style="color: #009900;">&#40;</span>
        <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #009900; font-weight: bold;">false</span> <span style="color: #339933;">!==</span> <span style="color: #000088;">$res</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
            <span style="color: #b1b100;">while</span> <span style="color: #009900;">&#40;</span><span style="color: #009900; font-weight: bold;">false</span> <span style="color: #339933;">!==</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$content</span> <span style="color: #339933;">=</span> <span style="color: #990000;">readdir</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$res</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$content</span> <span style="color: #339933;">!==</span> <span style="color: #0000ff;">'.'</span> <span style="color: #339933;">&amp;</span>amp<span style="color: #339933;">;&amp;</span>amp<span style="color: #339933;">;</span> <span style="color: #000088;">$content</span> <span style="color: #339933;">!==</span> <span style="color: #0000ff;">'..'</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
                    <span style="color: #000088;">$contents</span><span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$content</span><span style="color: #339933;">;</span>
                <span style="color: #009900;">&#125;</span>
            <span style="color: #009900;">&#125;</span>
        <span style="color: #009900;">&#125;</span>
        <span style="color: #000088;">$this</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span>view<span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span>contents <span style="color: #339933;">=</span> <span style="color: #000088;">$contents</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>So ist es möglich alle zu einem Modul gehörenden Files im Modul Verzeichnis zu verwalten. Installiert man dieses Modul in einer Applikation müssen so keine Anpassungen vorgenommen werden oder irgendwelche Pfade und Variablen zu den Pfaden angepasst werden.</p>
<h3>config/</h3>
<p>Wie der Name schon vermuten lässt werden hier globale Konfigurationen die in der gesamten Applikation gültig sind gespeichert. Egal ob es sich dabei um eine ini Datei handelt oder um eine xml Datei.</p>
<h3>&#8216;application/library/&#8217;</h3>
<p>Das &#8216;application/library/&#8217; Verzeichnis kann dazu verwendet werden vorhandene Klassen im globalen &#8216;library/&#8217; Verzeichnis zu überladen. Das ermöglicht es auf Servern wo mehrere unterschiedliche ZF Applikationen gehostet sind und gemeinsam eine Library nutzen, einzelne Klassen des Zend Frameworks oder der eigenen Library zu überladen. Dazu sollte mittels set_include_path() in der bootstrap.php der Pfad an die erste Stelle gesetzt werden:<br />
<strong>bootstrap.php:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #339933;">&amp;</span>lt<span style="color: #339933;">;</span> ?php
<span style="color: #000088;">$applicationPath</span> <span style="color: #339933;">=</span> <span style="color: #990000;">dirname</span><span style="color: #009900;">&#40;</span><span style="color: #009900; font-weight: bold;">__FILE__</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #990000;">define</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'APPLICATION_PATH'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$applicationPath</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #990000;">unset</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$applicationPath</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #b1b100;">require_once</span> <span style="color: #0000ff;">'Zend/Loader.php'</span><span style="color: #339933;">;</span>
Zend_Loader<span style="color: #339933;">::</span><span style="color: #004000;">registerAutoload</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000088;">$oldIncludePath</span> <span style="color: #339933;">=</span> <span style="color: #990000;">get_include_path</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$localLibraryDir</span> <span style="color: #339933;">=</span> APPLICATION_PATH <span style="color: #339933;">.</span> <span style="color: #009900; font-weight: bold;">DIRECTORY_SEPARATOR</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'library'</span><span style="color: #339933;">;</span>
<span style="color: #990000;">set_include_path</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$localLibraryDir</span> <span style="color: #339933;">.</span> PATH_SEPARATOR <span style="color: #339933;">.</span> <span style="color: #000088;">$oldIncludePath</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000088;">$front</span> <span style="color: #339933;">=</span> Zend_Controller_Front<span style="color: #339933;">::</span><span style="color: #004000;">getInstance</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$front</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span>addModuleDirectory<span style="color: #009900;">&#40;</span>APPLICATION_PATH <span style="color: #339933;">.</span> <span style="color: #009900; font-weight: bold;">DIRECTORY_SEPARATOR</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'modules'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$front</span><span style="color: #339933;">-&amp;</span>gt<span style="color: #339933;">;</span>dispatch<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<h3>log/</h3>
<p>Log Dateien der Applikation. Modul Log Files sollten ebenfalls in diesem Verzeichnis gespeichert werden. Hier sollten nicht die Apache Log Files geloggt werden.</p>
<h3>modules/</h3>
<p>Alle Zend Framework Module werden hier drin gespeichert.<br />
Ein einzelnes Modul sollte nach diesem Muster aufgebaut sein:</p>
<p><strong>Modulverzeichnisstruktur:</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">default<span style="color: #000000; font-weight: bold;">/</span>
    config<span style="color: #000000; font-weight: bold;">/</span>
    controllers<span style="color: #000000; font-weight: bold;">/</span>
    models<span style="color: #000000; font-weight: bold;">/</span>
    views<span style="color: #000000; font-weight: bold;">/</span>
       helpers<span style="color: #000000; font-weight: bold;">/</span>
       filters<span style="color: #000000; font-weight: bold;">/</span>
       scripts<span style="color: #000000; font-weight: bold;">/</span>
       layouts<span style="color: #000000; font-weight: bold;">/</span></pre></div></div>

<p>Die Bedeutung der einzelnen Verzeichnisse sollte soweit klar sein.</p>
<h3>temp/</h3>
<p>In diesem Verzeichnis sollten alle temporären Dateien, wie zum Beispiel caching files fuer Zend_Cache, oder auch das &#8216;templates_c&#8217; Verzeichnis von Smarty, gespeichert werden. PHP Sessions sollten sollten nicht hier gespeichert werden, weil es das Auslesen vorhandener Sessions erleichtern würde, in dem Fall das die Applikation durch einen Fehler es ermöglicht fremden Code auszuf¨hren.</p>
<hr />Im nächsten Teil meines <a href="http://fritzthomas.com/tags/zend-framework-tutorial-1/">Zend Framework Tutorial</a> werde ich anhand einer Beispiel Applikation die Verwendung von <a href="http://fritzthomas.com/tags/zend-framework-tutorial-1/">Zend_Layout</a> und den neuen Zend_View_Helpern Placeholder, Partial und Action erklären.</p>
<hr />Welche Verzeichnisstruktur verwendet Ihr? Was haben Eure Erfahrungen gezeigt? Ich denke es würde allen Lesern interessieren.</p>

	Tags: <a href="http://fritzthomas.com/tags/application-library/" title="application library" rel="tag">application library</a>, <a href="http://fritzthomas.com/tags/application-modules/" title="application modules" rel="tag">application modules</a>, <a href="http://fritzthomas.com/tags/how-to/" title="how-to" rel="tag">how-to</a>, <a href="http://fritzthomas.com/tags/php/" title="PHP" rel="tag">PHP</a>, <a href="http://fritzthomas.com/tags/programmierpraktiken/" title="Programmierpraktiken" rel="tag">Programmierpraktiken</a>, <a href="http://fritzthomas.com/tags/tutorial/" title="Tutorial" rel="tag">Tutorial</a>, <a href="http://fritzthomas.com/tags/use-case/" title="use case" rel="tag">use case</a>, <a href="http://fritzthomas.com/tags/verzeichnisstruktur/" title="Verzeichnisstruktur" rel="tag">Verzeichnisstruktur</a>, <a href="http://fritzthomas.com/tags/zend-framework/" title="Zend Framework" rel="tag">Zend Framework</a>, <a href="http://fritzthomas.com/tags/zend-framework-tutorial-1/" title="Zend Framework Tutorial 1" rel="tag">Zend Framework Tutorial 1</a><br />

	<h4>&Auml;hnliche Beitr&auml;ge:</h4>
	<ul class="st-related-posts">
	<li><a href="http://fritzthomas.com/php/10-zend_layout-zend_view_enhanced/" title="Zend_Layout, Zend_View_Enhanced (December 16, 2007)">Zend_Layout, Zend_View_Enhanced</a> (0)</li>
	<li><a href="http://fritzthomas.com/overall/29-zend-studio-6-0-0-eclipse-released/" title="Zend Studio 6.0.0 Eclipse Released (January 23, 2008)">Zend Studio 6.0.0 Eclipse Released</a> (1)</li>
	<li><a href="http://fritzthomas.com/php/24-zend-framework-web-developer-appliance/" title="Zend Framework Web Developer Appliance (January 15, 2008)">Zend Framework Web Developer Appliance</a> (1)</li>
</ul>

]]></content:encoded>
			<wfw:commentRss>http://fritzthomas.com/php/zend-framework/33-how-to-teil-1-projektaufbau-konventionen-und-modulare-verzeichnisstruktur/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>7zip unter Gentoo Linux verwenden</title>
		<link>http://fritzthomas.com/open-source/linux/22-7zip-unter-gentoo-linux-verwenden/</link>
		<comments>http://fritzthomas.com/open-source/linux/22-7zip-unter-gentoo-linux-verwenden/#comments</comments>
		<pubDate>Fri, 11 Jan 2008 10:27:44 +0000</pubDate>
		<dc:creator>Thomas</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Open-Source]]></category>
		<category><![CDATA[7zip]]></category>
		<category><![CDATA[gentoo]]></category>
		<category><![CDATA[how-to]]></category>

		<guid isPermaLink="false">http://fritzthomas.com/allgemein/22-7zip-unter-gentoo-linux-verwenden/</guid>
		<description><![CDATA[Das 7zip Kompressionsformat wird nicht &#8220;Out-Of-The-Box&#8221; unterst&#252;tzt. Das Programm kann einfach mit thomas@gentoo ~ $ emerge -av p7zip installiert werden. Einfaches schnelles Komprimieren Eine Datei oder ein ganzen Verzeichnis mit den Standard Optionen zu komprimieren ist ganz einfach. Nehmen wir an, wir wollen ein ganzes Verzeichnis komprimieren. thomas@gentoo ~ $ 7za a test.7z test-verzeichnis/ Starkes [...]]]></description>
			<content:encoded><![CDATA[<p>Das 7zip Kompressionsformat wird nicht &#8220;Out-Of-The-Box&#8221; unterst&uuml;tzt. Das Programm kann einfach mit</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">thomas<span style="color: #000000; font-weight: bold;">@</span>gentoo ~ $ emerge <span style="color: #660033;">-av</span> p7zip</pre></div></div>

<p>installiert werden.</p>
<h3>Einfaches schnelles Komprimieren</h3>
<p>Eine Datei oder ein ganzen Verzeichnis mit den Standard Optionen zu komprimieren ist ganz einfach. Nehmen wir an, wir wollen ein ganzes Verzeichnis komprimieren.</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">thomas<span style="color: #000000; font-weight: bold;">@</span>gentoo ~ $ 7za a test.7z test-verzeichnis<span style="color: #000000; font-weight: bold;">/</span></pre></div></div>

<h3>Starkes Komprimieren mit den &#8220;Ultra&#8221; Optionen</h3>
<p>Um eine Datei oder ein ganzes Verzeichnis st&auml;rker zu komprimieren sind einige Optionen n&ouml;tig. An den einzelenen Optionen kann nat&uuml;rlich noch &#8220;getuned&#8221; werden, aber man sollte daran denken, dass sich die Zeit zum komprimieren und entpacken des Archives erh&ouml;ht umso st&auml;rker komprimiert wird. Ausserdem wird, bei st&auml;rker Komprimierung, auch der Speicherverbrauch beim Entpacken gr&ouml;&szlig;er.</p>
<p><span id="more-22"></span><br />
<div style="width:100%;text-align:center;padding:0;margin:0;border:0;overflow:hidden;clear:both;"><script type="text/javascript"><!--
google_ad_client = "pub-1963733382421272";
google_ui_features = "rc:0";
google_ad_width = 234;
google_ad_height = 60;
google_ad_format = "234x60_as";
google_ad_type = "text_image";
google_alternate_ad_color = "ffffff";
google_color_border = "ffffff";
google_color_bg = "ffffff";
google_color_link = "319BD8";
google_color_text = "666666";
google_color_url = "319BD8";

//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div><br />
Bei der schnellsten Kompressionsst&uuml;rke sind laut 7zip lediglich 3MB beim komprimieren und 3MB beim Entpacken n&ouml;tig, mit den &#8220;Ultra&#8221; Optionen sind zur Komprimierung ca. 709Mb n&uuml;tig und beim Entpacken ca. 66Mb.</p>
<p>Diese &#8220;Ultra&#8221; Kompressionsst&auml;rke setzt sich aus folgenden Kommandozeilen Paramteren zusammen:</p>
<ul>
<li>Archivtyp: -t7z</li>
<li>Kompressionsverfahren: -m0=lzma</li>
<li>Kompressionsst&auml;rke: -mx=9</li>
<li>Wortgr&ouml;&szlig;e (Fast Bytes): -mfb=64</li>
<li>W&ouml;rterbuchgr&ouml;&szlig;e: -md=32m</li>
<li>Solides Archiv: -ms=on</li>
</ul>
<p>Auf der Kommandozeile w&uuml;rde das dann so aussehen:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">thomas<span style="color: #000000; font-weight: bold;">@</span>gentoo ~ $ 7za a <span style="color: #660033;">-t7z</span> <span style="color: #660033;">-m0</span>=lzma <span style="color: #660033;">-mx</span>=<span style="color: #000000;">9</span> <span style="color: #660033;">-mfb</span>=<span style="color: #000000;">64</span> <span style="color: #660033;">-ms</span>=on <span style="color: #660033;">-md</span>=32m test.7z test-verzeichnis<span style="color: #000000; font-weight: bold;">/</span></pre></div></div>

<p>Wie schon erw&aumlhnt;, mit den einzelenen Optionen kann man sich noch spielen um eine ideale Kompressionsrate zu erzielen.</p>
<p>Mit diesen Optionen hab ich auf einem AMD Athlon(tm) 64 X2 Dual Core Processor 4600+ ein Verzeichnis mit mehreren Dateien (insgesamt 5Gb) komprimieren lassen. Nach 20 Minuten war das 1.4Gb gro&szlig;e Archiv fertig komprimiert. Ein Ersparnis von 3.6Gb. Das Ergebnis kann sich sehen lassen.</p>

	Tags: <a href="http://fritzthomas.com/tags/7zip/" title="7zip" rel="tag">7zip</a>, <a href="http://fritzthomas.com/tags/gentoo/" title="gentoo" rel="tag">gentoo</a>, <a href="http://fritzthomas.com/tags/how-to/" title="how-to" rel="tag">how-to</a>, <a href="http://fritzthomas.com/tags/linux/" title="Linux" rel="tag">Linux</a><br />

	<h4>&Auml;hnliche Beitr&auml;ge:</h4>
	<ul class="st-related-posts">
	<li><a href="http://fritzthomas.com/open-source/linux/12-aendern-oder-setzen-eines-statischen-netzwerk-device-namen-unter-gentoo-eth0-eth1ethn/" title="Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;) (December 27, 2007)">Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;)</a> (0)</li>
	<li><a href="http://fritzthomas.com/gentoo-php-web-development-vmware-appliance/" title="Web Dev Appliance (January 13, 2008)">Web Dev Appliance</a> (16)</li>
	<li><a href="http://fritzthomas.com/overall/491-how-to-cleaning-up-gentoo-to-get-more-free-disk-space/" title="How-To: Cleaning up Gentoo to get more free disk space (August 20, 2009)">How-To: Cleaning up Gentoo to get more free disk space</a> (4)</li>
</ul>

]]></content:encoded>
			<wfw:commentRss>http://fritzthomas.com/open-source/linux/22-7zip-unter-gentoo-linux-verwenden/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Manuell die Mac Adresse einer VMware Appliance ändern</title>
		<link>http://fritzthomas.com/overall/19-manuell-die-mac-adresse-einer-vmware-appliance-andern/</link>
		<comments>http://fritzthomas.com/overall/19-manuell-die-mac-adresse-einer-vmware-appliance-andern/#comments</comments>
		<pubDate>Thu, 10 Jan 2008 14:43:18 +0000</pubDate>
		<dc:creator>Thomas</dc:creator>
				<category><![CDATA[Overall]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[vmware]]></category>

		<guid isPermaLink="false">http://fritzthomas.com/allgemein/19-manuell-die-mac-adresse-einer-vmware-appliance-andern/</guid>
		<description><![CDATA[&#196;ndert sich der Pfad einer VMware Appliance wird auch eine neue Mac Adresse generiert. Will man immer dieselbe Mac Adresse behalten, kann man eine Mac Adresse auch manuell zuweisen. Dazu sind einige wenige &#196;nderungen in der VMware Konfigurations Datei n&#246;tig. Aber Vorsicht: M&#246;chte man mehrere VMware Appliances im selben Ethernet betreiben muss sichergestellt sein das [...]]]></description>
			<content:encoded><![CDATA[<p>&Auml;ndert sich der Pfad einer VMware Appliance wird auch eine neue Mac Adresse generiert. Will man immer dieselbe Mac Adresse behalten, kann man eine Mac Adresse auch manuell zuweisen.<br />
Dazu sind einige wenige &Auml;nderungen in der VMware Konfigurations Datei n&ouml;tig.</p>
<p><span id="more-19"></span></p>
<p><strong>Aber Vorsicht:</strong><br />
M&ouml;chte man mehrere VMware Appliances im selben Ethernet betreiben muss sichergestellt sein das keine Appliances dieselbe MAC Adresse hat. Das kann zu Fehlern im Netzwerk f&uuml;hren.</p>
<h2>Manuelles zuweisen einer MAC Adresse</h2>
<p>Die Konfigurationsdatei muss ge&ouml;ffnet werden. Diese Datei hat normalweise eine Endung .vmx.</p>
<p><div style="width:100%;text-align:center;padding:0;margin:0;border:0;overflow:hidden;clear:both;"><script type="text/javascript"><!--
google_ad_client = "pub-1963733382421272";
google_ui_features = "rc:0";
google_ad_width = 234;
google_ad_height = 60;
google_ad_format = "234x60_as";
google_ad_type = "text_image";
google_alternate_ad_color = "ffffff";
google_color_border = "ffffff";
google_color_bg = "ffffff";
google_color_link = "319BD8";
google_color_text = "666666";
google_color_url = "319BD8";

//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div></p>
<p>Wurde die Konfigurationsdatei automatisch erstellt (zum Beispiel von VMware Server), findet man folgende 3 Zeilen &#8211; diese sind zu entfernen:</p>

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;">ethernet<span style="color: #000066; font-weight:bold;"><span style="">&#91;</span>n<span style="">&#93;</span></span>.generatedAddress
ethernet<span style="color: #000066; font-weight:bold;"><span style="">&#91;</span>n<span style="">&#93;</span></span>.addressType
ethernet<span style="color: #000066; font-weight:bold;"><span style="">&#91;</span>n<span style="">&#93;</span></span>.generatedAddressOffset</pre></div></div>

<p>Die oberen 3 Zeilen mit dieser ersetzen:</p>

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;">ethernet<span style="color: #000066; font-weight:bold;"><span style="">&#91;</span><span style="">0</span><span style="">&#93;</span></span>.address <span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;"> 00:<span style="">50</span>:<span style="">56</span>:XX:YY:ZZ</span></pre></div></div>

<p>In den beiden Beispielen ist &#8220;[n]&#8221; durch die Nummer der Netzwerkkarte die konfiguriert werden soll, zu ersetzen. Verwendet man nur eine Netzwerkkarte ist &#8220;[n]&#8221; durch 0 zu ersetzen.</p>
<p>Beim manuellen zuweisen einer MAC Adresse ist zu beachten das sie mit &#8220;00:50:56&#8243; beginnen muss. XX muss im Bereich 00h und 3Fh sein. YY und ZZ muss im Bereich 00h and FFh sein. Mehr Informationen &uuml;ber das <a href="http://de.wikipedia.org/wiki/Hexadezimal">Hexadezimalsystem</a> oder &uuml;ber <a href="http://de.wikipedia.org/wiki/MAC-Adresse">Mac Adressen</a> findet ihr auf wikipedia.</p>

	Tags: <a href="http://fritzthomas.com/tags/how-to/" title="how-to" rel="tag">how-to</a>, <a href="http://fritzthomas.com/tags/vmware/" title="vmware" rel="tag">vmware</a><br />

	<h4>&Auml;hnliche Beitr&auml;ge:</h4>
	<ul class="st-related-posts">
	<li><a href="http://fritzthomas.com/open-source/linux/12-aendern-oder-setzen-eines-statischen-netzwerk-device-namen-unter-gentoo-eth0-eth1ethn/" title="Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;) (December 27, 2007)">Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;)</a> (0)</li>
	<li><a href="http://fritzthomas.com/php/24-zend-framework-web-developer-appliance/" title="Zend Framework Web Developer Appliance (January 15, 2008)">Zend Framework Web Developer Appliance</a> (1)</li>
	<li><a href="http://fritzthomas.com/php/zend-framework/33-how-to-teil-1-projektaufbau-konventionen-und-modulare-verzeichnisstruktur/" title="Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur (January 28, 2008)">Zend Framework How-To Teil 1: Projektaufbau, Konventionen und modulare Verzeichnisstruktur</a> (13)</li>
</ul>

]]></content:encoded>
			<wfw:commentRss>http://fritzthomas.com/overall/19-manuell-die-mac-adresse-einer-vmware-appliance-andern/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Setzen eines statischen Netzwerk Device Namen unter Gentoo. (eth0,eth1,&#8230;)</title>
		<link>http://fritzthomas.com/open-source/linux/12-aendern-oder-setzen-eines-statischen-netzwerk-device-namen-unter-gentoo-eth0-eth1ethn/</link>
		<comments>http://fritzthomas.com/open-source/linux/12-aendern-oder-setzen-eines-statischen-netzwerk-device-namen-unter-gentoo-eth0-eth1ethn/#comments</comments>
		<pubDate>Thu, 27 Dec 2007 16:33:18 +0000</pubDate>
		<dc:creator>Thomas</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[bash]]></category>
		<category><![CDATA[gentoo]]></category>
		<category><![CDATA[how-to]]></category>
		<category><![CDATA[vmware]]></category>

		<guid isPermaLink="false">http://fritzthomas.com/archives/2007/12/aendern-oder-setzen-eines-statischen-netzwerk-device-namen-unter-gentoo-eth0-eth1ethn/</guid>
		<description><![CDATA[Wird durch den Kernel eine neue Mac Adresse erkannt, wird angenommen das es sich dabei um ein neues Netzwerk Interface handelt. Dieses neue Device muss anschließend auch neu konfiguriert werden. Soweit so gut. Möchte man aber seine Netzwerkkarte gegen eine neue tauschen, aber denselben Device Namen behalten, um so die evtl. bereits erstellte und wahrscheinlich [...]]]></description>
			<content:encoded><![CDATA[<p>Wird durch den Kernel eine neue Mac Adresse erkannt, wird angenommen das es sich dabei um ein <em>neues</em> Netzwerk Interface handelt. Dieses neue Device muss anschließend  auch <em>neu</em> konfiguriert werden.</p>
<p><div style="width:100%;text-align:center;padding:0;margin:0;border:0;overflow:hidden;clear:both;"><script type="text/javascript"><!--
google_ad_client = "pub-1963733382421272";
google_ui_features = "rc:0";
google_ad_width = 234;
google_ad_height = 60;
google_ad_format = "234x60_as";
google_ad_type = "text_image";
google_alternate_ad_color = "ffffff";
google_color_border = "ffffff";
google_color_bg = "ffffff";
google_color_link = "319BD8";
google_color_text = "666666";
google_color_url = "319BD8";

//--></script>
<script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>
</div></p>
<p>Soweit so gut. Möchte man aber seine Netzwerkkarte gegen eine neue <em>tauschen</em>, aber denselben Device Namen behalten, um so die evtl. bereits erstellte und wahrscheinlich auch funktionierende Konfiguration (Netzwerkkonfiguration, iptables,&#8230;) zu verwenden, kann mittels udev Regeln der neuen Mac Adresse einen statischen Namen zuweisen.</p>
<p>Das ist auch dann hilfreich wenn man eine Linux <strong>VMware</strong> Appliance kopiert, und eine neue UUID generieren l&auml;sst, um zum Beispiel mehrere &#8220;identische&#8221; Appliances im selben Netzwerk zu betreiben. Das neu generieren ändert auch die Mac Adresse der virtuellen Netzwerkkarte und somit wird auch ein neues Interface angelegt. Was vorher eth0 war wird dann zu eth1 und muss auch wieder neu konfiguriert werden.<br />
Will man einfach <a href="/allgemein/19-manuell-die-mac-adresse-einer-vmware-appliance-andern/">manuell die Mac Adresse einer Appliance &auml;ndern</a> oder zuweisen, um immer dieselbe MAC Adresse zu haben auch wenn die Appliance kopiert wird seht <a href="/allgemein/19-manuell-die-mac-adresse-einer-vmware-appliance-andern/">hier</a>.</p>
<p><span id="more-12"></span></p>
<p>Um sich das neu Konfigurieren zu ersparen kann man mit einer einfachen udev Regel den Namen des Devices setzen.</p>
<h2>Mac Adresse rausfinden</h2>
<p>Zuerst müssen wir die neue Mac Adresse rausfinden.<br />
Entweder die Ausgabe von ifconfig verrät uns schon die Mac Adresse (HWaddr XX:XX:XX:XX:XX:XX):</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">ifconfig</span> <span style="color: #660033;">-a</span>
eth1      Link encap:Ethernet  HWaddr XX:XX:XX:XX:XX:XX
          inet addr:192.168.0.1  Bcast:192.168.0.255  Mask:255.255.255.0
          inet6 addr: fe80::20c:29ff:fe06:<span style="color: #000000;">528</span><span style="color: #000000; font-weight: bold;">/</span><span style="color: #000000;">64</span> Scope:Link
          UP BROADCAST RUNNING MULTICAST  MTU:<span style="color: #000000;">1500</span>  Metric:<span style="color: #000000;">1</span>
          RX packets:<span style="color: #000000;">14656</span> errors:<span style="color: #000000;">0</span> dropped:<span style="color: #000000;">0</span> overruns:<span style="color: #000000;">0</span> frame:<span style="color: #000000;">0</span>
          TX packets:<span style="color: #000000;">13877</span> errors:<span style="color: #000000;">0</span> dropped:<span style="color: #000000;">0</span> overruns:<span style="color: #000000;">0</span> carrier:<span style="color: #000000;">0</span>
          collisions:<span style="color: #000000;">0</span> txqueuelen:<span style="color: #000000;">1000</span>
          RX bytes:<span style="color: #000000;">5958558</span> <span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">5.6</span> Mb<span style="color: #7a0874; font-weight: bold;">&#41;</span>  TX bytes:<span style="color: #000000;">2020530</span> <span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #000000;">1.9</span> Mb<span style="color: #7a0874; font-weight: bold;">&#41;</span>
          Interrupt:<span style="color: #000000;">16</span> Base address:0x1400</pre></div></div>

<p>oder aber udevinfo:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">udevinfo <span style="color: #660033;">-a</span> <span style="color: #660033;">-p</span> <span style="color: #000000; font-weight: bold;">/</span>sys<span style="color: #000000; font-weight: bold;">/</span>class<span style="color: #000000; font-weight: bold;">/</span>net<span style="color: #000000; font-weight: bold;">/</span>eth1 <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> address
    ATTR<span style="color: #7a0874; font-weight: bold;">&#123;</span>address<span style="color: #7a0874; font-weight: bold;">&#125;</span>==<span style="color: #ff0000;">&quot;XX:XX:XX:XX:XX:XX&quot;</span></pre></div></div>

<p>Wenn man die Mac Adresse einer vmware Appliance herausfinden will, ist es ganz einfach. Die &#8220;.vmx&#8221; Datei der Appliance mit einem Texteditor offnen. Die Mac Adresse wird nach &#8220;ethernet0.generatedAddress&#8221; gespeichert. In derselben Datei findet man auch auch die UUID. Die wird in &#8220;uuid.location&#8221; und &#8220;uuid.bios&#8221; gespeichert.</p>
<h2>Namen für das Device setzen / ändern</h2>
<p>Mit der Mac Adresse die wir jetzt wissen, können wir eine neue Udev Regel erstellen und einen beliebigen Namen setzen. Also können wir aus eth1 ein eth0 machen.</p>
<p>Unter <strong>Gentoo</strong> werden die Regeln in <strong>/etc/udev/rules.d</strong> gespeichert.<br />
Unsere neue Regel speichern wir in ein neues File.<br />
<strong>/etc/udev/rules.d/10-rules.local</strong>:</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #007800;">SUBSYSTEM</span>==<span style="color: #ff0000;">&quot;net&quot;</span>, ATTR<span style="color: #7a0874; font-weight: bold;">&#123;</span>address<span style="color: #7a0874; font-weight: bold;">&#125;</span>==<span style="color: #ff0000;">&quot;XX:XX:XX:XX:XX:XX&quot;</span>, <span style="color: #007800;">NAME</span>=<span style="color: #ff0000;">&quot;eth0&quot;</span></pre></div></div>

<p>Die Mac Adresse (&#8220;XX:XX:XX:XX:XX:XX&#8221;) und den Namen (&#8220;eth0&#8243;) muesst ihr natürlich mit eurer Mac Adresse und euren Wunschnamen ersetzen.</p>
<p>Das obige Beispiel wird also das Device mit der Mac Adresse XX:XX:XX:XX:XX:XX mit dem Namen eth0 erstellen und nicht eth1 wie in unserem Beispiel.<br />
Man kann auch sprechendere Namen verwenden, wenn man mehrere Devices für verschiedene Dienste verwendet und man sich keine Zahlen merken will (oder kann)<br />
Zum Beispiel: eth_www und eth_db oder eth_lan und eth_wan. Alles ist möglich.</p>
<p>Ändert sich die Mac Adresse erneut, zum Beispiel beim erneuten generieren der UUID unter VMware, muss natürlich in <strong>/etc/udev/rules.d/10-local.rules</strong> die neue Mac Adresse nachgetragen werden.</p>
<p>Wie man den Namen unter Ubuntu ändert findet man <a href="http://www.ubuntu-forum.de/artikel/15909/GELOeST-bezeichnung-der-Netzwerkkarte-aendern.html">HIER</a></p>

	Tags: <a href="http://fritzthomas.com/tags/bash/" title="bash" rel="tag">bash</a>, <a href="http://fritzthomas.com/tags/gentoo/" title="gentoo" rel="tag">gentoo</a>, <a href="http://fritzthomas.com/tags/how-to/" title="how-to" rel="tag">how-to</a>, <a href="http://fritzthomas.com/tags/linux/" title="Linux" rel="tag">Linux</a>, <a href="http://fritzthomas.com/tags/vmware/" title="vmware" rel="tag">vmware</a><br />

	<h4>&Auml;hnliche Beitr&auml;ge:</h4>
	<ul class="st-related-posts">
	<li><a href="http://fritzthomas.com/gentoo-php-web-development-vmware-appliance/" title="Web Dev Appliance (January 13, 2008)">Web Dev Appliance</a> (16)</li>
	<li><a href="http://fritzthomas.com/open-source/linux/22-7zip-unter-gentoo-linux-verwenden/" title="7zip unter Gentoo Linux verwenden (January 11, 2008)">7zip unter Gentoo Linux verwenden</a> (1)</li>
	<li><a href="http://fritzthomas.com/php/24-zend-framework-web-developer-appliance/" title="Zend Framework Web Developer Appliance (January 15, 2008)">Zend Framework Web Developer Appliance</a> (1)</li>
</ul>

]]></content:encoded>
			<wfw:commentRss>http://fritzthomas.com/open-source/linux/12-aendern-oder-setzen-eines-statischen-netzwerk-device-namen-unter-gentoo-eth0-eth1ethn/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
