<?xml version="1.0" encoding="utf-8" ?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <title type="html">Homepage von Andreas Juch</title>
  <subtitle type="html"></subtitle>
  <author>
    <name>Andreas Juch</name>
    <uri></uri>
  </author>

  <link href="http://andreas.juch.cc/" rel="alternate" />
  <link href="http://andreas.juch.cc/articles.atom" rel="self" />
  <generator uri="http://webgen.rubyforge.org/documentation/sourcehandler/feed.html" version="0.5.14">
    webgen - Webgen::SourceHandler::Feed
  </generator>
  <updated>2012-09-28T11:12:58+02:00</updated>
  <id>http://andreas.juch.cc/</id>

  
  <entry>
    <title type="html">Efficient equals() and hashCode()</title>
    
    <link href="http://andreas.juch.cc/java/equals.en.html" rel="alternate" />
    <id>http://andreas.juch.cc/java/equals.en.html</id>
    <updated>2012-03-09T19:07:45Z</updated>
    
    <published>2012-03-09T18:58:33Z</published>
    
    <content type="html">&lt;p&gt;Using &lt;a href=&quot;http://commons.apache.org/lang/&quot;&gt;Apache Commons Lang&lt;/a&gt; to write simple equals() and hashCode()
methods is better than generating them (e.g. with Eclipse) or coding them by
hand in terms of complexity and readability.&lt;/p&gt;
&lt;h2&gt;Without commons-lang:&lt;/h2&gt;
&lt;div class=&quot;CodeRay&quot;&gt;
  &lt;div class=&quot;code&quot;&gt;&lt;pre&gt;&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n1&quot; name=&quot;n1&quot;&gt;1&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;public&lt;/span&gt; &lt;span style=&quot;color:#339;font-weight:bold&quot;&gt;int&lt;/span&gt; hashCode() {
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n2&quot; name=&quot;n2&quot;&gt;2&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;final&lt;/span&gt; &lt;span style=&quot;color:#339;font-weight:bold&quot;&gt;int&lt;/span&gt; prime = &lt;span style=&quot;color:#00D&quot;&gt;31&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n3&quot; name=&quot;n3&quot;&gt;3&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#339;font-weight:bold&quot;&gt;int&lt;/span&gt; result = &lt;span style=&quot;color:#00D&quot;&gt;1&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n4&quot; name=&quot;n4&quot;&gt;4&lt;/a&gt;&lt;/span&gt;        result = prime * result + ((artist == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) ? &lt;span style=&quot;color:#00D&quot;&gt;0&lt;/span&gt; : artist.hashCode());
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n5&quot; name=&quot;n5&quot;&gt;5&lt;/a&gt;&lt;/span&gt;        result = prime * result + bpm;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n6&quot; name=&quot;n6&quot;&gt;6&lt;/a&gt;&lt;/span&gt;        result = prime * result + duration;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n7&quot; name=&quot;n7&quot;&gt;7&lt;/a&gt;&lt;/span&gt;        result = prime * result + ((file == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) ? &lt;span style=&quot;color:#00D&quot;&gt;0&lt;/span&gt; : file.hashCode());
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n8&quot; name=&quot;n8&quot;&gt;8&lt;/a&gt;&lt;/span&gt;        result = prime * result + ((genre == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) ? &lt;span style=&quot;color:#00D&quot;&gt;0&lt;/span&gt; : genre.hashCode());
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n9&quot; name=&quot;n9&quot;&gt;9&lt;/a&gt;&lt;/span&gt;        result = prime * result + ((key == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) ? &lt;span style=&quot;color:#00D&quot;&gt;0&lt;/span&gt; : key.hashCode());
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n10&quot; name=&quot;n10&quot;&gt;10&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;        result = prime * result
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n11&quot; name=&quot;n11&quot;&gt;11&lt;/a&gt;&lt;/span&gt;                        + ((releaseDate == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) ? &lt;span style=&quot;color:#00D&quot;&gt;0&lt;/span&gt; : releaseDate.hashCode());
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n12&quot; name=&quot;n12&quot;&gt;12&lt;/a&gt;&lt;/span&gt;        result = prime * result + ((title == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) ? &lt;span style=&quot;color:#00D&quot;&gt;0&lt;/span&gt; : title.hashCode());
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n13&quot; name=&quot;n13&quot;&gt;13&lt;/a&gt;&lt;/span&gt;        result = prime * result + ((url == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) ? &lt;span style=&quot;color:#00D&quot;&gt;0&lt;/span&gt; : url.hashCode());
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n14&quot; name=&quot;n14&quot;&gt;14&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; result;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n15&quot; name=&quot;n15&quot;&gt;15&lt;/a&gt;&lt;/span&gt;}&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;CodeRay&quot;&gt;
  &lt;div class=&quot;code&quot;&gt;&lt;pre&gt;&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n1&quot; name=&quot;n1&quot;&gt;1&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;public&lt;/span&gt; &lt;span style=&quot;color:#339;font-weight:bold&quot;&gt;boolean&lt;/span&gt; equals(&lt;span style=&quot;color:#0a5;font-weight:bold&quot;&gt;Object&lt;/span&gt; obj) {
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n2&quot; name=&quot;n2&quot;&gt;2&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (&lt;span style=&quot;color:#963&quot;&gt;this&lt;/span&gt; == obj)
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n3&quot; name=&quot;n3&quot;&gt;3&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;true&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n4&quot; name=&quot;n4&quot;&gt;4&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (obj == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n5&quot; name=&quot;n5&quot;&gt;5&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n6&quot; name=&quot;n6&quot;&gt;6&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (getClass() != obj.getClass())
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n7&quot; name=&quot;n7&quot;&gt;7&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n8&quot; name=&quot;n8&quot;&gt;8&lt;/a&gt;&lt;/span&gt;        Song other = (Song) obj;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n9&quot; name=&quot;n9&quot;&gt;9&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (artist == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) {
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n10&quot; name=&quot;n10&quot;&gt;10&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (other.artist != &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n11&quot; name=&quot;n11&quot;&gt;11&lt;/a&gt;&lt;/span&gt;                        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n12&quot; name=&quot;n12&quot;&gt;12&lt;/a&gt;&lt;/span&gt;        } &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;else&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (!artist.equals(other.artist))
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n13&quot; name=&quot;n13&quot;&gt;13&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n14&quot; name=&quot;n14&quot;&gt;14&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (bpm != other.bpm)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n15&quot; name=&quot;n15&quot;&gt;15&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n16&quot; name=&quot;n16&quot;&gt;16&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (duration != other.duration)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n17&quot; name=&quot;n17&quot;&gt;17&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n18&quot; name=&quot;n18&quot;&gt;18&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (file == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) {
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n19&quot; name=&quot;n19&quot;&gt;19&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (other.file != &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n20&quot; name=&quot;n20&quot;&gt;20&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;                        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n21&quot; name=&quot;n21&quot;&gt;21&lt;/a&gt;&lt;/span&gt;        } &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;else&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (!file.equals(other.file))
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n22&quot; name=&quot;n22&quot;&gt;22&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n23&quot; name=&quot;n23&quot;&gt;23&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (genre == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) {
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n24&quot; name=&quot;n24&quot;&gt;24&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (other.genre != &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n25&quot; name=&quot;n25&quot;&gt;25&lt;/a&gt;&lt;/span&gt;                        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n26&quot; name=&quot;n26&quot;&gt;26&lt;/a&gt;&lt;/span&gt;        } &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;else&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (!genre.equals(other.genre))
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n27&quot; name=&quot;n27&quot;&gt;27&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n28&quot; name=&quot;n28&quot;&gt;28&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (key != other.key)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n29&quot; name=&quot;n29&quot;&gt;29&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n30&quot; name=&quot;n30&quot;&gt;30&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (releaseDate == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) {
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n31&quot; name=&quot;n31&quot;&gt;31&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (other.releaseDate != &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n32&quot; name=&quot;n32&quot;&gt;32&lt;/a&gt;&lt;/span&gt;                        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n33&quot; name=&quot;n33&quot;&gt;33&lt;/a&gt;&lt;/span&gt;        } &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;else&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (!releaseDate.equals(other.releaseDate))
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n34&quot; name=&quot;n34&quot;&gt;34&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n35&quot; name=&quot;n35&quot;&gt;35&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (title == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) {
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n36&quot; name=&quot;n36&quot;&gt;36&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (other.title != &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n37&quot; name=&quot;n37&quot;&gt;37&lt;/a&gt;&lt;/span&gt;                        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n38&quot; name=&quot;n38&quot;&gt;38&lt;/a&gt;&lt;/span&gt;        } &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;else&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (!title.equals(other.title))
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n39&quot; name=&quot;n39&quot;&gt;39&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n40&quot; name=&quot;n40&quot;&gt;40&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (url == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) {
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n41&quot; name=&quot;n41&quot;&gt;41&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (other.url != &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n42&quot; name=&quot;n42&quot;&gt;42&lt;/a&gt;&lt;/span&gt;                        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n43&quot; name=&quot;n43&quot;&gt;43&lt;/a&gt;&lt;/span&gt;        } &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;else&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (!url.equals(other.url))
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n44&quot; name=&quot;n44&quot;&gt;44&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n45&quot; name=&quot;n45&quot;&gt;45&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;true&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n46&quot; name=&quot;n46&quot;&gt;46&lt;/a&gt;&lt;/span&gt;}&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;h2&gt;With commons-lang:&lt;/h2&gt;
&lt;div class=&quot;CodeRay&quot;&gt;
  &lt;div class=&quot;code&quot;&gt;&lt;pre&gt;&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n1&quot; name=&quot;n1&quot;&gt;1&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;private&lt;/span&gt; &lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;static&lt;/span&gt; &lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;final&lt;/span&gt; &lt;span style=&quot;color:#339;font-weight:bold&quot;&gt;int&lt;/span&gt; &lt;span class=&quot;caps&quot;&gt;INITIAL&lt;/span&gt; = &lt;span style=&quot;color:#00D&quot;&gt;17&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n2&quot; name=&quot;n2&quot;&gt;2&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;private&lt;/span&gt; &lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;static&lt;/span&gt; &lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;final&lt;/span&gt; &lt;span style=&quot;color:#339;font-weight:bold&quot;&gt;int&lt;/span&gt; &lt;span class=&quot;caps&quot;&gt;MULTIPLIER&lt;/span&gt; = &lt;span style=&quot;color:#00D&quot;&gt;37&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n3&quot; name=&quot;n3&quot;&gt;3&lt;/a&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n4&quot; name=&quot;n4&quot;&gt;4&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;public&lt;/span&gt; &lt;span style=&quot;color:#339;font-weight:bold&quot;&gt;int&lt;/span&gt; hashCode() {
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n5&quot; name=&quot;n5&quot;&gt;5&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;new&lt;/span&gt; HashCodeBuilder(&lt;span class=&quot;caps&quot;&gt;INITIAL&lt;/span&gt;, &lt;span class=&quot;caps&quot;&gt;MULTIPLIER&lt;/span&gt;).append(artist)
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n6&quot; name=&quot;n6&quot;&gt;6&lt;/a&gt;&lt;/span&gt;                        .append(bpm).append(duration).append(file).append(genre)
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n7&quot; name=&quot;n7&quot;&gt;7&lt;/a&gt;&lt;/span&gt;                        .append(key).append(releaseDate).append(title).append(url)
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n8&quot; name=&quot;n8&quot;&gt;8&lt;/a&gt;&lt;/span&gt;                        .toHashCode();
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n9&quot; name=&quot;n9&quot;&gt;9&lt;/a&gt;&lt;/span&gt;}&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;div class=&quot;CodeRay&quot;&gt;
  &lt;div class=&quot;code&quot;&gt;&lt;pre&gt;&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n1&quot; name=&quot;n1&quot;&gt;1&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#088;font-weight:bold&quot;&gt;public&lt;/span&gt; &lt;span style=&quot;color:#339;font-weight:bold&quot;&gt;boolean&lt;/span&gt; equals(&lt;span style=&quot;color:#0a5;font-weight:bold&quot;&gt;Object&lt;/span&gt; obj) {
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n2&quot; name=&quot;n2&quot;&gt;2&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (obj == &lt;span style=&quot;color:#069&quot;&gt;null&lt;/span&gt;) {
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n3&quot; name=&quot;n3&quot;&gt;3&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n4&quot; name=&quot;n4&quot;&gt;4&lt;/a&gt;&lt;/span&gt;        }
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n5&quot; name=&quot;n5&quot;&gt;5&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (obj == &lt;span style=&quot;color:#963&quot;&gt;this&lt;/span&gt;) {
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n6&quot; name=&quot;n6&quot;&gt;6&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;true&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n7&quot; name=&quot;n7&quot;&gt;7&lt;/a&gt;&lt;/span&gt;        }
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n8&quot; name=&quot;n8&quot;&gt;8&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; (obj.getClass() != getClass()) {
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n9&quot; name=&quot;n9&quot;&gt;9&lt;/a&gt;&lt;/span&gt;                &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#069&quot;&gt;false&lt;/span&gt;;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n10&quot; name=&quot;n10&quot;&gt;10&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;        }
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n11&quot; name=&quot;n11&quot;&gt;11&lt;/a&gt;&lt;/span&gt;        Song s = (Song) obj;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n12&quot; name=&quot;n12&quot;&gt;12&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;new&lt;/span&gt; EqualsBuilder().append(artist, s.artist).append(bpm, s.bpm)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n13&quot; name=&quot;n13&quot;&gt;13&lt;/a&gt;&lt;/span&gt;                        .append(duration, s.duration).append(file, s.file)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n14&quot; name=&quot;n14&quot;&gt;14&lt;/a&gt;&lt;/span&gt;                        .append(genre, s.genre).append(key, s.key)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n15&quot; name=&quot;n15&quot;&gt;15&lt;/a&gt;&lt;/span&gt;                        .append(releaseDate, s.releaseDate).append(title, s.title)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n16&quot; name=&quot;n16&quot;&gt;16&lt;/a&gt;&lt;/span&gt;                        .append(url, s.url).isEquals();
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n17&quot; name=&quot;n17&quot;&gt;17&lt;/a&gt;&lt;/span&gt;}&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Java</title>
    
    <link href="http://andreas.juch.cc/java/index.en.html" rel="alternate" />
    <id>http://andreas.juch.cc/java/index.en.html</id>
    <updated>2012-03-09T18:58:33Z</updated>
    
    <published>2012-03-09T18:58:33Z</published>
    
    <content type="html">&lt;p&gt;Some unrelated Java Tips.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Impressum</title>
    
    <link href="http://andreas.juch.cc/impressum.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/impressum.de.html</id>
    <updated>2012-01-12T15:40:03Z</updated>
    
    <published>2009-09-11T14:05:59Z</published>
    
    <content type="html">&lt;p&gt;Seitenbetreiber und inhaltlich Verantwortlicher:&lt;/p&gt;
&lt;pre&gt;Andreas Juch
Lorenz-Müller-Gasse 1A/5109
1200 Wien
Österreich&lt;/pre&gt;
&lt;p&gt;E-Mail: homepage@juch.cc&lt;/p&gt;
&lt;h2&gt;Haftungshinweis&lt;/h2&gt;
&lt;p&gt;Trotz sorgfältiger inhaltlicher Kontrolle übernehme ich keine Haftung für die
Inhalte externer Links. Für den Inhalt der verlinkten Seiten sind
ausschließlich deren Betreiber verantwortlich.&lt;/p&gt;
&lt;h2&gt;Produkt- und Firmennamen&lt;/h2&gt;
&lt;p&gt;Die auf diesen Webseiten verwendeten Produkt- und Firmennamen sind Waren- oder
Markenzeichen ihrer jeweiligen Besitzer.&lt;/p&gt;
&lt;h2&gt;Grafiken auf dieser Webseite&lt;/h2&gt;
&lt;p&gt;Auf dieser Webseite werden Grafiken des &lt;a href=&quot;http://tango.freedesktop.org/&quot;&gt;Tango
Projektes&lt;/a&gt; verwendet.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Duplikate finden</title>
    
    <link href="http://andreas.juch.cc/software/duplikat-finder.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/software/duplikat-finder.de.html</id>
    <updated>2011-07-09T11:31:56Z</updated>
    
    <published>2009-04-08T16:51:49Z</published>
    
    <content type="html">&lt;p&gt;Manchmal belegen Duplikate von Dateien viel Platz, bei nicht besonders
ordentlichem Dateisystem-Layout findet man diese Duplikate nicht einmal. Dieses
simple Python-Programm (mit Abhängigkeit zum Kommandozeilenprogramm md5sum)
findet sie und gibt aus, wieviel Platz durch Duplikate verschwendet wird.&lt;/p&gt;
&lt;div class=&quot;CodeRay&quot;&gt;
  &lt;div class=&quot;code&quot;&gt;&lt;pre&gt;&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n1&quot; name=&quot;n1&quot;&gt;1&lt;/a&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n2&quot; name=&quot;n2&quot;&gt;2&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#777&quot;&gt;#!/usr/bin/env python&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n3&quot; name=&quot;n3&quot;&gt;3&lt;/a&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n4&quot; name=&quot;n4&quot;&gt;4&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;import&lt;/span&gt; &lt;span style=&quot;color:#B44;font-weight:bold&quot;&gt;os&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n5&quot; name=&quot;n5&quot;&gt;5&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;import&lt;/span&gt; &lt;span style=&quot;color:#B44;font-weight:bold&quot;&gt;os.path&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n6&quot; name=&quot;n6&quot;&gt;6&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;import&lt;/span&gt; &lt;span style=&quot;color:#B44;font-weight:bold&quot;&gt;sys&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n7&quot; name=&quot;n7&quot;&gt;7&lt;/a&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n8&quot; name=&quot;n8&quot;&gt;8&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;def&lt;/span&gt; &lt;span style=&quot;color:#06B;font-weight:bold&quot;&gt;filesize&lt;/span&gt;(&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt;):
&lt;span class=&quot;line-numbers&quot;&gt; &lt;a href=&quot;#n9&quot; name=&quot;n9&quot;&gt;9&lt;/a&gt;&lt;/span&gt;    &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; os.stat(&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt;)[&lt;span style=&quot;color:#00D&quot;&gt;6&lt;/span&gt;]
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n10&quot; name=&quot;n10&quot;&gt;10&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n11&quot; name=&quot;n11&quot;&gt;11&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;def&lt;/span&gt; &lt;span style=&quot;color:#06B;font-weight:bold&quot;&gt;md5sum&lt;/span&gt;(&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt;):
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n12&quot; name=&quot;n12&quot;&gt;12&lt;/a&gt;&lt;/span&gt;    cld_in, cld_out = os.popen2(&lt;span style=&quot;background-color:hsla(0,100%,50%,0.05)&quot;&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8216;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt;md5sum &amp;quot;%s&amp;quot;&lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8217;&lt;/span&gt;&lt;/span&gt; % &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n13&quot; name=&quot;n13&quot;&gt;13&lt;/a&gt;&lt;/span&gt;    result = cld_out.read()
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n14&quot; name=&quot;n14&quot;&gt;14&lt;/a&gt;&lt;/span&gt;    cld_in.close()
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n15&quot; name=&quot;n15&quot;&gt;15&lt;/a&gt;&lt;/span&gt;    cld_out.close()
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n16&quot; name=&quot;n16&quot;&gt;16&lt;/a&gt;&lt;/span&gt;    &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; result.split(&lt;span style=&quot;background-color:hsla(0,100%,50%,0.05)&quot;&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;quot;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt; &lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt;)[&lt;span style=&quot;color:#00D&quot;&gt;0&lt;/span&gt;]
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n17&quot; name=&quot;n17&quot;&gt;17&lt;/a&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n18&quot; name=&quot;n18&quot;&gt;18&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;def&lt;/span&gt; &lt;span style=&quot;color:#06B;font-weight:bold&quot;&gt;size_fmt&lt;/span&gt;(&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;bytes&lt;/span&gt;):
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n19&quot; name=&quot;n19&quot;&gt;19&lt;/a&gt;&lt;/span&gt;    &lt;span style=&quot;color:#777&quot;&gt;&lt;span style=&quot;color:#444&quot;&gt;&amp;quot;&amp;quot;&amp;quot;&lt;/span&gt;&lt;span&gt;Thanks to Fred Cirera&lt;/span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n20&quot; name=&quot;n20&quot;&gt;20&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;&lt;span style=&quot;color:#777&quot;&gt;&lt;span&gt;&lt;/span&gt;&lt;span&gt;    http://blogmag.net/blog/read/38/Print_human_readable_file_size&lt;/span&gt;&lt;span style=&quot;color:#444&quot;&gt;&amp;quot;&amp;quot;&amp;quot;&lt;/span&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n21&quot; name=&quot;n21&quot;&gt;21&lt;/a&gt;&lt;/span&gt;    &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;for&lt;/span&gt; x &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;in&lt;/span&gt; [&lt;span style=&quot;background-color:hsla(0,100%,50%,0.05)&quot;&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8216;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt;Bytes&lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8217;&lt;/span&gt;&lt;/span&gt;, &lt;span style=&quot;background-color:hsla(0,100%,50%,0.05)&quot;&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8216;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt;KiB&lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8217;&lt;/span&gt;&lt;/span&gt;, &lt;span style=&quot;background-color:hsla(0,100%,50%,0.05)&quot;&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8216;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt;MiB&lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8217;&lt;/span&gt;&lt;/span&gt;, &lt;span style=&quot;background-color:hsla(0,100%,50%,0.05)&quot;&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8216;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt;GiB&lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8217;&lt;/span&gt;&lt;/span&gt;, &lt;span style=&quot;background-color:hsla(0,100%,50%,0.05)&quot;&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8216;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt;TiB&lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8217;&lt;/span&gt;&lt;/span&gt;]:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n22&quot; name=&quot;n22&quot;&gt;22&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;bytes&lt;/span&gt; &amp;lt; &lt;span style=&quot;color:#60E&quot;&gt;1024.0&lt;/span&gt;:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n23&quot; name=&quot;n23&quot;&gt;23&lt;/a&gt;&lt;/span&gt;            &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;return&lt;/span&gt; &lt;span style=&quot;background-color:hsla(0,100%,50%,0.05)&quot;&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;quot;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt;%3.1f &lt;span&gt;s&lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;quot;&lt;/span&gt;&lt;/span&gt; % (&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;bytes&lt;/span&gt;, x)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n24&quot; name=&quot;n24&quot;&gt;24&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;bytes&lt;/span&gt; /= &lt;span style=&quot;color:#60E&quot;&gt;1024.0&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n25&quot; name=&quot;n25&quot;&gt;25&lt;/a&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n26&quot; name=&quot;n26&quot;&gt;26&lt;/a&gt;&lt;/span&gt;dir = sys.argv[&lt;span style=&quot;color:#00D&quot;&gt;1&lt;/span&gt;]
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n27&quot; name=&quot;n27&quot;&gt;27&lt;/a&gt;&lt;/span&gt;size_dic = {}
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n28&quot; name=&quot;n28&quot;&gt;28&lt;/a&gt;&lt;/span&gt;md5_dic = {}
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n29&quot; name=&quot;n29&quot;&gt;29&lt;/a&gt;&lt;/span&gt;md5_size = {}
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n30&quot; name=&quot;n30&quot;&gt;30&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;sum = &lt;span style=&quot;color:#00D&quot;&gt;0&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n31&quot; name=&quot;n31&quot;&gt;31&lt;/a&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n32&quot; name=&quot;n32&quot;&gt;32&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;for&lt;/span&gt; root, dirs, files &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;in&lt;/span&gt; os.walk(&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;dir&lt;/span&gt;):
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n33&quot; name=&quot;n33&quot;&gt;33&lt;/a&gt;&lt;/span&gt;    &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;for&lt;/span&gt; &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;in&lt;/span&gt; files:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n34&quot; name=&quot;n34&quot;&gt;34&lt;/a&gt;&lt;/span&gt;        abs_filename = os.path.join(root, &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n35&quot; name=&quot;n35&quot;&gt;35&lt;/a&gt;&lt;/span&gt;        size = filesize(abs_filename)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n36&quot; name=&quot;n36&quot;&gt;36&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;str&lt;/span&gt;(size) &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;in&lt;/span&gt; size_dic:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n37&quot; name=&quot;n37&quot;&gt;37&lt;/a&gt;&lt;/span&gt;            size_dic[&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;str&lt;/span&gt;(size)].append(abs_filename)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n38&quot; name=&quot;n38&quot;&gt;38&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;else&lt;/span&gt;:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n39&quot; name=&quot;n39&quot;&gt;39&lt;/a&gt;&lt;/span&gt;            size_dic[&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;str&lt;/span&gt;(size)] = [abs_filename]
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n40&quot; name=&quot;n40&quot;&gt;40&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n41&quot; name=&quot;n41&quot;&gt;41&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;for&lt;/span&gt; size &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;in&lt;/span&gt; size_dic:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n42&quot; name=&quot;n42&quot;&gt;42&lt;/a&gt;&lt;/span&gt;    &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;len&lt;/span&gt;(size_dic[size]) &amp;gt; &lt;span style=&quot;color:#00D&quot;&gt;1&lt;/span&gt;:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n43&quot; name=&quot;n43&quot;&gt;43&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;for&lt;/span&gt; &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;in&lt;/span&gt; size_dic[size]:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n44&quot; name=&quot;n44&quot;&gt;44&lt;/a&gt;&lt;/span&gt;            filemd5 = md5sum(&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n45&quot; name=&quot;n45&quot;&gt;45&lt;/a&gt;&lt;/span&gt;            &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; filemd5 &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;in&lt;/span&gt; md5_dic:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n46&quot; name=&quot;n46&quot;&gt;46&lt;/a&gt;&lt;/span&gt;                md5_dic[filemd5].append(&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n47&quot; name=&quot;n47&quot;&gt;47&lt;/a&gt;&lt;/span&gt;            &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;else&lt;/span&gt;:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n48&quot; name=&quot;n48&quot;&gt;48&lt;/a&gt;&lt;/span&gt;                md5_dic[filemd5] = [&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt;]
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n49&quot; name=&quot;n49&quot;&gt;49&lt;/a&gt;&lt;/span&gt;            &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;not&lt;/span&gt; filemd5 &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;in&lt;/span&gt; md5_size:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n50&quot; name=&quot;n50&quot;&gt;50&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;                md5_size[filemd5] = &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;int&lt;/span&gt;(size)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n51&quot; name=&quot;n51&quot;&gt;51&lt;/a&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n52&quot; name=&quot;n52&quot;&gt;52&lt;/a&gt;&lt;/span&gt;&lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;for&lt;/span&gt; entry &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;in&lt;/span&gt; md5_dic:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n53&quot; name=&quot;n53&quot;&gt;53&lt;/a&gt;&lt;/span&gt;    &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;if&lt;/span&gt; &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;len&lt;/span&gt;(md5_dic[entry]) &amp;gt; &lt;span style=&quot;color:#00D&quot;&gt;1&lt;/span&gt;:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n54&quot; name=&quot;n54&quot;&gt;54&lt;/a&gt;&lt;/span&gt;        verschwendet = (&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;len&lt;/span&gt;(md5_dic[entry]) -&lt;span style=&quot;color:#00D&quot;&gt;1&lt;/span&gt;) * md5_size[entry]
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n55&quot; name=&quot;n55&quot;&gt;55&lt;/a&gt;&lt;/span&gt;        sum = &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;sum&lt;/span&gt; + verschwendet
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n56&quot; name=&quot;n56&quot;&gt;56&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;print&lt;/span&gt; &lt;/span&gt;,50%,0.05)&amp;quot;&amp;gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8216;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt;Duplikate mit md5 %s verschwenden %s&lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8217;&lt;/span&gt;&lt;/span&gt; % (entry, size_fmt(verschwendet))
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n57&quot; name=&quot;n57&quot;&gt;57&lt;/a&gt;&lt;/span&gt;        &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;for&lt;/span&gt; &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt; &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;in&lt;/span&gt; md5_dic[entry]:
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n58&quot; name=&quot;n58&quot;&gt;58&lt;/a&gt;&lt;/span&gt;            &lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;print&lt;/span&gt; &lt;span style=&quot;background-color:hsla(0,100%,50%,0.05)&quot;&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8216;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt; * %s&lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8217;&lt;/span&gt;&lt;/span&gt; % &lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;file&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n59&quot; name=&quot;n59&quot;&gt;59&lt;/a&gt;&lt;/span&gt;
&lt;span class=&quot;line-numbers&quot;&gt;&lt;strong&gt;&lt;a href=&quot;#n60&quot; name=&quot;n60&quot;&gt;60&lt;/a&gt;&lt;/strong&gt;&lt;/span&gt;&lt;span style=&quot;color:#080;font-weight:bold&quot;&gt;print&lt;/span&gt; &lt;span style=&quot;background-color:hsla(0,100%,50%,0.05)&quot;&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8216;&lt;/span&gt;&lt;span style=&quot;color:#D20&quot;&gt;Insgesamt verschwendet: %s&lt;/span&gt;&lt;span style=&quot;color:#710&quot;&gt;&amp;#8217;&lt;/span&gt;&lt;/span&gt; % size_fmt(&lt;span style=&quot;color:#369;font-weight:bold&quot;&gt;sum&lt;/span&gt;)
&lt;span class=&quot;line-numbers&quot;&gt;&lt;a href=&quot;#n61&quot; name=&quot;n61&quot;&gt;61&lt;/a&gt;&lt;/span&gt;
&lt;/pre&gt;&lt;/div&gt;
&lt;/div&gt;
&lt;p&gt;Verwendung: &lt;code&gt;./duplicatefinder.py /home/someone/somedir&lt;/code&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;duplicatefinder.py&quot;&gt;Download&lt;/a&gt;&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Scam suspected sites</title>
    
    <link href="http://andreas.juch.cc/diverses/facebook-scams.en.html" rel="alternate" />
    <id>http://andreas.juch.cc/diverses/facebook-scams.en.html</id>
    <updated>2011-04-18T17:43:59Z</updated>
    
    <published>2011-03-15T16:15:38Z</published>
    
    <content type="html">&lt;p&gt;Pages that I would warn to open or click something at because they look like
scam.&lt;/p&gt;
&lt;h2&gt;fbliveonline.info&lt;/h2&gt;
&lt;p&gt;Domain: fbliveonline.info&lt;/p&gt;
&lt;p&gt;First seen: March 7 2011&lt;/p&gt;
&lt;p&gt;Posted text: &amp;#8220;New FB tool shows who stalks your profile&amp;#8221;&lt;/p&gt;
&lt;p&gt;Whois: &lt;pre&gt;Admin Name:Registration Private
Admin Organization:Domains by Proxy, Inc.
Admin Street1:DomainsByProxy.com
Admin Street2:15111 N. Hayden Rd., Ste 160, &lt;span class=&quot;caps&quot;&gt;PMB&lt;/span&gt; 353
Admin Street3:
Admin City:Scottsdale
Admin State/Province:Arizona
Admin Postal Code:85260
Admin Country:US
Admin Phone:&lt;ins&gt;1.4806242599
Admin Phone Ext.:
Admin &lt;span class=&quot;caps&quot;&gt;FAX&lt;/span&gt;:&lt;/ins&gt;1.4806242598
Admin &lt;span class=&quot;caps&quot;&gt;FAX&lt;/span&gt; Ext.:
Admin Email:&lt;span class=&quot;caps&quot;&gt;FBLIVEONLINE&lt;/span&gt;.INFO@domainsbyproxy.com
&lt;/pre&gt;&lt;/p&gt;
&lt;h2&gt;mileyy.info&lt;/h2&gt;
&lt;p&gt;Domain: mileyy.info&lt;/p&gt;
&lt;p&gt;First seen: March 14 2011&lt;/p&gt;
&lt;p&gt;Posted text: &amp;#8220;&lt;span class=&quot;caps&quot;&gt;SICK&lt;/span&gt;! I lost all respect for Miley Cyrus when I saw this video.&amp;#8221;&lt;/p&gt;
&lt;p&gt;Whois: Protected by whoisguard (!)&lt;/p&gt;
&lt;h2&gt;close*.info, go*.info&lt;/h2&gt;
&lt;p&gt;Domain:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;closetroll.info&lt;/li&gt;
	&lt;li&gt;closeheart.info&lt;/li&gt;
	&lt;li&gt;closewind.info&lt;/li&gt;
	&lt;li&gt;closeyork.info&lt;/li&gt;
	&lt;li&gt;closelove.info&lt;/li&gt;
	&lt;li&gt;closeking.info&lt;/li&gt;
	&lt;li&gt;gomolly.info&lt;/li&gt;
	&lt;li&gt;goyossi.info&lt;/li&gt;
	&lt;li&gt;gohiphop.info&lt;/li&gt;
	&lt;li&gt;gorima.info&lt;/li&gt;
	&lt;li&gt;fbholly.info&lt;/li&gt;
	&lt;li&gt;gojaniv.info&lt;/li&gt;
	&lt;li&gt;goshay.info&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;First seen: March 16 2011&lt;/p&gt;
&lt;p&gt;Posted text: &amp;#8220;I just saw my Top 3 Stalkers and how many times they viewed my
profile! Creepy, might have to remove some people.. click here to see yours&amp;#8221;&lt;/p&gt;
&lt;p&gt;Whois: &lt;pre&gt;Registrant Name:Yaniv Tal
Registrant Organization:
Registrant Street1:Arzei Halevanon 8 st.
Registrant Street2:
Registrant Street3:
Registrant City:Hadera
Registrant State/Province:IL
&lt;/pre&gt;
&lt;pre&gt;Tech ID:CR78626612
Tech Name:Yaniv Tal
Tech Organization:
Tech Street1:3539 &lt;span class=&quot;caps&quot;&gt;HAMMOCK&lt;/span&gt; ST
Tech Street2:
Tech Street3:
Tech City:&lt;span class=&quot;caps&quot;&gt;LAS&lt;/span&gt; &lt;span class=&quot;caps&quot;&gt;VEGA&lt;/span&gt;
Tech State/Province:Nevada
Tech Postal Code:89147
Tech Country:US
Tech Phone:&lt;ins&gt;1.7024159560
Tech Phone Ext.:
Tech &lt;span class=&quot;caps&quot;&gt;FAX&lt;/span&gt;:
Tech &lt;span class=&quot;caps&quot;&gt;FAX&lt;/span&gt; Ext.:
Tech Email:tzviplatinum@gmail.com
&lt;/pre&gt;
&lt;pre&gt;Tech ID:9f0249045508b22c
Tech Name:Mika  Greenstein II
Tech Organization:
Tech Street1:jersualem 16 st.
Tech Street2:
Tech Street3:
Tech City:Hadera
Tech State/Province:Alberta
Tech Postal Code:42312
Tech Country:TN
Tech Phone:&lt;/ins&gt;46.54645757
Tech Phone Ext.:
Tech &lt;span class=&quot;caps&quot;&gt;FAX&lt;/span&gt;:
Tech &lt;span class=&quot;caps&quot;&gt;FAX&lt;/span&gt; Ext.:
Tech Email:janiv20@gmail.com
&lt;/pre&gt;&lt;/p&gt;
&lt;h2&gt;heartsarebroken&lt;/h2&gt;
&lt;p&gt;Domain:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;http://apps.facebook.com/heartsarebroken/&lt;/li&gt;
	&lt;li&gt;http://apps.facebook.com/missingmygirl/&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;First seen: March 20, 2011&lt;/p&gt;
&lt;p&gt;Posted text: &amp;#8220;has spent [number] hours on facebook! See how many hours you&amp;#8217;ve spent at
http://apps.facebook.com/heartsarebroken/&amp;#8221;&lt;/p&gt;
&lt;h2&gt;Ich kann nicht glauben, wie viele Menschen haben mein Profil ange&lt;/h2&gt;
&lt;p&gt;Domain:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;http://goo.gl/RH1tl (http://gator1270.hostgator.com/~kitty/)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;First seen: April 09, 2011&lt;/p&gt;
&lt;p&gt;Posted text: &amp;#8220;Ich kann nicht glauben, wie viele Menschen haben mein Profil ange&amp;#8221;
&amp;#8220;Uberprufen Sie Ihre Profilaufrufe @ http://goo.gl/RH1tl&amp;#8221;&lt;/p&gt;
&lt;h2&gt;www.stayeran.info&lt;/h2&gt;
&lt;p&gt;Domain:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;http://www.stayeran.info&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Posted text: &amp;#8220;&lt;span class=&quot;caps&quot;&gt;DAMN&lt;/span&gt;: young babe from Austria &lt;span class=&quot;caps&quot;&gt;KILLED&lt;/span&gt; her self in front of cam -
Watch video here&amp;#8221;&lt;/p&gt;
&lt;p&gt;Whois:&lt;/p&gt;
&lt;pre&gt;Tech ID:CR80886766
Tech Name:John F Mackey
Tech Organization:
Tech Street1:Holberry street
Tech Street2:
Tech Street3:
Tech City:Holberry
Tech State/Province:Antwerpen
Tech Postal Code:12123
Tech Country:BE
Tech Phone:+31.2213123123
Tech Phone Ext.:
Tech FAX:
Tech FAX Ext.:
Tech Email:ipoli263@globalnet.hr&lt;/pre&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Various</title>
    
    <link href="http://andreas.juch.cc/diverses/index.en.html" rel="alternate" />
    <id>http://andreas.juch.cc/diverses/index.en.html</id>
    <updated>2011-03-15T16:15:38Z</updated>
    
    <published>2011-03-15T16:15:38Z</published>
    
    <content type="html">&lt;p&gt;Various topics.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Diverses</title>
    
    <link href="http://andreas.juch.cc/diverses/index.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/diverses/index.de.html</id>
    <updated>2011-03-15T16:15:38Z</updated>
    
    <published>2011-03-15T16:15:38Z</published>
    
    <content type="html">&lt;p&gt;Diverse Themen.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Simulator für Registermaschinen</title>
    
    <link href="http://andreas.juch.cc/software/registermaschinensimulator.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/software/registermaschinensimulator.de.html</id>
    <updated>2011-02-11T20:03:00Z</updated>
    
    <published>2009-03-22T00:18:54Z</published>
    
    <content type="html">&lt;p&gt;Den habe ich mal in den Ferien geschrieben als ich verschwendend viel Zeit
hatte. Besonders viel Zeit nahm das zwar nicht in Anspruch, aber egal :-) Unter
Windows gibt es glaube ich Probleme mit den Umlauten, aber im Grunde sollte das
Ding lauffähig sein. Wer damit herumspielen will: &lt;span class=&quot;caps&quot;&gt;GPL&lt;/span&gt;, aber nicht unbedingt
schön&amp;#8230; Beispiele sind dabei.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;rmsim.tar.gz&quot;&gt;Download&lt;/a&gt;&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Screenshots erstellen</title>
    
    <link href="http://andreas.juch.cc/hardware/android/screenshot.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/hardware/android/screenshot.de.html</id>
    <updated>2011-01-21T17:34:09Z</updated>
    
    <published>2011-01-21T17:31:41Z</published>
    
    <content type="html">&lt;h2&gt;Auf dem Telefon&lt;/h2&gt;
&lt;p&gt;Unter Einstellungen &amp;#8594; Anwendungen &amp;#8594; Entwicklung das &lt;span class=&quot;caps&quot;&gt;USB&lt;/span&gt;-Debugging aktivieren.&lt;/p&gt;
&lt;h2&gt;Auf dem PC&lt;/h2&gt;
&lt;p&gt;Ins Tools-Verzeichnis des Android &lt;span class=&quot;caps&quot;&gt;SDK&lt;/span&gt; wechseln:
&lt;pre&gt;$ cd tools&lt;/pre&gt;
Den adb-Server starten:
&lt;pre&gt;# ./adb start-server&lt;/pre&gt;
Den Davlik Debug Monitor starten:
&lt;pre&gt;$ ./ddms&lt;/pre&gt;
Danach kann man unter Device &amp;#8594; Screen Capture Screenshots machen und noch
andere lustige Sachen.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Android</title>
    
    <link href="http://andreas.juch.cc/hardware/android/index.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/hardware/android/index.de.html</id>
    <updated>2011-01-21T17:31:41Z</updated>
    
    <published>2011-01-21T17:31:41Z</published>
    
    <content type="html">&lt;p&gt;Verschiedene Tricks und Tipps zu Android.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Das Android SDK installieren</title>
    
    <link href="http://andreas.juch.cc/hardware/android/install-sdk.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/hardware/android/install-sdk.de.html</id>
    <updated>2011-01-21T17:31:41Z</updated>
    
    <published>2011-01-21T17:31:41Z</published>
    
    <content type="html">&lt;h2&gt;Installieren&lt;/h2&gt;
&lt;p&gt;Das &lt;span class=&quot;caps&quot;&gt;SDK&lt;/span&gt; &lt;a href=&quot;http://developer.android.com/sdk/index.html&quot;&gt;herunterladen&lt;/a&gt; und
entpacken.&lt;/p&gt;
&lt;h2&gt;Aktualisieren&lt;/h2&gt;
&lt;p&gt;Ins tools-Verzeichnis wechseln
&lt;pre&gt;$ cd tools&lt;/pre&gt;
Das android Programm starten
&lt;pre&gt;$ ./android&lt;/pre&gt;
Unter Installed packages den Update All Button drücken.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Gephi SCM Importer</title>
    
    <link href="http://andreas.juch.cc/software/gephi-scm-importer.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/software/gephi-scm-importer.de.html</id>
    <updated>2011-01-21T17:15:06Z</updated>
    
    <published>2011-01-21T17:15:06Z</published>
    
    <content type="html">&lt;p&gt;Ein Importer, der Metadaten aus Git Repositories in Gephi &lt;span class=&quot;caps&quot;&gt;GEXF&lt;/span&gt; Dateien
extrahiert. Damit kann man den Entwicklungsverlauf von Softwareprojekten
visualisieren.&lt;/p&gt;
&lt;p&gt;Der Sourcecode ist auf &lt;a href=&quot;https://github.com/ajuch/Gephi-SCM-data-importer&quot;&gt;Github&lt;/a&gt;
zu finden.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Debian-Tipps</title>
    
    <link href="http://andreas.juch.cc/linux/debian-tipps.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/linux/debian-tipps.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-06-01T20:54:41Z</published>
    
    <content type="html">&lt;h2&gt;Neue Keyboard Konfiguration mit X-Server 1.6.1&lt;/h2&gt;
&lt;p&gt;Seit Lenny hat sich einiges geändert: Die Tastatur wird nicht mehr über
&lt;code&gt;/etc/X11/xorg.conf&lt;/code&gt; konfiguriert. Die nächste Stelle war &lt;code&gt;/etc/hal/fdi/policy&lt;/code&gt;,
aber auch das ist Geschichte. Aktuell läuft das ganze über
&lt;code&gt;/etc/default/console-setup&lt;/code&gt;. Das gute ist, dass die Tastatur sowohl in Konsole
und auch in Xorg über eine gemeinsame Konfigurationsdatei gesteuert werden.
Diese Datei kann auch mit mehreren Layouts umgeben (die scheinbar in der Konsole
ignoriert werden). Bei mir sieht der signifikante Teil so aus:&lt;/p&gt;
&lt;pre&gt;# The following variables describe your keyboard and can have the same
# values as the XkbModel, XkbLayout, XkbVariant and XkbOptions options
# in /etc/X11/xorg.conf.
XKBMODEL=&quot;pc105&quot;
XKBLAYOUT=&quot;de,ru(phonetic)&quot;
XKBVARIANT=&quot;nodeadkeys&quot;
XKBOPTIONS=&quot;lv3:ralt_switch,grp:shifts_toggle&quot;&lt;/pre&gt;
&lt;h2&gt;Hardwareuhr als &lt;span class=&quot;caps&quot;&gt;UTC&lt;/span&gt;&lt;/h2&gt;
&lt;p&gt;Wenn die Hardwareuhr auf &lt;span class=&quot;caps&quot;&gt;UTC&lt;/span&gt; läuft und die Systemzeit immer beim booten falsch
gesetzt wird, muss man die Einstellung utc in &lt;code&gt;/etc/default/rcS&lt;/code&gt; auf yes setzen:&lt;/p&gt;
&lt;pre&gt;UTC=yes&lt;/pre&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Filesystem Defragmentierung</title>
    
    <link href="http://andreas.juch.cc/linux/filesystem-defrag.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/linux/filesystem-defrag.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-21T23:37:21Z</published>
    
    <content type="html">&lt;h2&gt;Ist Defragmentierung überhaupt notewendig?&lt;/h2&gt;
&lt;p&gt;Dateisysteme zu Defragmentieren ist vor allem unter Windows eine Notwendigkeit.
Ein frisch defragmentiertes Windows-Dateisystem ist nach der Installation eines
neuen Programms oder dem Kopieren von Dateien sofort wieder fragmentiert. Daran
hat sich seit &lt;acronym title=&quot;Disk Operating System&quot;&gt;&lt;span class=&quot;caps&quot;&gt;DOS&lt;/span&gt;&lt;/acronym&gt; nichts grundlegendes geändert.&lt;/p&gt;
&lt;p&gt;Die Linux-Dateisysteme (hier vor allem Ext3) sind einen Schritt weiter und
Dateien werden, sofern ihre Größe bekannt ist, so geschrieben, dass sie nicht
als Fragmente vorliegen. Dabei gibt es allerdings Einschränkungen: ist das
Dateisystem zu voll (manche sagen &amp;gt;80%, manche &amp;gt;90%), funktioniert dieses
System nicht mehr, da nicht genügend freie Blöcke vorhanden sind. Auch
Bittorrent Programme können, sofern Dateien nicht reserviert werden, zur
Fragmentierung bei. Einen guten
&lt;a href=&quot;http://www.heise.de/open/Das-Dateisystem-Ext3-tunen--/artikel/104859&quot;&gt;Artikel&lt;/a&gt;
dazu gibt es bei heise online. Kurz: manchmal muss auch Ext3 defragmentiert
werden. Dazu gibt es allerdings keine Software. e2defrag sollte besser nicht
benutzt werden (siehe Manpage).&lt;/p&gt;
&lt;h2&gt;Wie macht man das?&lt;/h2&gt;
&lt;p&gt;Am einfachsten ist es die Partition zu sichern, neu anzulegen und die Daten
zurückzukopieren. Bei normalen Datenpartitionen geht das mit tar (Dateirechte
mitsichern!). Für Systemplatten geht das mit cpio recht gut. Ich habe das auch
vor kurzem gemacht, hier steht wie:&lt;/p&gt;
&lt;p&gt;Den Rechner mit einer Live-CD booten, ich verwende die ausgezeichnete
&lt;a href=&quot;http://grml.org/&quot;&gt;grml&lt;/a&gt; 2008.11. Dateisysteme mounten (hier: Root-Dateisystem
nach /mnt/rootfs, Backup-Dateisystem nach /mnt/backup), mit cpio alle Dateien auf
eine externe Platte oder eine andere Partition sichern (dazu mehr).&lt;/p&gt;
&lt;p&gt;Wenn man &lt;span class=&quot;caps&quot;&gt;LVM&lt;/span&gt; verwendet, muss man das Volume mit den &lt;span class=&quot;caps&quot;&gt;LVM&lt;/span&gt; Tools verfügbar machen:&lt;/p&gt;
&lt;pre&gt;vgscan
vgchange&lt;/pre&gt;
&lt;p&gt;Bei Software-RAIDs wird mdadm benötigt:&lt;/p&gt;
&lt;pre&gt;mdadm --assemble /dev/mdX&lt;/pre&gt;
&lt;p&gt;Das Sichern:&lt;/p&gt;
&lt;pre&gt;cd /mnt/rootfs
find -xdev -print0 | cpio --create -0a --format=newc | gzip &amp;gt; /mnt/backup/file.gz
umount /mnt/rootfs&lt;/pre&gt;
&lt;p&gt;Dann mit mkfs.ext3 (entsprechend dem ursprünglichen Dateisystem) ein frisches
Dateisystem anlegen und die Daten zurückkopieren. Die Sicherung erst löschen,
wenn man sich von der erfolgreichen Rücksicherung überzeugt hat.&lt;/p&gt;
&lt;pre&gt;mkfs.ext3 /dev/sda5 /mnt/rootfs
mount /dev/sda5 /mnt/rootfs
cd /mnt/rootfs
zcat /mnt/backup/file.gz | cpio --extract -dm
&lt;/pre&gt;
&lt;p&gt;Natürlich alles unmounten, rebooten und schon sollte die Maschine schneller
starten.&lt;/p&gt;
&lt;h2&gt;Ext4&lt;/h2&gt;
&lt;p&gt;Bei Ext4 dürfte sich die Fragmentierung durch diverse Maßnahmen ziemlich in
Grenzen halten (außerdem soll es ja bald e4defrag geben). Ich habe seit
Erscheinen von Kernel 2.6.28 mein Home-Dateisystem auf Ext4 laufen und es
scheint wirklich nicht so leicht zu fragmentieren wie Ext3. Wenn die
Distributionen Ext4 als Standarddateisystem verwenden, ist es bestimmt eine
bessere Wahl als Ext3. Falls man sein Root-Dateisystem ebenfalls auf Ext4 legen
möchte, muss man allerdings
&amp;#8220;folgendes:&amp;#8221;http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=494922 beachten.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Firefox 3 SQLite Optimization</title>
    
    <link href="http://andreas.juch.cc/linux/firefox-sqlite.en.html" rel="alternate" />
    <id>http://andreas.juch.cc/linux/firefox-sqlite.en.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-23T00:29:25Z</published>
    
    <content type="html">&lt;p&gt;Because Firefox 3 uses SQLite databases for pretty much everything, optimizing
these databases can really speed up Firefox. On debian systems the
sqlite3-package must be installed to have the command line client for SQLite3
databases. Optimization is really simple:&lt;/p&gt;
&lt;pre&gt;cd .mozilla/firefox/[profile]
for i in *.sqlite; do sqlite3 $i &quot;VACUUM&quot; ; done&lt;/pre&gt;
&lt;p&gt;Of course Firefox should not be running while doing this, parallel access from
multiple processes on the same database is &lt;span class=&quot;caps&quot;&gt;AFAIK&lt;/span&gt; not possible with SQLite.&lt;/p&gt;
&lt;p&gt;Source: &lt;a href=&quot;http://www.gettingclever.com/2008/06/vacuum-your-firefox-3.html&quot;&gt;Vacuum your Firefox 3&lt;/a&gt;&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Tipps und Tricks</title>
    
    <link href="http://andreas.juch.cc/linux/tipps-und-tricks.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/linux/tipps-und-tricks.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-21T23:37:21Z</published>
    
    <content type="html">&lt;h2&gt;Bash History durchsuchen&lt;/h2&gt;
&lt;p&gt;Wenn man häufig längere Befehle eintippt, kann man sich mit der Suche in der
Bash History etwas Zeit sparen. Es reicht den Anfang des Befehls einzugeben und
mit den Bild-auf- und Bild-ab-Tasten den entsprechenden Befehl zu suchen.
Aktiviert wird das ganze in /etc/inputrc:&lt;/p&gt;
&lt;pre&gt;# alternate mappings for &quot;page up&quot; and &quot;page down&quot; to search the history
&quot;\e[5~&quot;: history-search-backward
&quot;\e[6~&quot;: history-search-forward&lt;/pre&gt;
&lt;h2&gt;Dateien nach Schema umbenennen&lt;/h2&gt;
&lt;p&gt;Mit dem rename Kommando kann man auch normales Grouping wie bei Perl-REs
verwenden. Um Blabla.S00E00Blubb.txt in S00E00.txt umzubenennen, hilft
folgendes Kommando:&lt;/p&gt;
&lt;pre&gt;rename 's/.*(S[0-9]{2}E[0-9]{2}).*(\.[a-z]+$)/$1$2/' *&lt;/pre&gt;
&lt;p&gt;Die geklammerten Teile sind als $1, $2, &amp;#8230; ansprechbar.&lt;/p&gt;
&lt;h2&gt;Inhalt in mehreren Dateien ersetzen&lt;/h2&gt;
&lt;p&gt;Mit sed kann man in mehreren Dateien automatisch Ersetzungen durchführen.
Zuerst testet man das ganze mit:&lt;/p&gt;
&lt;pre&gt;sed 's/Suchstring/Ersetzung/' `find . -name &quot;*.html&quot;`&lt;/pre&gt;
&lt;p&gt;Die richtige Ersetzung kann man dann mit dem Parameter i durchführen:&lt;/p&gt;
&lt;pre&gt;sed -i 's/Suchstring/Ersetzung/' `find . -name &quot;*.html&quot;`&lt;/pre&gt;
&lt;h2&gt;DG965WH sound side Kanal bei Kernel &amp;gt;= 2.6.30&lt;/h2&gt;
&lt;p&gt;Der Headphone Kanal wurde geändert, leider funktioniert der side-Kanal dadurch
nicht mehr (&lt;a href=&quot;http://bugzilla.kernel.org/show_bug.cgi?id=13250&quot;&gt;Bugreport&lt;/a&gt;). Mit
folgenden Kommandos lässt sich das alte Verhalten bei mir wiederherstellen:&lt;/p&gt;
&lt;pre&gt;echo 0x0a 0x40000100 &amp;gt; /sys/class/sound/hwC0D2/user_pin_configs
echo 1 &amp;gt; /sys/class/sound/hwC0D2/reconfig&lt;/pre&gt;
&lt;h2&gt;window-class-string herausfinden&lt;/h2&gt;
&lt;p&gt;Den window-class-string benötigt man etwa für die automatische Positionierung
von Fenstern im window manager awesome.&lt;/p&gt;
&lt;pre&gt;xprop | grep -i WM_CLASS&lt;/pre&gt;
&lt;h2&gt;MP3 Dateien in &lt;span class=&quot;caps&quot;&gt;OGG&lt;/span&gt;/Vorbis umkodieren&lt;/h2&gt;
&lt;pre&gt;for file in *.mp3; do mpg321 -w - &quot;$file&quot; | oggenc -o &quot;$file.ogg&quot; - ; done&lt;/pre&gt;
&lt;h2&gt;&lt;span class=&quot;caps&quot;&gt;DVB&lt;/span&gt; Datum übernehmen&lt;/h2&gt;
&lt;p&gt;Man muss entweder mit zap oder einem anderen &lt;span class=&quot;caps&quot;&gt;DVB&lt;/span&gt; Programm einen Sender
eingestellt haben, von dem dann die Zeit übernommen wird. Erklärung zur TZ
Umgebungvariable:
&lt;a href=&quot;http://www.gnu.org/s/libc/manual/html_node/TZ-Variable.html&quot;&gt;&lt;span class=&quot;caps&quot;&gt;GLIBC&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;
&lt;pre&gt;TZ=UTC dvbdate --set&lt;/pre&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Firefox 3 SQLite Optimierung</title>
    
    <link href="http://andreas.juch.cc/linux/firefox-sqlite.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/linux/firefox-sqlite.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-21T23:37:21Z</published>
    
    <content type="html">&lt;p&gt;Da der Firefox 3 SQLite Datenbanken für so ziemlich alles verwendet, bringt es
durchaus Performancevorteile wenn man die zwischendurch optimiert. Unter Debian
muss man dafür das sqlite3-Paket installiert haben, den Kommandozeilenclient
für SQLite Datenbanken. Das Optimieren ist ganz einfach:&lt;/p&gt;
&lt;pre&gt;cd .mozilla/firefox/[Profilkennung]
for i in *.sqlite; do sqlite3 $i &quot;VACUUM&quot; ; done&lt;/pre&gt;
&lt;p&gt;Natürlich sollte der Firefox nicht laufen, wenn man das macht, der parallele
Zugriff von mehreren Prozessen auf die selbe Datenbank ist soweit ich weiß in
SQLite nicht möglich.&lt;/p&gt;
&lt;p&gt;Quelle: &lt;a href=&quot;http://www.gettingclever.com/2008/06/vacuum-your-firefox-3.html&quot;&gt;Vacuum your Firefox 3&lt;/a&gt;&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Postfix mit Tele2</title>
    
    <link href="http://andreas.juch.cc/linux/tele2-postfix.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/linux/tele2-postfix.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-21T23:37:21Z</published>
    
    <content type="html">&lt;p&gt;Um Emails von Postfix über den Tele2 &lt;span class=&quot;caps&quot;&gt;SMTP&lt;/span&gt; Server zu versenden benötigt man
einige Einstellungen. Zunächst muss man in der main.cf die &lt;span class=&quot;caps&quot;&gt;SASL&lt;/span&gt;
Authentifizierung aktivieren:&lt;/p&gt;
&lt;pre&gt;smtp_sasl_auth_enable = yes
smtp_sasl_type = cyrus
smtp_sasl_password_maps = hash:/etc/postfix/sasl/sasl_password
smtp_sasl_security_options = noanonymous&lt;/pre&gt;
&lt;p&gt;Außerdem muss man den Relayhost konfigurieren:&lt;/p&gt;
&lt;pre&gt;relayhost = [smtp.tele2.at]:587&lt;/pre&gt;
&lt;p&gt;Benutzername und Passwort müssen in der oben konfigurierten Datei stehen
(/etc/postfix/sasl/sasl_password):&lt;/p&gt;
&lt;pre&gt;[smtp.tele2.at]:587 username:password&lt;/pre&gt;
&lt;p&gt;Mit dem Befehl postmap muss die Datei in eine Postfix-Hash-Datei umgewandelt
werden, dann sollte alles funktionieren.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Entfernter Zugriff</title>
    
    <link href="http://andreas.juch.cc/linux/entfernter_zugriff.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/linux/entfernter_zugriff.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-21T23:37:21Z</published>
    
    <content type="html">&lt;p&gt;Manchmal möchte man einfach Zugriff auf seine Daten vom Internet aus haben.
Natürlich möchte man Angreifer aussperren. &lt;acronym title=&quot;Secure Shell&quot;&gt;&lt;span class=&quot;caps&quot;&gt;SSH&lt;/span&gt;&lt;/acronym&gt; bietet sehr viele
Möglichkeiten dies zu erreichen. Mit diesen einfachen Tricks kann man entfernte
Logins ziemlich stark absichern, man sollte aber trotzdem noch die Logdateien
im Auge behalten.&lt;/p&gt;
&lt;h2&gt;Anderer Port&lt;/h2&gt;
&lt;p&gt;&lt;span class=&quot;caps&quot;&gt;SSH&lt;/span&gt; sollte auf einem anderen Port laufen. In der sshd-Konfigurationsdatei
sollte man daher den Parameter Port ändern:&lt;/p&gt;
&lt;pre&gt;Port 1234&lt;/pre&gt;
&lt;p&gt;Dies sperrt die meisten Script-Kiddies aus, die nur nach Rechnern mit offenem
Port 22 suchen. Wenn jemand den &lt;span class=&quot;caps&quot;&gt;SSH&lt;/span&gt; Port herausfinden möchte ist dies zwar
möglich, aber mit etwas Anstrengung verbunden.&lt;/p&gt;
&lt;h2&gt;root-Logins verbieten&lt;/h2&gt;
&lt;p&gt;Das Einloggen des Root-Benutzers sollte man auf jeden Fall verbieten. Das
bedeutet für den Angreifer, dass er nicht nur ein Passwort erraten muss,
sondern auch noch einen gültigen Benutzeraccount kennen/erraten muss. Im
übrigen hat der Angreifer keinen Anhaltspunkt ob er sich überhaupt als Root
einloggen darf:&lt;/p&gt;
&lt;pre&gt;$ ssh root@server
Password:
Password:
Password:
Permission denied (publickey,keyboard-interactive).
$ ssh user@server
Password:
Password:
Password:
Permission denied (publickey,keyboard-interactive).&lt;/pre&gt;
&lt;p&gt;Root darf sich nicht anmelden, user schon. Die Prozedur ist jedoch bei beiden
gleich. Diese Einstellung nimmt man wie folgt vor:&lt;/p&gt;
&lt;pre&gt;PermitRootLogin no&lt;/pre&gt;
&lt;h2&gt;Anderes&lt;/h2&gt;
&lt;p&gt;Man sollte leere Passwörter verbieten (meist Standard):&lt;/p&gt;
&lt;pre&gt;PermitEmptyPasswords no&lt;/pre&gt;
&lt;p&gt;Man könnte auch die Passwortauthentifizierung abschalten und nur noch das
Einloggen über &lt;span class=&quot;caps&quot;&gt;PKI&lt;/span&gt; erlauben.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Linksys WRT54GL</title>
    
    <link href="http://andreas.juch.cc/hardware/linksys_wrt54gl.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/hardware/linksys_wrt54gl.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-06-19T18:57:29Z</published>
    
    <content type="html">&lt;p&gt;Der WRT54GL ist wirklich sehr empfehlenswert. Nachdem ich mich früher mit einem
D-Link Router prügeln musste um ungefähr die Funktionalität zu bekommen die ich
möchte, ist der Linksys mit alternativer Firmware wirklich ein Hammer. Anfangs
verwendete ich DD-&lt;span class=&quot;caps&quot;&gt;WRT&lt;/span&gt;, da es relativ einfach zu bedienen ist und man es über die
Firmwareupdate Funktion installieren kann. Mittlerweile bin ich begeisterter
OpenWRT-User. OpenWRT wird hauptsächlich mittels &lt;span class=&quot;caps&quot;&gt;SSH&lt;/span&gt;-Zugang konfiguriert, davon
darf man sich nicht abschrecken lassen. Das beste Feature ist aber der
beschreibbare Flash-Speicher durch den man Software-Pakete wie in einer normalen
Linux-Distribution installieren kann. Trotz des geringen Speichers (1,7MiB) kann
man da sehr viel Software installieren. Für mich jedenfalls die bestmögliche
Lösung für einen Router.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Hardware</title>
    
    <link href="http://andreas.juch.cc/hardware/index.en.html" rel="alternate" />
    <id>http://andreas.juch.cc/hardware/index.en.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-06-19T19:20:59Z</published>
    
    <content type="html">&lt;p&gt;Various stuff about hardware I own or with which I made good or bad experiences.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Letzte Änderungen</title>
    
    <link href="http://andreas.juch.cc/changelog.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/changelog.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-09-11T14:05:59Z</published>
    
    <content type="html">&lt;pre&gt;commit 22029b2ace0a929655143116492eb8a23ede90f6
Author: Andreas Juch &amp;lt;andreas.juch@gmail.com&amp;gt;
Date:   Mon May 7 14:11:40 2012 +0200

    Add link to SSL site.

 1 file changed, 1 insertion(+)

commit 3fed69e2c049420baf695b69eb44a866a4fa270a
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Thu Apr 12 14:39:08 2012 +0200

    remove piwik code

 1 file changed, 12 deletions(-)

commit 02982b73e32c12a8d8d892f258dda42c233f201d
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Fri Mar 9 20:07:45 2012 +0100

    forgot magic variables

 1 file changed, 4 insertions(+), 1 deletion(-)

commit 06591e01f77512bf9c02e9100fafda269a28384a
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Fri Mar 9 19:58:33 2012 +0100

    add java tip about equals() and hashCode()

 2 files changed, 109 insertions(+)

commit c28e24b0f70f19472a57af8e57a674d1f1e50c6c
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Thu Jan 12 16:40:03 2012 +0100

    update impressum

 1 file changed, 2 insertions(+), 2 deletions(-)

commit dcf71a3db27a1546fb91c0146bd01dee7629536d
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Thu Jan 12 16:12:56 2012 +0100

    use zsh

 1 file changed, 1 insertion(+), 1 deletion(-)

commit caa9d59dd6f957441796c92f49063da7d910573a
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Thu Jan 12 16:07:10 2012 +0100

    change to domainfactory

 1 file changed, 1 insertion(+), 2 deletions(-)

commit 239e4398d334d78af6a0023260ad605a5469c8f7
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Thu Jan 12 15:43:49 2012 +0100

    yui-compressor doesn't work atm

 1 file changed, 2 insertions(+), 2 deletions(-)

commit e85882c9e3f1ee896d814a08e113251c166d1aec
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Sat Jul 9 13:31:56 2011 +0200

    use coderay to render python

 1 file changed, 3 insertions(+), 2 deletions(-)

commit 3c23b8bd703292065466fe73f3f171de96d229c0
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Mon Apr 18 19:43:59 2011 +0200

    stayeran.info

 1 file changed, 27 insertions(+)
&lt;/pre&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Recent Changes</title>
    
    <link href="http://andreas.juch.cc/changelog.en.html" rel="alternate" />
    <id>http://andreas.juch.cc/changelog.en.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-09-11T14:05:59Z</published>
    
    <content type="html">&lt;pre&gt;commit 22029b2ace0a929655143116492eb8a23ede90f6
Author: Andreas Juch &amp;lt;andreas.juch@gmail.com&amp;gt;
Date:   Mon May 7 14:11:40 2012 +0200

    Add link to SSL site.

 1 file changed, 1 insertion(+)

commit 3fed69e2c049420baf695b69eb44a866a4fa270a
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Thu Apr 12 14:39:08 2012 +0200

    remove piwik code

 1 file changed, 12 deletions(-)

commit 02982b73e32c12a8d8d892f258dda42c233f201d
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Fri Mar 9 20:07:45 2012 +0100

    forgot magic variables

 1 file changed, 4 insertions(+), 1 deletion(-)

commit 06591e01f77512bf9c02e9100fafda269a28384a
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Fri Mar 9 19:58:33 2012 +0100

    add java tip about equals() and hashCode()

 2 files changed, 109 insertions(+)

commit c28e24b0f70f19472a57af8e57a674d1f1e50c6c
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Thu Jan 12 16:40:03 2012 +0100

    update impressum

 1 file changed, 2 insertions(+), 2 deletions(-)

commit dcf71a3db27a1546fb91c0146bd01dee7629536d
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Thu Jan 12 16:12:56 2012 +0100

    use zsh

 1 file changed, 1 insertion(+), 1 deletion(-)

commit caa9d59dd6f957441796c92f49063da7d910573a
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Thu Jan 12 16:07:10 2012 +0100

    change to domainfactory

 1 file changed, 1 insertion(+), 2 deletions(-)

commit 239e4398d334d78af6a0023260ad605a5469c8f7
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Thu Jan 12 15:43:49 2012 +0100

    yui-compressor doesn't work atm

 1 file changed, 2 insertions(+), 2 deletions(-)

commit e85882c9e3f1ee896d814a08e113251c166d1aec
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Sat Jul 9 13:31:56 2011 +0200

    use coderay to render python

 1 file changed, 3 insertions(+), 2 deletions(-)

commit 3c23b8bd703292065466fe73f3f171de96d229c0
Author: Andreas Juch &amp;lt;andreas@juch.cc&amp;gt;
Date:   Mon Apr 18 19:43:59 2011 +0200

    stayeran.info

 1 file changed, 27 insertions(+)
&lt;/pre&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Linux</title>
    
    <link href="http://andreas.juch.cc/linux/index.en.html" rel="alternate" />
    <id>http://andreas.juch.cc/linux/index.en.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-04-13T13:33:10Z</published>
    
    <content type="html">&lt;p&gt;Here you can find some texts and tutorials on linux-related topics.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Software</title>
    
    <link href="http://andreas.juch.cc/software/index.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/software/index.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-21T23:47:08Z</published>
    
    <content type="html">&lt;p&gt;Texte über verschiedene Anwendungsprogramme und von mir geschriebene Programme.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Energieeffizienz bei Computern</title>
    
    <link href="http://andreas.juch.cc/hardware/energieeffizienz.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/hardware/energieeffizienz.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-22T20:33:04Z</published>
    
    <content type="html">&lt;p&gt;Wie baut man einen stromsparenden PC? So einfach ist es leider momentan nicht,
aber ich möchte hier ein paar Tipps geben, wie man einiges sparen kann.&lt;/p&gt;
&lt;p&gt;Das &lt;a href=&quot;http://www.80plus.org/&quot;&gt;80-Plus Siegel&lt;/a&gt; bei Netzteilen gibt Auskunft über
die Effizienz des Netzteils. Bei der Umwandlung von 220V Netzspannung auf 12, 5
und 3,5V, die der Computer braucht, verpufft eine Menge Energie als Wärme. Bei
den 80+ Netzteilen ist sichergestellt, dass in einem Leistungsspektrum von
20-100% der Nennleistung nur maximal 20% der Energie als Wärme abgegeben
werden. Wichtig ist es auch, ein Netzteil zu kaufen, dass zur Energieaufnahme
des PCs passt, da die Netzteile bei ca. 50% Auslastung am effizientesten
arbeiten. Das ist leider gar nicht so leicht. Wenn der PC zwischen 60 und 100W
verbraucht wie mein Core2 System, ist es scheinbar nicht möglich ein passendes
&lt;span class=&quot;caps&quot;&gt;ATX&lt;/span&gt; Netzteil zu erwerben.  Die Industrie rennt momentan einem Watt-Wahnsinn
hinterher. Bei Alternate sind Netzteile in die Kategorien &amp;#8220;bis 400 Watt&amp;#8221;, &amp;#8220;bis
600 Watt&amp;#8221; und &amp;#8220;über 600 Watt&amp;#8221; eingeteilt. Teilweise sind Netzteile mit über
1000W (!!!) erhältlich, eine wahnsinnige Verschwendung von Ressourcen! Ich
werde einmal beginnen Hersteller zu fragen warum es keine 80+ Netzteile mit
200W (reicht für meinen Core 2 Duo E6600, Intel Mainboard mit integrierter
Graphik und 2 Festplatten locker!) im Angebot gibt. Möglicherweise tut sich ja
etwas wenn das andere auch machen&amp;#8230;&lt;/p&gt;
&lt;p&gt;Jeder, der nicht die neuesten Computerspiele spielen will, sondern zu der
aussterbenden Sorte der PC-Benutzer gehört, die mit ihrem Computer noch
arbeiten wollen, sollte sich ein Mainboard mit integriertem Graphikchipsatz
kaufen. Ich persönlich finde die Intel Graphikchipsätze (z.B. X3000) sehr gut.
Sie reichen für ältere Spiele (etwa von der Kategorie &lt;span class=&quot;caps&quot;&gt;GTA&lt;/span&gt; San Andreas, mit
reduzierten Graphikeinstellungen) und zum Arbeiten sowieso. Neuere NVidia
Karten schlucken bis zu 185W&amp;#8230; In meinen Augen eine völlige Verschwendung&amp;#8230;&lt;/p&gt;
&lt;p&gt;Neue CPUs von Intel der Core 2 Duo Serie sind stark auf Energieeffizienz
getrimmt worden. Bei &lt;span class=&quot;caps&quot;&gt;AMD&lt;/span&gt; würde ich auf die EE-Modelle zurückgreifen. Die
Watt-Zahlen der Hersteller sind allerdings unterschiedlich. Intels &lt;span class=&quot;caps&quot;&gt;TDP&lt;/span&gt; Werte
sind meines Wissens nach nur Werte für die Verlustleistung während &lt;span class=&quot;caps&quot;&gt;AMD&lt;/span&gt; die
Gesamtleistung angibt.&lt;/p&gt;
&lt;p&gt;Besser eine große Festplatte als 2 kleine. Spart Strom und schont die Ohren.
Datensicherungen sollte man aber in jedem Fall nicht vergessen!&lt;/p&gt;
&lt;p&gt;Mein Ziel ist ein 45W Server und ein 50W Desktop. Hoffentlich erreiche ich das
irgendwann. Nur schläft die Industrie momentan ziemlich. Vor allem fehlende
schwächere aber effiziente Netzteile (bis 200W) sind de facto nicht erhältlich.
Wenn jemand mehr Infos als ich hat: bitte Kommentar posten!&lt;/p&gt;
&lt;p&gt;Auch interessant: http://www.lesswatts.org, Energie sparen mit Linux.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Hardware</title>
    
    <link href="http://andreas.juch.cc/hardware/index.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/hardware/index.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-21T23:37:21Z</published>
    
    <content type="html">&lt;p&gt;Verschiedene Inhalte über Hardware die ich besitze oder mit der ich positive
oder negative Erfahrungen gemacht habe.&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Alcatel SpeedTouch Modem</title>
    
    <link href="http://andreas.juch.cc/hardware/alcatel_speedtouch.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/hardware/alcatel_speedtouch.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-21T23:37:21Z</published>
    
    <content type="html">&lt;p&gt;Mittlerweile habe ich keinen TA Internetzugang mehr, diese Notizen lasse ich
aber noch da, falls sie jemandem nützlich sind.&lt;/p&gt;
&lt;p&gt;Das Alcatel SpeedTouch Modem wird Österreich-spezifisch über &lt;acronym title=&quot;Point-To-Point Tunneling Protocol&quot;&gt;&lt;span class=&quot;caps&quot;&gt;PPTP&lt;/span&gt;&lt;/acronym&gt; angesprochen. Dies ist meines Wissens nach
(fast) weltweit einzigartig. Die Konfiguration unter Debian ist deshalb etwas
&amp;#8220;fummelig&amp;#8221;. Ausserdem muss man bei der Debian Netzwerkinstallations CD das
pptp-linux Paket per &lt;span class=&quot;caps&quot;&gt;USB&lt;/span&gt;-Stick installieren (aus dem Internet herunterladen ist
ja etwas schwierig, wenn man das Modem nicht zum Laufen bewegen kann). Hier
geht es nur um die Ethernet-Version!&lt;/p&gt;
&lt;h2&gt;Installation der benötigten Pakete&lt;/h2&gt;
&lt;p&gt;Mit der Debian Paketverwaltung müssen folgende Pakete installiert werden:&lt;/p&gt;
&lt;ul&gt;
	&lt;li&gt;ppp&lt;/li&gt;
	&lt;li&gt;pptp-linux&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Konfiguration (Aon)&lt;/h2&gt;
&lt;p&gt;Entspricht auch der Konfiguration von &lt;span class=&quot;caps&quot;&gt;UTA&lt;/span&gt; &lt;span class=&quot;caps&quot;&gt;ADSL&lt;/span&gt; (hatte ich vorher).&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Peer Konfiguration&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;Die Datei /etc/ppp/peers/aon enthält die providerspezifische Konfiguration. Die
zweite Zeile bindet das pptp Programm ein, das die Datenübertragung übernimmt:&lt;/p&gt;
&lt;pre&gt;user 0000000000000000
pty &quot;/usr/sbin/pptp 10.0.0.138 --nolaunchpppd&quot;
noipdefault
defaultroute
hide-password
usepeerdns
lcp-echo-interval 20
lcp-echo-failure 3
connect /bin/true
noauth
persist
mtu 1492&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;Passwortdatei&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;In /etc/ppp/pap-secrets werden die Benutzernamen und Passwörter für die
&lt;span class=&quot;caps&quot;&gt;PAP&lt;/span&gt;-Authentifizierung gespeichert:&lt;/p&gt;
&lt;pre&gt;...
00000000000000 * passwort&lt;/pre&gt;
&lt;p&gt;&lt;strong&gt;Interfaces&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;In der Datei /etc/network/interfaces ist die Konfiguration der
Netzwerkschnittstellen zu ändern. Zunächst einmal muss die Netzwerkkarte mit
der das Modem verbunden ist konfiguriert werden:&lt;/p&gt;
&lt;pre&gt;auto eth1
iface eth1 inet static
address 10.0.0.1
netmask 255.255.255.0&lt;/pre&gt;
&lt;p&gt;Dann kann die Internetverbindung konfiguriert werden:&lt;/p&gt;
&lt;pre&gt;auto ppp0
iface ppp0 inet ppp
provider aon&lt;/pre&gt;
&lt;h2&gt;Auf- und Abbauen von Verbindungen&lt;/h2&gt;
&lt;p&gt;Die Verbindung aufbauen:&lt;/p&gt;
&lt;pre&gt;$ ifup ppp0&lt;/pre&gt;
&lt;p&gt;Eigentlich sollte das &amp;#8220;auto&amp;#8221; in der Datei /etc/network/interfaces das
automatische Aufbauen der Verbindung beim Systemstart bewirken.&lt;/p&gt;
&lt;p&gt;Die Verbindung beenden:&lt;/p&gt;
&lt;pre&gt;$ ifdown ppp0&lt;/pre&gt;
&lt;p&gt;Wenn die Verbindung vom Provider zwangsgetrennt wird (bei mir ca. alle 8
Stunden), kann es sein, dass das Programm pptp abstürzt. Das muss gekillt
werden bevor man die Verbindung wieder ab- und aufbauen kann! Bei sieht die
typische Befehlsfolge für diesen Fall so aus:&lt;/p&gt;
&lt;pre&gt;$ ifconfig
$ ifdown ppp0
$ ps -A | grep pp
$ killall -9 pptp
$ ifup ppp0
$ ifconfig&lt;/pre&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Openmoko Freerunner</title>
    
    <link href="http://andreas.juch.cc/hardware/openmoko-freerunner.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/hardware/openmoko-freerunner.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-06-27T22:46:53Z</published>
    
    <content type="html">&lt;h2&gt;Lange Wartezeit auf &lt;span class=&quot;caps&quot;&gt;GPS&lt;/span&gt; Fix&lt;/h2&gt;
&lt;p&gt;Manchmal ist die Lösung so einfach: Den Freerunner vertikal halten (vertikal im
Vergleich zu horizontal auf dem Tisch liegend). Die Antenne ist in der Oberseite
des Gerätes. Wenn ich das Gerät richtig halte, ist die Zeit bis zum ersten &lt;span class=&quot;caps&quot;&gt;GPS&lt;/span&gt;
Fix im Vergleich zur horizontalen Position wirklich sehr niedrig (1-2 Minuten im
Vergleich zu 5-10 Minuten).&lt;/p&gt;</content>
  </entry>
  
  <entry>
    <title type="html">Kodak EasyShare C713</title>
    
    <link href="http://andreas.juch.cc/hardware/kodak_easyshare_c713.de.html" rel="alternate" />
    <id>http://andreas.juch.cc/hardware/kodak_easyshare_c713.de.html</id>
    <updated>2011-01-21T17:00:17Z</updated>
    
    <published>2009-03-21T23:37:21Z</published>
    
    <content type="html">&lt;p&gt;Die Anschaffung einer Digitalkamera stand ja schon länger mal auf dem Programm.
Aber jetzt hat die Kodak das Rennen gemacht. Für 100€ + 10€ für die
Speicherkarte eigentlich eine gute Investition. Wenn das Licht stimmt, werden
die Fotos normalerweise recht gut. Die Kamera läuft auch Plug &amp;amp; Play unter
Linux (&lt;acronym title=&quot;Picture Transfer Protocol&quot;&gt;&lt;span class=&quot;caps&quot;&gt;PTP&lt;/span&gt;&lt;/acronym&gt;).&lt;/p&gt;</content>
  </entry>
  
</feed>
