<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-6302270466598962946</id><updated>2011-10-01T18:57:25.240+02:00</updated><category term='core system support'/><category term='cdrom'/><category term='gpg'/><category term='fibre channel'/><category term='convergence'/><category term='disk'/><category term='db2'/><category term='sed'/><category term='library'/><category term='slamd'/><category term='restore'/><category term='encryption'/><category term='hpux'/><category term='logadm'/><category term='nwam'/><category term='pkcs12'/><category term='spam'/><category term='mktemp'/><category term='sun'/><category term='dsee'/><category term='solaris'/><category term='smf'/><category term='cde'/><category term='backup'/><category term='utility'/><category term='directory manager'/><category term='zpool'/><category term='crle'/><category term='security'/><category term='vmware'/><category term='directory server'/><category term='openssl'/><category term='algorithm'/><category term='rubygems'/><category term='gui'/><category term='rmdom.pl'/><category term='delegated administrator'/><category term='rbac'/><category term='pem'/><category term='tcp/ip'/><category term='pkgadd'/><category term='opends'/><category term='pid'/><category term='ssl'/><category term='certificate'/><category term='network'/><category term='ubuntu'/><category term='disable'/><category term='mta'/><category term='ruby'/><category term='elom'/><category term='mail'/><category term='zfs'/><category term='ipsec'/><category term='ipfw'/><category term='macosx'/><category term='rsa'/><category term='service packages'/><category term='mirror'/><category term='glassfish'/><category term='monit'/><category term='application'/><category term='snapshot'/><category term='oneliners'/><category term='rpm'/><category term='comms'/><category term='da'/><category term='ldap'/><category term='fmri'/><category term='ca'/><category term='messaging server'/><category term='debian'/><category term='script'/><category term='scrub'/><category term='firewall'/><category term='port'/><category term='file'/><category term='driver'/><category term='ksh'/><category term='linux'/><category term='password policy'/><category term='boot'/><category term='login'/><category term='macbook pro'/><category term='aix'/><category term='ssh'/><category term='monitoring'/><category term='freeware'/><category term='cs-tools'/><category term='rotation'/><category term='spamassassin'/><category term='ilom'/><category term='log'/><category term='x2200'/><category term='csr'/><category term='opensolaris'/><category term='resilver'/><category term='ldif'/><category term='ipv6'/><title type='text'>Unix Wear</title><subtitle type='html'>Put your favourite unix on</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>63</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-8568118848480527989</id><published>2011-09-11T23:26:00.000+02:00</published><updated>2011-09-11T23:26:19.590+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='disk'/><category scheme='http://www.blogger.com/atom/ns#' term='firewall'/><category scheme='http://www.blogger.com/atom/ns#' term='ipfw'/><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><title type='text'>Blind Administration</title><content type='html'>A few weeks ago I've lost the ability to see any output form my MacBook Pro.&lt;br /&gt;&lt;br /&gt;It was a second time. For the first time I had lost the embedded led display only.&lt;br /&gt;The DVI output worked fine. Then came the healing power of promise - I have to buy a new one.&lt;br /&gt;But threat without the coverage it's just the bucket of words.&lt;br /&gt;The MBP makes me blind completely and definately. No video output. No remote access.&lt;br /&gt;No working ssh daemon, no firewall access, no future.&lt;br /&gt;&lt;br /&gt;I thought the target mode would be the cure.&lt;br /&gt;I have PowerBook Pismo with Tiger onboard. Unfortunately, the data on MBP was encrypted with&lt;br /&gt;a FileVault from Snow Leopard. Either try of target mode connection, or try of manual mount failed.&lt;br /&gt;&lt;br /&gt;Collecting of the recipe components took me many hours, often filled with an exasperation.&lt;br /&gt;Hidden typos. Invisible prompts. Lurking daemons.&lt;br /&gt;&lt;br /&gt;The recipe.&lt;br /&gt;It's here to remember. It's here to save other souls.&lt;br /&gt;&lt;br /&gt;Power On.&lt;br /&gt;Listen to chime and wait a few moments, then log in yourself:&lt;br /&gt;&lt;i&gt;username &lt;/i&gt;TAB&lt;br /&gt;&lt;i&gt;password&lt;/i&gt;&lt;br /&gt;&lt;br /&gt;Open Applications&lt;br /&gt;&lt;b&gt;&amp;#8984;+Shift+A&lt;/b&gt;&lt;br /&gt;and invoke your favourite text terminal by typing its name, followed by CMD+O&lt;br /&gt;i t e r m &lt;b&gt;&amp;#8984;+O&lt;/b&gt;&lt;br /&gt;&lt;br /&gt;Confirm you're in:&lt;br /&gt;&lt;pre style="color: #006600"&gt;$ say ok&lt;br /&gt;$ sudo su&lt;br /&gt;&gt; put your password &lt;&lt;br /&gt;&lt;/pre&gt;Confirm your personality.&lt;pre style="color: #006600"&gt;$ whoami | say&lt;br /&gt;&lt;/pre&gt;Let the dogs out. Select a race, choose wisely.&lt;pre style="color: #006600"&gt;$ launchctl load -w /System/Library/LaunchDaemons/telnet.plist # enable configuration and&lt;br /&gt;$ launchctl load -w /System/Library/LaunchDaemons/ssh.plist    # set Disable key to false&lt;br /&gt;$ launchctl start com.apple.telnetd&lt;br /&gt;$ launchctl start com.openssh.sshd&lt;br /&gt;&lt;/pre&gt;Check the locks.&lt;pre style="color: #006600"&gt;$ defaults read /Library/Preferences/com.apple.alf globalstate | say&lt;br /&gt;2&lt;br /&gt;&lt;/pre&gt;Firewall states&lt;ul type="square"&gt;&lt;li&gt;0 - de-activated&lt;br /&gt;&lt;li&gt;1 - on for specific services&lt;br /&gt;&lt;li&gt;2 - on for essential services&lt;br /&gt;&lt;/ul&gt;Open the gates.&lt;br /&gt;&lt;i&gt;Pretty enough for older systems (Tiger), where no reboot required:&lt;/i&gt;&lt;pre style="color: #006600"&gt;$ ipfw flush&lt;br /&gt;&gt; 'y' to flush &lt;&lt;br /&gt;$ ipfw list | say # 'any to any' means success&lt;br /&gt;&lt;/pre&gt;&lt;i&gt;Permanent solution:&lt;/i&gt;&lt;pre style="color: #006600"&gt;$ defaults write /Library/Preferences/com.apple.alf globalstate -int 0&lt;br /&gt;$ reboot&lt;br /&gt;&lt;/pre&gt;Connect and enjoy it.&lt;br /&gt;&lt;br /&gt;Mount USB Disk drive.&lt;pre style="color: #006600"&gt;sh-3.2# diskutil list| grep SAM&lt;br /&gt;   1:             Windows_FAT_32 SAMSUNG                 2.0 TB     disk2s1&lt;br /&gt;sh-3.2# diskutil mountDisk SAMSUNG&lt;br /&gt;Volume(s) mounted successfully&lt;br /&gt;&lt;/pre&gt;Rsync your secrets.&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-8568118848480527989?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/8568118848480527989/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=8568118848480527989' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8568118848480527989'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8568118848480527989'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2011/09/blind-administration.html' title='Blind Administration'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-6697246150215713399</id><published>2011-01-03T20:15:00.009+01:00</published><updated>2011-01-03T21:40:58.473+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='debian'/><category scheme='http://www.blogger.com/atom/ns#' term='ubuntu'/><category scheme='http://www.blogger.com/atom/ns#' term='db2'/><title type='text'>db2setup start failure on Debian/Ubuntu</title><content type='html'>Two late evenings of life - that was the time cost of the solution discovery.&lt;br /&gt;I had tried to put the DB2 Express-C 9.7.2 on 64-bit Linux system, and I failed either on Ubuntu 8.04 LTS&lt;br /&gt;or on Debian 5.0 (I know it is not recommended/supported solution).&lt;br /&gt;&lt;br /&gt;The first and the last problem was related to the db2setup startup error. &lt;br /&gt;It can be seen from the console just like that:&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# ./db2setup &lt;br /&gt;DBI1190I  db2setup is preparing the DB2 Setup wizard which will guide&lt;br /&gt;      you through the program setup process. Please wait.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;#&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;But, there was the trail in the error log:&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# cd /tmp&lt;br /&gt;# cat db2setup.err &lt;br /&gt;Exception in thread "main" java.lang.UnsatisfiedLinkError: awt (An exception was pending after running JNI_OnLoad)&lt;br /&gt;        at java.lang.ClassLoader.loadLibraryWithPath(ClassLoader.java:998)&lt;br /&gt;        at java.lang.ClassLoader.loadLibraryWithClassLoader(ClassLoader.java:962)&lt;br /&gt;        at java.lang.System.loadLibrary(System.java:465)&lt;br /&gt;        at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:69)&lt;br /&gt;        at java.security.AccessController.doPrivileged(AccessController.java:202)&lt;br /&gt;        at java.awt.Toolkit.loadLibraries(Toolkit.java:1605)&lt;br /&gt;        at java.awt.Toolkit.&lt;clinit&gt;(Toolkit.java:1627)&lt;br /&gt;        at java.lang.J9VMInternals.initializeImpl(Native Method)&lt;br /&gt;        at java.lang.J9VMInternals.initialize(J9VMInternals.java:200)&lt;br /&gt;        at java.awt.AWTEvent.&lt;clinit&gt;(AWTEvent.java:220)&lt;br /&gt;        at java.lang.J9VMInternals.initializeImpl(Native Method)&lt;br /&gt;        at java.lang.J9VMInternals.initialize(J9VMInternals.java:200)&lt;br /&gt;        at java.lang.J9VMInternals.initialize(J9VMInternals.java:167)&lt;br /&gt;        at java.lang.J9VMInternals.initialize(J9VMInternals.java:167)&lt;br /&gt;        at java.lang.J9VMInternals.initialize(J9VMInternals.java:167)&lt;br /&gt;        at sun.misc.Unsafe.ensureClassInitialized(Native Method)&lt;br /&gt;        at sun.reflect.UnsafeFieldAccessorFactory.newFieldAccessor(UnsafeFieldAccessorFactory.java:37)&lt;br /&gt;        at sun.reflect.ReflectionFactory.newFieldAccessor(ReflectionFactory.java:122)&lt;br /&gt;        at java.lang.reflect.Field.acquireFieldAccessor(Field.java:920)&lt;br /&gt;        at java.lang.reflect.Field.getFieldAccessor(Field.java:901)&lt;br /&gt;        at java.lang.reflect.Field.get(Field.java:360)&lt;br /&gt;        at com.ibm.db2.tools.common.support.AssistManager.loadVKeys(Unknown Source)&lt;br /&gt;        at com.ibm.db2.tools.common.support.AssistManager.&lt;clinit&gt;(Unknown Source)&lt;br /&gt;        at java.lang.J9VMInternals.initializeImpl(Native Method)&lt;br /&gt;        at java.lang.J9VMInternals.initialize(J9VMInternals.java:200)&lt;br /&gt;        at DB2Setup.&lt;init&gt;(Unknown Source)&lt;br /&gt;        at DB2Setup.main(Unknown Source)&lt;br /&gt;#&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Let me start from the beginning.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# ./db2setup&lt;br /&gt;WARNING:&lt;br /&gt;   Can't use string to find the version of libstdc++.&lt;br /&gt;   Check the following web site for the up-to-date system requirements&lt;br /&gt;   of IBM DB2 9.7&lt;br /&gt;   http://www.ibm.com/software/data/db2/udb/sysreqs.html&lt;br /&gt;   http://www.software.ibm.com/data/db2/linux/validate  &lt;br /&gt;  The force option "-f sysreq" is used to force the installation ...&lt;br /&gt;&lt;br /&gt;DBI1190I  db2setup is preparing the DB2 Setup wizard which will guide&lt;br /&gt;      you through the program setup process. Please wait.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;The DISPLAY variable is not set properly.  Ensure that the DISPLAY variable is set properly and that permissions are set properly to open windows on the display specified, then rerun the command.&lt;br /&gt;# &lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Even with the &lt;b&gt;-f sysreq&lt;/b&gt; there was no visible progress.&lt;br /&gt;Before the installation begins I have installed the &lt;b&gt;libaio1&lt;/b&gt; and &lt;b&gt;libstdc++6&lt;/b&gt; as it was mentioned in the online documentation.&lt;br /&gt;&lt;br /&gt;The installation was on the remote server, so to verify that X11 session forwarding works fine I had to install &lt;em&gt;xauth&lt;/em&gt; and use the &lt;b&gt;ssh -Y&lt;/b&gt; option.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# xauth list&lt;br /&gt;digestive.deadsystems.com/unix:10  MIT-MAGIC-COOKIE-1  a957c95c1c862f5314b32e88c5bd9e17&lt;br /&gt;# echo $DISPLAY&lt;br /&gt;localhost:10.0&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;em&gt;I have used the xarclock to check that the remote app is being displayed fine on my laptop.&lt;/em&gt;&lt;br /&gt;&lt;br /&gt;"Can't use string to find the version of libstdc++." - &lt;br /&gt;it was resolved by simple &lt;b&gt;binutils&lt;/b&gt; package installation (to get the &lt;em&gt;strings&lt;/em&gt; binary).&lt;br /&gt;&lt;br /&gt;But, there was no progress yet.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# ./db2setup &lt;br /&gt;WARNING:&lt;br /&gt;   The 32 bit library file libstdc++.so.6 is not found on the system. &lt;br /&gt;   32-bit applications may be affected.  &lt;br /&gt;DBI1190I  db2setup is preparing the DB2 Setup wizard which will guide&lt;br /&gt;      you through the program setup process. Please wait.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;# &lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Then I thought that the /tmp/db2setup.err contains the java related exception, but there is no java vm on the machine.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# java -version&lt;br /&gt;-ksh93: java: not found [No such file or directory]&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;After the &lt;b&gt;sun-java6-jre&lt;/b&gt; installation there was still nothing more.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# java -version&lt;br /&gt;java version "1.6.0_22"&lt;br /&gt;Java(TM) SE Runtime Environment (build 1.6.0_22-b04)&lt;br /&gt;Java HotSpot(TM) 64-Bit Server VM (build 17.1-b03, mixed mode)&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;A few search queries more and I have found a &lt;a href="http://publib.boulder.ibm.com/infocenter/javasdk/v6r0/index.jsp?topic=/com.ibm.java.doc.user.lnx.60/user/limitations.html&lt;br /&gt;"&gt;tip&lt;/a&gt;:&lt;br /&gt;&lt;cite&gt;&lt;br /&gt;GUI applications, such as the JConsole monitoring tool, on 64-bit Ubuntu with a 32-bit JVM&lt;br /&gt;When running a 32-bit JVM on a 64-bit Ubuntu system, GUI applications do not start because some AWT libraries are missing. To fix the problem, install the 32-bit libraries using the ia32-libs package:&lt;br /&gt;sudo apt-get install ia32-libs&lt;br /&gt;The following exception is thrown if the libraries are not available:&lt;br /&gt;Exception in thread "main" java.lang.UnsatisfiedLinkError: awt (An exception was pending after running JNI_OnLoad)&lt;br /&gt;        at java.lang.ClassLoader.loadLibraryWithPath(ClassLoader.java:993)&lt;br /&gt;        at java.lang.ClassLoader.loadLibraryWithClassLoader(ClassLoader.java:962)&lt;br /&gt;        at java.lang.System.loadLibrary(System.java:465)&lt;br /&gt;        ... lines removed for clarity ...&lt;br /&gt;If problems are encountered with DNS name resolution, install the package lib32nss-mdns.&lt;br /&gt;&lt;/cite&gt;&lt;br /&gt;But neither &lt;b&gt;ia32-libs&lt;/b&gt; nor &lt;b&gt;lib32nss-mdns&lt;/b&gt; installation helped me to go further.&lt;br /&gt;The only benefit was the lack of warning message:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;WARNING:&lt;br /&gt;   The 32 bit library file libstdc++.so.6 is not found on the system. &lt;br /&gt;   32-bit applications may be affected.&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Then It looked like:&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# ./db2setup &lt;br /&gt;DBI1190I  db2setup is preparing the DB2 Setup wizard which will guide&lt;br /&gt;      you through the program setup process. Please wait.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;#&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;After the additional few hours of digging through the differences between the library sets on two machines,&lt;br /&gt;on which the first have the fully operational DB2 instances and the second is the reported unlucky node, I have pointed the main responsible for all the evil - there was no &lt;b&gt;libxft2&lt;/b&gt;. After the &lt;em&gt;apt-get install libxft2&lt;/em&gt; - db2setup has raised from the ashes.&lt;br /&gt;&lt;br /&gt;Enjoy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-6697246150215713399?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/6697246150215713399/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=6697246150215713399' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6697246150215713399'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6697246150215713399'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2011/01/db2setup-start-failure-on-debianubuntu.html' title='db2setup start failure on Debian/Ubuntu'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-513731684519082486</id><published>2011-01-01T23:38:00.006+01:00</published><updated>2011-01-01T23:54:43.546+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='monit'/><category scheme='http://www.blogger.com/atom/ns#' term='monitoring'/><title type='text'>Un-monit</title><content type='html'>Using the &lt;em&gt;monit&lt;/em&gt; to look after the hosts and services, sometimes you need to stop watching a particular check.&lt;br /&gt;The argument for &lt;b&gt;unmonitor&lt;/b&gt; option is the process name or host name being monitored, ex.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# monit status&lt;br /&gt;[...]&lt;br /&gt;Remote Host 'eye0.deadsystems.com'&lt;br /&gt;  status                            Connection failed&lt;br /&gt;  monitoring status                 monitored&lt;br /&gt;[...]&lt;br /&gt;&lt;br /&gt;# monit unmonitor eye0.deadsystems.com&lt;br /&gt;# monit summary&lt;br /&gt;[...]&lt;br /&gt;Process 'sshd'                      running&lt;br /&gt;Remote Host 'eye0.deadsystems.com'  not monitored&lt;br /&gt;[...]&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-513731684519082486?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/513731684519082486/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=513731684519082486' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/513731684519082486'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/513731684519082486'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2011/01/un-monit.html' title='Un-monit'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-2394917883349303218</id><published>2010-09-28T15:45:00.003+02:00</published><updated>2010-09-28T15:57:03.823+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='directory server'/><category scheme='http://www.blogger.com/atom/ns#' term='opends'/><category scheme='http://www.blogger.com/atom/ns#' term='ldap'/><category scheme='http://www.blogger.com/atom/ns#' term='password policy'/><category scheme='http://www.blogger.com/atom/ns#' term='dsee'/><title type='text'>User passwords may not be provided in pre-encoded form</title><content type='html'>One of the very first differences between the OpenDS and DSEE I have noticed &lt;br /&gt;was the possibility of ldapmodifing the userPassword value. In OpenDS this feature is disabled by default.&lt;br /&gt;&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;$ ldapmodify -p 1389 -D cn=dirmgr -j ~/.odspwd&lt;br /&gt;dn: cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;changetype: modify&lt;br /&gt;replace: userpassword&lt;br /&gt;userpassword: {SSHA512}1g9Byn7MOZ1TgZCNY8gw4NA6o8UguyYg0b48d89zJS+AyIs9OP2rHfbZ6aaqTluryTh3Ux1ZW5RSWuTjH9wvtBxFXCxJzyt0&lt;br /&gt;&lt;br /&gt;Processing MODIFY request for cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;MODIFY operation failed&lt;br /&gt;Result Code:  53 (Unwilling to Perform)&lt;br /&gt;Additional Information:  User passwords may not be provided in pre-encoded form&lt;br /&gt;&lt;br /&gt;$ ldapsearch -p 1389 -D cn=dirmgr -j ~/.odspwd -b cn=config "cn=Default Password Policy" ds-cfg-allow-pre-encoded-passwords&lt;br /&gt;dn: cn=Default Password Policy,cn=Password Policies,cn=config&lt;br /&gt;ds-cfg-allow-pre-encoded-passwords: false&lt;br /&gt;&lt;br /&gt;$ ldapsearch -p 1389 -D cn=dirmgr -j ~/.odspwd -b cn=config "cn=Root Password Policy" ds-cfg-allow-pre-encoded-passwords&lt;br /&gt;dn: cn=Root Password Policy,cn=Password Policies,cn=config&lt;br /&gt;ds-cfg-allow-pre-encoded-passwords: false&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;I do not know the pro and con voices in this discussion, but for me there is only one disadvantage - the ability to observe&lt;br /&gt;multiple instances of the same encoded password strings. And it is only the risk when the one who would notice this fact is the bad guy.&lt;br /&gt;In contrast I see only the advantages.&lt;br /&gt;So...&lt;br /&gt;&lt;pre style="color: #003399"&gt;&lt;br /&gt;dn: cn=Root Password Policy,cn=Password Policies,cn=config&lt;br /&gt;changetype: modify&lt;br /&gt;replace: ds-cfg-allow-pre-encoded-passwords&lt;br /&gt;ds-cfg-allow-pre-encoded-passwords: true&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;LDIF has been implemented.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;$ encode-password -s SSHA512 -f ~/.odspwd&lt;br /&gt;Encoded Password:  "{SSHA512}Gur7YkCGk4oP2sun+KqpXF4rB9wmzUgjhb3P6hBNmNRLBBQgTxSwLR5WuO41yytG9sUzslYc2HyUAM1otujRW+UkAOapbB7c"&lt;br /&gt;&lt;br /&gt;$ ldapmodify -p 1389 -D cn=dirmgr -j ~/.odspwd&lt;br /&gt;dn: cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;changetype: modify&lt;br /&gt;replace: userpassword&lt;br /&gt;userpassword: {SSHA512}Gur7YkCGk4oP2sun+KqpXF4rB9wmzUgjhb3P6hBNmNRLBBQgTxSwLR5WuO41yytG9sUzslYc2HyUAM1otujRW+UkAOapbB7c&lt;br /&gt;&lt;br /&gt;Processing MODIFY request for cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;MODIFY operation successful for DN cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;&lt;br /&gt;$ ldapsearch -p 1389 -D cn=dsmgr -j ~/.dspwd -b cn=config "cn=odsmgr" +&lt;br /&gt;The simple bind attempt failed&lt;br /&gt;Result Code:  49 (Invalid Credentials)&lt;br /&gt;$ ldapsearch -p 1389 -D cn=dsmgr -j ~/.odspwd -b cn=config "cn=odsmgr" +&lt;br /&gt;dn: cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;modifiersName: cn=Directory Manager,cn=Root DNs,cn=config&lt;br /&gt;modifyTimestamp: 20100927104857Z&lt;br /&gt;createTimestamp: 20100924124513Z&lt;br /&gt;pwdChangedTime: 20100927104857.435Z&lt;br /&gt;creatorsName: cn=Directory Manager,cn=Root DNs,cn=config&lt;br /&gt;entryDN: cn=odsmgr,cn=root dns,cn=config&lt;br /&gt;entryUUID: 99296ddd-e705-468b-8112-afd19bb38821&lt;br /&gt;hasSubordinates: false&lt;br /&gt;subschemaSubentry: cn=schema&lt;br /&gt;ds-pwp-password-policy-dn: cn=Root Password Policy,cn=Password Policies,cn=confi&lt;br /&gt; g&lt;br /&gt;structuralObjectClass: inetOrgPerson&lt;br /&gt;numSubordinates: 0&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-2394917883349303218?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/2394917883349303218/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=2394917883349303218' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2394917883349303218'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2394917883349303218'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/09/user-passwords-may-not-be-provided-in.html' title='User passwords may not be provided in pre-encoded form'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-4816423409039829176</id><published>2010-09-26T20:51:00.002+02:00</published><updated>2010-09-26T20:59:24.364+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='directory server'/><category scheme='http://www.blogger.com/atom/ns#' term='opends'/><category scheme='http://www.blogger.com/atom/ns#' term='ldap'/><category scheme='http://www.blogger.com/atom/ns#' term='password policy'/><category scheme='http://www.blogger.com/atom/ns#' term='directory manager'/><title type='text'>Directory Managers. Lots of Directory Managers.</title><content type='html'>Last week I have decided to take some OpenDS practise. The practical solving of a problem is better&lt;br /&gt;then hundreds lines of reading about the others activity. At least that's the way I feel.&lt;br /&gt;Task: Multiple the Directory Manager account to delegate administration without providing your secret password.&lt;br /&gt;&lt;br /&gt;In theory it is possible without any problems.&lt;br /&gt;The only requirement is the object class of &lt;em&gt;ds-cfg-root-dn-user&lt;/em&gt;.&lt;br /&gt;I have copied almost the all attributes from the current "root" account into a new one.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;$ ldapsearch -p 1389 -D cn=dirmgr -j ~/.odspwd -b cn=config "cn=Directory Manager"&lt;br /&gt;dn: cn=Directory Manager,cn=Root DNs,cn=config&lt;br /&gt;sn: Manager&lt;br /&gt;ds-cfg-alternate-bind-dn: cn=dirmgr&lt;br /&gt;cn: Directory Manager&lt;br /&gt;givenName: Directory&lt;br /&gt;objectClass: ds-cfg-root-dn-user&lt;br /&gt;objectClass: top&lt;br /&gt;objectClass: inetOrgPerson&lt;br /&gt;objectClass: organizationalPerson&lt;br /&gt;objectClass: person&lt;br /&gt;userpassword: {SSHA512}1g9Byn7MOZ1TgZCNY8gw4NA6o8UguyYg0b48d89zJS+AyIs9OP2rHfbZ6&lt;br /&gt; aaqTluryTh3Ux1ZW5RSWuTjH9wvtBxFXCxJzyt0&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;$ ldapmodify -p 1389 -D cn=dirmgr -j ~/.odspwd&lt;br /&gt;dn: cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;changetype: add&lt;br /&gt;objectClass: ds-cfg-root-dn-user&lt;br /&gt;objectClass: top&lt;br /&gt;objectClass: inetOrgPerson&lt;br /&gt;objectClass: organizationalPerson&lt;br /&gt;objectClass: person&lt;br /&gt;cn: odsmgr&lt;br /&gt;givenName: ODS&lt;br /&gt;sn: Manager&lt;br /&gt;userPAssword: secret&lt;br /&gt;&lt;br /&gt;Processing ADD request for cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;ADD operation successful for DN cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;For the initial testing I have duplicated also the password.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;$ ldappasswordmodify -p 1389 -D "cn=dirmgr" -j ~/.odspwd \&lt;br /&gt;&gt; -a "dn:cn=odsmgr,cn=Root DNs,cn=config" -c secret -N ~/.odspwd  &lt;br /&gt;The LDAP password modify operation was successful&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;During the cut'n'copy session of ldapmodify I have omitted &lt;em&gt;ds-cfg-alternate-bind-dn&lt;/em&gt; intentionally. &lt;br /&gt;I thought the adjective "alternate" is self-explanatory.&lt;br /&gt;Wrong!&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;$ ldapsearch -p 1389 -D cn=odsmgr -j ~/.odspwd -b cn=config cn=odsmgr&lt;br /&gt;The simple bind attempt failed&lt;br /&gt;Result Code:  49 (Invalid Credentials)&lt;br /&gt;&lt;br /&gt;$ ldapmodify -p 1389 -D "cn=dirmgr" -j ~/.odspwd&lt;br /&gt;dn: cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;changetype: modify&lt;br /&gt;add: ds-cfg-alternate-bind-dn&lt;br /&gt;ds-cfg-alternate-bind-dn: cn=odsmgr&lt;br /&gt;&lt;br /&gt;Processing MODIFY request for cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;MODIFY operation successful for DN cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;&lt;br /&gt;$ ldapsearch -p 1389 -D cn=odsmgr -j ~/.odspwd -b cn=config cn=odsmgr&lt;br /&gt;dn: cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;sn: Manager&lt;br /&gt;ds-cfg-alternate-bind-dn: cn=odsmgr&lt;br /&gt;cn: odsmgr&lt;br /&gt;givenName: ODS&lt;br /&gt;objectClass: top&lt;br /&gt;objectClass: ds-cfg-root-dn-user&lt;br /&gt;objectClass: organizationalPerson&lt;br /&gt;objectClass: inetOrgPerson&lt;br /&gt;objectClass: person&lt;br /&gt;userPassword: {SSHA}gF7nQ6N6gmpuufM1/8FemlwH1/HikScaVOlP3Q==&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Why not to test a case with multiple &lt;em&gt;ds-cfg-alternate-bind-dn&lt;/em&gt; attibute values.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;$ ldapmodify -p 1389 -D "cn=dirmgr" -j ~/.odspwd&lt;br /&gt;dn: cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;changetype: modify&lt;br /&gt;add: ds-cfg-alternate-bind-dn&lt;br /&gt;ds-cfg-alternate-bind-dn: cn=dsmgr&lt;br /&gt;&lt;br /&gt;Processing MODIFY request for cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;MODIFY operation successful for DN cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;&lt;br /&gt;$ ldapsearch -p 1389 -D cn=dsmgr -j ~/.odspwd -b cn=config cn=odsmgr&lt;br /&gt;dn: cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;ds-cfg-alternate-bind-dn: cn=odsmgr&lt;br /&gt;ds-cfg-alternate-bind-dn: cn=dsmgr&lt;br /&gt;sn: Manager&lt;br /&gt;cn: odsmgr&lt;br /&gt;givenName: ODS&lt;br /&gt;objectClass: ds-cfg-root-dn-user&lt;br /&gt;objectClass: top&lt;br /&gt;objectClass: inetOrgPerson&lt;br /&gt;objectClass: organizationalPerson&lt;br /&gt;objectClass: person&lt;br /&gt;userPassword: {SSHA}gF7nQ6N6gmpuufM1/8FemlwH1/HikScaVOlP3Q==&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;But wait a minute. Why the userPassword value is encoded with a &lt;b&gt;SSHA&lt;/b&gt; password scheme, while &lt;br /&gt;the Directory Manager and the default root scheme is pointing to &lt;b&gt;SSHA512&lt;/b&gt;.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;$ ldapsearch -p 1389 -D cn=dsmgr -j ~/.odspwd -b cn=config cn="Directory Manager" userpassword&lt;br /&gt;dn: cn=Directory Manager,cn=Root DNs,cn=config&lt;br /&gt;userpassword: {SSHA512}1g9Byn7MOZ1TgZCNY8gw4NA6o8UguyYg0b48d89zJS+AyIs9OP2rHfbZ6&lt;br /&gt; aaqTluryTh3Ux1ZW5RSWuTjH9wvtBxFXCxJzyt0&lt;br /&gt; &lt;br /&gt;$ ldapsearch -p 1389 -D cn=dsmgr -j ~/.dspwd -b cn=config "cn=Root Password Policy" \&lt;br /&gt;&gt; ds-cfg-default-password-storage-scheme&lt;br /&gt;dn: cn=Root Password Policy,cn=Password Policies,cn=config&lt;br /&gt;ds-cfg-default-password-storage-scheme: cn=Salted SHA-512,cn=Password Storage Sc&lt;br /&gt; hemes,cn=config &lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;The answer has come with the hint from &lt;a href="http://twitter.com/LudoMP"&gt;Ludovic Poitou&lt;/a&gt;.&lt;br /&gt;The virtual attribute of &lt;em&gt;ds-pwp-password-policy-dn&lt;/em&gt; should be set explicitly.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;$ ldapmodify -p 1389 -D cn=dsmgr -j ~/.odspwd&lt;br /&gt;dn: cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;changetype: modify&lt;br /&gt;add: ds-pwp-password-policy-dn&lt;br /&gt;ds-pwp-password-policy-dn: cn=Root Password Policy,cn=Password Policies,cn=config&lt;br /&gt;&lt;br /&gt;Processing MODIFY request for cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;MODIFY operation successful for DN cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;&lt;br /&gt;$ openssl rand -base64 12 &gt; ~/.dspwd&lt;br /&gt;&lt;br /&gt;$ ldappasswordmodify -p 1389 -D cn=dsmgr -j ~/.odspwd -a "cn=odsmgr,cn=Root DNs,cn=config" \&lt;br /&gt;&gt; -C ~/.odspwd -N ~/.dspwd&lt;br /&gt;The LDAP password modify operation was successful&lt;br /&gt;&lt;br /&gt;$ ldapsearch -p 1389 -D cn=dsmgr -j ~/.dspwd -b cn=config cn=odsmgr userpassword&lt;br /&gt;dn: cn=odsmgr,cn=Root DNs,cn=config&lt;br /&gt;userpassword: {SSHA512}BxvZzrhuVpwOv6FMc9sI1infjPC7PQ0dXXdry4ZLNgq6FJbjCVfSiLwBO&lt;br /&gt; A1uzaXAscS7pkNbfkP4hG11L9DTPsRfpusta+4x&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Nice.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-4816423409039829176?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/4816423409039829176/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=4816423409039829176' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4816423409039829176'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4816423409039829176'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/09/directory-managers-lots-of-directory.html' title='Directory Managers. Lots of Directory Managers.'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-8492258995284398500</id><published>2010-09-21T21:18:00.007+02:00</published><updated>2010-09-21T22:09:36.739+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='directory server'/><category scheme='http://www.blogger.com/atom/ns#' term='comms'/><category scheme='http://www.blogger.com/atom/ns#' term='da'/><category scheme='http://www.blogger.com/atom/ns#' term='ldap'/><category scheme='http://www.blogger.com/atom/ns#' term='delegated administrator'/><category scheme='http://www.blogger.com/atom/ns#' term='service packages'/><title type='text'>Custom Service Packages</title><content type='html'>During each subsequent comms implementation I forget one or more steps from the following recipe.&lt;br /&gt;So, here comes the milestones to remember.&lt;br /&gt;For the complete documentation refer to the &lt;a href="http://wikis.sun.com/display/CommSuite7/Delegated+Administrator+7+Initial+Configuration"&gt;wikis.sun.com&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Template for basic set of packages - &lt;strong&gt;da.cos.skeleton.ldif&lt;/strong&gt; can be found in directory:&lt;br /&gt;&lt;strong&gt;/opt/sun/comms/da/lib/config-templates/&lt;/strong&gt;&lt;br /&gt;on Delegated Administrator default installation path.&lt;br /&gt;&lt;br /&gt;Usually I use only the packages for MailUser, MailCalendarUser and MailGroup.&lt;br /&gt;After the customization the file might look like:&lt;br /&gt;&lt;pre style="color: #003399"&gt;&lt;br /&gt;dn: cn=wisniosMailUser,o=mailuser,o=cosTemplates,o=root&lt;br /&gt;changetype: add&lt;br /&gt;objectclass: top&lt;br /&gt;objectclass: LDAPsubentry&lt;br /&gt;objectclass: extensibleobject&lt;br /&gt;objectclass: cosTemplate&lt;br /&gt;cn: wisniosMailUser&lt;br /&gt;mailMsgMaxBlocks: 5000&lt;br /&gt;mailAllowedServiceAccess: +imap,imaps,pop,pops,smtp,smtps,http,smime:ALL&lt;br /&gt;daServiceType: mail user&lt;br /&gt;&lt;br /&gt;dn: cn=wisniosMailCalendarUser,o=mailcalendaruser,o=cosTemplates,o=root&lt;br /&gt;changetype: add&lt;br /&gt;objectclass: top&lt;br /&gt;objectclass: LDAPsubentry&lt;br /&gt;objectclass: extensibleobject&lt;br /&gt;objectclass: cosTemplate&lt;br /&gt;cn: wisniosMailCalendarUser&lt;br /&gt;mailMsgMaxBlocks: 5000&lt;br /&gt;mailAllowedServiceAccess: +imap,imaps,pop,pops,smtp,smtps,http,smime:ALL&lt;br /&gt;daServiceType: calendar user&lt;br /&gt;daServiceType: mail user&lt;br /&gt;&lt;br /&gt;dn: cn=wisniosMailGroup,o=mailgroup,o=cosTemplates,o=root&lt;br /&gt;changetype: add&lt;br /&gt;objectclass: top&lt;br /&gt;objectclass: LDAPsubentry&lt;br /&gt;objectclass: extensibleobject&lt;br /&gt;objectclass: cosTemplate&lt;br /&gt;cn: wisniosMailGroup&lt;br /&gt;mailMsgMaxBlocks: 5000&lt;br /&gt;daServiceType: mail group&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Dry run:&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# ldapmodify -p 1389 -D cn=dirmgr -j /root/.dspwd -n -f da.cos.wisnios.ldif &lt;br /&gt;!adding new entry cn=wisniosMailUser,o=mailuser,o=cosTemplates,o=root&lt;br /&gt;&lt;br /&gt;!adding new entry cn=wisniosMailCalendarUser,o=mailcalendaruser,o=cosTemplates,o=root&lt;br /&gt;&lt;br /&gt;!adding new entry cn=wisniosMailGroup,o=mailgroup,o=cosTemplates,o=root&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Wet run:&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# ldapmodify -p 1389 -D cn=dirmgr -j /root/.dspwd -f da.cos.wisnios.ldif &lt;br /&gt;adding new entry cn=wisniosMailUser,o=mailuser,o=cosTemplates,o=root&lt;br /&gt;&lt;br /&gt;adding new entry cn=wisniosMailCalendarUser,o=mailcalendaruser,o=cosTemplates,o=root&lt;br /&gt;&lt;br /&gt;adding new entry cn=wisniosMailGroup,o=mailgroup,o=cosTemplates,o=root&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Check:&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# ldapsearch -p 1389 -D cn=dirmgr -j /root/.dspwd -b o=cosTemplates,o=root \&lt;br /&gt;&gt; "(&amp;(cn=wisnios*)(objectclass=LDAPsubentry))" daServiceType&lt;br /&gt;version: 1&lt;br /&gt;dn: cn=wisniosMailUser,o=mailuser,o=cosTemplates,o=root&lt;br /&gt;daServiceType: mail user&lt;br /&gt;&lt;br /&gt;dn: cn=wisniosMailCalendarUser,o=mailcalendaruser,o=cosTemplates,o=root&lt;br /&gt;daServiceType: calendar user&lt;br /&gt;daServiceType: mail user&lt;br /&gt;&lt;br /&gt;dn: cn=wisniosMailGroup,o=mailgroup,o=cosTemplates,o=root&lt;br /&gt;daServiceType: mail group&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;To make sure that the changes (packages) will be visible restart the app/web container.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-8492258995284398500?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/8492258995284398500/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=8492258995284398500' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8492258995284398500'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8492258995284398500'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/09/custom-service-packages.html' title='Custom Service Packages'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-632355776825621930</id><published>2010-09-08T20:30:00.007+02:00</published><updated>2010-09-09T00:38:06.219+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='messaging server'/><category scheme='http://www.blogger.com/atom/ns#' term='spamassassin'/><category scheme='http://www.blogger.com/atom/ns#' term='rbac'/><category scheme='http://www.blogger.com/atom/ns#' term='comms'/><category scheme='http://www.blogger.com/atom/ns#' term='spam'/><category scheme='http://www.blogger.com/atom/ns#' term='convergence'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>How to automate the SpamAssassin feeding</title><content type='html'>This post is my answer to the Sun Wikis' &lt;a href="http://wikis.sun.com/display/CommSuite7U1090210/Convergence+Administrative+Tasks#ConvergenceAdministrativeTasks-EnablingAntiSpam"&gt;entry&lt;/a&gt; about Enabling Anti-Spam functionality in Convergence.&lt;br /&gt;&lt;br /&gt;Technologies used:&lt;br /&gt;Messaging Server&lt;br /&gt;SpamAssassin&lt;br /&gt;RBAC - execution profiles&lt;br /&gt;&lt;br /&gt;Messaging Server use the two variables to hold the email accounts for feeding anti-spam system&lt;br /&gt; with the positive and false positive spam messages: &lt;br /&gt;&lt;ul&gt;&lt;br /&gt; &lt;li&gt;service.feedback.spam&lt;/li&gt;&lt;br /&gt; &lt;li&gt;service.feedback.notspam&lt;/li&gt;&lt;br /&gt;&lt;/ul&gt;&lt;br /&gt;But there is no embedded mechanism to deal with them.&lt;br /&gt;Here comes my solution.&lt;br /&gt;&lt;br /&gt;Every time the Convergence user marks the spam (ot not spam), with the appropriate button from its interface,&lt;br /&gt;the mail is being sent to the address provided within the configuration.&lt;br /&gt;The email messages accumulate in the accounts and waiting for the action.&lt;br /&gt;&lt;br /&gt;Scenario:&lt;br /&gt;&lt;ul&gt;&lt;br /&gt; &lt;li&gt;fetching messages from spam account&lt;/li&gt;&lt;br /&gt; &lt;li&gt;teaching spamassassin with spam&lt;/li&gt;&lt;br /&gt; &lt;li&gt;cleaing INBOX folder&lt;/li&gt; &lt;br /&gt; &lt;li&gt;fetching messages from notspam account&lt;/li&gt;&lt;br /&gt; &lt;li&gt;teaching SA with ham&lt;/li&gt;&lt;br /&gt; &lt;li&gt;cleaning account&lt;/li&gt;&lt;br /&gt;&lt;/ul&gt;&lt;br /&gt;&lt;br /&gt;Methods:&lt;br /&gt;&lt;ul&gt;&lt;br /&gt; &lt;li&gt;fetching messages from spam account&lt;/li&gt;&lt;br /&gt; &lt;ol type="i"&gt;&lt;br /&gt;         &lt;li&gt;imsexport&lt;/li&gt;&lt;br /&gt; &lt;/ol&gt;&lt;br /&gt; &lt;li&gt;teaching spamassassin with spam&lt;/li&gt;&lt;br /&gt; &lt;ol type="i"&gt;&lt;br /&gt;         &lt;li&gt;sa-learn --spam&lt;/li&gt;&lt;br /&gt; &lt;/ol&gt;&lt;br /&gt; &lt;li&gt;cleaing INBOX folder&lt;/li&gt; &lt;br /&gt; &lt;ol type="i"&gt;&lt;br /&gt;         &lt;li&gt;mboxutil -d&lt;/li&gt;&lt;br /&gt;         &lt;li&gt;mboxutil -c&lt;/li&gt;&lt;br /&gt; &lt;/ol&gt;&lt;br /&gt; &lt;li&gt;fetching messages from notspam account&lt;/li&gt;&lt;br /&gt; &lt;ol type="i"&gt;&lt;br /&gt;         &lt;li&gt;imsexport&lt;/li&gt;&lt;br /&gt; &lt;/ol&gt; &lt;br /&gt; &lt;li&gt;teaching SA with ham&lt;/li&gt;&lt;br /&gt; &lt;ol type="i"&gt;&lt;br /&gt;         &lt;li&gt;sa-learn --ham&lt;/li&gt;&lt;br /&gt; &lt;/ol&gt;&lt;br /&gt; &lt;li&gt;cleaning account&lt;/li&gt;&lt;br /&gt; &lt;ol type="i"&gt;&lt;br /&gt;         &lt;li&gt;mboxutil -d&lt;/li&gt;&lt;br /&gt;         &lt;li&gt;mboxutil -c&lt;/li&gt;&lt;br /&gt; &lt;/ol&gt;&lt;br /&gt;&lt;/ul&gt;&lt;br /&gt;Due to a fact the script will be invoked by root account, to get the access either to imsexport files or sa-learn with valid Bayes DB,&lt;br /&gt;I have decided to use one of the Solaris RBAC mechanisms - profiles.&lt;br /&gt;&lt;br /&gt;I would not describe the profile creation step-by-step, because the learning by example is much more valuable.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# /usr/sadm/bin/smexec add -H localhost -u root -- \&lt;br /&gt;-n "SpamAssassin Administration" -t cmd -c /export/home/sa/bin/sa-learn -U 105 -G 102&lt;br /&gt;Authenticating as user: root&lt;br /&gt;&lt;br /&gt;Type /? for help, pressing &lt;enter&gt; accepts the default denoted by [ ]&lt;br /&gt;Please enter a string value for: password ::&lt;br /&gt;There is no Solaris Management Console Server running on localhost.&lt;br /&gt;^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^&lt;br /&gt;\&lt;br /&gt;# svcadm enable wbem&lt;br /&gt;&lt;br /&gt;# /usr/sadm/bin/smexec add -H localhost -u root -- \&lt;br /&gt;-n "SpamAssassin Administration" -t cmd -c /export/home/sa/bin/sa-learn -U 105 -G 102&lt;br /&gt;Authenticating as user: root&lt;br /&gt;&lt;br /&gt;Type /? for help, pressing &lt;enter&gt; accepts the default denoted by [ ]&lt;br /&gt;Please enter a string value for: password ::&lt;br /&gt;Loading Tool: com.sun.admin.usermgr.cli.execs.UserMgrExecCli from localhost&lt;br /&gt;Login to localhost as user root was successful.&lt;br /&gt;Download of com.sun.admin.usermgr.cli.execs.UserMgrExecCli from localhost was successful.&lt;br /&gt;You have entered a non-existent right SpamAssassin Administration.&lt;br /&gt;^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^&lt;br /&gt;\&lt;br /&gt;# cd /usr/lib/help/profiles/locale/C&lt;br /&gt;# cat RtSAAdmin.html&lt;br /&gt;&lt; HTML &gt;&lt;br /&gt;&lt; HEAD &gt;&lt;br /&gt;&lt; TITLE &gt;&lt; /TITLE &gt;&lt;br /&gt;&lt; /HEAD &gt;&lt;br /&gt;&lt; BODY &gt;&lt;br /&gt;SpamAssassin Administration right allows the user or role SA management.&lt;br /&gt;&lt; /BODY &gt;&lt;br /&gt;&lt; /HTML &gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;^^^^^&lt;br /&gt;Spaces has been added to HTML tags in due to blogspot problems with handling this kind of stuff within the post body.&lt;br /&gt;&lt;pre style="color: #006600"&gt;&lt;br /&gt;# /usr/sadm/bin/smprofile add -H localhost -u root -- \&lt;br /&gt;-n "SpamAssassin Administration" -d "Manage SpamAssassin" -m RtSAAdmin.html&lt;br /&gt;Authenticating as user: root&lt;br /&gt;&lt;br /&gt;Type /? for help, pressing &lt;enter&gt; accepts the default denoted by [ ]&lt;br /&gt;Please enter a string value for: password ::&lt;br /&gt;Loading Tool: com.sun.admin.usermgr.cli.profile.UserMgrProfCli from localhost&lt;br /&gt;Login to localhost as user root was successful.&lt;br /&gt;Download of com.sun.admin.usermgr.cli.profile.UserMgrProfCli from localhost was successful.&lt;br /&gt;&lt;br /&gt;# tail -1 /etc/security/prof_attr&lt;br /&gt;SpamAssassin Administration:::Manage SpamAssassin:help=RtSAAdmin.html&lt;br /&gt; &lt;br /&gt;# /usr/sadm/bin/smexec add -H localhost -u root -- \&lt;br /&gt;-n "SpamAssassin Administration" -t cmd -c /export/home/sa/bin/sa-learn -U 105 -G 102&lt;br /&gt;Authenticating as user: root&lt;br /&gt;&lt;br /&gt;Type /? for help, pressing &lt;enter&gt; accepts the default denoted by [ ]&lt;br /&gt;Please enter a string value for: password ::&lt;br /&gt;Loading Tool: com.sun.admin.usermgr.cli.execs.UserMgrExecCli from localhost&lt;br /&gt;Login to localhost as user root was successful.&lt;br /&gt;Download of com.sun.admin.usermgr.cli.execs.UserMgrExecCli from localhost was successful.&lt;br /&gt;&lt;br /&gt;# tail -1 /etc/security/exec_attr&lt;br /&gt;SpamAssassin Administration:solaris:cmd:::/export/home/sa/bin/sa-learn:uid=105;gid=102&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;So, running &lt;em&gt;sa-learn&lt;/em&gt; by the user / role with "SpamAssassin Administration" profile assigned&lt;br /&gt;allow access to bayes DB files with the proper rights.&lt;br /&gt;Examples can be seen in the script code provided below.&lt;br /&gt;&lt;br /&gt;&lt;pre style="color: #003399"&gt;&lt;br /&gt;#!/usr/bin/ksh&lt;br /&gt;#------------------------------------&lt;br /&gt;# sa-feed.ksh&lt;br /&gt;#  feed SpamAssassin with {NOT}SPAM&lt;br /&gt;#   from file in mbox format&lt;br /&gt;#====================================&lt;br /&gt;# author: Marcin Wisnios&lt;br /&gt;# e-mail: wisnios at wisnios dot com&lt;br /&gt;#------------------------------------&lt;br /&gt;PATH=$PATH:/opt/sun/comms/messaging64/bin:/export/home/sa/bin&lt;br /&gt;&lt;br /&gt;TDIR=$(mktemp -td)                                      # temporary directory&lt;br /&gt;FILE=$TDIR/INBOX                                        # mbox file&lt;br /&gt;MUSR=$(ps -o user -p $(pgrep -nf dispatcher) | tail -1) # messaging server runtime user&lt;br /&gt;SUSR=$(ps -o user -p $(pgrep -nf spamd) | tail -1)      # spamassassin runtime user&lt;br /&gt;SPAM=$(configutil -o service.feedback.spam)             # feedback account for spam&lt;br /&gt;NOTSPAM=$(configutil -o service.feedback.notspam)       # feedback account for not spam&lt;br /&gt;BDBL=/export/home/sa/.spamassassin                      # Bayes DB location&lt;br /&gt;SALEARN="pfexec sa-learn --dbpath $BDBL"                # fixed part of sa-learn invocation&lt;br /&gt;&lt;br /&gt;chown $MUSR $TDIR&lt;br /&gt;chmod 0755 $TDIR&lt;br /&gt;&lt;br /&gt;imsexport -s INBOX -d $TDIR -u $SPAM&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;[ -f $FILE ] &amp;&amp; {&lt;br /&gt;        chown $SUSR $FILE&lt;br /&gt;&lt;br /&gt;        NSPAM_BEFORE=$($SALEARN --dump magic 2&gt; /dev/null | grep nspam | awk '{print $3}')&lt;br /&gt;        $SALEARN --mbox --spam $FILE 2&gt; /dev/null &amp;&amp;\&lt;br /&gt;        NSPAM_AFTER=$($SALEARN --dump magic 2&gt; /dev/null | grep nspam | awk '{print $3}')&lt;br /&gt;&lt;br /&gt;        [ $NSPAM_BEFORE -lt $NSPAM_AFTER ] &amp;&amp; {&lt;br /&gt;                mboxutil -d user/$SPAM/INBOX&lt;br /&gt;                mboxutil -c user/$SPAM/INBOX&lt;br /&gt;        }&lt;br /&gt;&lt;br /&gt;        rm $FILE&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;imsexport -s INBOX -d $TDIR -u $NOTSPAM&lt;br /&gt;&lt;br /&gt;[ -f $FILE ] &amp;&amp; {&lt;br /&gt;        chown $SUSR $FILE&lt;br /&gt;&lt;br /&gt;        NHAM_BEFORE=$($SALEARN --dump magic 2&gt; /dev/null | grep nham | awk '{print $3}')&lt;br /&gt;        $SALEARN --mbox --ham $FILE 2&gt; /dev/null &amp;&amp;\&lt;br /&gt;        NHAM_AFTER=$($SALEARN --dump magic 2&gt; /dev/null | grep nham | awk '{print $3}')&lt;br /&gt;&lt;br /&gt;        [ $NHAM_BEFORE -lt $NHAM_AFTER ] &amp;&amp; {&lt;br /&gt;                mboxutil -d user/$NOTSPAM/INBOX&lt;br /&gt;                mboxutil -c user/$NOTSPAM/INBOX&lt;br /&gt;        }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;[ -d $TDIR ] &amp;&amp; rm -rf $TDIR&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Run the script in a way you like.&lt;br /&gt;I put it directly to a crontab. Root's crontab.&lt;br /&gt;&lt;br /&gt;Enjoy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-632355776825621930?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/632355776825621930/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=632355776825621930' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/632355776825621930'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/632355776825621930'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/09/how-to-automate-spamassassin-feeding.html' title='How to automate the SpamAssassin feeding'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-7113896672833733026</id><published>2010-06-25T19:53:00.007+02:00</published><updated>2010-06-25T21:33:37.613+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='gpg'/><category scheme='http://www.blogger.com/atom/ns#' term='spamassassin'/><category scheme='http://www.blogger.com/atom/ns#' term='library'/><category scheme='http://www.blogger.com/atom/ns#' term='crle'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>crle and missing libusb.so.1 library</title><content type='html'>Today I have installed SpamAssassin from a tar.gz archive on Solaris 10 10/09.&lt;br /&gt;Though everything looked fine I faced the problem with invocation of sa-update - SpamAssassin rules updater.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;$ sa-update&lt;br /&gt;ld.so.1: gpg: fatal: libusb.so.1: open failed: No such file or directory&lt;br /&gt;Killed&lt;br /&gt;ld.so.1: gpg: fatal: libusb.so.1: open failed: No such file or directory&lt;br /&gt;Killed&lt;br /&gt;error: GPG validation failed!&lt;br /&gt;The update downloaded successfully, but the GPG signature verification&lt;br /&gt;failed.&lt;br /&gt;channel: GPG validation failed, channel failed&lt;br /&gt;$ gpg&lt;br /&gt;ld.so.1: gpg: fatal: libusb.so.1: open failed: No such file or directory&lt;br /&gt;Killed&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;(gnupg has been installed from a package from sunfreeware.com, but it was not a problem)&lt;br /&gt;&lt;br /&gt;Quick truss session:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# truss gpg&lt;br /&gt;[...]&lt;br /&gt;stat64("/usr/local/lib/libusb.so.1", 0x080473A0) Err#2 ENOENT&lt;br /&gt;stat64("/usr/local/ssl/lib/libusb.so.1", 0x080473A0) Err#2 ENOENT&lt;br /&gt;stat64("/usr/openwin/lib/libusb.so.1", 0x080473A0) Err#2 ENOENT&lt;br /&gt;stat64("/usr/lib/libusb.so.1", 0x080473A0)      Err#2 ENOENT&lt;br /&gt;stat64("/usr/X11R6/lib/libusb.so.1", 0x080473A0) Err#2 ENOENT&lt;br /&gt;stat64("/usr/local/BerkeleyDB.4.7/lib/libusb.so.1", 0x080473A0) Err#2 ENOENT&lt;br /&gt;stat64("/lib/libusb.so.1", 0x080473A0)          Err#2 ENOENT&lt;br /&gt;stat64("/usr/lib/libusb.so.1", 0x080473A0)      Err#2 ENOENT&lt;br /&gt;ld.so.1: gpg: fatal: libusb.so.1: open failed: No such file or directory&lt;br /&gt;[...]&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;find lookup:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# find /usr -name libusb.so.1&lt;br /&gt;/usr/sfw/lib/libusb.so.1&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;...and I had to change the default library path.&lt;br /&gt;The tool - crle - runtime linking environment configurator, was taken as the only fair solution.&lt;br /&gt;Do not want to reproduce the manual pages, so, below is the syntax I had used.&lt;br /&gt;Checking the current options:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# crle&lt;br /&gt;&lt;br /&gt;Configuration file [version 4]: /var/ld/ld.config  &lt;br /&gt;  Default Library Path (ELF):   /lib:/usr/lib  (system default)&lt;br /&gt;  Trusted Directories (ELF):    /usr/lib/secure:/opt/sun/comms/calendar/SUNWics5/cal/lib&lt;br /&gt;&lt;br /&gt;Command line:&lt;br /&gt;  crle -c /var/ld/ld.config -s /usr/lib/secure:/opt/sun/comms/calendar/SUNWics5/cal/lib&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Complementation of default library path:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# crle -c /var/ld/ld.config -l /lib:/usr/lib:/usr/sfw/lib -s /usr/lib/secure:/opt/sun/comms/calendar/SUNWics5/cal/lib&lt;br /&gt;&lt;br /&gt;[CHECK]&lt;br /&gt;# crle&lt;br /&gt;Configuration file [version 4]: /var/ld/ld.config  &lt;br /&gt;  Default Library Path (ELF):   /lib:/usr/lib:/usr/sfw/lib&lt;br /&gt;  Trusted Directories (ELF):    /usr/lib/secure:/opt/sun/comms/calendar/SUNWics5/cal/lib&lt;br /&gt;&lt;br /&gt;Command line:&lt;br /&gt;  crle -c /var/ld/ld.config -l /lib:/usr/lib:/usr/sfw/lib -s /usr/lib/secure:/opt/sun/comms/calendar/SUNWics5/cal/lib&lt;br /&gt;# exit&lt;br /&gt;$ gpg&lt;br /&gt;gpg: WARNING: using insecure memory!&lt;br /&gt;gpg: please see http://www.gnupg.org/faq.html for more information&lt;br /&gt;gpg: directory `/export/home/sa/.gnupg' created&lt;br /&gt;gpg: new configuration file `/export/home/sa/.gnupg/gpg.conf' created&lt;br /&gt;gpg: WARNING: options in `/export/home/sa/.gnupg/gpg.conf' are not yet active during this run&lt;br /&gt;gpg: keyring `/export/home/sa/.gnupg/secring.gpg' created&lt;br /&gt;gpg: keyring `/export/home/sa/.gnupg/pubring.gpg' created&lt;br /&gt;gpg: Go ahead and type your message ...&lt;br /&gt;^C&lt;br /&gt;gpg: signal 2 caught ... exiting&lt;br /&gt;$ sa-update&lt;br /&gt;gpg: WARNING: using insecure memory!&lt;br /&gt;gpg: please see http://www.gnupg.org/faq.html for more information&lt;br /&gt;$&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Final notes&lt;/span&gt;&lt;br /&gt;The syntax being used could be shortened to a form of:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# crle -u -l /usr/sfw/lib&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;where &lt;em&gt;-u&lt;/em&gt; stands for existing configuration (file /var/ld/ld.config) update.&lt;br /&gt;But be aware that by omitting the &lt;em&gt;-u&lt;/em&gt; argument you turn your box into soldered fish tin, until you turn the other directories to the default path.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# crle -l /usr/sfw/lib&lt;br /&gt;# init&lt;br /&gt;ld.so.1: init: fatal: libpam.so.1: open failed: No such file or directory&lt;br /&gt;Killed&lt;br /&gt;# crle -u -l /lib -l /usr/lib -l /usr/sfw/lib&lt;br /&gt;# init&lt;br /&gt;Usage: init [0123456SsQqabc]&lt;br /&gt;#&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-7113896672833733026?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/7113896672833733026/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=7113896672833733026' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7113896672833733026'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7113896672833733026'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/06/crle-and-missing-libusbso1-library.html' title='crle and missing libusb.so.1 library'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-408716613540731873</id><published>2010-06-07T23:13:00.007+02:00</published><updated>2010-09-08T21:08:30.631+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='fmri'/><category scheme='http://www.blogger.com/atom/ns#' term='log'/><category scheme='http://www.blogger.com/atom/ns#' term='smf'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><category scheme='http://www.blogger.com/atom/ns#' term='script'/><title type='text'>svclog</title><content type='html'>Everytime I have to check the SMF log file quickly I suffer.&lt;br /&gt;I suffer in due to lack of simple method which I would provide you today with.&lt;br /&gt;&lt;br /&gt;C'n'P:&lt;br /&gt;&lt;pre style="color: #003399"&gt;&lt;br /&gt;#!/usr/bin/ksh&lt;br /&gt;#------------------------------------&lt;br /&gt;# svclog&lt;br /&gt;#  ...run for your logs&lt;br /&gt;#====================================&lt;br /&gt;# author: Marcin Wisnios&lt;br /&gt;# e-mail: wisnios at wisnios dot com&lt;br /&gt;#------------------------------------&lt;br /&gt;&lt;br /&gt;svcs $1 &gt; /dev/null 2&gt;&amp;1&lt;br /&gt;if [ $? -eq 1 ]; then&lt;br /&gt;        echo "No match."&lt;br /&gt;        exit&lt;br /&gt;fi&lt;br /&gt;&lt;br /&gt;if [ ! -z $1 ]; then&lt;br /&gt;        LOG=$(svcs -l $1 | sed 's/logfile[ ]*\(.*\)/\1/p;d')&lt;br /&gt;        echo "\n\t\t${LOG}\n"&lt;br /&gt;else&lt;br /&gt;        echo "Usage: $0 FMRI [n]"&lt;br /&gt;        echo "n - number of lines to display"&lt;br /&gt;        exit&lt;br /&gt;fi&lt;br /&gt;&lt;br /&gt;if [ ! -z $2 ]; then&lt;br /&gt;        tail -$2 ${LOG}&lt;br /&gt;else&lt;br /&gt;        tail -f ${LOG}&lt;br /&gt;fi&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Save as, for ex. /usr/local/bin/svclog and... run for your logs:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# svclog ds 3&lt;br /&gt;&lt;br /&gt;                /var/svc/log/application-sun-ds:default.log&lt;br /&gt;&lt;br /&gt;Waiting for Directory Server instance '/instances/ds1' to start...&lt;br /&gt;Directory Server instance '/instances/ds1' started: pid=434&lt;br /&gt;[ Jun  7 16:53:00 Method "start" exited with status 0 ]&lt;br /&gt;# svclog ms&lt;br /&gt;&lt;br /&gt;                /var/svc/log/application-sun-ms:default.log&lt;br /&gt;&lt;br /&gt;Stopping dispatcher server 593 ... done&lt;br /&gt;Stopping sched server 591 ... done&lt;br /&gt;Stopping http server 590 ... done&lt;br /&gt;Stopping pop server 589 ...... done&lt;br /&gt;Stopping imap server 588 ... done&lt;br /&gt;Stopping purge server 587 ... done&lt;br /&gt;Stopping store server 584 .... done&lt;br /&gt;Stopping watcher 583 ... done&lt;br /&gt;[ Jun  7 23:40:12 Method "stop" exited with status 0 ]&lt;br /&gt;[ Jun  7 23:40:12 Executing start method ("/opt/sun/comms/messaging64/bin/start-msg") ]&lt;br /&gt;Connecting to watcher ...&lt;br /&gt;Launching watcher ... 1463&lt;br /&gt;Starting store server .... 1464&lt;br /&gt;Checking store server status .....&lt;br /&gt;- CUT -&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Enjoy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-408716613540731873?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/408716613540731873/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=408716613540731873' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/408716613540731873'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/408716613540731873'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/06/svclog.html' title='svclog'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-7684500939697852380</id><published>2010-05-25T19:55:00.009+02:00</published><updated>2010-05-25T20:52:00.811+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='smf'/><category scheme='http://www.blogger.com/atom/ns#' term='fibre channel'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>fc-fabric(ation) of server's dysfunction</title><content type='html'>Do you like minimization? I do.&lt;br /&gt;But sometimes you can go one bridge too far.&lt;br /&gt;&lt;br /&gt;Today I have switched off the set of useless services.&lt;br /&gt;One after one...&lt;br /&gt;Do I need... No!&lt;br /&gt;Do I need... No!&lt;br /&gt;Do I need Fibre Channel Fabric device support? No.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;$ svcadm disable fc-fabric&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Another one bites the dust.&lt;br /&gt;&lt;br /&gt;After the couple of hours I decided to reboot the server to check its readiness to serve.&lt;br /&gt;And... it failed.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_D5SVazG3Wvc/S_wVNgzGoqI/AAAAAAAACYY/pYzcMb3NCIw/s1600/fc-fabric.jpg"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 143px;" src="http://3.bp.blogspot.com/_D5SVazG3Wvc/S_wVNgzGoqI/AAAAAAAACYY/pYzcMb3NCIw/s400/fc-fabric.jpg" border="0" alt=""id="BLOGGER_PHOTO_ID_5475274568862442146" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Of course at the moment of failure I dit not realize it was caused by service unavailability of fc-fabric.&lt;br /&gt;Unnecessary stress.&lt;br /&gt;&lt;br /&gt;The solution has been revealed during the dependencies check.&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_D5SVazG3Wvc/S_wcFKXmljI/AAAAAAAACYw/t_4DvdkoVAc/s1600/fc-fabric_devices.png"&gt;&lt;img style="display:block; margin:0px auto 10px; text-align:center;cursor:pointer; cursor:hand;width: 400px; height: 136px;" src="http://1.bp.blogspot.com/_D5SVazG3Wvc/S_wcFKXmljI/AAAAAAAACYw/t_4DvdkoVAc/s400/fc-fabric_devices.png" border="0" alt=""id="BLOGGER_PHOTO_ID_5475282121983956530" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Keep this in mind.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-7684500939697852380?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/7684500939697852380/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=7684500939697852380' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7684500939697852380'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7684500939697852380'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/05/fc-fabrication-of-servers-dysfunction.html' title='fc-fabric(ation) of server&apos;s dysfunction'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_D5SVazG3Wvc/S_wVNgzGoqI/AAAAAAAACYY/pYzcMb3NCIw/s72-c/fc-fabric.jpg' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-1977378295363452909</id><published>2010-04-29T20:33:00.008+02:00</published><updated>2010-04-29T21:32:54.092+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='restore'/><category scheme='http://www.blogger.com/atom/ns#' term='backup'/><category scheme='http://www.blogger.com/atom/ns#' term='aix'/><title type='text'>AIX backup / restore</title><content type='html'>The commonly used mode of backup utility back up file systems by i-node. It uses the Level param of 0 - for full,&lt;br /&gt; 1 to 9 for incremental backups, and takes the predefined fileset as input (/, /home, /opt, /usr, /var, etc.).&lt;br /&gt;If you want to use the ordinary directory, not the one of predefined filesets use the -i switch.&lt;br /&gt;It takes the list of files from the standard input (back up by name), and when used in conjunction with hyphen sign&lt;br /&gt; as the target device, it can be piped directly to dd, to put the output into the file.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;$ find /etc | backup -i -f - | dd of=/backup/etc.bak&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;To list the content of backup archive use restore with the -T switch.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;$ restore -Tq -f /backup/etc.bak&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;To restore the individually named file use -x switch.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# restore -xqf /backup/etc.bak /etc/passwd&lt;br /&gt;x /etc/passwd&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;...or files (in verbose mode):&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# restore -xqvf /backup/etc.bak /etc/passwd /etc/security/passwd&lt;br /&gt;New volume on /backup/etc.bak:&lt;br /&gt; Cluster 51200 bytes (100 blocks).&lt;br /&gt;    Volume number 1&lt;br /&gt;    Date of backup: Thu Apr 29 12:22:13 2010&lt;br /&gt;    Files backed up by name&lt;br /&gt;    User root&lt;br /&gt;x          560 /etc/passwd&lt;br /&gt;x          288 /etc/security/passwd&lt;br /&gt;    total size: 848&lt;br /&gt;    files restored: 2&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;And to get back all the content of the specified subdirectory use the force of -d&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# restore -xqdf /backup/etc.bak /etc/security&lt;br /&gt;x /etc/security&lt;br /&gt;x /etc/security/.idlck&lt;br /&gt;x /etc/security/.ids&lt;br /&gt;x /etc/security/.kst&lt;br /&gt;x /etc/security/.profile&lt;br /&gt;x /etc/security/acl&lt;br /&gt;x /etc/security/aixpert&lt;br /&gt;x /etc/security/aixpert/bin&lt;br /&gt;x /etc/security/aixpert/bin/ISSServerSensor&lt;br /&gt;x /etc/security/aixpert/bin/audit_report&lt;br /&gt;x /etc/security/aixpert/bin/binaudit&lt;br /&gt;[...]&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Be aware that all the above actions has overwritten the original files.&lt;/strong&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-1977378295363452909?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/1977378295363452909/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=1977378295363452909' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1977378295363452909'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1977378295363452909'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/04/aix-backup-restore.html' title='AIX backup / restore'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-3269541541720306437</id><published>2010-04-27T21:46:00.006+02:00</published><updated>2010-04-27T22:01:46.871+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='hpux'/><category scheme='http://www.blogger.com/atom/ns#' term='mktemp'/><title type='text'>mktemp portability</title><content type='html'>If you ever need to create a script, to run in the closest possible way in all the unix flavours - &lt;br /&gt;beware of HP-UX behaviour of &lt;em&gt;mktemp&lt;/em&gt; command.&lt;br /&gt;&lt;br /&gt;It is the only unix system (I know) where &lt;em&gt;mktemp&lt;/em&gt; do not create randomly named file/directory.&lt;br /&gt;&lt;br /&gt;The result of its actions is just a display of generated name.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-3269541541720306437?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/3269541541720306437/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=3269541541720306437' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/3269541541720306437'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/3269541541720306437'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/04/mktemp-portability.html' title='mktemp portability'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-4711278195070887238</id><published>2010-04-27T21:44:00.000+02:00</published><updated>2010-04-27T21:45:28.255+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='login'/><title type='text'>Silence is golden</title><content type='html'>&lt;pre&gt;&lt;br /&gt;$ touch .hushlogin&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-4711278195070887238?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/4711278195070887238/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=4711278195070887238' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4711278195070887238'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4711278195070887238'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/04/silence-is-golden.html' title='Silence is golden'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-5459467174831903541</id><published>2010-03-09T20:58:00.005+01:00</published><updated>2010-03-09T21:10:08.187+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ssl'/><category scheme='http://www.blogger.com/atom/ns#' term='openssl'/><category scheme='http://www.blogger.com/atom/ns#' term='certificate'/><title type='text'>User interface error</title><content type='html'>Have you ever encountered similar problems during the n-time tryout of the SSL signing process?&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# openssl rsa -in cakey.pem -out cakey.pem&lt;br /&gt;Enter pass phrase for cakey.pem:&lt;br /&gt;User interface error&lt;br /&gt;unable to load Private Key&lt;br /&gt;26116:error:0906A068:PEM routines:PEM_do_header:bad password read:pem_lib.c:403:&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;or...&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# ./CA.pl -sign&lt;br /&gt;Using configuration from /usr/lib/ssl/openssl.cnf&lt;br /&gt;Enter pass phrase for ./demoCA/private/cakey.pem:&lt;br /&gt;User interface error&lt;br /&gt;unable to load CA private key&lt;br /&gt;26676:error:0906A068:PEM routines:PEM_do_header:bad password read:pem_lib.c:403:&lt;br /&gt;Signed certificate is in newcert.pem&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;This is a single-echo-pill solution.&lt;br /&gt;&lt;br /&gt;ad. 1&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# echo | openssl rsa -in cakey.pem -out cakey.pem&lt;br /&gt;Enter pass phrase for cakey.pem:&lt;br /&gt;writing RSA key&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;ad. 2&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# printf "y\ny\n"| ./CA.pl -sign&lt;br /&gt;Using configuration from /usr/lib/ssl/openssl.cnf&lt;br /&gt;Enter pass phrase for ./demoCA/private/cakey.pem:&lt;br /&gt;Check that the request matches the signature&lt;br /&gt;Signature ok&lt;br /&gt;Certificate Details:&lt;br /&gt;[...]&lt;br /&gt;Sign the certificate? [y/n]:&lt;br /&gt;&lt;br /&gt;1 out of 1 certificate requests certified, commit? [y/n]Write out database with 1 new entries&lt;br /&gt;Data Base Updated&lt;br /&gt;Signed certificate is in newcert.pem&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Enjoy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-5459467174831903541?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/5459467174831903541/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=5459467174831903541' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5459467174831903541'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5459467174831903541'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/03/user-interface-error.html' title='User interface error'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-5626715864770676395</id><published>2010-03-03T19:36:00.006+01:00</published><updated>2010-03-03T20:06:59.951+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='pkgadd'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>maximum number of instances of the package</title><content type='html'>Sometimes there is a need of existence of concurrent versions of the same package.&lt;br /&gt;It is not a issue why, but how to achieve this behaviour.&lt;br /&gt;&lt;br /&gt;During the normal installation procedure of the package, with the same name but different version then already installed one, &lt;br /&gt;there is a chance to see a similar message:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# pkgadd -d somepkg*dstream&lt;br /&gt;[...]&lt;br /&gt;Current administration requires that a unique instance of the&lt;br /&gt;&amp;lt;somepkg&amp;gt; package be created.  However, the maximum number of&lt;br /&gt;instances of the package which may be supported at one time on the&lt;br /&gt;same system has already been met.&lt;br /&gt;&lt;br /&gt;No changes were made to the system.&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;To resolve the conflict change the value of &lt;b&gt;MAXINST&lt;/b&gt; variable from inside the &lt;b&gt;&lt;em&gt;pkginfo&lt;/em&gt;&lt;/b&gt; file&lt;br /&gt;(during the package build process).&lt;br /&gt;&lt;br /&gt;For example, to allow the coexistence of maximum number of two packages use the following:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;MAXINST=2&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# pkgadd -d somepkg*dstream&lt;br /&gt;[...]&lt;br /&gt;&lt;br /&gt;Installation of &amp;lt;somepkg.2&amp;gt; was successful.&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-5626715864770676395?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/5626715864770676395/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=5626715864770676395' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5626715864770676395'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5626715864770676395'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/03/maximum-number-of-instances-of-package.html' title='maximum number of instances of the package'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-3746827254394257489</id><published>2010-02-25T20:26:00.003+01:00</published><updated>2010-02-25T20:34:50.059+01:00</updated><title type='text'>E.T. call ~home</title><content type='html'>After many years of unix systems administration, it is a pure pleasure to discover the trick&lt;br /&gt; as simple as displaying the user home directory with &lt;span style="font-weight:bold;"&gt;~username&lt;/span&gt;.&lt;br /&gt;&lt;br /&gt;Examples:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;$ echo ~adm&lt;br /&gt;/var/adm&lt;br /&gt;$ echo ~listen&lt;br /&gt;/usr/net/nls&lt;br /&gt;$ echo ~wisnios&lt;br /&gt;/home/wisnios&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-3746827254394257489?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/3746827254394257489/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=3746827254394257489' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/3746827254394257489'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/3746827254394257489'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/02/et-call-home.html' title='E.T. call ~home'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-5930454494341734326</id><published>2010-02-12T22:40:00.002+01:00</published><updated>2010-02-12T22:45:02.958+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><title type='text'>digression</title><content type='html'>&lt;strong&gt;command+shift+L&lt;/strong&gt; rise a google search window with the results of the selected-piece-of-text query.&lt;br /&gt;Piękne. It's beautiful.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-5930454494341734326?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/5930454494341734326/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=5930454494341734326' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5930454494341734326'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5930454494341734326'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/02/digression.html' title='digression'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-8164683404898329861</id><published>2010-01-19T20:13:00.003+01:00</published><updated>2010-01-19T21:04:44.186+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sed'/><title type='text'>substitute multiple line pattern in sed</title><content type='html'>Today I faced a problem with a multiline replacement. I did not want to write a sophisticated regex.&lt;br /&gt;I just wanted to get a copy-pasted block of code and put it in place of the old one. Selected weapon - sed.&lt;br /&gt;I've chosen the &lt;b&gt;/begin/,/end/&lt;/b&gt; matching syntax.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;['test' input file]&lt;br /&gt;&lt;br /&gt;111&lt;br /&gt;222&lt;br /&gt;333&lt;br /&gt;  if (aaa) {&lt;br /&gt;     bbbbb&lt;br /&gt;  }xxx&lt;br /&gt;  }&lt;br /&gt;444&lt;br /&gt;  while (0) {&lt;br /&gt;     ccccc&lt;br /&gt;  }&lt;br /&gt;666&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;['change' script]&lt;br /&gt;&lt;br /&gt;#!/usr/bin/ksh&lt;br /&gt;&lt;br /&gt;sed '&lt;br /&gt;/if (aaa)/,/\   }$/ c\&lt;br /&gt;  CHANGE\&lt;br /&gt;     WAS\&lt;br /&gt;  MADE&lt;br /&gt;' \&lt;br /&gt;test&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;[session]&lt;br /&gt;&lt;br /&gt;$ ./change&lt;br /&gt;111&lt;br /&gt;222&lt;br /&gt;333&lt;br /&gt;  CHANGE&lt;br /&gt;     WAS&lt;br /&gt;  MADE&lt;br /&gt;444&lt;br /&gt;  while (0) {&lt;br /&gt;     ccccc&lt;br /&gt;  }&lt;br /&gt;666&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-8164683404898329861?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/8164683404898329861/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=8164683404898329861' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8164683404898329861'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8164683404898329861'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2010/01/substitute-multiple-line-pattern-in-sed.html' title='substitute multiple line pattern in sed'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-7486646117291246108</id><published>2009-12-22T20:14:00.012+01:00</published><updated>2009-12-22T20:54:23.831+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ldif'/><category scheme='http://www.blogger.com/atom/ns#' term='directory server'/><category scheme='http://www.blogger.com/atom/ns#' term='slamd'/><title type='text'>MakeLDIF.jar</title><content type='html'>Yesterday I have realized that I do not remember how to prepare the ldif file. But not just a simple  ldif with a few lines of add/modify/delete subcommands. I have forgotten how to use the SLAMD project's tool - MakeLDIF. As far as I remember there was the jar - MakeLDIF. It was, but now there is not. It had taken a few moments before I found the solution. Here you go:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;$ find . -name *.jar | grep -i make&lt;br /&gt;$ cd tools/MakeLDIF&lt;br /&gt;$ perl -e 's/(^define suffix=).*/\1o=ods/' -pi example.template&lt;br /&gt;$ perl -e 's/(^define numusers)=.*/\1=1000/' -pi exa*         &lt;br /&gt;$ perl -e 's/(^define maildomain)=.*/\1=wisnios\.com/' -pi exa*&lt;br /&gt;$ head -3 exa*&lt;br /&gt;define suffix=o=ods&lt;br /&gt;define maildomain=wisnios.com&lt;br /&gt;define numusers=1000&lt;br /&gt;$ cd ..&lt;br /&gt;$ ./make-ldif.sh -t MakeLDIF/example.template -o ~/ods1k.ldif   &lt;br /&gt;Processed 1000 entries&lt;br /&gt;Processing complete.&lt;br /&gt;1002 total entries written.&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;And the process view of similar command execution:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;/usr/jdk/instances/jdk1.5.0/bin/java -server -Xms512m -Xmx512m com.slamd.tools.makeldif.MakeLDIF&lt;br /&gt; -r /export/home/slamd200-20090712/tools/MakeLDIF -t /tmp/ods.template -o /tmp/ods100k.ldif&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Merry Xmas!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-7486646117291246108?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/7486646117291246108/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=7486646117291246108' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7486646117291246108'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7486646117291246108'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/12/makeldifjar.html' title='MakeLDIF.jar'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-2574019673281915361</id><published>2009-12-08T20:46:00.005+01:00</published><updated>2009-12-09T00:07:00.967+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='file'/><category scheme='http://www.blogger.com/atom/ns#' term='aix'/><title type='text'>AIX stat equivalent</title><content type='html'>&lt;code&gt;&lt;br /&gt;$ istat /usr/sbin/lsuser&lt;br /&gt;Inode 115447 on device 10/5     File&lt;br /&gt;Protection: r-xr-xr-x   Set UID &lt;br /&gt;Owner: 0(root)          Group: 7(security)&lt;br /&gt;Link count:   1         Length 84080 bytes&lt;br /&gt;&lt;br /&gt;Last updated:   Tue Dec  8 14:40:33 CST 2009&lt;br /&gt;Last modified:  Mon Mar 30 00:45:51 CDT 2009&lt;br /&gt;Last accessed:  Tue Dec  8 16:55:55 CST 2009&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;* lsuser hint&lt;br /&gt;To display the attributes of all the users, use the &lt;em&gt;ALL&lt;/em&gt; keyword:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;$ lsuser ALL&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-2574019673281915361?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/2574019673281915361/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=2574019673281915361' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2574019673281915361'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2574019673281915361'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/12/aix-stat-equivalent.html' title='AIX stat equivalent'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-1140233834812531692</id><published>2009-11-24T22:27:00.009+01:00</published><updated>2009-11-24T23:08:07.747+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ksh'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>Solaris ksh variations</title><content type='html'>Today i have &lt;a href="http://www.gnu.org/software/hello/manual/autoconf/Shellology.html"&gt;read&lt;/a&gt;, and in the parallel - discovered, that Solaris has got three ksh variants.&lt;br /&gt;Two of them are ksh88, and one ksh93.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;$ grep -i ver /usr/bin/ksh /usr/xpg4/bin/sh /usr/dt/bin/dtksh&lt;br /&gt;/usr/bin/ksh:@(#)Version M-11/16/88i&lt;br /&gt;/usr/xpg4/bin/sh:@(#)Version M-11/16/88i&lt;br /&gt;/usr/dt/bin/dtksh:@(#)Version M-12/28/93d&lt;br /&gt;/usr/dt/bin/dtksh:@(#)Version M-12/28/93&lt;br /&gt;/usr/dt/bin/dtksh:@(#)Version 12/28/93&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;The standard one - &lt;em&gt;/usr/bin/ksh&lt;/em&gt;, and a POSIX-compliant veriant of ksh88 - &lt;em&gt;/usr/xpg4/bin/sh&lt;/em&gt;.&lt;br /&gt;Both of them are the components of SUNWcsu (Core Solaris (Usr)) package.&lt;br /&gt;&lt;em&gt;dtksh&lt;/em&gt; comes from SUNWdtbas.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;$ ls -li /usr/bin/ksh /usr/xpg4/bin/sh /usr/dt/bin/dtksh&lt;br /&gt;       489 -r-xr-xr-x   3 root     bin       171412 Aug  7 13:27 /usr/bin/ksh&lt;br /&gt;     26709 -r-xr-xr-x   1 root     bin       620144 Jan 23  2005 /usr/dt/bin/dtksh&lt;br /&gt;      1536 -r-xr-xr-x   1 root     bin       171412 Aug  7 13:27 /usr/xpg4/bin/sh&lt;br /&gt;$ file /usr/bin/ksh /usr/xpg4/bin/sh /usr/dt/bin/dtksh&lt;br /&gt;/usr/bin/ksh:   ELF 32-bit LSB executable 80386 Version 1, dynamically linked, stripped&lt;br /&gt;/usr/xpg4/bin/sh:       ELF 32-bit LSB executable 80386 Version 1, dynamically linked, stripped&lt;br /&gt;/usr/dt/bin/dtksh:      ELF 32-bit LSB executable 80386 Version 1, dynamically linked, not stripped, no debugging information available&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;As you can already saw (on the ls -li listing) there are also the three brothers-in-inode:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# ls -li /usr/bin/*ksh&lt;br /&gt;       489 -r-xr-xr-x   3 root     bin       171412 Aug  7 13:27 /usr/bin/ksh&lt;br /&gt;       489 -r-xr-xr-x   3 root     bin       171412 Aug  7 13:27 /usr/bin/pfksh&lt;br /&gt;       489 -r-xr-xr-x   3 root     bin       171412 Aug  7 13:27 /usr/bin/rksh&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;It's the highest inode count from all of the Solaris shells (10u8, SUNWCall), the second place goes to csh with only two file names binded to its inode.&lt;br /&gt;&lt;br /&gt;Fascinating.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-1140233834812531692?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/1140233834812531692/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=1140233834812531692' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1140233834812531692'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1140233834812531692'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/11/solaris-ksh-variations.html' title='Solaris ksh variations'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-7443428869287015261</id><published>2009-11-22T19:35:00.008+01:00</published><updated>2009-11-22T22:23:04.589+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ssh'/><category scheme='http://www.blogger.com/atom/ns#' term='pkgadd'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>Make yourself a package</title><content type='html'>In the world where the Good Security Practices becomes Science Fiction, there was an Admin who wants to train himself in Solaris Packaging.&lt;br /&gt;He has written down the &lt;a href="http://cs-tools.googlecode.com/files/rootbox.sh"&gt;script&lt;/a&gt;, which has made his Lord the Legend ;-)&lt;br /&gt;Now, let's put some light on it.&lt;br /&gt;&lt;br /&gt;The script takes .ssh folder files from the specified user of template machine, and turns it into .ssh folder of root user on target host. There are also the configuration changes, inside of either /etc/default/login file, or /etc/ssh/sshd_config one.&lt;br /&gt;Do not try this at (production) home! &lt;br /&gt;&lt;code&gt;&lt;br /&gt;# ./rootbox.sh&lt;br /&gt;Generating package files&lt;br /&gt;prototype&lt;br /&gt;pkginfo&lt;br /&gt;checkinstall&lt;br /&gt;postinstall&lt;br /&gt;postremove&lt;br /&gt;login.sed&lt;br /&gt;sshd_config.sed&lt;br /&gt;Making package MMWrootbox.1.0.i386.pkg [/tmp]&lt;br /&gt;success&lt;br /&gt;Translating package format to a datastream&lt;br /&gt;success&lt;br /&gt;# cd /tmp&lt;br /&gt;# pkgadd -d MMWrootbox.1.0.i386.pkg&lt;br /&gt;&lt;br /&gt;The following packages are available:&lt;br /&gt;  1  MMWrootbox     Root box&lt;br /&gt;                    (i386) 1.0&lt;br /&gt;&lt;br /&gt;Select package(s) you wish to process (or 'all' to process&lt;br /&gt;all packages). (default: all) [?,??,q]: &lt;br /&gt;&lt;br /&gt;Processing package instance &lt;MMWrootbox&gt; from &lt;/tmp/MMWrootbox.1.0.i386.pkg&gt;&lt;br /&gt;&lt;br /&gt;Root box(i386) 1.0&lt;br /&gt;Marcin Marian Wisnios&lt;br /&gt;## Executing checkinstall script.&lt;br /&gt;## Processing package information.&lt;br /&gt;## Processing system information.&lt;br /&gt;## Verifying disk space requirements.&lt;br /&gt;## Checking for conflicts with packages already installed.&lt;br /&gt;## Checking for setuid/setgid programs.&lt;br /&gt;&lt;br /&gt;This package contains scripts which will be executed with super-user&lt;br /&gt;permission during the process of installing this package.&lt;br /&gt;&lt;br /&gt;Do you want to continue with the installation of &lt;MMWrootbox&gt; [y,n,?] y&lt;br /&gt;&lt;br /&gt;Installing Root box as &lt;MMWrootbox&gt;&lt;br /&gt;&lt;br /&gt;## Installing part 1 of 1.&lt;br /&gt;/root/.ssh/authorized_keys&lt;br /&gt;[ verifying class &lt;none&gt; ]&lt;br /&gt;Modifying /etc/default/login&lt;br /&gt;Modifying /etc/ssh/sshd_config&lt;br /&gt;[ verifying class &lt;sed&gt; ]&lt;br /&gt;## Executing postinstall script.&lt;br /&gt;&lt;br /&gt;Installation of &lt;MMWrootbox&gt; was successful.&lt;br /&gt;# date;svcs -x ssh| grep -i state&lt;br /&gt;Sun Nov 22 08:50:57 CET 2009&lt;br /&gt; State: online since Sun Nov 22 08:50:42 2009&lt;br /&gt;# diff /etc/ssh/sshd_config /tmp/rootbox.bak/sshd_config&lt;br /&gt;128c128&lt;br /&gt;&lt; PermitRootLogin without-password&lt;br /&gt;---&lt;br /&gt;&gt; PermitRootLogin no&lt;br /&gt;# diff /etc/default/login /tmp/rootbox.bak/login&lt;br /&gt;18c18&lt;br /&gt;&lt; #CONSOLE=/dev/console&lt;br /&gt;---&lt;br /&gt;&gt; CONSOLE=/dev/console&lt;br /&gt;# pkginfo MMWrootbox&lt;br /&gt;system      MMWrootbox Root box&lt;br /&gt;# pkginfo -l MMWrootbox&lt;br /&gt;   PKGINST:  MMWrootbox&lt;br /&gt;      NAME:  Root box&lt;br /&gt;  CATEGORY:  system&lt;br /&gt;      ARCH:  i386&lt;br /&gt;   VERSION:  1.0&lt;br /&gt;   BASEDIR:  /&lt;br /&gt;    VENDOR:  Marcin Marian Wisnios&lt;br /&gt;      DESC:  Methods and keys to allow remote root user access&lt;br /&gt;    PSTAMP:  20091122085002&lt;br /&gt;  INSTDATE:  Nov 22 2009 08:50&lt;br /&gt;     EMAIL:  wisnios@gmail.com&lt;br /&gt;    STATUS:  completely installed&lt;br /&gt;     FILES:        4 installed pathnames&lt;br /&gt;                   2 shared pathnames&lt;br /&gt;                   1 directories&lt;br /&gt;                   3 blocks used (approx)&lt;br /&gt;&lt;br /&gt;# pkgrm MMWrootbox&lt;br /&gt;&lt;br /&gt;The following package is currently installed:&lt;br /&gt;   MMWrootbox  Root box&lt;br /&gt;               (i386) 1.0&lt;br /&gt;&lt;br /&gt;Do you want to remove this package? [y,n,?,q] y&lt;br /&gt;&lt;br /&gt;## Removing installed package instance &lt;MMWrootbox&gt;&lt;br /&gt;&lt;br /&gt;This package contains scripts which will be executed with super-user&lt;br /&gt;permission during the process of removing this package.&lt;br /&gt;&lt;br /&gt;Do you want to continue with the removal of this package [y,n,?,q] y&lt;br /&gt;## Verifying package &lt;MMWrootbox&gt; dependencies in global zone&lt;br /&gt;## Processing package information.&lt;br /&gt;## Removing pathnames in class &lt;sed&gt;&lt;br /&gt;Modifying /etc/ssh/sshd_config&lt;br /&gt;Modifying /etc/default/login&lt;br /&gt;## Removing pathnames in class &lt;none&gt;&lt;br /&gt;/root/.ssh/authorized_keys&lt;br /&gt;/root/.ssh&lt;br /&gt;## Executing postremove script.&lt;br /&gt;## Updating system information.&lt;br /&gt;&lt;br /&gt;Removal of &lt;MMWrootbox&gt; was successful.&lt;br /&gt;# svcs -x ssh|grep -i state; date&lt;br /&gt; State: online since Sun Nov 22 08:52:33 2009&lt;br /&gt;Sun Nov 22 08:52:50 CET 2009&lt;br /&gt;# diff /etc/ssh/sshd_config /tmp/rootbox.bak/sshd_config&lt;br /&gt;# diff /etc/default/login /tmp/rootbox.bak/login&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="http://cs-tools.googlecode.com/files/rootbox.sh"&gt;http://cs-tools.googlecode.com/files/rootbox.sh&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Enjoy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-7443428869287015261?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/7443428869287015261/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=7443428869287015261' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7443428869287015261'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7443428869287015261'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/11/make-yourself-package.html' title='Make yourself a package'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-4850834784909581124</id><published>2009-10-28T10:00:00.010+01:00</published><updated>2009-10-28T22:45:56.395+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='smf'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><category scheme='http://www.blogger.com/atom/ns#' term='boot'/><title type='text'>Paranoid</title><content type='html'>So, have you ever seen the Solaris 10 boot process, line by line?&lt;br /&gt;I do not talk about the kernel &lt;em&gt;-m verbose&lt;/em&gt; mode, which only shows the particular SMF identifiers.&lt;br /&gt;Have you ever wondered why the boot process has hanged? and what's the cause?&lt;br /&gt;&lt;br /&gt;The Wisnios way is as follow.&lt;br /&gt;I've decided to replace the master restarter binary with a shell script.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# mv /lib/svc/bin/svc.startd /lib/svc/bin/svc.startdd&lt;br /&gt;# vi /lib/svc/bin/svc.startd&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;  #!/bin/sh&lt;br /&gt;  truss -fa -t exec /lib/svc/bin/svc.startdd&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# chmod 555 /lib/svc/bin/svc.startd&lt;br /&gt;# chgrp sys /lib/svc/bin/svc.startd&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;You could also choose the more verbose mode by adding the &lt;em&gt;-e&lt;/em&gt; switch to truss command.&lt;br /&gt;Truss &lt;em&gt;-f&lt;/em&gt; option follows all fork/vfork children, &lt;em&gt;-a&lt;/em&gt; shows the argument strings within the exec() calls and &lt;em&gt;-e&lt;/em&gt; shows the environment variables (for ex. SMF_FMRI).&lt;br /&gt;&lt;br /&gt;Other traces are limited by imagination only.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-4850834784909581124?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/4850834784909581124/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=4850834784909581124' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4850834784909581124'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4850834784909581124'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/10/paranoid.html' title='Paranoid'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-6120027130017808725</id><published>2009-09-24T22:17:00.016+02:00</published><updated>2009-09-25T11:50:38.109+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rmdom.pl'/><category scheme='http://www.blogger.com/atom/ns#' term='comms'/><category scheme='http://www.blogger.com/atom/ns#' term='cs-tools'/><title type='text'>rmdom.pl</title><content type='html'>I've just started the google code project called cs-tools (Commandline Support Tools).&lt;br /&gt;This will be a container for my set of scripts supporting the administration of Sun Java Communications Suite components. &lt;br /&gt;Project Home: &lt;a href="http://code.google.com/p/cs-tools/"&gt;http://code.google.com/p/cs-tools/&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;There's also the first one perl program - &lt;a href="http://cs-tools.googlecode.com/files/rmdom.pl"&gt;&lt;strong&gt;rmdom.pl&lt;/strong&gt;&lt;/a&gt; - you could use to simplify the deletion and purge process of hosted domain.&lt;br /&gt;&lt;br /&gt;Sample session:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# perl rmdom.pl &lt;br /&gt;fe  : frontend.localdomain&lt;br /&gt;be  : backend.localdomain&lt;br /&gt;ldap: ldap.localdomain:389&lt;br /&gt;%%%%%%%%%%%%%%%%%%%%%%%%%%&lt;br /&gt;bind dn: cn=dirmgr&lt;br /&gt;bind passwd: &lt;br /&gt;domain: rmdom.pl&lt;br /&gt;mail domain ok&lt;br /&gt;cal domain ok&lt;br /&gt;active users: 2&lt;br /&gt;active groups: 1&lt;br /&gt;are you sure (yes to confirm)? yes&lt;br /&gt;domain deleted&lt;br /&gt;domain purged&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Enjoy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-6120027130017808725?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/6120027130017808725/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=6120027130017808725' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6120027130017808725'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6120027130017808725'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/09/rmdompl.html' title='rmdom.pl'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-3855972948931085967</id><published>2009-09-22T00:27:00.003+02:00</published><updated>2009-09-22T00:52:55.399+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='elom'/><category scheme='http://www.blogger.com/atom/ns#' term='sun'/><category scheme='http://www.blogger.com/atom/ns#' term='x2200'/><category scheme='http://www.blogger.com/atom/ns#' term='ilom'/><title type='text'>DateTime set: Object cannot be written</title><content type='html'>Very lately (about fifteen minutes ago) I had to resolve the time issue from the ELOM level of Sun Fire X2200.&lt;br /&gt;It couldn't be done, because:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;/SP/AgentInfo -&gt; show &lt;br /&gt;&lt;br /&gt;  /SP/AgentInfo&lt;br /&gt;    Targets:&lt;br /&gt;        PEF&lt;br /&gt;        PET&lt;br /&gt;        SEL&lt;br /&gt;        console&lt;br /&gt;        mail&lt;br /&gt;        SNMP&lt;br /&gt;&lt;br /&gt;    Properties:&lt;br /&gt;[...]&lt;br /&gt;        DateTime = 01/03/1970-02:56:23&lt;br /&gt;[...]&lt;br /&gt;&lt;br /&gt;/SP/AgentInfo -&gt; set DateTime="09/22/2009-00:22:00"&lt;br /&gt;set: Object cannot be written&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;So, it's the place where the &lt;strong&gt;ipmitool&lt;/strong&gt; could be used.&lt;br /&gt;Ipmitool need the three kernel modules to be loaded:&lt;br /&gt;* ipmi_si&lt;br /&gt;* ipmi_devintf&lt;br /&gt;* ipmi_msghandler&lt;br /&gt;&lt;br /&gt;The time can be adjusted with an argument &lt;em&gt;set&lt;/em&gt; of the ipmitool's &lt;em&gt;SEL&lt;/em&gt; (System Event Log) subcommand.&lt;br /&gt;Sample Linux command line session:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# ipmitool sel time get&lt;br /&gt;Could not open device at /dev/ipmi0 or /dev/ipmi/0: No such file or directory&lt;br /&gt;Get SEL Time command failed&lt;br /&gt;# lsmod | grep ipmi&lt;br /&gt;# modprobe ipmi_devintf &lt;br /&gt;# modprobe ipmi_si      &lt;br /&gt;# lsmod | grep ipmi&lt;br /&gt;ipmi_si                57164  0 &lt;br /&gt;ipmi_devintf           20624  0 &lt;br /&gt;ipmi_msghandler        50680  2 ipmi_si,ipmi_devintf&lt;br /&gt;# ipmitool sel time get&lt;br /&gt;01/01/1970 22:07:22&lt;br /&gt;&lt;br /&gt;# ipmitool sel time set "09/22/2009 00:22:00"&lt;br /&gt;&lt;br /&gt;# ipmitool sel time get&lt;br /&gt;09/22/2009 00:22:03&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-3855972948931085967?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/3855972948931085967/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=3855972948931085967' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/3855972948931085967'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/3855972948931085967'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/09/datetime-set-object-cannot-be-written.html' title='DateTime set: Object cannot be written'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-6217286112166462976</id><published>2009-07-03T23:00:00.001+02:00</published><updated>2009-07-03T23:05:13.735+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='messaging server'/><category scheme='http://www.blogger.com/atom/ns#' term='spam'/><category scheme='http://www.blogger.com/atom/ns#' term='security'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>Arming Messaging Server</title><content type='html'>Today I've got the three recipes to tighten the unwanted malicious user activity.&lt;br /&gt;All of them are related to &lt;em&gt;mappings&lt;/em&gt; file rules.&lt;br /&gt;&lt;br /&gt;First i want to prohibit all the unauthenticated users from sending emails.&lt;br /&gt;It could be achieved with a following line in the &lt;em&gt;FROM_ACCESS&lt;/em&gt; table:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;TCP|*|25|*|*|SMTP*|*|tcp_local|*@*|*    $C$}$6,_canonical_name_{$N$ -$ Authentication$ required$ when$ sending$ with$ this$ envelope$ sender$ domain$E&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;The second step is to block attemtps of faking From header, after successful authentication &lt;br /&gt;(for ex. using stolen password, or personal account in a negative manner).&lt;br /&gt;I've prepared the suitable lines, also in &lt;em&gt;FROM_ACCESS&lt;/em&gt; table:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;*|SMTP*|*|tcp_auth|*@*|*@$4*            $Y&lt;br /&gt;*|SMTP*|*|tcp_auth|*@*|*@*              $N$_Sender$ address$ rejected$ for$ $4&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;It reject the use of tcp_auth channel when domain of authenticated account is different from the one used within the From header.&lt;br /&gt;&lt;br /&gt;The third method take advantage of &lt;em&gt;check_metermaid.so&lt;/em&gt; library (included in Messaging Server installation).&lt;br /&gt;MeterMaid could be used to throttle the agressive usage of mail server.&lt;br /&gt;I've used two rules (to block them all ;-) ).&lt;br /&gt;First one restrict the number of connections (15) in a unit of time (60 s.).&lt;br /&gt;It's assigned under &lt;em&gt;PORT_ACCESS&lt;/em&gt; table:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;*|*|*|*|*      $C$:A$[/opt/sun/comms/messaging64/lib/check_metermaid.so,throttle,ext_throttle,$3]$N421$ Connection$ declined$ at$ this$ time$E&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Related thresholds are defined with a &lt;em&gt;configutil&lt;/em&gt; command or by edition of &lt;em&gt;msg.conf&lt;/em&gt;:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;metermaid.config.secret = [your shared secret to authenticate incoming connections]&lt;br /&gt;metermaid.config.serverhost = [host name or ip address of your metermaid server]&lt;br /&gt;metermaid.table.ext_throttle.data_type = string&lt;br /&gt;metermaid.table.ext_throttle.options = nocase&lt;br /&gt;metermaid.table.ext_throttle.quota = 15&lt;br /&gt;metermaid.table.ext_throttle.quota_time = 60&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Ex.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# configutil -o metermaid.config.serverhost -v somehost.somedomain&lt;br /&gt;# configutil -o metermaid.config.secret -v somesecret&lt;br /&gt;and so on...&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;em&gt;ext_throttle&lt;/em&gt; is defined by you throttling table name, and must be the same within the &lt;em&gt;mappings&lt;/em&gt; and &lt;em&gt;msg.conf&lt;/em&gt; files.&lt;br /&gt;&lt;br /&gt;The second rule restrict number of total recipients sent to by a user (i've used the same limit values, but you could add the next throttle table with required thresholds).&lt;br /&gt;It should be addes within the &lt;em&gt;ORIG_SEND_ACCESS&lt;/em&gt; mapping tables:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;tcp_auth|*|*|*      $C$[/opt/sun/comms/messaging64/lib/check_metermaid.so,throttle,ext_throttle,$0]$NExcessive$ email$ sent$ -$ Please$ try$ again$ later$E&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;So, run &lt;em&gt;imsimta cnbuild &amp;&amp; imsimta restart&lt;/em&gt; and...&lt;br /&gt;&lt;code&gt;&lt;br /&gt;[...]&lt;br /&gt;235 2.7.0 LOGIN authentication successful.&lt;br /&gt;250 2.5.0 Address Ok.&lt;br /&gt;250 2.1.5 marcin.wisnios@somedomain OK.&lt;br /&gt;354 Enter mail, end with a single ".".&lt;br /&gt;250 2.5.0 Ok.&lt;br /&gt;250 2.5.0 Address Ok.&lt;br /&gt;250 2.1.5 marcin.wisnios@somedomain OK.&lt;br /&gt;354 Enter mail, end with a single ".".&lt;br /&gt;250 2.5.0 Ok.&lt;br /&gt;250 2.5.0 Address Ok.&lt;br /&gt;250 2.1.5 marcin.wisnios@somedomain OK.&lt;br /&gt;354 Enter mail, end with a single ".".&lt;br /&gt;250 2.5.0 Ok.&lt;br /&gt;[...]&lt;br /&gt;250 2.5.0 Address Ok.&lt;br /&gt;250 2.1.5 marcin.wisnios@somedomain OK.&lt;br /&gt;354 Enter mail, end with a single ".".&lt;br /&gt;250 2.5.0 Ok.&lt;br /&gt;250 2.5.0 Address Ok.&lt;br /&gt;550 5.7.1 Excessive email sent - Please try again later: marcin.wisnios@somedomain&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Enjoy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-6217286112166462976?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/6217286112166462976/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=6217286112166462976' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6217286112166462976'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6217286112166462976'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/07/arming-messaging-server.html' title='Arming Messaging Server'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-1064946487050246180</id><published>2009-06-23T23:46:00.009+02:00</published><updated>2009-06-24T00:35:55.288+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='nwam'/><category scheme='http://www.blogger.com/atom/ns#' term='opensolaris'/><category scheme='http://www.blogger.com/atom/ns#' term='ipv6'/><title type='text'>Disable IPv6 in OpenSolaris 2009.06</title><content type='html'>I always want the system works in a way I like it. This way comes with running only the things I really need. &lt;br /&gt;I do not want IPv6 protocol stack when it's useless.&lt;br /&gt;&lt;br /&gt;Here, it's a short recipe how it could be achieved.&lt;br /&gt;&lt;br /&gt;First, remove the IPv6 from network auto-magic interface configuration.&lt;br /&gt;Add the following entry to &lt;em&gt;/etc/nwam/llp&lt;/em&gt; file:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;e1000g0 noipv6 dhcp&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Now, you could permanently disable the &lt;em&gt;ndp&lt;/em&gt; with:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;svcadm disable ndp&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;It's no persistant across reboots without the modification of &lt;em&gt;/etc/nwam/llp&lt;/em&gt;.&lt;br /&gt;&lt;br /&gt;The second step is not so obvious. Some people in OpenSolaris team want it / like it / need it. I don't care.&lt;br /&gt;I want it to be disabled.&lt;br /&gt;The loopback inet6 interface is being plumbed form inside the &lt;em&gt;/lib/svc/method/net-loopback&lt;/em&gt; method of SMF -  &lt;em&gt;svc:/network/loopback:default&lt;/em&gt;&lt;br /&gt;I replace the original call with an IF condition of IPv6 entry existence inside the &lt;em&gt;/etc/inet/hosts&lt;/em&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# IPv6 loopback&lt;br /&gt;if ( egrep "^::1" /etc/inet/hosts ); then&lt;br /&gt;   /sbin/ifconfig lo0 inet6 plumb ::1 up&lt;br /&gt;fi&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;To polish the final result we should disable the sendmail ipv6 interface binding.&lt;br /&gt;I commented out the relevant line of &lt;em&gt;/etc/mail/sendmail.cf&lt;/em&gt; file:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;0 DaemonPortOptions=Name=MTA-v4, Family=inet&lt;br /&gt;#0 DaemonPortOptions=Name=MTA-v6, Family=inet6&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Enjoy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-1064946487050246180?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/1064946487050246180/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=1064946487050246180' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1064946487050246180'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1064946487050246180'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/06/disable-ipv6-in-opensolaris-200906.html' title='Disable IPv6 in OpenSolaris 2009.06'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-2549227471200330537</id><published>2009-05-31T22:28:00.006+02:00</published><updated>2009-05-31T23:11:37.259+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='tcp/ip'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>Solaris IP shortcuts</title><content type='html'>Today, I had to modify my routing table under Solaris 10u7 (5/09), and I made a typo.&lt;br /&gt;Instead of writing 10.0.2.1, I typed 10.0.21... and it has worked. &lt;br /&gt;&lt;pre&gt;&lt;br /&gt;sol10u7 [~]# route add default 10.0.21&lt;br /&gt;add net default: gateway 10.0.21&lt;br /&gt;sol10u7 [~]# netstat -rn&lt;br /&gt;&lt;br /&gt;Routing Table: IPv4&lt;br /&gt;  Destination           Gateway           Flags  Ref     Use     Interface&lt;br /&gt;-------------------- -------------------- ----- ----- ---------- ---------&lt;br /&gt;default              10.0.0.21            UG        1          0&lt;br /&gt;10.0.0.0             10.0.2.16            U         1          0 e1000g0&lt;br /&gt;224.0.0.0            10.0.2.16            U         1          0 e1000g0&lt;br /&gt;127.0.0.1            127.0.0.1            UH        1         54 lo0&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;I've also tried to use 10.1 and 10.1.1, and another success has been met.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;sol10u7 [/etc/krb5]# route add default 10.1&lt;br /&gt;add net default: gateway 10.1&lt;br /&gt;sol10u7 [/etc/krb5]# netstat -rn&lt;br /&gt;&lt;br /&gt;Routing Table: IPv4&lt;br /&gt;  Destination           Gateway           Flags  Ref     Use     Interface&lt;br /&gt;-------------------- -------------------- ----- ----- ---------- ---------&lt;br /&gt;default              10.0.2.2             UG        1          0&lt;br /&gt;default              10.0.0.1             UG        1          0&lt;br /&gt;10.0.0.0             10.0.2.16            U         1         24 e1000g0&lt;br /&gt;224.0.0.0            10.0.2.16            U         1          0 e1000g0&lt;br /&gt;127.0.0.1            127.0.0.1            UH        1         58 lo0&lt;br /&gt;sol10u7 [/etc/krb5]# route add default 10.1.1&lt;br /&gt;add net default: gateway 10.1.1&lt;br /&gt;sol10u7 [/etc/krb5]# netstat -rn&lt;br /&gt;&lt;br /&gt;Routing Table: IPv4&lt;br /&gt;  Destination           Gateway           Flags  Ref     Use     Interface&lt;br /&gt;-------------------- -------------------- ----- ----- ---------- ---------&lt;br /&gt;default              10.0.2.2             UG        1          0&lt;br /&gt;default              10.0.0.1             UG        1          0&lt;br /&gt;default              10.1.0.1             UG        1          0&lt;br /&gt;10.0.0.0             10.0.2.16            U         1         24 e1000g0&lt;br /&gt;224.0.0.0            10.0.2.16            U         1          0 e1000g0&lt;br /&gt;127.0.0.1            127.0.0.1            UH        1         58 lo0&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;The deletion works in the same manner.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;sol10u7 [~]# route delete default 10.0.21&lt;br /&gt;delete net default: gateway 10.0.21&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Nice. Is it a bug, or is it a feature ;-) ?&lt;br /&gt;I know there's a similar IPv6 behaviour - reducing the number of  Zeros in address notation, but I didn't know it's also related to IPv4.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-2549227471200330537?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/2549227471200330537/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=2549227471200330537' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2549227471200330537'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2549227471200330537'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/05/solaris-ip-shortcuts.html' title='Solaris IP shortcuts'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-1094535829317154962</id><published>2009-05-29T20:38:00.005+02:00</published><updated>2009-05-29T23:01:31.772+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='directory server'/><category scheme='http://www.blogger.com/atom/ns#' term='ldap'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>Create base64 jpegPhoto attribute</title><content type='html'>So, you wanna a picture in your user profile within the Directory Server entry?&lt;br /&gt;Go for it.&lt;br /&gt;&lt;br /&gt;Generate base-64 encoded value of the selected picture:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;book [/tmp]# ldif -b jpegPhoto &lt; marcin.jpg &lt;br /&gt;jpegPhoto:: /9j/4AAQSkZJRgABAgAAZABkAAD/7AARRHVja3kAAQAEAAAAMgAA/+4ADkFkb2JlA&lt;br /&gt; GTAAAAAAf/bAIQACAYGBgYGCAYGCAwIBwgMDgoICAoOEA0NDg0NEBEMDg0NDgwRDxITFBMSDxgYG&lt;br /&gt; hoYGCMiIiIjJycnJycnJycnJwEJCAgJCgkLCQkLDgsNCw4RDg4ODhETDQ0ODQ0TGBEPDw8PERgWF&lt;br /&gt; xQUFBcWGhoYGBoaISEgISEnJycnJycnJycn/8AAEQgBVAH0AwEiAAIRAQMRAf/EAK4AAAIDAQEBA&lt;br /&gt; QAAAAAAAAAAAAMEAAIFAQYHCAEAAwEBAQAAAAAAAAAAAAAAAAECAwQFEAACAQMCBAMFBQUFBwMDB&lt;br /&gt;[...]&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;Enter output to the ldif file or create the modification by hand:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;book [~]$ ldapmodify -D cn=dirmgr&lt;br /&gt;Enter bind password: &lt;br /&gt;dn: uid=marcin,ou=People,o=wisnios.com,o=isp&lt;br /&gt;changetype: modify&lt;br /&gt;add: jpegPhoto&lt;br /&gt;jpegPhoto:: /9j/4AAQSkZJRgABAgAAZABkAAD/7AARRHVja3kAAQAEAAAAMgAA/+4ADkFkb2JlA&lt;br /&gt; GTAAAAAAf/bAIQACAYGBgYGCAYGCAwIBwgMDgoICAoOEA0NDg0NEBEMDg0NDgwRDxITFBMSDxgYG&lt;br /&gt; hoYGCMiIiIjJycnJycnJycnJwEJCAgJCgkLCQkLDgsNCw4RDg4ODhETDQ0ODQ0TGBEPDw8PERgWF&lt;br /&gt; xQUFBcWGhoYGBoaISEgISEnJycnJycnJycn/8AAEQgBVAH0AwEiAAIRAQMRAf/EAK4AAAIDAQEBA&lt;br /&gt; QAAAAAAAAAAAAMEAAIFAQYHCAEAAwEBAQAAAAAAAAAAAAAAAAECAwQFEAACAQMCBAMFBQUFBwMDB&lt;br /&gt;[...]&lt;br /&gt;^D&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-1094535829317154962?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/1094535829317154962/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=1094535829317154962' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1094535829317154962'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1094535829317154962'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/05/create-base64-jpegphoto-attribute.html' title='Create base64 jpegPhoto attribute'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-2372452913649824382</id><published>2009-05-14T22:38:00.007+02:00</published><updated>2009-05-14T23:16:17.352+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='zfs'/><category scheme='http://www.blogger.com/atom/ns#' term='resilver'/><category scheme='http://www.blogger.com/atom/ns#' term='zpool'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><category scheme='http://www.blogger.com/atom/ns#' term='scrub'/><title type='text'>zpool replace problem</title><content type='html'>Scenario.&lt;br /&gt;Disk from pool1 failed. It was replaced with a new one, with appropriate &lt;em&gt;cfgadm -c unconfigure&lt;/em&gt; and &lt;em&gt;cfgadm -c configure&lt;/em&gt; commands. Process of resilvering has been completed, but there's still the unavailable device within a pool status. Any try to take a device offline causes the scrub process to start again.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;thumper [~]# zpool status -v pool1&lt;br /&gt;  pool: pool1&lt;br /&gt; state: DEGRADED&lt;br /&gt;status: One or more devices could not be opened.  Sufficient replicas exist for&lt;br /&gt;        the pool to continue functioning in a degraded state.&lt;br /&gt;action: Attach the missing device and online it using 'zpool online'.&lt;br /&gt;   see: http://www.sun.com/msg/ZFS-8000-D3&lt;br /&gt; scrub: resilver in progress, 2,32% done, 28h7m to go&lt;br /&gt;config:&lt;br /&gt;&lt;br /&gt;        NAME            STATE     READ WRITE CKSUM&lt;br /&gt;        pool1           DEGRADED     0     0     0&lt;br /&gt;          raidz2        DEGRADED     0     0     0&lt;br /&gt;            c7t0d0p0    ONLINE       0     0     0&lt;br /&gt;            c6t0d0p0    ONLINE       0     0     0&lt;br /&gt;            c7t4d0p0    ONLINE       0     0     0&lt;br /&gt;            c6t4d0p0    ONLINE       0     0     0&lt;br /&gt;            c1t0d0p0    ONLINE       0     0     0&lt;br /&gt;            c0t0d0p0    ONLINE       0     0     0&lt;br /&gt;            c1t4d0p0    ONLINE       0     0     0&lt;br /&gt;            c0t4d0p0    ONLINE       0     0     0&lt;br /&gt;            c5t1d0p0    ONLINE       0     0     0&lt;br /&gt;            c4t1d0p0    ONLINE       0     0     0&lt;br /&gt;            c5t5d0p0    ONLINE       0     0     0&lt;br /&gt;            c4t5d0p0    ONLINE       0     0     0&lt;br /&gt;            c7t1d0p0    ONLINE       0     0     0&lt;br /&gt;            c6t1d0p0    ONLINE       0     0     0&lt;br /&gt;            spare       DEGRADED     0     0     0&lt;br /&gt;              c7t5d0p0  UNAVAIL      0     0     0  cannot open&lt;br /&gt;              c1t3d0p0  ONLINE       0     0     0&lt;br /&gt;            c6t5d0p0    ONLINE       0     0     0&lt;br /&gt;            c1t1d0p0    ONLINE       0     0     0&lt;br /&gt;            c0t1d0p0    ONLINE       0     0     0&lt;br /&gt;            c1t5d0p0    ONLINE       0     0     0&lt;br /&gt;            c0t5d0p0    ONLINE       0     0     0&lt;br /&gt;        spares&lt;br /&gt;          c1t3d0p0      INUSE     currently in use&lt;br /&gt;          c0t3d0p0      AVAIL   &lt;br /&gt;&lt;br /&gt;errors: No known data errors&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;strong&gt;Solution&lt;/strong&gt;&lt;br /&gt;Do exactly the same what has been done with a disk from the system point of view.&lt;br /&gt;Replace it in place.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;thumper [~]# zpool replace pool1 c7t5d0p0 c7t5d0p0&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;After resilver period of time:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;thumper [~]# zpool status -v pool1&lt;br /&gt;  pool: pool1&lt;br /&gt; state: ONLINE&lt;br /&gt; scrub: resilver completed with 0 errors on Thu May 14 17:08:20 2009&lt;br /&gt;config:&lt;br /&gt;&lt;br /&gt;        NAME          STATE     READ WRITE CKSUM&lt;br /&gt;        pool1         ONLINE       0     0     0&lt;br /&gt;          raidz2      ONLINE       0     0     0&lt;br /&gt;            c7t0d0p0  ONLINE       0     0     0&lt;br /&gt;            c6t0d0p0  ONLINE       0     0     0&lt;br /&gt;            c7t4d0p0  ONLINE       0     0     0&lt;br /&gt;            c6t4d0p0  ONLINE       0     0     0&lt;br /&gt;            c1t0d0p0  ONLINE       0     0     0&lt;br /&gt;            c0t0d0p0  ONLINE       0     0     0&lt;br /&gt;            c1t4d0p0  ONLINE       0     0     0&lt;br /&gt;            c0t4d0p0  ONLINE       0     0     0&lt;br /&gt;            c5t1d0p0  ONLINE       0     0     0&lt;br /&gt;            c4t1d0p0  ONLINE       0     0     0&lt;br /&gt;            c5t5d0p0  ONLINE       0     0     0&lt;br /&gt;            c4t5d0p0  ONLINE       0     0     0&lt;br /&gt;            c7t1d0p0  ONLINE       0     0     0&lt;br /&gt;            c6t1d0p0  ONLINE       0     0     0&lt;br /&gt;            c7t5d0p0  ONLINE       0     0     0&lt;br /&gt;            c6t5d0p0  ONLINE       0     0     0&lt;br /&gt;            c1t1d0p0  ONLINE       0     0     0&lt;br /&gt;            c0t1d0p0  ONLINE       0     0     0&lt;br /&gt;            c1t5d0p0  ONLINE       0     0     0&lt;br /&gt;            c0t5d0p0  ONLINE       0     0     0&lt;br /&gt;        spares&lt;br /&gt;          c1t3d0p0    AVAIL   &lt;br /&gt;          c0t3d0p0    AVAIL   &lt;br /&gt;&lt;br /&gt;errors: No known data errors&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Voila!&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-2372452913649824382?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/2372452913649824382/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=2372452913649824382' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2372452913649824382'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2372452913649824382'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/05/zpool-replace-problem.html' title='zpool replace problem'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-8840420181675177443</id><published>2009-05-14T20:18:00.006+02:00</published><updated>2009-05-14T21:07:07.172+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='aix'/><title type='text'>AIX software (de)installation</title><content type='html'>During my AIX lab works I've accidentally installed all the packages from the /export/aix/lpp_source/xlCv8eval location&lt;br /&gt;(IBM XL C/C++ V8.0 Evaluation).&lt;br /&gt;&lt;code&gt;&lt;br /&gt;aix61 [/export/aix]# installp -a -d lpp_source/xlCv8eval all&lt;br /&gt;[...]&lt;br /&gt;&lt;br /&gt;+-----------------------------------------------------------------------------+&lt;br /&gt;                   BUILDDATE Verification ...&lt;br /&gt;+-----------------------------------------------------------------------------+&lt;br /&gt;Verifying build dates...done&lt;br /&gt;FILESET STATISTICS &lt;br /&gt;------------------&lt;br /&gt;  221  Selected to be installed, of which:&lt;br /&gt;       66  Passed pre-installation verification&lt;br /&gt;      146  FAILED pre-installation verification&lt;br /&gt;        9  Already installed (directly or via superseding filesets)&lt;br /&gt;  ----&lt;br /&gt;   66  Total to be installed&lt;br /&gt;&lt;br /&gt;+-----------------------------------------------------------------------------+&lt;br /&gt;                         Installing Software...&lt;br /&gt;+-----------------------------------------------------------------------------+&lt;br /&gt;&lt;br /&gt;[...]&lt;br /&gt;&lt;br /&gt;Finished processing all filesets.  (Total time:  2 mins 17 secs).&lt;br /&gt;&lt;br /&gt;[...]&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Two minutes and seventeen seconds of sorrow.&lt;br /&gt;&lt;br /&gt;Because it was my first installation attempt I wanted to rollback the applied changes.&lt;br /&gt;But, how to uninstall all the filesets together?&lt;br /&gt;I've prepared the handy oneliner. Feel free to provide a better solution.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;aix61 [/export/aix/lpp_source/xlCv8eval/installp]# for f in `ls -1 ppc | cut -d . -f 1 | sort | uniq`; \&lt;br /&gt;do installp -u -e /home/wisnios/xlCv8eval.uninstall.log -g $f; \&lt;br /&gt;done&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;where &lt;em&gt;ls -1 ppc | cut -d . -f 1 | sort | uniq&lt;/em&gt; gives:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;ibmdebugger&lt;br /&gt;memdbg&lt;br /&gt;vac&lt;br /&gt;vacpp&lt;br /&gt;xlC&lt;br /&gt;xlhelp&lt;br /&gt;xlmass&lt;br /&gt;xlsmp&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Mission accomplished.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-8840420181675177443?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/8840420181675177443/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=8840420181675177443' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8840420181675177443'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8840420181675177443'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/05/aix-deinstall-software.html' title='AIX software (de)installation'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-9199168377604848638</id><published>2009-05-07T19:41:00.019+02:00</published><updated>2009-05-07T23:24:56.209+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='algorithm'/><category scheme='http://www.blogger.com/atom/ns#' term='security'/><category scheme='http://www.blogger.com/atom/ns#' term='ipsec'/><category scheme='http://www.blogger.com/atom/ns#' term='utility'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>Solaris IPSec with preshared keys</title><content type='html'>To implement transport mode ipsec configuration we have to complete the following steps:&lt;br /&gt;&lt;ul type="disc"&gt;&lt;br /&gt;&lt;li&gt; assign ipsec policy (&lt;em&gt;ipsecinit.conf&lt;/em&gt;)&lt;br /&gt;&lt;li&gt; configure Internet Key Exchange (IKE) daemon (in.iked) (&lt;em&gt;config&lt;/em&gt;)&lt;br /&gt;&lt;li&gt; setup preshared key secret (&lt;em&gt;ike.preshared&lt;/em&gt;)&lt;br /&gt;&lt;/ul&gt;&lt;br /&gt;The configuration should be made on both of the communicating nodes.&lt;br /&gt;In below example i've used nodes named sol10u6 (10.0.2.15) and sol10u7 (10.0.2.16).&lt;br /&gt;To generate the password ascii representation i've used a piece of code:&lt;br /&gt;&lt;br /&gt;&lt;div class="codearea"&gt;&lt;br /&gt;/*&lt;br /&gt;  IKE password converter&lt;br /&gt;  - Marcin Wisnios [marcin AT wisnios.com]&lt;br /&gt;*/&lt;br /&gt;#include &amp;lt;stdio.h&amp;gt;&lt;br /&gt;#include &amp;lt;string.h&amp;gt;&lt;br /&gt;&lt;br /&gt;#define PSIZE 512&lt;br /&gt;&lt;br /&gt;int main(int argc, char* argv[])&lt;br /&gt;{&lt;br /&gt; int n;&lt;br /&gt; size_t size;&lt;br /&gt; char pass[PSIZE];&lt;br /&gt;&lt;br /&gt; if (argc == 1)&lt;br /&gt; {&lt;br /&gt;        fprintf(stderr, "Usage: %s password\n", argv[0]);&lt;br /&gt; }&lt;br /&gt; else&lt;br /&gt; {&lt;br /&gt;        size=strlen(argv[1]);&lt;br /&gt;        if (size &gt;= PSIZE)&lt;br /&gt;        {&lt;br /&gt;         fprintf(stderr, "Warning: possibility of buffer overflow on oversized password (&gt;=%d). Exiting.\n", PSIZE);&lt;br /&gt;         return -1;&lt;br /&gt;        }&lt;br /&gt;&lt;br /&gt;        strncpy(pass, argv[1], size);&lt;br /&gt;&lt;br /&gt;        for(n=0; n&amp;lt;size; n++)&lt;br /&gt;        {&lt;br /&gt;                printf("%d", pass[n]);&lt;br /&gt;        }&lt;br /&gt;&lt;br /&gt;        printf("\n");&lt;br /&gt; }&lt;br /&gt;&lt;br /&gt; return 0;&lt;br /&gt;}&lt;br /&gt;&lt;/div&gt;&lt;br /&gt;&lt;br /&gt;I've used &lt;b&gt;sample&lt;/b&gt; secret: example-preshared-key-secret-do-not-use-it.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;sol10u6 [~]$ ./ikepconv example-preshared-key-secret-do-not-use-it&lt;br /&gt;10112097109112108101451121141011151049711410110045107101121451151019911410111645100111451101111164511711510145105116&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Let's start with ipsec policy settings.&lt;br /&gt;Setup is as follows:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;sol10u6 [~]# cat /etc/inet/ipsecinit.conf&lt;br /&gt;[...]&lt;br /&gt;{ laddr 10.0.2.15 raddr 10.0.2.16 } ipsec { encr_algs aes encr_auth_algs md5 sa shared }&lt;br /&gt;&lt;br /&gt;sol10u7 [~]# cat /etc/inet/ipsecinit.conf&lt;br /&gt;[...]&lt;br /&gt;{ laddr 10.0.2.16 raddr 10.0.2.15 } ipsec { encr_algs aes encr_auth_algs md5 sa shared }&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;encr_algs aes - Use AES as Encapsulating Security Payload (ESP, IP Protocol: 50) encryption algorithm &lt;br /&gt;encr_auth_algs md5 - Use MD5 as ESP authentication algorithm &lt;br /&gt;sa shared - shared Security Association (SA) means the communication between the two nodes in one direction uses the same channel;&lt;br /&gt;in opposite to "unique" which uses separate SA for each pair of source and destination ports&lt;br /&gt;&lt;br /&gt;Apply IPSec policy to the system:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;sol10u6 [~]# ipsecconf -a /etc/inet/ipsecinit.conf&lt;br /&gt;sol10u6 [~]# ipsecconf&lt;br /&gt;#INDEX 2&lt;br /&gt;{ laddr 10.0.2.15 raddr 10.0.2.16 } ipsec { encr_algs aes encr_auth_algs md5 sa shared }&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;From now the communication is broken; IPSec has been instructed to encrypt and authenticate the traffic.&lt;br /&gt;We need to provide the valid SA related to security policy.&lt;br /&gt;To automate the process of key management I've used IKE daemon (in.iked).&lt;br /&gt;It should be configured similary to below output:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;sol10u6 [~]# cat /etc/inet/ike/config&lt;br /&gt;[...]&lt;br /&gt;### BEGINNING OF FILE&lt;br /&gt;&lt;br /&gt;{&lt;br /&gt;   label "preshared"&lt;br /&gt;   local_id_type ip&lt;br /&gt;   local_addr 10.0.2.15&lt;br /&gt;   remote_addr 10.0.2.16&lt;br /&gt;   &lt;br /&gt;   p1_xform&lt;br /&gt;   { auth_method preshared  oakley_group 5  encr_alg aes  auth_alg md5 }&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;sol10u7 [~]# cat /etc/inet/ike/config&lt;br /&gt;[...]&lt;br /&gt;### BEGINNING OF FILE&lt;br /&gt;&lt;br /&gt;{&lt;br /&gt;   label "preshared"&lt;br /&gt;   local_id_type ip&lt;br /&gt;   local_addr 10.0.2.16&lt;br /&gt;   remote_addr 10.0.2.15&lt;br /&gt;   &lt;br /&gt;   p1_xform&lt;br /&gt;   { auth_method preshared  oakley_group 5  encr_alg aes  auth_alg md5 }&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;oakley_group - The Oakley Diffie-Hellman group used for IKE SA key derivation. Acceptable values are currently 1 (768-bit), 2 (1024-bit), or 5 (1536-bit).&lt;br /&gt;&lt;br /&gt;The last step is to configure the preshared secrets file.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;sol10u6 [~]# cat /etc/inet/secret/ike.preshared&lt;br /&gt;[...]&lt;br /&gt;{&lt;br /&gt; localidtype IP&lt;br /&gt; localid 10.0.2.15&lt;br /&gt; remoteidtype IP&lt;br /&gt; remoteid 10.0.2.16&lt;br /&gt; key 10112097109112108101451121141011151049711410110045107101121451151019911410111645100111451101111164511711510145105116&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;sol10u7 [~]# cat /etc/inet/secret/ike.preshared&lt;br /&gt;[...]&lt;br /&gt;{&lt;br /&gt; localidtype IP&lt;br /&gt; localid 10.0.2.16&lt;br /&gt; remoteidtype IP&lt;br /&gt; remoteid 10.0.2.15&lt;br /&gt; key 10112097109112108101451121141011151049711410110045107101121451151019911410111645100111451101111164511711510145105116&lt;br /&gt;}&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;key - continuous ASCII characters decimal representation of the passphrase "example-preshared-key-secret-do-not-use-it" (converted with &lt;b&gt;ikepconv&lt;/b&gt; from the beginning of my post).&lt;br /&gt;That's it: e(101)x(120)a(97)m(109)p(112)l(108)e(101)-(45)...&lt;br /&gt;&lt;br /&gt;Start IKE daemon:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;sol10u6 [~]# /usr/lib/inet/in.iked -d  [debug mode]&lt;br /&gt;sol10u6 [~]# /usr/lib/inet/in.iked&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;It's time for a simple test.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;sol10u7 [~]# ping 10.0.2.15&lt;br /&gt;10.0.2.15 is alive&lt;br /&gt;&lt;br /&gt;sol10u6 [~]# snoop -c 1 src host 10.0.2.16&lt;br /&gt;Using device /dev/e1000g0 (promiscuous mode)&lt;br /&gt;     sol10u7 -&gt; sol10u6      ESP SPI=0xc072b272 Replay=6&lt;br /&gt;1 packets captured&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;sol10u7 [~]# ping 10.0.2.15&lt;br /&gt;10.0.2.15 is alive&lt;br /&gt;&lt;br /&gt;sol10u6 [~]# snoop -c 1 -v src host 10.0.2.16&lt;br /&gt;Using device /dev/e1000g0 (promiscuous mode)&lt;br /&gt;ETHER:  ----- Ether Header -----&lt;br /&gt;ETHER:&lt;br /&gt;ETHER:  Packet 1 arrived at 17:46:25.51503&lt;br /&gt;ETHER:  Packet size = 150 bytes&lt;br /&gt;ETHER:  Destination = 8:0:27:ba:19:34, PCS Computer Systems GmbH&lt;br /&gt;ETHER:  Source      = 8:0:27:30:9c:39, PCS Computer Systems GmbH&lt;br /&gt;ETHER:  Ethertype = 0800 (IP)&lt;br /&gt;ETHER:&lt;br /&gt;IP:   ----- IP Header -----&lt;br /&gt;IP:&lt;br /&gt;IP:   Version = 4&lt;br /&gt;IP:   Header length = 20 bytes&lt;br /&gt;IP:   Type of service = 0x00&lt;br /&gt;IP:         xxx. .... = 0 (precedence)&lt;br /&gt;IP:         ...0 .... = normal delay&lt;br /&gt;IP:         .... 0... = normal throughput&lt;br /&gt;IP:         .... .0.. = normal reliability&lt;br /&gt;IP:         .... ..0. = not ECN capable transport&lt;br /&gt;IP:         .... ...0 = no ECN congestion experienced&lt;br /&gt;IP:   Total length = 136 bytes&lt;br /&gt;IP:   Identification = 9596&lt;br /&gt;IP:   Flags = 0x0&lt;br /&gt;IP:         .0.. .... = may fragment&lt;br /&gt;IP:         ..0. .... = last fragment&lt;br /&gt;IP:   Fragment offset = 0 bytes&lt;br /&gt;IP:   Time to live = 255 seconds/hops&lt;br /&gt;IP:   Protocol = 50 (ESP)&lt;br /&gt;IP:   Header checksum = 7da9&lt;br /&gt;IP:   Source address = 10.0.2.16, sol10u7&lt;br /&gt;IP:   Destination address = 10.0.2.15, sol10u6&lt;br /&gt;IP:   No options&lt;br /&gt;IP:&lt;br /&gt;ESP:  ----- Encapsulating Security Payload -----&lt;br /&gt;ESP:&lt;br /&gt;ESP:  SPI = 0xc072b272&lt;br /&gt;ESP:  Replay = 10&lt;br /&gt;ESP:     ....ENCRYPTED DATA....&lt;br /&gt;&lt;br /&gt;1 packets captured&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;b&gt;INFO&lt;/b&gt;:&lt;br /&gt;The IPSec definitions has been added to SMF in Solaris 10 update 7:&lt;br /&gt;svc:/network/ipsec/manual-key:default&lt;br /&gt;svc:/network/ipsec/ike:default&lt;br /&gt;svc:/network/ipsec/ipsecalgs:default&lt;br /&gt;svc:/network/ipsec/policy:default&lt;br /&gt;&lt;br /&gt;Remember to enable ipsec/ike daemon service.&lt;br /&gt;&lt;br /&gt;Enjoy.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-9199168377604848638?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/9199168377604848638/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=9199168377604848638' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/9199168377604848638'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/9199168377604848638'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/05/solaris-ipsec-with-preshared-keys.html' title='Solaris IPSec with preshared keys'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-1089573497029936444</id><published>2009-04-26T22:05:00.004+02:00</published><updated>2009-04-26T22:12:50.964+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='directory server'/><category scheme='http://www.blogger.com/atom/ns#' term='ssl'/><category scheme='http://www.blogger.com/atom/ns#' term='openssl'/><title type='text'>Directory Server SSL Certificate</title><content type='html'>Recently, I've added the article about SSL configuration of Sun Java Commmunications Suite components (&lt;a href="http://unixwear.blogspot.com/2009/03/ssl-be-prepared.html"&gt;link&lt;/a&gt;).&lt;br /&gt;Today I want to expand its content with Directory Server SSL preparation.&lt;br /&gt;&lt;br /&gt;DS comes with self-signed certificate (it's valid for a period of three months). It name's &lt;em&gt;defaultCert&lt;/em&gt;, and by defalt allow for secure connections through the port 636.&lt;br /&gt;It's stored in &lt;em&gt;alias&lt;/em&gt; directory under the instance path:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;book [/]# ls /instances/ds1/alias&lt;br /&gt;certmap.conf    secmod.db       slapd-cert8.db  slapd-key3.db&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;book [/instances/ds1/alias]# dsconf get-server-prop -D cn=dirmgr ssl-rsa-cert-name&lt;br /&gt;Enter "cn=dirmgr" password:  &lt;br /&gt;ssl-rsa-cert-name  :  defaultCert&lt;br /&gt;&lt;br /&gt;book [/]# /opt/SUNWdsee/ds6/bin/dsadm list-certs /instances/ds1/&lt;br /&gt;Alias        Valid from        Expires on        Self-signed?  Issued by                                              Issued to  &lt;br /&gt;-----------  ----------------  ----------------  ------------  -----------------------------------------------------  --------------  &lt;br /&gt;defaultCert  2009/03/18 12:28  2009/06/18 12:28  y             CN=book,CN=636,CN=Directory Server,O=Sun Microsystems  Same as issuer  &lt;br /&gt;1 certificate(s) found&lt;br /&gt;&lt;br /&gt;book [/instances/ds1/alias]# /usr/sfw/bin/certutil -L -P slapd- -d .&lt;br /&gt;defaultCert                                                  CTu,u,u&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;But, I want to use the same one as with other COMMS components - Server-Cert - issued by CA.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;book [/instances/ds1/alias]# dsadm import-cert /instances/ds1/ /root/SSL/VeriSign.cert.pkcs12 &lt;br /&gt;Enter the PKCS#12 file password:&lt;br /&gt;The Directory Server will need to be restarted before being able to use the new certificate.&lt;br /&gt;book [/instances/ds1/alias]# dsadm stop /instances/ds1&lt;br /&gt;Directory Server instance '/instances/ds1' stopped&lt;br /&gt;book [/instances/ds1/alias]# dsadm start /instances/ds1&lt;br /&gt;Directory Server instance '/instances/ds1' started: pid=25150&lt;br /&gt;book [/instances/ds1/alias]# /usr/sfw/bin/certutil -L -P slapd- -d .&lt;br /&gt;defaultCert                                                  CTu,u,u&lt;br /&gt;Server-Cert                                                  u,u,u&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Now i have to change default rsa certificate name, within the DS configuration:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;book [~]# dsconf set-server-prop -p 389 -D cn=dirmgr ssl-rsa-cert-name:Server-Cert&lt;br /&gt;Enter "cn=dirmgr" password:  &lt;br /&gt;Before setting SSL configuration, export Directory Server data. &lt;br /&gt;Do you want to continue [y/n] ?  y&lt;br /&gt;Directory Server must be restarted for changes to take effect.&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Restart DS one more time.&lt;br /&gt;&lt;br /&gt;That's all folks.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;book [~]# dsconf get-server-prop -p 389 -D cn=dirmgr ssl-rsa-cert-name&lt;br /&gt;Certificate "CN=[...]" presented by the server is not trusted.&lt;br /&gt;Type "Y" to accept, "y" to accept just once, "n" to refuse, "d" for more details: Y&lt;br /&gt;Enter "cn=dirmgr" password:  &lt;br /&gt;ssl-rsa-cert-name  :  Server-Cert  &lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-1089573497029936444?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/1089573497029936444/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=1089573497029936444' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1089573497029936444'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1089573497029936444'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/04/directory-server-ssl-certificate.html' title='Directory Server SSL Certificate'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-7198621072191767166</id><published>2009-04-08T20:09:00.008+02:00</published><updated>2009-04-08T22:23:06.164+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='messaging server'/><title type='text'>Forward mappings</title><content type='html'>The presented configuration allows to gather messages of specified address pattern inside the given mail account.&lt;br /&gt;The below example is based on the destination address, but can be easily changed into source based.&lt;br /&gt;&lt;br /&gt;Sun Java Messaging Server allow to use the FORWARD mapping table and FORWARD lookup table.&lt;br /&gt;I will focus on FORWARD Mapping Table. This usage is disabled by default. So, before I can go further I have to enable the USE_FORWARD_DATABASE withing the &lt;em&gt;option.dat&lt;/em&gt; file.&lt;br /&gt;&lt;br /&gt;USE_FORWARD_DATABASE can take one of three values. The meaning is as follows:&lt;br /&gt;&lt;ul&gt;&lt;br /&gt;&lt;li&gt;1 - use forward database&lt;br /&gt;&lt;li&gt;8 - use forward database entries with a specified channel&lt;br /&gt;&lt;li&gt;16 - use forward mapping table entries with a specified channel&lt;br /&gt;&lt;/ul&gt;&lt;br /&gt;To get the pieces together I've used &lt;em&gt;16&lt;/em&gt;, so:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;[option.dat]&lt;br /&gt;[...]&lt;br /&gt;USE_FORWARD_DATABASE=16&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;To let the Messaging Server keep all the messages begining with a &lt;em&gt;prefix-&lt;/em&gt; on the wisnios@wisnios.com account, add the following to your &lt;em&gt;mappings&lt;/em&gt; file:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;FORWARD&lt;br /&gt; &lt;br /&gt;!&lt;br /&gt;! Format for channel specific forward mapping entries&lt;br /&gt;! src-channel|source-address|original-address changed-address&lt;br /&gt;!&lt;br /&gt;  *|*|prefix-*@wisnios.com  $D$H$Ywisnios@wisnios.com&lt;br /&gt;&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;The first * (asterisk) could be &lt;em&gt;tcp_local&lt;/em&gt;. I thought so, but it's not true.&lt;br /&gt;Simple test with &lt;em&gt;imsimta test -rewrite -debug prefix-test@wisnios.com&lt;/em&gt; shows that message uses the &lt;em&gt;l&lt;/em&gt; channel:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;[...]&lt;br /&gt;12:41:14.65:     Applying forward mapping to: l|postmaster@book.entic.net|prefix-test@wisnios.com&lt;br /&gt;12:41:14.65:       Matched, result is: wisnios@wisnios.com&lt;br /&gt;[...]&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;The second field could be used as an additional pattern filter, based on the sender address / domain part.&lt;br /&gt;In my example it's also the asterisk sign.&lt;br /&gt;&lt;br /&gt;The third field does the trick.&lt;br /&gt;&lt;br /&gt;$D - run rewrite process one more time (without this option mapping will fail)&lt;br /&gt;$H - do not check any other forward lookup table or FORWARD mapping entries (optional with this one entry)&lt;br /&gt;$Y - use specified address as a new one (no comment - required)&lt;br /&gt;&lt;br /&gt;So, let's try:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;book [/]# imsimta test -mapping -debug&lt;br /&gt;Enter table name: FORWARD&lt;br /&gt;Input string: tcp_local|wisnios@gmail.com|prefix-test@wisnios.com&lt;br /&gt;13:00:03.39: Mapping 6 applied to tcp_local|wisnios@gmail.com|prefix-test@wisnios.com&lt;br /&gt;13:00:03.39:   Entry #1 matched, pattern "*|*|prefix-*@wisnios.com", template "$D$H$Ywisnios@wisnios.com", match #0.&lt;br /&gt;13:00:03.39:   New target "wisnios@wisnios.com"&lt;br /&gt;13:00:03.39:   Exiting...&lt;br /&gt;13:00:03.39:   Final result "wisnios@wisnios.com"&lt;br /&gt;Output string: wisnios@wisnios.com&lt;br /&gt;Output flags: [0, 'D' (68), 'H' (72), 'Y' (89)]&lt;br /&gt;Input string: &lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;The last bastion was the &lt;em&gt;imsimta&lt;/em&gt; command itself.&lt;br /&gt;After the configuration changes I've run &lt;em&gt;imsimta cnbuild &amp;&amp; imsimta reload&lt;/em&gt;.&lt;br /&gt;That was a mistake. &lt;br /&gt;It allows &lt;em&gt;imsimta test -rewrite&lt;/em&gt; complete successfully, but rejects the incoming messages to prefix-something with:&lt;br /&gt;550 5.1.1 unknown or illegal alias: prefix-something@wisnios.com&lt;br /&gt;&lt;br /&gt;To make everything work smoothly run &lt;em&gt;imsimta restart&lt;/em&gt; after job complete.&lt;br /&gt;&lt;br /&gt;To test this configuration I've used: &lt;br /&gt;&lt;pre&gt;&lt;br /&gt;Sun Java(tm) System Messaging Server 6.3-2.01 (built Jun 13 2007; 64bit)&lt;br /&gt;libimta.so 6.3-2.01 (built 00:30:08, Jun 13 2007; 64bit)&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-7198621072191767166?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/7198621072191767166/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=7198621072191767166' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7198621072191767166'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7198621072191767166'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/04/forward-mappings.html' title='Forward mappings'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-2729480718315633389</id><published>2009-04-07T20:25:00.005+02:00</published><updated>2009-04-08T15:18:00.786+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='messaging server'/><category scheme='http://www.blogger.com/atom/ns#' term='mail'/><category scheme='http://www.blogger.com/atom/ns#' term='oneliners'/><title type='text'>Summary of the mail traffic size</title><content type='html'>Today I've written a handy oneliner to get a summary of mail traffic size for a current/yesterday period of log time.&lt;br /&gt;Sun Java Messaging Server denotes the size (sz) of every message in kilobytes, accordingly to the (MTA) BLOCK_SIZE variable (default value: 1024 bytes). &lt;br /&gt;&lt;br /&gt;For example, to get the yesterday sum of messages being sent to domain.com (single-tiered architecture):&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;sed '/tcp_local.*ims-ms.*domain.com/p;d' mail.log_yesterday | awk '{ SIZE+=$6 } END { print SIZE/1024 }' &lt;br /&gt;&lt;/pre&gt; &lt;br /&gt;The returned value will be presented in Mb.&lt;br /&gt;&lt;br /&gt;To get a similar check for frontend-backend (two-tiered) scenario, with LMTP, and for a current log file:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;sed '/tcp_local.*tcp_lmtpcs.*domain.com/p;d' mail.log_current | awk '{ SIZE+=$6 } END { print SIZE/1024 }'&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;To engage a command for the outbound messages I've used a tcp_auth channel name as a significant mark.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# sed '/tcp_auth.*wisnios.com/p;d;' mail.log_yesterday | awk '{ SIZE+=$6 } END { print SIZE/1024 }'&lt;br /&gt;102.645&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-2729480718315633389?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/2729480718315633389/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=2729480718315633389' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2729480718315633389'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2729480718315633389'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/04/summary-of-mail-traffic-size.html' title='Summary of the mail traffic size'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-1475176970072568582</id><published>2009-04-02T15:12:00.006+02:00</published><updated>2009-04-02T15:46:01.227+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='mta'/><category scheme='http://www.blogger.com/atom/ns#' term='messaging server'/><category scheme='http://www.blogger.com/atom/ns#' term='rotation'/><category scheme='http://www.blogger.com/atom/ns#' term='log'/><category scheme='http://www.blogger.com/atom/ns#' term='logadm'/><title type='text'>MTA log rotation for Messaging Server</title><content type='html'>Sun Java System Messaging Server do not rotate the log file of MTA process - &lt;em&gt;mail.log&lt;/em&gt;. There is only a two steps of pseudo rotation between the files: &lt;em&gt;mail.log_current&lt;/em&gt;, &lt;em&gt;mail.log_yesterday&lt;/em&gt; and a &lt;em&gt;mail.log&lt;/em&gt; "bucket".&lt;br /&gt;&lt;br /&gt;Present activity is being logged into mail.log_current. It's content will be moved into mail.log_yesterday after a day period.&lt;br /&gt;After the next day, it will end its rotation life inside the mail.log file, increasing its content.&lt;br /&gt;&lt;br /&gt;To control the mail.log growth process I use the Solaris logadm tool.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;book [/]# crontab -l&lt;br /&gt;[...]&lt;br /&gt;# Messaging Server MTA log rotation&lt;br /&gt;0 0 * * 1 /usr/sbin/logadm -c -C 52 -t '$dirname/$basename.$n' /var/opt/sun/comms/messaging64/log/mail.log&lt;br /&gt;book [/]#&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Every monday, at 0:00 AM, the logadm rotates the given logfile. It copies the original file (-c) to a next available one, with increased version number ($basename.$n), and truncates the mail.log content to zero (-c). It keeps 52 copies of rotated files (-C 52) and cleans the rest.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-1475176970072568582?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/1475176970072568582/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=1475176970072568582' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1475176970072568582'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1475176970072568582'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/04/mta-log-rotation-for-messaging-server.html' title='MTA log rotation for Messaging Server'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-5837014497741235488</id><published>2009-03-28T22:47:00.011+01:00</published><updated>2009-03-28T23:31:56.972+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='network'/><category scheme='http://www.blogger.com/atom/ns#' term='ipfw'/><category scheme='http://www.blogger.com/atom/ns#' term='macosx'/><title type='text'>Mac OS X ipfw traffic shaping</title><content type='html'>It's related to my common problem with images upload. When I start to upload a new set of pictures the rest of traffic on my isp network connection is being reduced almost to zero.&lt;br /&gt;&lt;br /&gt;To decrease the available bandwidth to a flickr website, I've used below commands:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;% sudo ipfw pipe 1 config bw 256kbit/s&lt;br /&gt;&lt;br /&gt;% sudo ipfw pipe show&lt;br /&gt;00001: 256.000 Kbit/s    0 ms   50 sl. 0 queues (1 buckets) droptail&lt;br /&gt;    mask: 0x00 0x00000000/0x0000 -&gt; 0x00000000/0x0000&lt;br /&gt;&lt;br /&gt;% sudo ipfw add pipe 1 dst-ip 87.248.121.213 dst-port 80&lt;br /&gt;33400 pipe 1 ip from any to any dst-ip 87.248.121.213 dst-port 80&lt;br /&gt;&lt;br /&gt;% sudo ipfw show                            &lt;br /&gt;33300       0          0 deny icmp from any to me in icmptypes 8&lt;br /&gt;33400    1492    2084081 pipe 1 ip from any to any dst-ip 87.248.121.213 dst-port 80&lt;br /&gt;&lt;br /&gt;% sudo ipfw pipe show&lt;br /&gt;00001: 256.000 Kbit/s    0 ms   50 sl. 1 queues (1 buckets) droptail&lt;br /&gt;    mask: 0x00 0x00000000/0x0000 -&gt; 0x00000000/0x0000&lt;br /&gt;BKT Prot ___Source IP/port____ ____Dest. IP/port____ Tot_pkt/bytes Pkt/Byte Drp&lt;br /&gt;  0 tcp    192.168.1.101/57602  87.248.121.213/80     437   611800 46 64400   0&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;When the job is completed:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;% sudo ipfw delete 33400 &lt;br /&gt;&lt;br /&gt;OR /if there's no other pipes/&lt;br /&gt;&lt;br /&gt;% sudo ipfw pipe flush&lt;br /&gt;Are you sure? [yn] y&lt;br /&gt;&lt;br /&gt;Flushed all pipes.&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-5837014497741235488?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/5837014497741235488/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=5837014497741235488' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5837014497741235488'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5837014497741235488'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/03/mac-os-x-ipfw-traffic-shaping.html' title='Mac OS X ipfw traffic shaping'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-2459284057418045346</id><published>2009-03-26T21:39:00.005+01:00</published><updated>2009-03-26T21:58:12.421+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='application'/><category scheme='http://www.blogger.com/atom/ns#' term='glassfish'/><category scheme='http://www.blogger.com/atom/ns#' term='convergence'/><category scheme='http://www.blogger.com/atom/ns#' term='monitoring'/><title type='text'>Monitoring sessions in application server</title><content type='html'>The method described below is reated to GlassFish Application Server in Solaris 10 environment.&lt;br /&gt;I've used the example of Convergence application (from Sun Java Communications Suite), but it could be any other app deployed on appsvr.&lt;br /&gt;&lt;br /&gt;Before we start let's check the monitoring levels of services:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# /opt/SUNWappserver/bin/asadmin get server.monitoring-service.module-monitoring-levels.*&lt;br /&gt;server.monitoring-service.module-monitoring-levels.connector-connection-pool = OFF&lt;br /&gt;server.monitoring-service.module-monitoring-levels.connector-service = OFF&lt;br /&gt;server.monitoring-service.module-monitoring-levels.ejb-container = OFF&lt;br /&gt;server.monitoring-service.module-monitoring-levels.http-service = OFF&lt;br /&gt;server.monitoring-service.module-monitoring-levels.jdbc-connection-pool = OFF&lt;br /&gt;server.monitoring-service.module-monitoring-levels.jms-service = OFF&lt;br /&gt;server.monitoring-service.module-monitoring-levels.jvm = OFF&lt;br /&gt;server.monitoring-service.module-monitoring-levels.orb = OFF&lt;br /&gt;server.monitoring-service.module-monitoring-levels.thread-pool = OFF&lt;br /&gt;server.monitoring-service.module-monitoring-levels.transaction-service = OFF&lt;br /&gt;server.monitoring-service.module-monitoring-levels.web-container = OFF&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;The most interesting, in this case, is the last one.&lt;br /&gt;To begin monitor the given service we have to switch its lavel to &lt;em&gt;HIGH&lt;/em&gt; (or &lt;em&gt;LOW&lt;/em&gt;; it makes no difference from GlassFish v3). &lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# /opt/SUNWappserver/bin/asadmin set server.monitoring-service.module-monitoring-levels.web-container=HIGH&lt;br /&gt;Please enter the admin user name&gt;admin&lt;br /&gt;Please enter the admin password&gt;&lt;br /&gt;server.monitoring-service.module-monitoring-levels.web-container = HIGH&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Let's look at all the session counters related lines.&lt;br /&gt;&lt;br /&gt;All appliacations:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# /opt/SUNWappserver/bin/asadmin get --user admin --passwordfile /your/favourite/path/to/password/file \&lt;br /&gt;--monitor=true server.applications.*.server.*session*count &lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Convergence only:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# /opt/SUNWappserver/bin/asadmin get --user admin --passwordfile /your/favourite/path/to/password/file \&lt;br /&gt;--monitor=true server.applications.Convergence.server.*session*count &lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Sample command to get the current value of Convergence active sessions:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# /opt/SUNWappserver/bin/asadmin get --user admin --passwordfile /your/favourite/path/to/password/file \&lt;br /&gt;--monitor=true server.applications.Convergence.server.activesessionscurrent-count&lt;br /&gt;server.applications.Convergence.server.activesessionscurrent-count = 99&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-2459284057418045346?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/2459284057418045346/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=2459284057418045346' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2459284057418045346'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2459284057418045346'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/03/monitoring-sessions-in-application.html' title='Monitoring sessions in application server'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-223767197389376441</id><published>2009-03-14T20:15:00.007+01:00</published><updated>2009-03-14T23:16:36.787+01:00</updated><title type='text'>Sun Java System Directory Server Platform Support</title><content type='html'>SJSDSPS... nice title ;-)&lt;br /&gt;&lt;br /&gt;Since yesterday I've been looking forward for the Directory Server installator for AIX (6.1) system.  I know, there is still the OpenDS, but I want the same solution I know from Solaris. The last possible download of DS for AIX (5.2), available on the official Sun Microsystems web site, is Directory Server 5.2 P4 Full Distribution and Directory Server 5.2 P6 Patch. There's no opportunity to get the Directory Server Enterprise Edition (DSEE).&lt;br /&gt;&lt;br /&gt;I thought I missed something. Maybe Sun guys do not like IBM guys.&lt;br /&gt;Than, I've found this - &lt;a href="http://docs.sun.com/app/docs/doc/820-2759/eof-platform-support"&gt;http://docs.sun.com/app/docs/doc/820-2759/eof-platform-support&lt;/a&gt; :&lt;br /&gt;&lt;em&gt;&lt;br /&gt;In future releases of Directory Server Enterprise Edition, support for Windows 2000, Red Hat Advanced Server 3.0, and J2SE platform 1.4 may be removed. Support for the native install package releases for platforms other than the Solaris operating system might be removed. Support for 32–bit versions of the software might be discontinued for some platforms. To be prepared, plan the transition to 64–bit versions of the software and to newer versions of the supported operating systems.&lt;br /&gt;&lt;/em&gt;&lt;br /&gt;"Might be" or "has been" makes a difference.&lt;br /&gt;&lt;br /&gt;And one more quotation - &lt;a href="http://docs.sun.com/source/819-1815/index.html"&gt;http://docs.sun.com/source/819-1815/index.html&lt;/a&gt; :&lt;br /&gt;&lt;em&gt;&lt;br /&gt;Directory Server 5.2 Patch 6 is available on the following platforms:&lt;br /&gt;[...]&lt;br /&gt;&amp;middot; IBM AIX 5.2 (Power PC) (32 bit)&lt;br /&gt;&lt;br /&gt;The original release of Directory Server 5.2 has not been validated on IBM AIX 5.2. However, this update is validated on IBM AIX 5.2. The original release of Directory Server 5.2 has been validated on IBM AIX 5.1, but IBM AIX 5.1 is no longer supported by IBM.&lt;br /&gt;&lt;/em&gt;&lt;br /&gt;So, the guilty of lack of AIX support for Directory Server is IBM itself. Am I wrong or right?&lt;br /&gt;But, it's related to AIX 5.2. What about AIX 5.3, AIX 6.1? I don't know the answer. Anybody?&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-223767197389376441?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/223767197389376441/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=223767197389376441' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/223767197389376441'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/223767197389376441'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/03/sun-java-system-directory-server.html' title='Sun Java System Directory Server Platform Support'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-4281310021310183813</id><published>2009-03-13T19:56:00.007+01:00</published><updated>2009-03-13T20:57:19.217+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rpm'/><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='freeware'/><category scheme='http://www.blogger.com/atom/ns#' term='aix'/><title type='text'>Linux stuff in the AIX neighbourhood</title><content type='html'>When I logged in into the AIX system for a very first time I had experienced the beauty of IBM system, and helplessness. I had known only the four AIX specific commands, and a bunch of experiences from Sun Solaris system.&lt;br /&gt;&lt;br /&gt;The first stonghold was the ksh system shell. No history. No command completion. "No" in a way I used to use it. It took me a while to find out the &lt;em&gt;fc&lt;/em&gt; cmd.&lt;br /&gt;So, the fist thought was to bring in the &lt;em&gt;zsh&lt;/em&gt;.&lt;br /&gt;&lt;br /&gt;But... in order to make it possible, I have to know - HOW and FROM. &lt;br /&gt;The Solaris has got it's &lt;a href="http://sunfreeware.com"&gt;sunfreeware.com&lt;/a&gt; and &lt;a href="http://blastwave.org"&gt;blastwave.org&lt;/a&gt;. AIX - rpm database of ppc packages.&lt;br /&gt;&lt;br /&gt;Here it is: &lt;a href="http://www-03.ibm.com/systems/power/software/aix/linux/toolbox/alpha.html"&gt;http://www-03.ibm.com/systems/power/software/aix/linux/toolbox/alpha.html&lt;/a&gt;&lt;br /&gt;How to get the rpm itself: &lt;a href="http://www-03.ibm.com/systems/power/software/aix/linux/toolbox/altlic.html"&gt;http://www-03.ibm.com/systems/power/software/aix/linux/toolbox/altlic.html&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;The rest is as simple as:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# rpm -i zsh*rpm &lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;... after installing the dependencies ;-) (rpm packages: coreutils, grep)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-4281310021310183813?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/4281310021310183813/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=4281310021310183813' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4281310021310183813'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4281310021310183813'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/03/linux-stuff-in-aix-neighbourhood.html' title='Linux stuff in the AIX neighbourhood'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-254687892942547008</id><published>2009-03-10T21:26:00.019+01:00</published><updated>2009-03-13T20:56:36.356+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ca'/><category scheme='http://www.blogger.com/atom/ns#' term='rsa'/><category scheme='http://www.blogger.com/atom/ns#' term='ssl'/><category scheme='http://www.blogger.com/atom/ns#' term='pem'/><category scheme='http://www.blogger.com/atom/ns#' term='csr'/><category scheme='http://www.blogger.com/atom/ns#' term='openssl'/><category scheme='http://www.blogger.com/atom/ns#' term='certificate'/><category scheme='http://www.blogger.com/atom/ns#' term='pkcs12'/><title type='text'>SSL: be prepared</title><content type='html'>Before you could start with SSL changes on application level of configuration, you have to prepare certificate and its database.&lt;br /&gt;First the certificate should be converted from PEM to PKCS#12 format.&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# openssl pkcs12 -export -in cert.pem -inkey key.rsa -out cert.pkcs12 -name Server-Cert&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style:italic;"&gt;cert.pem&lt;/span&gt; - certificate taken from Certificate Authority (CA), either local or public (Thawte, Verisign, other)&lt;br /&gt;&lt;span style="font-style:italic;"&gt;key.rsa&lt;/span&gt; - private key used to sign the Certificate Signing Request (CSR)&lt;br /&gt;&lt;span style="font-style:italic;"&gt;cert.pkcs12&lt;/span&gt; - pkcs#12 output file&lt;br /&gt;&lt;span style="font-style:italic; font-weight:bold"&gt;Server-Cert&lt;/span&gt; - you could use any other, but in the most cases it's a default certificate name (alias) used within SSL configuration, ex.&lt;br /&gt;&lt;pre&gt; &lt;br /&gt;# configutil -o encryption.rsa.nssslpersonalityssl&lt;br /&gt;Server-Cert&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Messaging Server&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Initialize certificate database:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# msgcert generate-certDB&lt;br /&gt;Choose the Certificate Database password:&lt;br /&gt;Confirm the Certificate Database password:&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;It lead to creation of database files: cert8.db, key3.db, secmod.db and sslpassword.conf - plain text file, used to store software token (password provided during the generation process).&lt;br /&gt;Initialization has created the self-signed certificate, with Server-Cert alias name.&lt;br /&gt;Before we start the import, we have to remove it unless different cert name will be used.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# msgcert remove-cert Server-Cert&lt;br /&gt;Enter the certificate database password:&lt;br /&gt;book [/opt/sun/comms/messaging64/config]# msgcert list-certs&lt;br /&gt;Enter the certificate database password:&lt;br /&gt;Alias  Valid from  Expires on  Self-signed?  Issued by  Issued to  &lt;br /&gt;-----  ----------  ----------  ------------  ---------  ---------  &lt;br /&gt;0 certificates found&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Now, let's eat some certificates.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# msgcert import-cert /root/SSL/cert.pkcs12&lt;br /&gt;Enter the PKCS#12 file password:&lt;br /&gt;Enter the certificate database password:&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Voile!&lt;br /&gt;&lt;br /&gt;If there's a need of rollback to self-signed certificate or renew the expired one, use the similar commads:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# msgcert add-selfsign-cert -S "CN=mail.wisnios.com" Server-Cert&lt;br /&gt;&lt;br /&gt;# msgcert renew-selfsign-cert Server-Cert&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Errors:&lt;br /&gt;&lt;em&gt;&lt;br /&gt;&amp;middot; Internal error: NSS error (SEC_PKCS12DecoderUpdate) in importCert:&lt;br /&gt;security library: improperly formatted DER-encoded message. (-8183)&lt;br /&gt;Failed to import the certificate&lt;br /&gt;&lt;/em&gt;&lt;br /&gt;The certificate file has not been converted from PEM to PKCS#12&lt;br /&gt;(use openssl pkcs12 -export)&lt;br /&gt;&lt;br /&gt;&lt;em&gt;&lt;br /&gt;&amp;middot; A certificate with the same alias already exists in the database.&lt;br /&gt;Failed to import the certificate&lt;br /&gt;&lt;/em&gt;&lt;br /&gt;The previously created (self-signed) certificate has not been removed&lt;br /&gt;(use msgcert remove-cert)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Web Server&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;We could use the same converted file to feed the web server database.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;[/var/opt/SUNWwbsvr7/https-mail.wisnios.com/config]&lt;br /&gt;# /opt/SUNWwbsvr7/bin/pk12util -i /root/SSL/cert.pkcs12 -d .&lt;br /&gt;Enter a password which will be used to encrypt your keys.&lt;br /&gt;The password should be at least 8 characters long,&lt;br /&gt;and should contain at least one non-alphabetic character.&lt;br /&gt;&lt;br /&gt;Enter new password: &lt;br /&gt;Re-enter password: &lt;br /&gt;Enter password for PKCS12 file: &lt;br /&gt;pk12util: PKCS12 IMPORT SUCCESSFUL&lt;br /&gt;&lt;br /&gt;[/var/opt/SUNWwbsvr7/https-mail.wisnios.com/config]&lt;br /&gt;# certutil -L -d .&lt;br /&gt;Server-Cert                                                  u,u,u&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;The triple 'u' means that certificate could be used for authentication (SSL, email) and object signing.&lt;br /&gt;&lt;br /&gt;The self-signed cert could be generated with &lt;em&gt;wadm&lt;/em&gt; administration command:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;wadm&gt; create-selfsigned-cert --config=mail.wisnios.com --server-name=mail.wisnios.com \&lt;br /&gt;--nickname=Server-Cert --token=internal&lt;br /&gt;CLI201 Command 'create-selfsigned-cert' ran successfully&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Application Server (Glassfish)&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The same trick with appsvr.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;[/opt/SUNWappserver/domains/domain1/config]&lt;br /&gt;# pk12util -i /root/SSL/cert.pkcs12 -d .&lt;br /&gt;&lt;br /&gt;[/opt/SUNWappserver/domains/domain1/config]&lt;br /&gt;# certutil -L -n Server-Cert -d .&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;To change the default instance ssl configuration, follow those steps:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;[https://appserver:4848]&lt;br /&gt;&lt;br /&gt;Configurations:&lt;br /&gt;    default-config:&lt;br /&gt;        HTTP Service:&lt;br /&gt;            http-listener-2: (switch to right panel)&lt;br /&gt;&lt;br /&gt;[right panel]&lt;br /&gt;SSL:&lt;br /&gt;    Certificate NickName: Server-Cert (replace the default &lt;em&gt;s1as&lt;/em&gt; entry)&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Good luck.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-254687892942547008?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/254687892942547008/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=254687892942547008' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/254687892942547008'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/254687892942547008'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/03/ssl-be-prepared.html' title='SSL: be prepared'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-5541360280570459946</id><published>2009-02-25T23:12:00.005+01:00</published><updated>2009-02-26T00:14:48.549+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='pid'/><category scheme='http://www.blogger.com/atom/ns#' term='port'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><category scheme='http://www.blogger.com/atom/ns#' term='script'/><title type='text'>port to pid / pid to port mapper</title><content type='html'>Finally, I've developed the mutual pid/port mapper.&lt;br /&gt;&lt;br /&gt;Here it is. Feel free to use.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;#!/bin/bash&lt;br /&gt;#&lt;br /&gt;# The mutual pid/port mapper&lt;br /&gt;# - Marcin Wisnios [marcin AT wisnios.com]&lt;br /&gt;#&lt;br /&gt;case "$1" in&lt;br /&gt;'')&lt;br /&gt;        echo "Usage: $0 PORT | -p PID | -n NAME | -a (ALL)"&lt;br /&gt;        exit 1&lt;br /&gt;        ;;&lt;br /&gt;'-p')&lt;br /&gt;        # pid search&lt;br /&gt;        P_ID=$2&lt;br /&gt;        ;;&lt;br /&gt;'-n')&lt;br /&gt;        # name search&lt;br /&gt;        P_ID=`pgrep $2`&lt;br /&gt;        ;;&lt;br /&gt;'-a')&lt;br /&gt;        # list all&lt;br /&gt;        P_ID=`ps -e -o pid,comm | sed '/PID/d; /ps/d; /sed/d; /bash/d; s/\([0-9]\{1,5\}\).*/\1/p;d'`&lt;br /&gt;        ;;&lt;br /&gt;*)&lt;br /&gt;        # port search&lt;br /&gt;        P_ID=`ps -e -o pid,comm | sed '/PID/d; /ps/d; /sed/d; /bash/d; s/\([0-9]\{1,5\}\).*/\1/p;d'`&lt;br /&gt;        PORT=$1&lt;br /&gt;        ;;&lt;br /&gt;esac&lt;br /&gt;&lt;br /&gt;for P in $P_ID; do&lt;br /&gt;&lt;br /&gt;        N=`ps -o comm -p $P | sed '/COMMAND/d'`&lt;br /&gt;        N=`basename $N`&lt;br /&gt;&lt;br /&gt;        pfiles $P | sed 's/.*sockname:\ AF_INET[6]\{0,1\} \(.*\)\ \ port:\ \(.*\)/\1:\2/p;d' | while read L; do&lt;br /&gt;                if [ -z $PORT ]; then&lt;br /&gt;                        echo "$L $P/$N"&lt;br /&gt;                else&lt;br /&gt;                        echo "$L $P/$N" | sed "/:$PORT/p;d"&lt;br /&gt;                fi&lt;br /&gt;        done&lt;br /&gt;&lt;br /&gt;done&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;Examples of use:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;book [/home/wisnios]# ./ppm.sh 22&lt;br /&gt;:::22 6963/sshd&lt;br /&gt;::ffff:208.64.63.178:22 13491/sshd&lt;br /&gt;::ffff:208.64.63.178:22 13507/sshd&lt;br /&gt;&lt;br /&gt;book [/home/wisnios]# ./ppm.sh -n ns-slapd&lt;br /&gt;:::389 7128/ns-slapd&lt;br /&gt;:::636 7128/ns-slapd&lt;br /&gt;&lt;br /&gt;book [/home/wisnios]# ./ppm.sh -p 20623&lt;br /&gt;0.0.0.0:80 20623/cherokee-worker&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-5541360280570459946?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/5541360280570459946/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=5541360280570459946' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5541360280570459946'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5541360280570459946'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2009/02/pid-to-port-mapper.html' title='port to pid / pid to port mapper'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-629675280371345372</id><published>2008-11-27T19:12:00.012+01:00</published><updated>2008-11-27T20:45:13.978+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='core system support'/><category scheme='http://www.blogger.com/atom/ns#' term='ssh'/><category scheme='http://www.blogger.com/atom/ns#' term='cdrom'/><category scheme='http://www.blogger.com/atom/ns#' term='pkgadd'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>Core system support - the journey begins</title><content type='html'>OK, I've installed 'core system support' software group. Solaris has started. &lt;br /&gt;What now? There's for ex. no ssh service, no bash or zsh shell.&lt;br /&gt;So I've decided to mount dvd image and install additional packages.&lt;br /&gt;&lt;br /&gt;But... which dsk device is the right one?&lt;br /&gt;No mounted device, no vfstab entry, no cdrom life marks on planet Solaris.&lt;br /&gt;&lt;br /&gt;I've found it finally with:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;for d in `ls /dev/dsk/*s2`;  do prtvtoc $d; sleep 2; done&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;The right one is that with only one slice, with sector count of 4509440 (dvd image size):&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;*                          First     Sector    Last&lt;br /&gt;* Partition  Tag  Flags    Sector     Count    Sector  Mount Directory&lt;br /&gt;       0      5    01          0   4509440   4509439&lt;br /&gt;       2      5    01          0   4509440   4509439&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;Mount:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;mount -F hsfs -o ro /dev/dsk/c1t0d0s2 /cdrom&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;and install desired software:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;pkgadd -R /a -d /cdrom/Solaris_10/Product&lt;br /&gt;[...]&lt;br /&gt;&lt;br /&gt;Select package(s) you wish to process  (or 'all' to process all packages).&lt;br /&gt;(default: all) [?,??,q]: SUNWsshcu,SUNWsshr,SUNWsshu,SUNWsshdr,SUNWsshdu,SUNWbash,SUNWzsh&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;I've used the &lt;em&gt;-R&lt;/em&gt; switch because I've done the work inside the shell session invoked from the Installation menu.&lt;br /&gt;The root system has been mounted at &lt;em&gt;/a&lt;/em&gt; directory.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-629675280371345372?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/629675280371345372/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=629675280371345372' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/629675280371345372'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/629675280371345372'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/11/core-system-support.html' title='Core system support - the journey begins'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-1774488530408200102</id><published>2008-11-17T19:16:00.005+01:00</published><updated>2008-11-17T19:57:29.836+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rubygems'/><category scheme='http://www.blogger.com/atom/ns#' term='ruby'/><category scheme='http://www.blogger.com/atom/ns#' term='encryption'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>libcrypt_d.so.1: open failed: No such file or directory</title><content type='html'>During the &lt;em&gt;rubygems&lt;/em&gt; installation process I've encountered the following problem:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;thumper [/export/install/sources/rubygems-1.3.1]# ruby setup.rb &lt;br /&gt;ld.so.1: ruby: fatal: libcrypt_d.so.1: open failed: No such file or directory&lt;br /&gt;Killed&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;Because of a cryptographic technology export restrictions there's no build-in support for some of the algorithms.&lt;br /&gt;&lt;br /&gt;To accomplish the task you should download and install 'Solaris 10 Encryption Kit for Sparc / x86'.&lt;br /&gt;Enjoy the screener:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;&lt;br /&gt;thumper [/export/install]# unzip sol-10-encrypt-GA-iso.zip&lt;br /&gt;thumper [/export/install]# lofiadm -a /export/install/sol-10-encrypt-GA.iso &lt;br /&gt;/dev/lofi/1&lt;br /&gt;thumper [/export/install]# mount -F hsfs -o ro /dev/lofi/1 /mnt&lt;br /&gt;thumper [/export/install]# mount -p | tail -1&lt;br /&gt;/dev/lofi/1 - /mnt hsfs - no ro,noglobal,maplcase,rr,traildot&lt;br /&gt;thumper [/export/install]# pkgadd -d /mnt/Encryption_10/i386/Packages&lt;br /&gt;&lt;br /&gt;The following packages are available:&lt;br /&gt;  1  SUNWcrman     Encryption Kit On-Line Manual Pages&lt;br /&gt;                   (i386) 10.0,REV=52.0&lt;br /&gt;  2  SUNWcry       Crypt Utilities&lt;br /&gt;                   (i386) 11.10.0,REV=2005.01.21.16.34&lt;br /&gt;  3  SUNWcryr      Solaris Root Crypto&lt;br /&gt;                   (i386) 11.10.0,REV=2005.01.21.16.34&lt;br /&gt;&lt;br /&gt;Select package(s) you wish to process (or 'all' to process&lt;br /&gt;all packages). (default: all) [?,??,q]: all&lt;br /&gt;[...]&lt;br /&gt;&lt;br /&gt;thumper [/export/install]# umount /mnt&lt;br /&gt;thumper [/export/install]# lofiadm -d /dev/lofi/1&lt;br /&gt;thumper [/export/install]# find /usr/lib -name libcrypt_d*&lt;br /&gt;/usr/lib/amd64/libcrypt_d.so&lt;br /&gt;/usr/lib/amd64/libcrypt_d.so.1&lt;br /&gt;/usr/lib/libcrypt_d.so&lt;br /&gt;/usr/lib/libcrypt_d.so.1&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;To make your ruby/gem environment fully usable don't forget to install &lt;em&gt;coreutils&lt;/em&gt; and &lt;em&gt;make&lt;/em&gt; sunfreeware packages. &lt;br /&gt;I've also linked the &lt;em&gt;ginstall&lt;/em&gt; to &lt;em&gt;install&lt;/em&gt; command:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;thumper [/usr/local/bin]# ln -s install ginstall&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;It's a solution for the gem package builder error messages.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-1774488530408200102?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/1774488530408200102/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=1774488530408200102' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1774488530408200102'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/1774488530408200102'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/11/libcryptdso1-open-failed-no-such-file.html' title='libcrypt_d.so.1: open failed: No such file or directory'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-7748980675773635100</id><published>2008-11-12T13:23:00.002+01:00</published><updated>2009-03-13T20:51:50.205+01:00</updated><title type='text'>Random password generator</title><content type='html'>&lt;pre&gt;&lt;br /&gt;openssl rand 8 -base64 | tr -d '='&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-7748980675773635100?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/7748980675773635100/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=7748980675773635100' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7748980675773635100'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7748980675773635100'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/11/random-password-generator.html' title='Random password generator'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-4986062874700212157</id><published>2008-11-08T21:01:00.004+01:00</published><updated>2009-03-13T20:52:13.362+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='messaging server'/><category scheme='http://www.blogger.com/atom/ns#' term='comms'/><category scheme='http://www.blogger.com/atom/ns#' term='oneliners'/><category scheme='http://www.blogger.com/atom/ns#' term='sed'/><title type='text'>On which partition?</title><content type='html'>Last time I wrote the script for Messaging Server backups I faced the problem with proper partition selection. It's easy to achieve with a &lt;em&gt;mboxutil&lt;/em&gt; utility... but I only need the names of the account and a corresponding partition. &lt;br /&gt;&lt;br /&gt;Up to today I've used the solution with sed &amp; awk. But I hate using many tools where the swiss army knife is available.&lt;br /&gt;So...&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# mboxutil -l -x| sed 's/.*user\/\(.*\)\/INBOX.*partition\/\(.*\)\/\=user\/.*/\1 \2/p;d'&lt;br /&gt;admin primary&lt;br /&gt;marcin.wisnios@somedomain.com secondary&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-4986062874700212157?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/4986062874700212157/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=4986062874700212157' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4986062874700212157'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4986062874700212157'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/11/on-which-partition.html' title='On which partition?'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-3488063926670793090</id><published>2008-09-25T22:56:00.008+02:00</published><updated>2008-10-26T20:15:16.477+01:00</updated><title type='text'>disable solaris services</title><content type='html'>Solaris installation comes with wide range of exposed net services. You could reduce it by using &lt;em&gt;netservices limited&lt;/em&gt; command or by applying Generic Limited Networking profile of services.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# cd /var/svc/profile &lt;br /&gt;# mv generic.xml _generic.xml&lt;br /&gt;# ln -s generic_limited_net.xml generic.xml &lt;br /&gt;# svccfg apply /var/svc/profile/generic_limited_net.xml &lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;Unfortunately there are still some of them left, ex. webconsole, rpc/bind.&lt;br /&gt;I like plain environment, with only ssh service exposed. It could be simply done with this litte piece of code:&lt;br /&gt;&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;#!/bin/bash&lt;br /&gt;&lt;br /&gt;SERVICES='autofs cde fc-cache ktkt_warn management ogl-select print rpc sendmail stfsloader stosreg webconsole'&lt;br /&gt;&lt;br /&gt;netservices limited &lt;br /&gt;&lt;br /&gt;for S in $SERVICES; do&lt;br /&gt;        for SVC in `svcs |sed "/$S/!d;s/.*\ svc/svc/"`; do&lt;br /&gt;                svcadm disable $SVC&lt;br /&gt;        done&lt;br /&gt;done&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-3488063926670793090?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/3488063926670793090/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=3488063926670793090' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/3488063926670793090'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/3488063926670793090'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/09/disable-solaris-services.html' title='disable solaris services'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-8556538302580511040</id><published>2008-09-24T10:25:00.002+02:00</published><updated>2008-09-24T10:29:02.362+02:00</updated><title type='text'>Sun Web Server autostart</title><content type='html'>To disable - modify &lt;em&gt;/etc/init.d/webserver7-4cfd5aeb&lt;/em&gt;.&lt;br /&gt;&lt;br /&gt;-WS_START_ONBOOT=1 &lt;br /&gt;+WS_START_ONBOOT=0&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-8556538302580511040?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/8556538302580511040/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=8556538302580511040' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8556538302580511040'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8556538302580511040'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/09/sun-web-server-autostart.html' title='Sun Web Server autostart'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-873753347491734367</id><published>2008-09-15T10:12:00.003+02:00</published><updated>2008-09-15T10:25:47.409+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='disk'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>primary label corrupt</title><content type='html'>During the ZFS testing process I've used dd command to erase the disk fragment with /dev/urandom (testing the ability of raidz crash handling). After resilvering there was still information on my console and dmesg log:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;Sep 15 07:42:00 thumper scsi: [ID 107833 kern.warning] WARNING: /pci@0,0/pci1022,7458@1/pci11ab,11ab@1/disk@0,0 (sd2):&lt;br /&gt;Sep 15 07:42:00 thumper         primary label corrupt; using backup&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;I've resolved this with a &lt;em&gt;format&lt;/em&gt; command.&lt;br /&gt;It could be done in the following way.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;thumper [/]# format&lt;br /&gt;Searching for disks...done&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;AVAILABLE DISK SELECTIONS:&lt;br /&gt;       0. c0t0d0 &lt;ATA-SEAGATE ST32500N-3AZQ-232.88GB&gt;&lt;br /&gt;          /pci@0,0/pci1022,7458@1/pci11ab,11ab@1/disk@0,0&lt;br /&gt;[...]&lt;br /&gt;&lt;br /&gt;Specify disk (enter its number): 0&lt;br /&gt;selecting c0t0d0&lt;br /&gt;[disk formatted]&lt;br /&gt;Reading the primary EFI GPT label failed.  Using backup label.&lt;br /&gt;Use the 'backup' command to restore the primary label.&lt;br /&gt;&lt;br /&gt;format&gt; backup&lt;br /&gt;Restoring primary label.&lt;br /&gt;format&gt; label&lt;br /&gt;Ready to label disk, continue? y&lt;br /&gt;&lt;br /&gt;format&gt; quit&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-873753347491734367?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/873753347491734367/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=873753347491734367' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/873753347491734367'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/873753347491734367'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/09/primary-label-corrupt.html' title='primary label corrupt'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-6462531704317064331</id><published>2008-07-04T15:05:00.005+02:00</published><updated>2008-07-04T15:10:22.236+02:00</updated><title type='text'>init_htent: error parsing IP address for host</title><content type='html'>&lt;code&gt;&lt;br /&gt;# imsimta run tcp_intranet&lt;br /&gt;init_htent: error parsing IP address for host #1&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;You have to check your &lt;em&gt;/etc/inet/hosts&lt;/em&gt; entries.&lt;br /&gt;At the first line (#1), ignoring the comment lines, there was IPv6 entry for localhost.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;::1     localhost&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;After removal the problem has gone.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-6462531704317064331?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/6462531704317064331/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=6462531704317064331' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6462531704317064331'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6462531704317064331'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/07/inithtent-error-parsing-ip-address-for.html' title='init_htent: error parsing IP address for host'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-7609580920050395391</id><published>2008-06-30T09:27:00.005+02:00</published><updated>2008-06-30T09:44:02.340+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oneliners'/><category scheme='http://www.blogger.com/atom/ns#' term='sed'/><title type='text'>oneliner</title><content type='html'>I use sed delete negation to remove lines that do not match the pattern.&lt;br /&gt;In the following example I want to delete the improper ssh-key entries from an &lt;em&gt;authorized_keys&lt;/em&gt; file.&lt;br /&gt;Ex.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;sed -e '/^environment.*USER.*/!d' .ssh/authorized_keys&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;I do not allow usage of ssh session without set &lt;em&gt;USER&lt;/em&gt; environment variable.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-7609580920050395391?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/7609580920050395391/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=7609580920050395391' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7609580920050395391'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7609580920050395391'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/06/oneliner.html' title='oneliner'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-6507312072378407053</id><published>2008-06-27T14:38:00.002+02:00</published><updated>2008-06-27T14:50:12.010+02:00</updated><title type='text'>Registering Solaris System from the command line</title><content type='html'>&lt;code&gt;&lt;br /&gt;bladerunner [/usr/lib/breg/data]# cp RegistrationProfile.properties /tmp/&lt;br /&gt;bladerunner [/usr/lib/breg/data]# cd /tmp&lt;br /&gt;bladerunner [/tmp]# vim RegistrationProfile.properties &lt;br /&gt;[...]&lt;br /&gt;#&lt;br /&gt;# Sun Online account information.  A new account can be created by visiting&lt;br /&gt;# http://updates.sun.com&lt;br /&gt;#&lt;br /&gt;userName=wisnios&lt;br /&gt;password=MySunOnlinePassword&lt;br /&gt;&lt;br /&gt;#&lt;br /&gt;# Name (label) of this machine as you would like it to appear on the Sun Connection&lt;br /&gt;# portal.  If left blank hostname will be used&lt;br /&gt;#&lt;br /&gt;hostName=bladerunner&lt;br /&gt;&lt;br /&gt;[...]&lt;br /&gt;:wq&lt;br /&gt;&lt;br /&gt;bladerunner [/tmp]# /usr/sbin/sconadm register -a -r /tmp/RegistrationProfile.properties &lt;br /&gt;sconadm is running&lt;br /&gt;Authenticating user ...&lt;br /&gt;finish registration!&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-6507312072378407053?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/6507312072378407053/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=6507312072378407053' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6507312072378407053'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6507312072378407053'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/06/registering-solaris-system-from-command.html' title='Registering Solaris System from the command line'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-6848640803806821715</id><published>2008-06-26T14:24:00.003+02:00</published><updated>2008-06-26T15:02:27.140+02:00</updated><title type='text'>How to determine the Sun Java System Directory Server version</title><content type='html'>Ex.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# /opt/SUNWdsee/ds6/lib/ns-slapd -v&lt;br /&gt;Sun Microsystems, Inc.&lt;br /&gt;Sun-Java(tm)-System-Directory/6.0 B2007.025.1834 32-bit&lt;br /&gt;[...]&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;ver. 6.0&lt;br /&gt;&lt;br /&gt;It could also be accomplished by:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# dsadm --version&lt;br /&gt;[dsadm]&lt;br /&gt;dsadm               : 6.0                  B2007.025.1834&lt;br /&gt;&lt;br /&gt;[slapd 32-bit]&lt;br /&gt;Sun Microsystems, Inc.&lt;br /&gt;Sun-Java(tm)-System-Directory/6.0 B2007.025.1834 32-bit&lt;br /&gt;ns-slapd            : 6.0                  B2007.025.1834&lt;br /&gt;Slapd Library       : 6.0                  B2007.025.1834&lt;br /&gt;Front-End Library   : 6.0                  B2007.025.1834&lt;br /&gt;&lt;br /&gt;[slapd 64-bit]&lt;br /&gt;Sun Microsystems, Inc.&lt;br /&gt;Sun-Java(tm)-System-Directory/6.0 B2007.025.1834 64-bit&lt;br /&gt;ns-slapd            : 6.0                  B2007.025.1834&lt;br /&gt;Slapd Library       : 6.0                  B2007.025.1834&lt;br /&gt;Front-End Library   : 6.0                  B2007.025.1834&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-6848640803806821715?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/6848640803806821715/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=6848640803806821715' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6848640803806821715'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/6848640803806821715'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/06/how-to-determine-sun-java-system.html' title='How to determine the Sun Java System Directory Server version'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-2638723041711614208</id><published>2008-05-22T21:52:00.005+02:00</published><updated>2008-05-22T22:12:27.506+02:00</updated><title type='text'>Call to undefined function pg_connect()</title><content type='html'>When using &lt;a href="http://cooltools.sunsource.net/coolstack/"&gt;coolstack&lt;/a&gt; and trying to connect to postgresql database from php script the following error appear:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;Call to undefined function pg_connect() in somescript.php on line XX&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;The reason is default php configuration; &lt;em&gt;php.ini&lt;/em&gt; doesn't know anything about postgresql extension, only mysql (finally, it's Solaris AMP - Apache MySQL PHP). To resolve the undesirable behaviour add:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;extension="pgsql.so"&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;to &lt;em&gt;php.ini&lt;/em&gt; configuration.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Cool Stack 1.2&lt;br /&gt;Default file location:&lt;br /&gt;&lt;em&gt;/opt/coolstack/php5/lib/php.ini&lt;br /&gt;/opt/coolstack/php5/lib/php/extensions/no-debug-non-zts-20060613/pgsql.so&lt;/em&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-2638723041711614208?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/2638723041711614208/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=2638723041711614208' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2638723041711614208'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2638723041711614208'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/05/call-to-undefined-function-pgconnect.html' title='Call to undefined function pg_connect()'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-7860702168544131085</id><published>2008-05-04T19:49:00.002+02:00</published><updated>2008-05-04T20:08:19.127+02:00</updated><title type='text'>ZFS dataset inside a non-global zone</title><content type='html'>To achieve the usage of global ZFS dataset inside a non-global zone you have to set the &lt;em&gt;zoned&lt;/em&gt; attribute to &lt;em&gt;on&lt;/em&gt;. It could be done during the dataset creation (&lt;em&gt;zfs create -o zoned=on DATASET&lt;/em&gt;) or after the creation process:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;zfs set zoned=on DATASET&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;Without this option the zone startup process will fail, ex.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;sunflower [/]# zoneadm -z samba boot&lt;br /&gt;zoneadm: zone 'samba': These file-systems are mounted on subdirectories of /export/zones/samba/root:&lt;br /&gt;zoneadm: zone 'samba':   /export/zones/samba/root/export/vol1&lt;br /&gt;zoneadm: zone 'samba': call to zoneadmd failed&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-7860702168544131085?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/7860702168544131085/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=7860702168544131085' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7860702168544131085'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7860702168544131085'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/05/zfs-dataset-inside-non-global-zone.html' title='ZFS dataset inside a non-global zone'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-5523912275884065092</id><published>2008-04-20T22:14:00.002+02:00</published><updated>2008-04-20T22:33:19.795+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='login'/><category scheme='http://www.blogger.com/atom/ns#' term='cde'/><category scheme='http://www.blogger.com/atom/ns#' term='disable'/><category scheme='http://www.blogger.com/atom/ns#' term='gui'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>Disable Solaris GUI</title><content type='html'>It could be done by using one of the two methods. &lt;br /&gt;The first one does its job immediate.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# svcadm disable cde-login&lt;br /&gt;&lt;/code&gt; &lt;br /&gt;(You could also use the full FMRI, svc:/application/graphical-login/cde-login:default) &lt;br /&gt;&lt;br /&gt;The second one takes place during the next startup.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# /usr/dt/bin/dtconfig -d&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;(Use &lt;em&gt;-e&lt;/em&gt; switch to enable auto-start)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-5523912275884065092?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/5523912275884065092/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=5523912275884065092' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5523912275884065092'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/5523912275884065092'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/04/disable-solaris-gui.html' title='Disable Solaris GUI'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-796134405228861302</id><published>2008-04-13T16:17:00.006+02:00</published><updated>2008-04-20T22:34:21.903+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='network'/><category scheme='http://www.blogger.com/atom/ns#' term='macbook pro'/><category scheme='http://www.blogger.com/atom/ns#' term='opensolaris'/><category scheme='http://www.blogger.com/atom/ns#' term='driver'/><title type='text'>OpenSolaris on MacBook Pro</title><content type='html'>The purpose of this post is not to give the recipe for an overall installation.&lt;br /&gt;I've written down a few notes about the network configuration.&lt;br /&gt;&lt;br /&gt;I've used the Parallels virtualization and OpenSolaris b79b. Parallels emulates the Realtek 8029(AS) network card but there's no support inside the OS.&lt;br /&gt;To complete this task perform the following steps:&lt;br /&gt;&lt;br /&gt;1. Mount vmtools.iso as CD/DVD-ROM (/Library/Parallels/Tools/vmtools.iso)&lt;br /&gt;2. Turn off the eeprom DMA property (atapi-cd-dma-enabled) - before the boot process edit the grub menu list (press 'e') and add the following to the kernel line:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;grub edit&gt; kernel$ /platform/i86pc/kernel/$ISADIR/unix &lt;b&gt;-B atapi-cd-dma-enabled=0&lt;/b&gt;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Boot with a 'b' key.&lt;br /&gt;3. Install the requested driver:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# cd /cdrom/prltools/Drivers/Network/RTL8029/SOLARIS&lt;br /&gt;# ./network.sh&lt;br /&gt;[...]&lt;br /&gt;Will you receive IP address from DHCP server (Y/N)&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;If you've chosen the answer 'N', enter the requested values:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;Enter IP address of the virtual machine:&lt;br /&gt;Enter network address:&lt;br /&gt;Enter network mask:&lt;br /&gt;Enter default gateway IP address:&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;The script will modify the following files:&lt;br /&gt;/etc/inet/hosts&lt;br /&gt;/etc/hostname.ni0&lt;br /&gt;/etc/netmasks&lt;br /&gt;/etc/defaultrouter&lt;br /&gt;or&lt;br /&gt;/etc/dhcp.ni0&lt;br /&gt;/etc/hostname.ni0&lt;br /&gt;(if the 'Y' have been chosen)&lt;br /&gt;&lt;br /&gt;Now, reboot the system.&lt;br /&gt;&lt;br /&gt;During the boot process you could see the information:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;WARNING: ni0: niattach: SA_eeprom is funny, assuming byte-mode&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;but everything should be just fine.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-796134405228861302?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/796134405228861302/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=796134405228861302' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/796134405228861302'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/796134405228861302'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2008/04/opensolaris-on-macbook-pro.html' title='OpenSolaris on MacBook Pro'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-7009510277966414147</id><published>2007-09-17T11:54:00.000+02:00</published><updated>2008-01-30T18:48:21.933+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oneliners'/><category scheme='http://www.blogger.com/atom/ns#' term='sed'/><title type='text'>oneliner</title><content type='html'>Task: Remove user1, user2 and user3 ssh keys from multiple machines for both home users and root account,&lt;br /&gt;for ssh protocol 1 as well as protocol 2 files.&lt;br /&gt;&lt;br /&gt;To accomplish this task I've used sed and &lt;a href="http://www.netfort.gr.jp/~dancer/software/dsh.html.en"&gt;DSH&lt;/a&gt; (Dancer's Shell / Distributed Shell) on Debian GNU/Linux.&lt;br /&gt;&lt;br /&gt;I've defined the &lt;em&gt;redpool&lt;/em&gt; host group:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# cat /etc/dsh/group/redpool&lt;br /&gt;root@red1&lt;br /&gt;root@red2&lt;br /&gt;[...]&lt;br /&gt;root@red99&lt;br /&gt;root@red100&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;and I've done:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;dsh -g redpool "sed -i '/^.*user1\|user2\|user3.*$/d' /{root,home/*}/.ssh/authorized_keys*"&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;But... you could sue me: "You're guilty of using multiple commands to perform your job."&lt;br /&gt;So, let's ride:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;for i in {1..100}; do ssh root@red$i "sed -i '/^.*user1\|user2\|user3.*$/d' /{root,home/*}/.ssh/authorized_keys*"; done&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;Above option is only usable with hostnames / addresses counted sequentially.&lt;br /&gt;In case of various name schemes it's easier to use the dsh command.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-7009510277966414147?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/7009510277966414147/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=7009510277966414147' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7009510277966414147'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7009510277966414147'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2007/09/onliner.html' title='oneliner'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-4621372072656287058</id><published>2007-08-13T20:52:00.000+02:00</published><updated>2007-08-24T09:56:57.090+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='opensolaris'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>Solaris hostname</title><content type='html'>Setting the hostname - one of the most basic installation procedure. Unlike other operating systems a few places to visit. A few places to forget at least one of them.&lt;br /&gt;&lt;br /&gt;Ex. setting the &lt;span style="font-style:italic;"&gt;sunshine&lt;/span&gt; hostname on the machine with a &lt;span style="font-style:italic;"&gt;bge0&lt;/span&gt; interface and IP address &lt;span style="font-style:italic;"&gt;10.0.0.1&lt;/span&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# echo -e "10.0.0.1\tsunshine" &gt;&gt; /etc/inet/hosts&lt;br /&gt;# echo "sunshine" &gt; /etc/hostname.bge0&lt;br /&gt;# echo "sunshine" &gt; /etc/nodename&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;There's one more file with the hostname and IP address information - &lt;span style="font-style:italic;"&gt;/etc/inet/ipnodes&lt;/span&gt;. In Solaris 11 it's a symlink to /etc/inet/hosts file. So, you could leave it alone.&lt;br /&gt;&lt;br /&gt;The change of the running system's name is as simple as:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;# hostname sunshine&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-4621372072656287058?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/4621372072656287058/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=4621372072656287058' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4621372072656287058'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/4621372072656287058'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2007/08/solaris-hostname.html' title='Solaris hostname'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-2349073460807132498</id><published>2007-08-03T16:08:00.000+02:00</published><updated>2007-08-03T16:13:18.026+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oneliners'/><category scheme='http://www.blogger.com/atom/ns#' term='sed'/><title type='text'>oneliner</title><content type='html'>Remove asterisks only from the lines beginning with a specified TAG:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;sed '/^TAG.*/!p; s/\*//g; n'&lt;br /&gt;&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-2349073460807132498?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/2349073460807132498/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=2349073460807132498' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2349073460807132498'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/2349073460807132498'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2007/08/oneliner.html' title='oneliner'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-134536041703512877</id><published>2007-08-03T00:02:00.000+02:00</published><updated>2007-08-03T00:03:08.598+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='zfs'/><category scheme='http://www.blogger.com/atom/ns#' term='mirror'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><title type='text'>turn into mirror</title><content type='html'>In below example i've used single volume zfs pool to convert it into mirror zpool.&lt;br /&gt;To show the possibilities of zfs in more extensive way it's based on file volumes instead of drives.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# mkfile -nv 1g mud&lt;br /&gt;mud 1073741824 bytes&lt;br /&gt;# zpool create pond /export/mud&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;I've created the &lt;em&gt;pond&lt;/em&gt; pool based on a &lt;em&gt;mud&lt;/em&gt; file.&lt;br /&gt;Now, using the &lt;em&gt;attach&lt;/em&gt; method of &lt;em&gt;zpool&lt;/em&gt; command, I'll turn it into mirror with &lt;em&gt;water&lt;/em&gt; (second file volume).&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;# mkfile -nv 1g water&lt;br /&gt;water 1073741824 bytes&lt;br /&gt;# zpool attach pond /export/mud /export/water&lt;br /&gt;# zpool status pond&lt;br /&gt;  pool: pond&lt;br /&gt; state: ONLINE&lt;br /&gt; scrub: resilver completed with 0 errors on Wed Apr 11 09:43:22 2007&lt;br /&gt;config:&lt;br /&gt;&lt;br /&gt;        NAME               STATE     READ WRITE CKSUM&lt;br /&gt;        pond               ONLINE       0     0     0&lt;br /&gt;          mirror           ONLINE       0     0     0&lt;br /&gt;            /export/mud    ONLINE       0     0     0&lt;br /&gt;            /export/water  ONLINE       0     0     0&lt;br /&gt;&lt;br /&gt;errors: No known data errors&lt;br /&gt;&lt;/pre&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-134536041703512877?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/134536041703512877/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=134536041703512877' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/134536041703512877'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/134536041703512877'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2007/08/turn-into-mirror.html' title='turn into mirror'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-8817374523356640006</id><published>2007-08-02T23:58:00.000+02:00</published><updated>2007-08-03T00:01:51.340+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='zfs'/><category scheme='http://www.blogger.com/atom/ns#' term='solaris'/><category scheme='http://www.blogger.com/atom/ns#' term='snapshot'/><title type='text'>quick snapshot tour</title><content type='html'>To take a snapshot of zfs pool &lt;em&gt;pool/aqua&lt;/em&gt; you have to run an example command:&lt;br /&gt;&lt;code&gt;# zfs snapshot pool/aqua@cold&lt;/code&gt;&lt;br /&gt;where the &lt;em&gt;cold&lt;/em&gt; is the name of a newly created shot.&lt;br /&gt;&lt;br /&gt;You could find it in (pool/aqua/) &lt;em&gt;.zfs/snapshot&lt;/em&gt; directory. By default it's hidden.&lt;br /&gt;You can change this behaviour by setting &lt;em&gt;snapdir&lt;/em&gt; variable on pool/aqua to &lt;em&gt;visible&lt;/em&gt;:&lt;br /&gt;&lt;code&gt;# zfs set snapdir=visible pool/aqua&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;To take advantage of snapshots in another way, use it to quickly reproduce the filesystems with &lt;em&gt;clone&lt;/em&gt; method.&lt;br /&gt;The clone is functional fs instead of snapshot which cannot be modified (ro mode).&lt;br /&gt;&lt;code&gt;# zfs clone pool/aqua@cold pool/ice&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;It's a good habit to name the snapshop in a way enabling you to remember the creation time.&lt;br /&gt;In a case of memory leak do the following:&lt;br /&gt;&lt;code&gt;# zfs get creation pool/aqua@cold&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;To destroy snapshot simply run:&lt;br /&gt;&lt;code&gt;# zfs destroy pool/aqua@cold&lt;/code&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-8817374523356640006?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/8817374523356640006/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=8817374523356640006' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8817374523356640006'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/8817374523356640006'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2007/08/quick-snapshot-tour.html' title='quick snapshot tour'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-6302270466598962946.post-7478854035238813187</id><published>2007-08-02T09:56:00.000+02:00</published><updated>2007-08-03T09:27:30.261+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='opensolaris'/><category scheme='http://www.blogger.com/atom/ns#' term='vmware'/><title type='text'>VMware command line handling</title><content type='html'>No more 'VMware Server Console' to power on the virtual system. Sometimes I need only to turn it on from command line over the ssh session. Now, I know how.&lt;br /&gt;&lt;br /&gt;Ex. starting Solaris Express 'Nevada' system.&lt;br /&gt;&lt;code&gt;&lt;br /&gt;$ vmware-cmd /var/lib/vmware-server/Virtual\ Machines/sol-nv-b69/sol-nv-b69.vmx start&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;To get state simply run:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;$ vmware-cmd /var/lib/vmware-server/Virtual\ Machines/sol-nv-b69/sol-nv-b69.vmx getstate&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;When I've installed the first Solaris system under VMware I choosed wrong architecture of guest OS. The process of making correct entry is as simple as:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;$ cd /var/lib/vmware-server/Virtual\ Machines/sol-nv-b69/&lt;br /&gt;$ sed -i'' -e 's/solaris10/solaris10-64' sol-nv-b69.vmx&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;Remember to change this value while the virtual is down. After changing it's state to up the 32-bit architecture will be replaced by 64-bit.&lt;br /&gt;&lt;br /&gt;Sadly, it's generating the error message (VMware Server 1.0.3 build-44356) and user action is required. You can still pass over the graphical frontend using the &lt;em&gt;answer&lt;/em&gt; subcommand.&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;$ vmware-cmd /var/lib/vmware-server/Virtual\ Machines/sol-nv-b69/sol-nv-b69.vmx start   &lt;br /&gt;VMControl error -16: Virtual machine requires user input to continue&lt;br /&gt;$ vmware-cmd /var/lib/vmware-server/Virtual\ Machines/sol-nv-b69/sol-nv-b69.vmx answer&lt;br /&gt;&lt;br /&gt;Question (id = 49294347) :The vlance NIC is not supported for 64-bit guests in this release.&lt;br /&gt;Please consult the documentation for the appropriate type of NIC to use with 64-bit guests.&lt;br /&gt;Failed to configure ethernet0.&lt;br /&gt;&lt;br /&gt;        0) OK&lt;br /&gt;Select choice. Press enter for default &lt;0&gt; :&lt;br /&gt;$ vmware-cmd /var/lib/vmware-server/Virtual\ Machines/sol-nv-b69/sol-nv-b69.vmx getstate&lt;br /&gt;getstate() = off&lt;br /&gt;$ sed -i'' -e 's/solaris10-64/solaris10/' /var/lib/vmware-server/Virtual\ Machines/sol-nv-b69/sol-nv-b69.vmx&lt;br /&gt;$ vmware-cmd /var/lib/vmware-server/Virtual\ Machines/sol-nv-b69/sol-nv-b69.vmx start&lt;br /&gt;start() = 1&lt;br /&gt;$ vmware-cmd /var/lib/vmware-server/Virtual\ Machines/sol-nv-b69/sol-nv-b69.vmx getstate&lt;br /&gt;getstate() = on&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;I couldn't leave it as it was resolved. A few minutes later the solution has been found - &lt;a href="http://www.vmware.com/community/message.jspa?messageID=430087"&gt;the Source&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;You are at the crossroad. &lt;br /&gt;You can force the usage of older adapters by setting .vmx configuration options:&lt;br /&gt;&lt;pre&gt;&lt;br /&gt;ethernet0.allow64bitVlance = "TRUE"&lt;br /&gt;ethernet0.allow64bitVmxnet = "TRUE"&lt;br /&gt;&lt;/pre&gt;&lt;br /&gt;...or take a step into the future. I've choosed that one. To take advantages of 64-bit guest os you have to change the network adapter driver from &lt;em&gt;vlance&lt;/em&gt; to &lt;em&gt;e1000&lt;/em&gt;. It could be achieved by enforcing the usage of correct driver.&lt;br /&gt; &lt;br /&gt;Ex. from my sol-nv-b69.vmx file.:&lt;br /&gt;&lt;pre&gt;ethernet0.virtualDev = "e1000"&lt;/pre&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight:bold;"&gt;Hint:&lt;/span&gt;&lt;br /&gt;Remember to update your Solaris network configuration:&lt;br /&gt;&lt;br /&gt;* plumb a new interface&lt;br /&gt;&lt;code&gt;$ ifconfig e1000g0 plumb&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;* add &lt;em&gt;/etc/hostname.e1000g0&lt;/em&gt; file&lt;br /&gt;&lt;br /&gt;* replace the file &lt;em&gt;/etc/dhcp.pcn0&lt;/em&gt; with a new one - &lt;em&gt;/etc/dhcp.e1000g0&lt;/em&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/6302270466598962946-7478854035238813187?l=unixwear.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://unixwear.blogspot.com/feeds/7478854035238813187/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=6302270466598962946&amp;postID=7478854035238813187' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7478854035238813187'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/6302270466598962946/posts/default/7478854035238813187'/><link rel='alternate' type='text/html' href='http://unixwear.blogspot.com/2007/08/vmware-comman-line-handling.html' title='VMware command line handling'/><author><name>Marcin Wiśnios</name><uri>http://www.blogger.com/profile/04040800455610004174</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='21' src='http://2.bp.blogspot.com/_D5SVazG3Wvc/SvnWM5_ngYI/AAAAAAAACXA/nr0iCLUDgO8/s1600-R/3281495153_3e1fc8484b_m.jpg'/></author><thr:total>0</thr:total></entry></feed>
