<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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/" version="2.0">

<channel>
	<title>dev-eth0.de</title>
	
	<link>http://www.dev-eth0.de</link>
	<description>Zu viele Lösungen für zu wenig Probleme...</description>
	<lastBuildDate>Sat, 18 Feb 2012 09:30:12 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
<xhtml:meta xmlns:xhtml="http://www.w3.org/1999/xhtml" name="robots" content="noindex" />
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/dev-eth0de" /><feedburner:info xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" uri="dev-eth0de" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>ApkCreationException: Debug Certificate expired</title>
		<link>http://www.dev-eth0.de/apkcreationexception-debug-certificate-expired/</link>
		<comments>http://www.dev-eth0.de/apkcreationexception-debug-certificate-expired/#comments</comments>
		<pubDate>Sat, 18 Feb 2012 09:30:12 +0000</pubDate>
		<dc:creator>dev-eth0</dc:creator>
				<category><![CDATA[Android]]></category>

		<guid isPermaLink="false">http://www.dev-eth0.de/?p=1520</guid>
		<description><![CDATA[Sometimes, you get a ApkCreationException when you try to build your Android Project. This Exception is produced by a expired Debug Certificate, which is created while the first build with a new installed Android SDK and which expires after 1 year.
To force the Android-SDK to create a new Debug Certificate, you have to delete ...]]></description>
			<content:encoded><![CDATA[<p>Sometimes, you get a ApkCreationException when you try to build your Android Project. This Exception is produced by a expired Debug Certificate, which is created while the first build with a new installed Android SDK and which expires after 1 year.<br />
To force the Android-SDK to create a new Debug Certificate, you have to delete the old certificate (debug.keystore).<br />
It can be found at the following locations:</p>
<pre><strong>Windows XP:</strong>
 C:\Documents and Settings\.android\
<strong>Windows 7:</strong>
 C:\Users\.android\
<strong>OS X and Linux:</strong>
 ~/.android</pre>
<p class="wp-flattr-button"></p> <p><a href="http://www.dev-eth0.de/?flattrss_redirect&amp;id=1520&amp;md5=b35143e86be22c2f3e617dde9b9d6b1e" title="Flattr" target="_blank"><img src="http://www.dev-eth0.de/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p><img src="http://feeds.feedburner.com/~r/dev-eth0de/~4/z1CAbcMacYo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.dev-eth0.de/apkcreationexception-debug-certificate-expired/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>TOR on OpenSolaris</title>
		<link>http://www.dev-eth0.de/tor-on-opensolaris/</link>
		<comments>http://www.dev-eth0.de/tor-on-opensolaris/#comments</comments>
		<pubDate>Mon, 06 Feb 2012 00:34:17 +0000</pubDate>
		<dc:creator>dev-eth0</dc:creator>
				<category><![CDATA[(Open)Solaris]]></category>
		<category><![CDATA[Homeserver]]></category>
		<category><![CDATA[Solaris Server]]></category>
		<category><![CDATA[HowTos]]></category>
		<category><![CDATA[OpenIndiana]]></category>
		<category><![CDATA[OpenSolaris]]></category>

		<guid isPermaLink="false">http://www.dev-eth0.de/?p=1506</guid>
		<description><![CDATA[As the currently available OpenSolaris packages of TOR are outdated, I compiled the sources and documented what to do.
Basic installation
First we need to install some packages which are required to download and compile TOR:



The next step is to create a user for TOR (we don't want to run it as root).



Then we need to download ...]]></description>
			<content:encoded><![CDATA[<p>As the currently available OpenSolaris packages of <a href="https://www.torproject.org/">TOR</a> are outdated, I compiled the sources and documented what to do.</p>
<h4>Basic installation</h4>
<p>First we need to install some packages which are required to download and compile TOR:</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~#  pkg install wget gcc-43 system/library/math/header-math libevent
               Packages to install:    18
           Create boot environment:    No
DOWNLOAD                                  PKGS       FILES    XFER (MB)
Completed                                18/18   3066/3066    70.7/70.7

PHASE                                        ACTIONS
Install Phase                              4013/4013

PHASE                                          ITEMS
Package State Update Phase                     18/18
Image State Update Phase                         2/2

root@test:~# PATH=$PATH:/usr/gcc/4.3/bin
</pre>
<p>The next step is to create a user for TOR (we don&#8217;t want to run it as root).</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# mkdir -p /export/home
root@test:~# useradd -d /export/home/tor -s /usr/bin/false -m tor
</pre>
<p>Then we need to download and unpack the current TOR version from <a href="https://www.torproject.org/download/download.html.en">https://www.torproject.org/download/download.html.en</a>.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# wget https://www.torproject.org/dist/tor-0.2.2.35.tar.gz
--2012-02-06 00:46:36--  https://www.torproject.org/dist/tor-0.2.2.35.tar.gz
Resolving www.torproject.org (www.torproject.org)... 86.59.30.36, 38.229.72.14, 38.229.72.16
Connecting to www.torproject.org (www.torproject.org)|86.59.30.36|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 2787536 (2.7M) [application/x-gzip]
Saving to: `tor-0.2.2.35.tar.gz'

100%[==============================================&gt;] 2,787,536   2.20M/s   in 1.2s

2012-02-06 00:46:56 (224 KB/s) - `tor-0.2.2.35.tar.gz' saved [2787536/2787536]

root@test:~# tar xf tor-0.2.2.35.tar.gz
root@test:~# cd tor-0.2.2.35
root@test:~/tor-0.2.2.35#
</pre>
<p>Now we can configure and build tor.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~/tor-0.2.2.35# ./configure --prefix=/opt/tor
checking for a BSD-compatible install... ./install-sh -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
...

root@test:~/tor-0.2.2.35# make
make  all-recursive
make[1]: Entering directory `/root/tor-0.2.2.35'
Making all in src
make[2]: Entering directory `/root/tor-0.2.2.35/src'
...

root@test:~/tor-0.2.2.35# make install
Making install in src
make[1]: Entering directory `/root/tor-0.2.2.35/src'
Making install in common
make[2]: Entering directory `/root/tor-0.2.2.35/src/common'
make[3]: Entering directory `/root/tor-0.2.2.35/src/common'
...

root@test:~/tor-0.2.2.35# cd /opt/tor/
root@test:/opt/tor#
</pre>
<h4>Configuration</h4>
<p>There is a sample configuration available which can be used as a base for further modification.</p>
<pre class="brush: bash; title: ; notranslate">
oot@test233:/opt/tor# cd etc/tor
root@test:/opt/tor/etc/tor# cp torrc.sample torrc
</pre>
<p>Have a look at the <a href="https://www.torproject.org/docs/manual.html.en">manual</a> for further information. </p>
<p>Finally we have to create the data and log directory which are configured in the config.<br />
e.g.:</p>
<pre class="brush: bash; title: ; notranslate">
Create data-directory
root@test:/opt/tor# mkdir -p /opt/tor/var/tor
root@test:/opt/tor# chown tor /opt/tor/var/tor

Create log-directory
root@test:~# mkdir /var/log/tor
root@test:~# chmod 777 /var/log/tor
</pre>
<h4>TOR as Solaris Service</h4>
<p>The final step is to integrate TOR into Solaris&#8217; <a href="http://en.wikipedia.org/wiki/Service_Management_Facility">Service Management Facility (smf)</a>. This requires a XML config file which describes the TOR-service.<br />
The required file can be found here:</p>
<p><a href="http://www.dev-eth0.de/wp-content/uploads/2012/02/tor.xml">tor.xml</a></p>
<pre class="brush: bash; title: ; notranslate">
root@test:/opt/tor# cd /tmp/
root@test:/tmp# wget http://www.dev-eth0.de/wp-content/uploads/2012/02/tor.xml
root@test:/tmp# svccfg import -V tor.xml
</pre>
<p>Now we have installed TOR as a Solaris Service and can start and stop it with the <strong>svcadm</strong> command and check it&#8217;s status with <strong>svcs</strong>.</p>
<p><strong>Commands:</strong></p>
<pre class="brush: bash; title: ; notranslate">
svcadm enable tor
svcadm disable tor
</pre>
<p>The following commands will start tor and check if everything is ok and running.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:/tmp# svcadm enable tor
root@test:~# svcs -x tor
svc:/network/tor:default (Tor Relay Daemon)
 State: online since Mon Feb  6 01:29:18 2012
   See: tor(1M)
   See: /var/svc/log/network-tor:default.log
Impact: None.
</pre>
<p>Finally you can check the tor logfile which should contain a line similar to</p>
<pre class="brush: bash; title: ; notranslate">
Feb 06 02:00:44.494 [notice] Self-testing indicates your ORPort is reachable from the outside. Excellent. Publishing server descriptor.
</pre>
<p class="wp-flattr-button"></p> <p><a href="http://www.dev-eth0.de/?flattrss_redirect&amp;id=1506&amp;md5=15077489599847bb6d944edfc17f594d" title="Flattr" target="_blank"><img src="http://www.dev-eth0.de/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p><img src="http://feeds.feedburner.com/~r/dev-eth0de/~4/Uw7tpYRC9_U" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.dev-eth0.de/tor-on-opensolaris/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Leseempfehlung: Android-Emulator auf Steroid</title>
		<link>http://www.dev-eth0.de/leseempfehlung-android-emulator-auf-steroid/</link>
		<comments>http://www.dev-eth0.de/leseempfehlung-android-emulator-auf-steroid/#comments</comments>
		<pubDate>Sun, 30 Oct 2011 18:43:27 +0000</pubDate>
		<dc:creator>dev-eth0</dc:creator>
				<category><![CDATA[Android]]></category>
		<category><![CDATA[HowTos]]></category>

		<guid isPermaLink="false">http://www.dev-eth0.de/?p=1501</guid>
		<description><![CDATA[Die meisten Entwickler nutzen den Android-Emulator ja wahrscheinlich dafür, selbst entwickelte Programme komfortabel zu testen. Es gibt aber auch noch einen weiteren interessanten Einsatzzweck, den Gaby Becker in einem Blog-Beitrag beschrieben hat.

Es geht hierbei um die Möglichkeit, über den Android Market Apps im Emulator zu installieren und diese dann sowohl lokal zu nutzen oder ...]]></description>
			<content:encoded><![CDATA[<p>Die meisten Entwickler nutzen den Android-Emulator ja wahrscheinlich dafür, selbst entwickelte Programme komfortabel zu testen. Es gibt aber auch noch einen weiteren interessanten Einsatzzweck, den Gaby Becker in einem Blog-Beitrag beschrieben hat.</p>
<p>Es geht hierbei um die Möglichkeit, über den Android Market Apps im Emulator zu installieren und diese dann sowohl lokal zu nutzen oder für Präsentationen zu nutzen.</p>
<p><a href="http://www.gaby-becker.de/component/content/article/47-android/96-android-praesentieren-mit-dem-emulator.html">Gaby Becker: Präsentieren mit dem Emulator</a></p>
<p>&nbsp;</p>
<p class="wp-flattr-button"></p> <p><a href="http://www.dev-eth0.de/?flattrss_redirect&amp;id=1501&amp;md5=377ce6d02e06bff63fe5d37a89913f07" title="Flattr" target="_blank"><img src="http://www.dev-eth0.de/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p><img src="http://feeds.feedburner.com/~r/dev-eth0de/~4/dj3qqt16-lk" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.dev-eth0.de/leseempfehlung-android-emulator-auf-steroid/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Postfix on OpenSolaris</title>
		<link>http://www.dev-eth0.de/postfix-on-opensolaris/</link>
		<comments>http://www.dev-eth0.de/postfix-on-opensolaris/#comments</comments>
		<pubDate>Wed, 05 Oct 2011 16:00:15 +0000</pubDate>
		<dc:creator>dev-eth0</dc:creator>
				<category><![CDATA[Homeserver]]></category>
		<category><![CDATA[Solaris Server]]></category>
		<category><![CDATA[HowTos]]></category>
		<category><![CDATA[OpenIndiana]]></category>
		<category><![CDATA[OpenSolaris]]></category>

		<guid isPermaLink="false">http://www.dev-eth0.de/postfix-on-opensolaris/</guid>
		<description><![CDATA[OpenSolaris uses Sendmail as default Mail Transfer Agent (MTA) which seems to be designed as a admin-hell. I prefer Postfix with it's easy to read config files.

As the package repository of OpenSolaris doesn't provide a current Postfix, this HowTo explains a way to build Postfix from source and install it on your OpenSolaris system.
Basics
First ...]]></description>
			<content:encoded><![CDATA[<p>OpenSolaris uses <a title="Sendmail" href="http://www.sendmail.com/sm/open_source/" target="_blank">Sendmail</a> as default <a title="Message transfer agent" href="https://en.wikipedia.org/wiki/Message_transfer_agent" target="_blank">Mail Transfer Agent (MTA)</a> which seems to be designed as a admin-hell. I prefer <a title="Postfix" href="http://www.postfix.org" target="_blank">Postfix</a> with it&#8217;s easy to read config files.</p>
<p>As the package repository of OpenSolaris doesn&#8217;t provide a current Postfix, this HowTo explains a way to build Postfix from source and install it on your OpenSolaris system.</p>
<h4>Basics</h4>
<p>First step is to install/get a working GCC (preferred version &gt;4.3). One possibility is to follow my Guide about <a title="Compile GCC 4 on OpenSolaris" href="http://www.dev-eth0.de/compile-gcc-4-on-opensolaris/" target="_blank">GCC-4 on OpenSolaris</a> or to use the package repository. In addition you will need gnu-make and wget.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# pkg install gcc-43 wget nano developer/build/gnu-make

               Packages to install:    18
           Create boot environment:    No
DOWNLOAD                                  PKGS       FILES    XFER (MB)
Completed                                18/18   3121/3121    71.5/71.5

PHASE                                        ACTIONS
Install Phase                              4183/4183

PHASE                                          ITEMS
Package State Update Phase                     18/18
Image State Update Phase                         2/2

root@test:~# PATH=/usr/bin:/usr/gcc/4.3/bin:$PATH
</pre>
<h4>Preparations</h4>
<p>Since the build environment is now set up, you can download the current postfix source release.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# wget http://de.postfix.org/ftpmirror/official/postfix-2.8.5.tar.gz

--2011-10-04 22:38:09--  http://de.postfix.org/ftpmirror/official/postfix-2.8.5.tar.gz
Resolving de.postfix.org (de.postfix.org)... 141.42.206.35
Connecting to de.postfix.org (de.postfix.org)|141.42.206.35|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 3647010 (3.5M) [application/x-gzip]
Saving to: `postfix-2.8.5.tar.gz'

100%[======================================&gt;] 3,647,010    700K/s   in 5.6s    =

2011-10-04 22:38:15 (632 KB/s) - `postfix-2.8.5.tar.gz' saved [3647010/3647010]

root@test:~# tar xf postfix-2.8.5.tar.gz
root@test:~# cd postfix-2.8.5
</pre>
<p>One of the postfix scripts has an error and tries to use NIS and NIS+ with OpenSolaris which will result in a build-fail.</p>
<p>To fix it, remove the lines &#8220;#define HAS_NIS&#8221; and &#8220;#define HAS_NISPLUS&#8221; (line 403 and 404) from src/util/sys_defs.h or apply this path:</p>
<pre class="brush: bash; title: ; notranslate">
--- src/util/sys_defs.h.bak     Thu Jun 16 00:36:37 2011
+++ src/util/sys_defs.h Tue Oct  4 22:39:49 2011
@@ -400,8 +400,6 @@
 #define HAS_DBM
 #define DEF_DB_TYPE    &quot;dbm&quot;
 #define ALIAS_DB_MAP   &quot;dbm:/etc/mail/aliases&quot;
-#define HAS_NIS
-#define HAS_NISPLUS
 #define USE_SYS_SOCKIO_H               /* Solaris 2.5, changed sys/ioctl.h */
 #define GETTIMEOFDAY(t)        gettimeofday(t)
 #define ROOT_PATH      &quot;/bin:/usr/bin:/sbin:/usr/sbin:/usr/ucb&quot;
</pre>
<h4>Building</h4>
<p>Now you can start building Postfix.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~/postfix-2.8.5# gmake makefiles CCARGS='-DUSE_TLS \
 -lssl -lcrypto -DUSE_SASL_AUTH \
 -DUSE_CYRUS_SASL -I/usr/include/sasl' \
 AUXLIBS=&quot;-L/usr/lib -lsasl -lssl -lcrypto&quot;

(echo &quot;# Do not edit -- this file documents how Postfix was built for your machine.&quot;;
&gt;makedefs.tmp
set +e; if cmp makedefs.tmp conf/makedefs.out; then rm makedefs.tmp; \
...

root@test:~/postfix-2.8.5# gmake

gmake -f Makefile.in MAKELEVEL= Makefiles
(echo &quot;# Do not edit -- this file documents how Postfix was built for your machine.&quot;;
&gt;makedefs.tmp
...
</pre>
<p>If you didn&#8217;t get an error, you can now check if libsasl was linked correctly:</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~/postfix-2.8.5# ldd ./bin/postconf

        libsasl.so.1 =&gt;  /usr/lib/libsasl.so.1
        libssl.so.0.9.8 =&gt;       /lib/libssl.so.0.9.8
        libcrypto.so.0.9.8 =&gt;    /lib/libcrypto.so.0.9.8
        libresolv.so.2 =&gt;        /lib/libresolv.so.2
        libsocket.so.1 =&gt;        /lib/libsocket.so.1
        libnsl.so.1 =&gt;   /lib/libnsl.so.1
        libc.so.1 =&gt;     /lib/libc.so.1
        libmd.so.1 =&gt;    /lib/libmd.so.1
        libmp.so.2 =&gt;    /lib/libmp.so.2
        libm.so.2 =&gt;     /lib/libm.so.2
</pre>
<h4>Create a OpenSolaris Package</h4>
<p>There is a cool script available which takes the compiled Postfix sources and builds a OpenSolaris package with all required settings (e.g. users, service-definitions).</p>
<p>You can find the script on Ihsan Dogan&#8217;s website: http://ihsan.dogan.ch/postfix/</p>
<p>Directlink: http://ihsan.dogan.ch/postfix/downloads/makePostfixPkg.sh</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~/postfix-2.8.5# wget http://ihsan.dogan.ch/postfix/downloads/makePostfixPkg.sh

--2011-10-04 22:42:35--  http://ihsan.dogan.ch/postfix/downloads/makePostfixPkg.sh
Resolving ihsan.dogan.ch (ihsan.dogan.ch)... 82.220.5.55
Connecting to ihsan.dogan.ch (ihsan.dogan.ch)|82.220.5.55|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 21030 (21K) [application/x-sh]
Saving to: `makePostfixPkg.sh'

100%[======================================&gt;] 21,030      --.-K/s   in 0.1s

2011-10-04 22:42:35 (205 KB/s) - `makePostfixPkg.sh' saved [21030/21030]

root@test:~/postfix-2.8.5# chmod +x makePostfixPkg.sh
root@test:~/postfix-2.8.5# ./makePostfixPkg.sh
...
</pre>
<p>This will result in a file named CNDpostfix-2.8.5,REV=111005-SunOS5.11-i386.pkg</p>
<h4>Install Postfix</h4>
<p>If you have a installed Sendmail, you need to remove it before the installation of postfix:</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~/postfix-2.8.5# pkg uninstall sendmail
</pre>
<p>Now you can use pkgadd to install the package:</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~/postfix-2.8.5# pkgadd -d CNDpostfix-2.8.5\,REV\=111005-SunOS5.11-i386.pkg

The following packages are available:
  1  CNDpostfix     Postfix MTA
                    (i386) 2.8.5r0.4.0,REV=111005

Select package(s) you wish to process (or 'all' to process
all packages). (default: all) [?,??,q]: a

Processing package instance  from

Postfix MTA(i386) 2.8.5r0.4.0,REV=111005
http://www.postfix.org/ packaged by Ihsan Dogan
...
</pre>
<p>The final step is to configure your Postfix and activate it afterwards.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~/postfix-2.8.5# svcadm enable svc:/network/postfix:default
root@test:~/postfix-2.8.5# svcs -vx postfix
svc:/network/postfix:default (Postfix SMTP Server)
 State: online since Tue Oct  4 22:46:29 2011
   See: man -M /usr/share/man -s 1 postfix
   See: http://www.postfix.org/documentation.html
   See: /var/svc/log/network-postfix:default.log
Impact: None.
</pre>
<p class="wp-flattr-button"></p> <p><a href="http://www.dev-eth0.de/?flattrss_redirect&amp;id=1488&amp;md5=254cbe0438f363a4bbec5c6d3be3d63e" title="Flattr" target="_blank"><img src="http://www.dev-eth0.de/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p><img src="http://feeds.feedburner.com/~r/dev-eth0de/~4/GGfN59GDuFQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.dev-eth0.de/postfix-on-opensolaris/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Upgrade an OpenIndiana Zone with pkg</title>
		<link>http://www.dev-eth0.de/upgrade-an-openindiana-zone-with-pkg/</link>
		<comments>http://www.dev-eth0.de/upgrade-an-openindiana-zone-with-pkg/#comments</comments>
		<pubDate>Wed, 05 Oct 2011 08:00:44 +0000</pubDate>
		<dc:creator>dev-eth0</dc:creator>
				<category><![CDATA[Homeserver]]></category>
		<category><![CDATA[Solaris Server]]></category>
		<category><![CDATA[HowTos]]></category>
		<category><![CDATA[OpenIndiana]]></category>
		<category><![CDATA[OpenSolaris]]></category>

		<guid isPermaLink="false">http://www.dev-eth0.de/?p=1472</guid>
		<description><![CDATA[On September 14th 2011 the OpenIndiana Project announced the next development release of OpenIndiana (Build 151a). That's a good reason to upgrade your system and it's Zones.

The common way to upgrade your OpenIndiana System is to run the following command.



This will result in a new snapshot on your disk and a new entry in ...]]></description>
			<content:encoded><![CDATA[<p>On September 14th 2011 the OpenIndiana Project announced the next development release of OpenIndiana (Build 151a). That&#8217;s a good reason to upgrade your system and it&#8217;s Zones.</p>
<p>The common way to upgrade your OpenIndiana System is to run the following command.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# pkg image-update
                Packages to remove:     2
               Packages to install:    13
                Packages to update:   115
           Create boot environment:   Yes
...
</pre>
<p>This will result in a new snapshot on your disk and a new entry in the boot menu.</p>
<p>If you try to perform an Upgrade of a Zone this way, it will fail with the message:</p>
<pre class="brush: bash; title: ; notranslate">
pkg: Unable to clone the current boot environment.
</pre>
<p>Therefor the upgrade process has to be triggered from the global zone. Let&#8217;s say you want to upgrade the Zone &#8220;<strong>test</strong>&#8221; with the ZFS dataset under &#8220;<strong>/zones/test</strong>&#8220;. The Zone currently runs OpenIndiana Build 148 as we can see after the login:</p>
<pre class="brush: bash; title: ; notranslate">
root@global:~# zlogin test
[Connected to zone 'test' pts/2]
Last login: Wed Oct  4 22:32:48 on pts/2
OpenIndiana     SunOS 5.11      oi_148  November 2010
</pre>
<p>To perform the upgrade, we should halt the zone first.</p>
<pre class="brush: bash; title: ; notranslate">
root@global:~# zoneadm -z test halt
root@global:~# pkg -R /zones/test/root image-update -v
                Packages to remove:     2
               Packages to install:     13
                Packages to update:     115
           Create boot environment:     No
               Services to restart:     2
              Rebuild boot archive:     No
Changed fmris:
pkg://openindiana.org/runtime/perl-584@5.8.4,5.11-0.148:20101122T085618Z -&gt; None
pkg://openindiana.org/runtime/perl-584/extra@5.8.4,5.11-0.148:20101122T085622Z -&gt; None
...
</pre>
<p>If everything work fine, you should see this message:</p>
<pre class="brush: bash; title: ; notranslate">
DOWNLOAD                                  PKGS       FILES    XFER (MB)
Completed                              130/130 15260/15260  106.7/106.7

PHASE                                        ACTIONS
Removal Phase                              4253/4253
Install Phase                            16931/16931
Update Phase                               5112/5112

PHASE                                          ITEMS
Package State Update Phase                   245/245
Package Cache Update Phase                   117/117
Image State Update Phase                         2/2

---------------------------------------------------------------------------
NOTE: Please review release notes posted at:

http://wiki.openindiana.org/oi/oi_151a+Release+Notes

---------------------------------------------------------------------------

root@global:~#
</pre>
<p>Now it&#8217;s time to restart your zone and check it&#8217;s status.</p>
<pre class="brush: bash; title: ; notranslate">
root@global:~# zoneadm -z test boot
root@global:~# zlogin test
[Connected to zone 'test' pts/2]
Last login: Wed Oct  4 23:10:48 on pts/2
OpenIndiana (powered by illumos)    SunOS 5.11    oi_151a    September 2011
root@test:~#
</pre>
<p>As you can see, the Zone now runs OpenIndiana Build 151a</p>
<p class="wp-flattr-button"></p> <p><a href="http://www.dev-eth0.de/?flattrss_redirect&amp;id=1472&amp;md5=1898efc8b0746d3a6c85f4e7aeb3aa97" title="Flattr" target="_blank"><img src="http://www.dev-eth0.de/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p><img src="http://feeds.feedburner.com/~r/dev-eth0de/~4/8K3jTUlweqU" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.dev-eth0.de/upgrade-an-openindiana-zone-with-pkg/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Concat and minimize JavaScript and CSS files with an ANT-Script</title>
		<link>http://www.dev-eth0.de/concat-and-minimize-javascript-and-css-files-with-an-ant-script/</link>
		<comments>http://www.dev-eth0.de/concat-and-minimize-javascript-and-css-files-with-an-ant-script/#comments</comments>
		<pubDate>Wed, 28 Sep 2011 16:00:47 +0000</pubDate>
		<dc:creator>dev-eth0</dc:creator>
				<category><![CDATA[Coding]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[HowTos]]></category>

		<guid isPermaLink="false">http://www.dev-eth0.de/?p=1449</guid>
		<description><![CDATA[If you develop a website or webapplication it's always a good idea to reduce the number of HTTP requests by combining the Javascript and CSS into single files. In addition those files should be minimized.

There is a cool Java-tool available which can help you: YUI-Compressor. It can be used from the commandline and is ...]]></description>
			<content:encoded><![CDATA[<p>If you develop a website or webapplication it&#8217;s always a good idea to reduce the number of HTTP requests by combining the Javascript and CSS into single files. In addition those files should be minimized.</p>
<p>There is a cool Java-tool available which can help you: <a title="YUI-Compressor" href="http://developer.yahoo.com/yui/compressor/" target="_blank">YUI-Compressor</a>. It can be used from the commandline and is able to minimize Javascript and CSS files. A document about the CSS minification can be found <a title="CSS-minification" href="http://developer.yahoo.com/yui/compressor/css.html" target="_blank">here</a>.</p>
<p>To automate the process of concatination and minification I wrote a little <a title="Ant" href="http://ant.apache.org/" target="_blank">ANT</a> script.</p>
<p><a href="http://www.dev-eth0.de/wp-content/uploads/2011/09/minify.zip">Ant Script for CSS and JS concatination and minification</a></p>
<p>All settings can be found in the head, pathes can be either relational or absolut. You have to download a current version of YUI-Compressor from here: </p>
<p><a title="Download YUI-Compressor" href="http://yuilibrary.com/download/yuicompressor/" target="_blank">Download YUI-Compressor</a>.</p>
<pre class="brush: xml; title: ; notranslate">
&lt;!-- Settings for CSS --&gt;
&lt;property name=&quot;css.src-dir&quot; value=&quot;path-to-css-source&quot;/&gt;
&lt;property name=&quot;css.dest-dir&quot; value=&quot;path-to-css-destination&quot;/&gt;
&lt;property name=&quot;css.files&quot; value=&quot;
    css1.css,
    css2.css
&quot;/&gt;

&lt;!-- Settings for JS --&gt;
&lt;property name=&quot;js.src-dir&quot; value=&quot;path-to-js-source&quot;/&gt;
&lt;property name=&quot;js.dest-dir&quot; value=&quot;path-to-js-destination&quot;/&gt;
&lt;property name=&quot;js.files&quot; value=&quot;
    js1.js,
    js2.js
&quot;/&gt;

&lt;!-- General settings --&gt;
&lt;property name=&quot;yuicompressor-jar&quot; value=&quot;path-to-yuicompressor.jar&quot;/&gt;
</pre>
<p>I defined three targets to provide a maximum of flexibility:</p>
<ul>
<li>all: Triggers css and javascript target</li>
<li>css: Processes CSS</li>
<li>javascript: Processes Javascript</li>
</ul>
<p>Those targets can be called from commandline:</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# ant -f minify.xml TARGET
</pre>
<p>The CSS and Javascript target first concat the given CSS/JS files and then uses YUI-Compressor to minify them. The concated version will be deleted afterwards.</p>
<p>NOTE: YUI-Compressor version minor 2.4.4 have a bug which prevents the usage of Media-Queries in minified CSS!!!</p>
<p class="wp-flattr-button"></p> <p><a href="http://www.dev-eth0.de/?flattrss_redirect&amp;id=1449&amp;md5=9b53ee8f9981fbcb80caa21002cd8511" title="Flattr" target="_blank"><img src="http://www.dev-eth0.de/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p><img src="http://feeds.feedburner.com/~r/dev-eth0de/~4/59awW2u_8HA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.dev-eth0.de/concat-and-minimize-javascript-and-css-files-with-an-ant-script/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Compile GCC 4 on OpenSolaris</title>
		<link>http://www.dev-eth0.de/compile-gcc-4-on-opensolaris/</link>
		<comments>http://www.dev-eth0.de/compile-gcc-4-on-opensolaris/#comments</comments>
		<pubDate>Thu, 11 Aug 2011 18:43:36 +0000</pubDate>
		<dc:creator>dev-eth0</dc:creator>
				<category><![CDATA[Homeserver]]></category>
		<category><![CDATA[Solaris Server]]></category>
		<category><![CDATA[HowTos]]></category>
		<category><![CDATA[OpenIndiana]]></category>
		<category><![CDATA[OpenSolaris]]></category>

		<guid isPermaLink="false">http://www.dev-eth0.de/?p=1429</guid>
		<description><![CDATA[In some cases, it's neccessary to use a newer GCC compiler (Homepage) than the one provided via a package-manager. OpenSolaris currently provices a GCC 3.4.3 and GCC 4.3. This guide should help you to compile GCC 4 on OpenSolaris, in this case GCC 4.6.1.
The whole software compiled in this guide will be installed in ...]]></description>
			<content:encoded><![CDATA[<p>In some cases, it&#8217;s neccessary to use a newer <strong>GCC</strong> compiler <a href="http://gcc.gnu.org/">(Homepage)</a> than the one provided via a package-manager. OpenSolaris currently provices a GCC 3.4.3 and GCC 4.3. This guide should help you to compile GCC 4 on OpenSolaris, in this case <strong>GCC 4.6.1</strong>.<br />
The whole software compiled in this guide will be installed in <strong>/opt/local</strong>. As I don&#8217;t run OpenSolaris on a single-core machine, I&#8217;ll use the <strong>-j</strong> switch for make to compile multithreaded.</p>
<h4>Basics</h4>
<p>Like in most howtos, we need some basic packages from the repository. Those are required to compile GCC and it&#8217;s dependencies.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# pkg install wget SUNWgcc SUNWgmake SUNWxcu4 system/library/math/header-math
               Packages to install:     7
           Create boot environment:    No
DOWNLOAD                                  PKGS       FILES    XFER (MB)
Completed                                  7/7   2393/2393    37.1/37.1

PHASE                                        ACTIONS
Install Phase                              3215/3215

PHASE                                          ITEMS
Package State Update Phase                       7/7
Image State Update Phase                         2/2
</pre>
<h4>Building dependencies</h4>
<p>The next step is to compile some dependencies of GCC. We could use OpenSolaris packages, but those are most likely outdated too.</p>
<h5>binutils</h5>
<p>The first part of software we will build are the <strong>binutils</strong> <a href="http://www.gnu.org/s/binutils/">(Homepage)</a>. The current release is 2.21.1 and can be downloaded <a href="http://ftp.gnu.org/gnu/binutils/binutils-2.21.1.tar.gz">from here</a>.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# wget http://ftp.gnu.org/gnu/binutils/binutils-2.21.1.tar.gz
--2011-08-05 20:54:31--  http://ftp.gnu.org/gnu/binutils/binutils-2.21.1.tar.gz
Connecting to ftp.gnu.org|140.186.70.20|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 25195472 (24M) [application/x-gzip]
Saving to: `binutils-2.21.1.tar.gz'

100%[==============================================&gt;] 25,195,472   441K/s   in 58s

2011-08-05 20:55:29 (427 KB/s) - `binutils-2.21.1.tar.gz' saved [25195472/25195472]

root@test:~# tar xjf binutils-2.21.1.tar.gz
root@test:~# cd binutils-2.21.1
root@test:~/binutils-2.21.1# ./configure --prefix=/opt/local/gnu --disable-nls
checking build system type... i386-pc-solaris2.11
checking host system type... i386-pc-solaris2.11
...

root@test:~/binutils-2.21.1# gmake -j 4 &amp;&amp; gmake install
gmake[1]: Entering directory `/root/binutils-2.21.1'
Configuring in ./intl
...
gmake[1]: Nothing to be done for `install-target'.
gmake[1]: Leaving directory `/root/binutils-2.21.1'

root@test:~/binutils-2.21.1# gmake clean
gmake[1]: Entering directory `/root/binutils-2.21.1'
Doing clean in bfd
...

root@test:~/binutils-2.21.1# cd ..
root@test:~# rm -r binutils-2.21.1*
</pre>
<h5>gmplib</h5>
<p>Now we will compile three libraries, which depend on each other. The first one is <strong>gmp</strong> <a href="http://gmplib.org/">(Homepage)</a> in <a href="ftp://ftp.gmplib.org/pub/gmp-5.0.2/gmp-5.0.2.tar.bz2">version 5.0.2</a>.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# wget ftp://ftp.gmplib.org/pub/gmp-5.0.2/gmp-5.0.2.tar.bz2
--2011-08-05 22:13:01--  ftp://ftp.gmplib.org/pub/gmp-5.0.2/gmp-5.0.2.tar.bz2
           =&gt; `gmp-5.0.2.tar.bz2'
Resolving ftp.gmplib.org... 130.237.222.241
Connecting to ftp.gmplib.org|130.237.222.241|:21... #connected.
Logging in as anonymous ... Logged in!
==&gt; SYST ... done.    ==&gt; PWD ... done.
==&gt; TYPE I ... done.  ==&gt; CWD (1) /pub/gmp-5.0.2 ... done.
==&gt; SIZE gmp-5.0.2.tar.bz2 ... 2024576
==&gt; PASV ... done.    ==&gt; RETR gmp-5.0.2.tar.bz2 ... done.
Length: 2024576 (1.9M) (unauthoritative)

100%[===============================================&gt;] 2,024,576    195K/s   in 11s

2011-08-05 22:13:13 (187 KB/s) - `gmp-5.0.2.tar.bz2' saved [2024576]

root@test:~# tar xfj gmp-5.0.2.tar.bz2
root@test:~# cd gmp-5.0.2
root@test:~/gmp-5.0.2# ./configure --prefix=/opt/local/gmp/5.0.2 \
    --build=i386-pc-solaris2.11

checking build system type... i386-pc-solaris2.11
checking host system type... i386-pc-solaris2.11
...

root@test:~/gmp-5.0.2# gmake -j 4
gcc -std=gnu99 `test -f 'gen-fac_ui.c' || echo './'`gen-fac_ui.c -o gen-fac_ui
gcc -std=gnu99 `test -f 'gen-fib.c' || echo './'`gen-fib.c -o gen-fib
...

root@test:~/gmp-5.0.2# gmake install
gmake  install-recursive
gmake[1]: Entering directory `/root/gmp-5.0.2'
...

root@test:~/gmp-5.0.2# gmake clean
Making clean in doc
gmake[1]: Entering directory `/root/gmp-5.0.2/doc'
...

root@test:~/gmp-5.0.2# cd ..
root@test:~# rm -r gmp-5.0.2*
root@test:~# ln -s /opt/local/gmp/5.0.2/lib/* /usr/lib/
</pre>
<h5>mpfr</h5>
<p>MPFR <a href="http://www.mpfr.org/">(Homepage)</a> depends on GMP and is next on our list.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# wget http://www.mpfr.org/mpfr-current/mpfr-3.0.1.tar.gz
--2011-08-05 21:09:42--  http://www.mpfr.org/mpfr-current/mpfr-3.0.1.tar.gz
Resolving www.mpfr.org... 152.81.144.6
Connecting to www.mpfr.org|152.81.144.6|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 1478243 (1.4M) [application/x-gzip]
Saving to: `mpfr-3.0.1.tar.gz'

100%[================================================&gt;] 1,478,243    412K/s   in 3.7s

2011-08-05 21:09:46 (394 KB/s) - `mpfr-3.0.1.tar.gz' saved [1478243/1478243]

root@test:~# tar xfj mpfr-3.0.1.tar.gz
root@test:~# cd mpfr-3.0.1
root@test:~/mpfr-3.0.1# ./configure --prefix=/opt/local/mpfr/3.0.1 \
    --build=i386-pc-solaris2.11 \
    --with-gmp=/opt/local/gmp/5.0.2

checking for a BSD-compatible install... ./install-sh -c
checking whether build environment is sane... yes
...

root@test:~/mpfr-3.0.1# gmake -j 4 install
gmake  install-recursive
gmake[1]: Entering directory `/root/mpfr-3.0.1'
...

root@test:~/mpfr-3.0.1# gmake clean
Making clean in tests
gmake[1]: Entering directory `/root/mpfr-3.0.1/tests'
..

root@test:~/mpfr-3.0.1# cd ..
root@test:~# rm -r mpfr-3.0.1*
root@test:~# ln -s /opt/local/mpfr/3.0.1/lib/* /usr/lib/
</pre>
<h5>mpc</h5>
<p>The final dependeny is <strong>mpc</strong> <a href="http://www.multiprecision.org/">(Homepage)</a> which depends on both GMP and MPFR. The current version is 0.9, but this one doesn&#8217;t compile on OpenSolaris. We will use <a href="http://www.multiprecision.org/mpc/download/mpc-0.8.2.tar.gz">0.8.2</a> instead.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# wget http://www.multiprecision.org/mpc/download/mpc-0.8.2.tar.gz
--2011-08-05 21:32:50--  http://www.multiprecision.org/mpc/download/mpc-0.8.2.tar.gz
Resolving www.multiprecision.org... 213.165.76.208
Connecting to www.multiprecision.org|213.165.76.208|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 548401 (536K) [application/x-tar]
Saving to: `mpc-0.8.2.tar.gz'

100%[=====================================================&gt;] 548,401      265K/s   in 2.0s

2011-08-05 21:32:52 (265 KB/s) - `mpc-0.8.2.tar.gz' saved [548401/548401]

root@test:~# tar xfj mpc-0.8.2.tar.gz
root@test:~# cd mpc-0.8.2
root@test:~/mpc-0.8.2# ./configure --prefix=/opt/local/mpc/0.8.2 --build=i386-pc-solaris2.11 --with-gmp=/opt/local/gmp/5.0.2 --with-mpfr=/opt/local/mpfr/3.0.1
checking for a BSD-compatible install...
...

root@test:~/mpc-0.8.2# gmake -j 4 install
Making install in src
gmake[1]: Entering directory `/root/mpc-0.8.2/src'
...

root@test:~/mpc-0.8.2# gmake clean
Making clean in doc
gmake[1]: Entering directory `/root/mpc-0.8.2/doc'
...

root@test:~/mpc-0.8.2# cd ..
root@test:~# rm -r mpc-0.8.2*
root@test:~# ln -s /opt/local/mpc/0.8.2/lib/* /usr/lib/
</pre>
<h4>GCC</h4>
<p>Now we can finally begin to compile GCC. The current release is <a href="ftp://ftp.fu-berlin.de/unix/languages/gcc/releases/gcc-4.6.1/gcc-4.6.1.tar.gz">4.6.1</a>.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# wget ftp://ftp.fu-berlin.de/unix/languages/gcc/releases/gcc-4.6.1/gcc-4.6.1.tar.gz
--2011-08-05 21:36:24--  ftp://ftp.fu-berlin.de/unix/languages/gcc/releases/gcc-4.6.1/gcc-4.6.1.tar.gz
           =&gt; `gcc-4.6.1.tar.gz'
Resolving ftp.fu-berlin.de... 130.133.3.130
Connecting to ftp.fu-berlin.de|130.133.3.130|:21... connected.
Logging in as anonymous ... Logged in!
==&gt; SYST ... done.    ==&gt; PWD ... done.
==&gt; TYPE I ... done.  ==&gt; CWD (1) /unix/languages/gcc/releases/gcc-4.6.1 ... done.
==&gt; SIZE gcc-4.6.1.tar.gz ... 93426552
==&gt; PASV ... done.    ==&gt; RETR gcc-4.6.1.tar.gz ... done.
Length: 93426552 (89M) (unauthoritative)

100%[=================================================&gt;] 93,426,552   348K/s   in 3m 57s

2011-08-05 21:40:21 (385 KB/s) - `gcc-4.6.1.tar.gz' saved [93426552]

root@test:~# tar xjf gcc-4.6.1.tar.gz
root@test:~# mkdir gcc-obj
root@test:~# cd gcc-obj/
root@test:~/gcc-obj# ../gcc-4.6.1/configure \
    --with-gmp=/opt/local/gmp/5.0.2 \
    --with-mpfr=/opt/local/mpfr/3.0.1 \
    --with-mpc=/opt/local/mpc/0.8.2 \
    --with-gnu-as \
    --with-as=/opt/local/gnu/bin/as \
    --enable-shared \
    --disable-nls \
    --enable-languages=c,c++,objc \
    --prefix=/opt/local/gcc/4.6.1

checking build system type... i386-pc-solaris2.11
checking host system type... i386-pc-solaris2.11
...

root@test:~/gcc-obj# gmake -j 4
a lot of stuff, get a coffee...
...

root@test:~/gcc-obj# gmake install

root@test:~/gcc-obj# gmake clean

root@test:~/gcc-obj# cd ..
root@test:~/gcc-obj# rm -r gcc*
</pre>
<p>Now you have compiled your own GCC and can call it from <strong>/opt/local/gcc/4.6.1/bin</strong>.</p>
<p class="wp-flattr-button"></p> <p><a href="http://www.dev-eth0.de/?flattrss_redirect&amp;id=1429&amp;md5=aab818cc665a859162647120c3ca80c5" title="Flattr" target="_blank"><img src="http://www.dev-eth0.de/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p><img src="http://feeds.feedburner.com/~r/dev-eth0de/~4/w0Y9LrRd9bU" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.dev-eth0.de/compile-gcc-4-on-opensolaris/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>ejabberd on OpenSolaris</title>
		<link>http://www.dev-eth0.de/ejabberd-on-opensolaris/</link>
		<comments>http://www.dev-eth0.de/ejabberd-on-opensolaris/#comments</comments>
		<pubDate>Tue, 02 Aug 2011 16:00:21 +0000</pubDate>
		<dc:creator>dev-eth0</dc:creator>
				<category><![CDATA[Homeserver]]></category>
		<category><![CDATA[Solaris Server]]></category>
		<category><![CDATA[HowTos]]></category>
		<category><![CDATA[OpenIndiana]]></category>
		<category><![CDATA[OpenSolaris]]></category>

		<guid isPermaLink="false">http://www.dev-eth0.de/?p=1399</guid>
		<description><![CDATA[Jenkins provides a nice plugin which lets you chat with it. I decided to install ejabberd on OpenSolaris. This is an easy to use Jabber/XMPP daemon which should be setup quite easy.

Installation
The OpenSolaris Package Repository contains a ejabberd Package which will be used. It includes the integration of ejabberd into is into Solaris' Service ...]]></description>
			<content:encoded><![CDATA[<p><a href="http://jenkins-ci.org/">Jenkins</a> provides a <a href="https://wiki.jenkins-ci.org/display/JENKINS/Jabber+Plugin">nice plugin</a> which lets you chat with it. I decided to install <a href="http://www.ejabberd.im/ejabberd">ejabberd</a> on OpenSolaris. This is an easy to use Jabber/XMPP daemon which should be setup quite easy.</p>
<h4>Installation</h4>
<p>The <a href="http://pkg.opensolaris.org/release/en/index.shtml">OpenSolaris Package Repository</a> contains a <a href="http://pkg.opensolaris.org/release/en/search.shtml?action=Search&#038;token=ejabberd">ejabberd Package</a> which will be used. It includes the integration of ejabberd into is into Solaris&#8217; <a href="http://en.wikipedia.org/wiki/Service_Management_Facility">Service Management Facility (smf)</a> and makes it easy to use.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# pkg install web/server/ejabberd
               Packages to install:     1
           Create boot environment:    No
               Services to restart:     1
DOWNLOAD                                  PKGS       FILES    XFER (MB)
Completed                                  1/1     167/167      0.8/0.8

PHASE                                        ACTIONS
Install Phase                                212/212

PHASE                                          ITEMS
Package State Update Phase                       1/1
Image State Update Phase                         2/2
</pre>
<p>Now we can enable ejabberd and check it&#8217;s status.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# svcadm enable  svc:/network/xmpp:ejabberd
root@test:~# svcs -x  svc:/network/xmpp:ejabberd
svc:/network/xmpp:ejabberd (ejabberd Jabber/XMPP Server)
 State: online since Mon Aug 01 14:27:32 2011
   See: ejabberdctl(8)
   See: http://www.ejabberd.im
   See: /var/svc/log/network-xmpp:ejabberd.log
Impact: None.
</pre>
<h4>Configuration</h4>
<p>The configuration files of ejabberd can be found in <strong>/etc/ejabberd/</strong>. First we need to add the hostname of our server and modify the user permissions for an admin user we will create later.</p>
<p>In <strong>/etc/ejabberd/ejabberd.cfg</strong> we need the following entries:</p>
<pre class="brush: bash; title: ; notranslate">
...
%%%   ================
%%%   SERVED HOSTNAMES
{hosts, [&amp;amp;quot;myhost&amp;amp;quot;, &amp;amp;quot;localhost&amp;amp;quot;]}
...
%%%   ====================
%%%   ACCESS CONTROL LISTS
{acl, admin, {user, &amp;amp;quot;myuser&amp;amp;quot;, &amp;amp;quot;localhost&amp;amp;quot;}}.
{acl, admin, {user, &amp;amp;quot;myuser&amp;amp;quot;, &amp;amp;quot;myhost&amp;amp;quot;}}.
</pre>
<p>Afterwards we need to restart ejabberd and can create the user via commandline.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# svcadm restart ejabberd
root@test:~# su daemon -c &amp;amp;quot;ejabberdctl register myuser myhost mypassword&amp;amp;quot;
</pre>
<p>We can now visit the admin WebGUI of ejabberd on http://myhost:5280/admin and login with the username <strong>myuser@myhost</strong> and the password.</p>
<h4>Adding SSL Support</h4>
<p>To enable the SSL Support of ejabberd, we need to create a certificate and add it to the ejabberd.cfg.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# cd /etc/ejabberd/
root@test:/etc/ejabberd# openssl req -new -x509 -days 365 -nodes -out cert.pem -keyout cert.pem
Generating a 1024 bit RSA private key
........................................++++++
........++++++
writing new private key to 'cert.pem'
...
</pre>
<p>Now find the line</p>
<pre class="brush: bash; title: ; notranslate">
{5222, ejabberd_c2s, [
</pre>
<p>in your <strong>ejabberd.cfg</strong> and uncomment and modify the entry </p>
<pre class="brush: bash; title: ; notranslate">
{certfile, &amp;amp;quot;/path/to/ssl.pem&amp;amp;quot;}, starttls,
</pre>
<p>.<br />
The config should now look like this:</p>
<pre class="brush: bash; title: ; notranslate">
{5222, ejabberd_c2s, [
            %%
            %% If TLS is compiled and you installed a SSL
            %% certificate, put the correct path to the
            %% file and uncomment this line:
            %%
            {certfile, &amp;amp;quot;/etc/ejabberd/cert.pem&amp;amp;quot;}, starttls,
            {access, c2s},
            {shaper, c2s_shaper},
            {max_stanza_size, 65536}
          ]},
</pre>
<p>If we now restart ejabberd, SSL support is available.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:/etc/ejabberd# svcadm restart ejabberd
</pre>
<h4>Connect your XMPP Client to ejabberd</h4>
<p>Now we can connect your XMPP Client to your ejabberd Server. The following screenshot contains the information for <a href="http://www.pidgin.im/">Pidgin</a>.<br />
<a href="http://www.dev-eth0.de/wp-content/uploads/2011/08/ejabberd.png" rel="lightbox[1399]"><img src="http://www.dev-eth0.de/wp-content/uploads/2011/08/ejabberd-270x300.png" alt="ejabberd 270x300 ejabberd on OpenSolaris" title="Connect to your ejabberd" width="270" height="300" class="alignnone size-medium wp-image-1406" /></a></p>
<p class="wp-flattr-button"></p> <p><a href="http://www.dev-eth0.de/?flattrss_redirect&amp;id=1399&amp;md5=cd4928313ae02928a292915ab734d5f9" title="Flattr" target="_blank"><img src="http://www.dev-eth0.de/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p><img src="http://feeds.feedburner.com/~r/dev-eth0de/~4/W4UEYmlkptE" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.dev-eth0.de/ejabberd-on-opensolaris/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Maven on OpenSolaris</title>
		<link>http://www.dev-eth0.de/maven-on-opensolaris/</link>
		<comments>http://www.dev-eth0.de/maven-on-opensolaris/#comments</comments>
		<pubDate>Mon, 01 Aug 2011 16:15:33 +0000</pubDate>
		<dc:creator>dev-eth0</dc:creator>
				<category><![CDATA[Homeserver]]></category>
		<category><![CDATA[Solaris Server]]></category>
		<category><![CDATA[HowTos]]></category>
		<category><![CDATA[OpenIndiana]]></category>
		<category><![CDATA[OpenSolaris]]></category>

		<guid isPermaLink="false">http://www.dev-eth0.de/?p=1371</guid>
		<description><![CDATA[After the installation of Ant we can proceed with Maven.

This HowTo descripes the installation of Maven 3 on a OpenSolaris system and the following integration into Jenkins whose installation was descriped in this guide.

Setup

The Maven installation requires Ant and a JDK to build. If you haven't installed Ant yet, you should visit the appropriate ...]]></description>
			<content:encoded><![CDATA[<p>After the <a href="http://www.dev-eth0.de/ant-on-opensolaris">installation</a> of <a href="http://ant.apache.org/">Ant</a> we can proceed with <a href="http://maven.apache.org/">Maven</a>.</p>
<p>This HowTo descripes the installation of Maven 3 on a OpenSolaris system and the following integration into <a href="http://jenkins-ci.org/">Jenkins</a> whose installation was descriped in <a href="http://www.dev-eth0.de/jenkins-continuous-integration-on-opensolaris/">this guide</a>.</p>
<h4>Setup</h4>
<p>The Maven installation requires Ant and a JDK to build. If you haven&#8217;t installed Ant yet, you should visit the <a href="http://www.dev-eth0.de/ant-on-opensolaris">appropriate guide</a> first. The JDK can beinstalled via <strong>pkg install</strong>.<br />
You can find the current version of Maven on any <a href="http://www.apache.org/mirrors/">Apache Mirror near you</a>.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# cd /tmp
root@test:/tmp# pkg install jdk
root@test:/tmp# PATH=$PATH:/opt/local/bin
root@test:/tmp# wget http://apache.easy-webs.de/maven/source/apache-maven-3.0.3-src.tar.gz
--2011-07-31 21:15:53--  http://apache.easy-webs.de/maven/source/apache-maven-3.0.3-src.tar.gz
Connecting to apache.easy-webs.de|87.106.190.69|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 3728950 (3.6M) [application/x-gzip]
Saving to: `apache-maven-3.0.3-src.tar.gz'

100%[===========================================================&amp;gt;] 3,728,950    641K/s   in 6.1s

2011-07-31 21:15:59 (598 KB/s) - `apache-maven-3.0.3-src.tar.gz' saved [3728950/3728950]

root@test:/tmp# tar xvf apache-maven-3.0.3-src.tar.gz
Decompressing 'apache-maven-3.0.3-src.tar.gz' with '/usr/bin/gzcat'...
x apache-maven-3.0.3, 0 bytes, 0 tape blocks
x apache-maven-3.0.3/apache-maven, 0 bytes, 0 tape blocks
x apache-maven-3.0.3/apache-maven/src, 0 bytes, 0 tape blocks
...

root@test:/tmp/apache-maven-3.0.3# export M2_HOME=/opt/maven/
root@test:/tmp/apache-maven-3.0.3# ant
root@test:/tmp/apache-maven-3.0.3# cd ..
root@test:/tmp# rm -r apache-maven-3.0.3
</pre>
<h4>Jenkins Setup</h4>
<p>To tell Jenkins which Maven installation should be used, you need to enter the Jenkins-Website and click on <strong>Manage Jenkins</strong>.</p>
<p><a href="http://www.dev-eth0.de/wp-content/uploads/2011/08/Jenkins02.png" rel="lightbox[1371]"><img class="alignnone size-medium wp-image-1383" title="Manage Jenkins" src="http://www.dev-eth0.de/wp-content/uploads/2011/08/Jenkins02-300x129.png" alt="Jenkins02 300x129 Maven on OpenSolaris" width="300" height="129" /></a></p>
<p>Now enter <strong>Configure System</strong> and set the Maven settings according to this screenshot.<br />
<a href="http://www.dev-eth0.de/wp-content/uploads/2011/08/Jenkins03_Maven.png" rel="lightbox[1371]"><img src="http://www.dev-eth0.de/wp-content/uploads/2011/08/Jenkins03_Maven-300x84.png" alt="Jenkins03 Maven 300x84 Maven on OpenSolaris" title="Jenkins Settings for Maven" width="300" height="84" class="alignnone size-medium wp-image-1392" /></a></p>
<p class="wp-flattr-button"></p> <p><a href="http://www.dev-eth0.de/?flattrss_redirect&amp;id=1371&amp;md5=c40ad7a253c01b5b7b53a56746c637e3" title="Flattr" target="_blank"><img src="http://www.dev-eth0.de/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p><img src="http://feeds.feedburner.com/~r/dev-eth0de/~4/yE2i2xowMnc" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.dev-eth0.de/maven-on-opensolaris/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Ant on OpenSolaris</title>
		<link>http://www.dev-eth0.de/ant-on-opensolaris/</link>
		<comments>http://www.dev-eth0.de/ant-on-opensolaris/#comments</comments>
		<pubDate>Mon, 01 Aug 2011 16:15:15 +0000</pubDate>
		<dc:creator>dev-eth0</dc:creator>
				<category><![CDATA[Homeserver]]></category>
		<category><![CDATA[Solaris Server]]></category>
		<category><![CDATA[HowTos]]></category>
		<category><![CDATA[OpenIndiana]]></category>
		<category><![CDATA[OpenSolaris]]></category>

		<guid isPermaLink="false">http://www.dev-eth0.de/?p=1369</guid>
		<description><![CDATA[If you're running a Jenkins Continous Integration System as descriped in this guide, you most likely need Ant and/or Maven to build your applications.

The next two HowTos are about the installation of those tools and the required setup in Jenkins. As Maven requires Ant, we start with that. The guide about the installation of ...]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;re running a Jenkins Continous Integration System as descriped in <a href="http://www.dev-eth0.de/jenkins-continuous-integration-on-opensolaris/">this guide</a>, you most likely need <a title="Ant" href="http://ant.apache.org/">Ant</a> and/or <a title="Maven" href="http://maven.apache.org/">Maven</a> to build your applications.</p>
<p>The next two HowTos are about the installation of those tools and the required setup in Jenkins. As Maven requires Ant, we start with that. The guide about the installation of Maven can be <a href="http://www.dev-eth0.de/maven-on-opensolaris">found here</a>.</p>
<p>You can find the current version of ant on any <a href="http://www.apache.org/mirrors/">Apache Mirror near you</a>.</p>
<h4>Setup</h4>
<p>First we have to download the current Ant version and put it into <strong>/opt/ant/current</strong>. Afterwards we can setup Jenkins to use this installation.</p>
<pre class="brush: bash; title: ; notranslate">
root@test:~# cd /opt
root@test:/opt# mkdir ant
root@test:/opt# cd ant/
root@test:/opt/ant# wget http://apache.openmirror.de//ant/binaries/apache-ant-1.8.2-bin.tar.gz
--2011-07-31 21:25:34--  http://apache.openmirror.de//ant/binaries/apache-ant-1.8.2-bin.tar.gz
Connecting to apache.openmirror.de|83.246.74.136|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 8324124 (7.9M) [application/x-gzip]
Saving to: `apache-ant-1.8.2-bin.tar.gz'

100%[==========================================================&amp;gt;] 8,324,124    668K/s   in 12s

2011-07-31 21:25:46 (679 KB/s) - `apache-ant-1.8.2-bin.tar.gz' saved [8324124/8324124]

root@test:/opt/ant# tar xvf apache-ant-1.8.2-bin.tar.gz
Decompressing 'apache-ant-1.8.2-bin.tar.gz' with '/usr/bin/gzcat'...
x apache-ant-1.8.2/bin/ant, 9997 bytes, 20 tape blocks
x apache-ant-1.8.2/bin/antRun, 861 bytes, 2 tape blocks
x apache-ant-1.8.2/bin/antRun.pl, 2199 bytes, 5 tape blocks
...

root@test:/opt/ant# ln -s apache-ant-1.8.2 current
root@test:/opt/ant# ln -s /opt/ant/current/bin/ant /opt/local/bin/
root@test:/opt/ant# rm apache-ant-1.8.2-bin.tar.gz
</pre>
<h4>Jenkins Setup</h4>
<p>To tell Jenkins which Ant installation should be used, you need to enter the Jenkins-Website and click on <strong>Manage Jenkins</strong>.</p>
<p><a href="http://www.dev-eth0.de/wp-content/uploads/2011/08/Jenkins02.png" rel="lightbox[1369]"><img class="alignnone size-medium wp-image-1383" title="Manage Jenkins" src="http://www.dev-eth0.de/wp-content/uploads/2011/08/Jenkins02-300x129.png" alt="Jenkins02 300x129 Ant on OpenSolaris" width="300" height="129" /></a></p>
<p>Now enter <strong>Configure System</strong> and set the Ant settings according to this screenshot.<br />
<a href="http://www.dev-eth0.de/wp-content/uploads/2011/08/Jenkins03_Ant.png" rel="lightbox[1369]"><img class="alignnone size-medium wp-image-1384" title="Setup Ant for Jenkins" src="http://www.dev-eth0.de/wp-content/uploads/2011/08/Jenkins03_Ant-300x83.png" alt="Jenkins03 Ant 300x83 Ant on OpenSolaris" width="300" height="83" /></a></p>
<p class="wp-flattr-button"></p> <p><a href="http://www.dev-eth0.de/?flattrss_redirect&amp;id=1369&amp;md5=4e7f681c056f148d20981f3543032c5b" title="Flattr" target="_blank"><img src="http://www.dev-eth0.de/wp-content/plugins/flattr/img/flattr-badge-large.png" alt="flattr this!"/></a></p><img src="http://feeds.feedburner.com/~r/dev-eth0de/~4/Mh5wbqlfI8Q" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://www.dev-eth0.de/ant-on-opensolaris/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss><!-- Dynamic page generated in 3.064 seconds. --><!-- Cached page generated by WP-Super-Cache on 2012-02-21 05:19:39 --><!-- Compression = gzip -->

