Dec 23, 2010

Released VirtualBox 4.0.0 installed on OpenIndiana Build 148

The Version 4.0.0 of VirtualBox is released as a Christmas present.

After downloading, the installation was fine and the installed Windows XP is
up and running in Seamless mode.

Additional to the package, there is a extension pack available now.

See here for a documentation. The extension pack provided by Oracle contains
support for some additional hardware - see the link above.

Dec 18, 2010

Upgraded from OpenIndiana 147 to OpenIndiana 148

Today I upgraded from OpenIndiana 147 to OpenIndiana 148 without any
problems.

root@solewer:~# pkg image-update --be-name OI_148                              
                Packages to remove:    10
               Packages to install:    11
                Packages to update:  1095
           Create boot environment:   Yes
DOWNLOAD                                  PKGS       FILES    XFER (MB)
Completed                              1116/1116 22673/22673  780.6/780.6

PHASE                                        ACTIONS
Removal Phase                              6579/6579
Install Phase                              5186/5186
Update Phase                             36358/36358

PHASE                                          ITEMS
Package State Update Phase                 2211/2211
Package Cache Update Phase                 1105/1105
Image State Update Phase                         2/2

A clone of OI_147 exists and has been updated and activated.
On the next boot the Boot Environment OI_148 will be mounted on '/'.
Reboot when ready to switch to this updated BE.



[ewer@solewer:~]$uname -a
SunOS solewer 5.11 oi_148 i86pc i386 i86pc Solaris

The restart imported 4 new SMF-Services and delete the javadb-Service because of a missing manifest.

The suspend/resume still doesn't work.


nvidia seems to work on this laptop

nVidia Corporation G96M [Quadro FX 770M]

Dec 14, 2010

working with Mercurial behind a proxy

Mercurial can use the http protocol for version management, but when you
are behind a proxy, you can simple set the configuration in your hgrc file
or give the configuration in the command line like this:

hg --config http_proxy.host=#IP#:#PORT# pull

Dec 2, 2010

VirtualBox 3.2.12 is installable on OpenIndiana 147 without any modification

Today, I installed the VirtualBox 3.2.12. I remembered to have to
patch a file in the package to allow the installation on OpenIndiana.
So I transfered the stream package with pkgtrans and looked into the file,
but there are already changes in the package to recognize the OpenIndiana
distribution. So there is no change necessary anymore.

See here for the discussion at openIndiana.

Nov 26, 2010

SFTP withing jedit doesn't work to login in to SLES10 x 64

I've a SLES10 x64, to which I'd like to connect with the SFTP Plugin in
jEdit to view remote files.

But the login fails with the following trace:
10:18:56 [jEdit I/O #2] [message] SftpLogger: Connection established                                                                                           
10:18:56 [jEdit I/O #2] [message] SftpLogger: Remote version string: SSH-1.99-OpenSSH_4.2
10:18:56 [jEdit I/O #2] [message] SftpLogger: Local version string: SSH-2.0-JSCH-0.1.42
10:18:56 [jEdit I/O #2] [message] SftpLogger: CheckCiphers: aes256-ctr,aes192-ctr,aes128-ctr,aes256-cbc,aes192-cbc,aes128-cbc,3des-ctr,arcfour,arcfour128,arcfour256
10:18:56 [jEdit I/O #2] [message] SftpLogger: aes256-ctr is not available.             
10:18:56 [jEdit I/O #2] [message] SftpLogger: aes192-ctr is not available.             
10:18:56 [jEdit I/O #2] [message] SftpLogger: aes256-cbc is not available.             
10:18:56 [jEdit I/O #2] [message] SftpLogger: aes192-cbc is not available.             
10:18:56 [jEdit I/O #2] [message] SftpLogger: arcfour256 is not available.             
10:18:56 [jEdit I/O #2] [message] SftpLogger: SSH_MSG_KEXINIT sent                     
10:18:56 [jEdit I/O #2] [message] SftpLogger: SSH_MSG_KEXINIT received                 
10:18:56 [jEdit I/O #2] [message] SftpLogger: kex: server->client aes128-ctr hmac-md5 none
10:18:56 [jEdit I/O #2] [message] SftpLogger: kex: client->server aes128-ctr hmac-md5 none
10:18:56 [jEdit I/O #2] [message] SftpLogger: SSH_MSG_KEXDH_INIT sent                  
10:18:56 [jEdit I/O #2] [message] SftpLogger: expecting SSH_MSG_KEXDH_REPLY            
10:18:56 [jEdit I/O #2] [message] SftpLogger: ssh_rsa_verify: signature true           
10:18:56 [jEdit I/O #2] [message] SftpLogger: Host 'xxxxxxx' is known and mathces the RSA host key
10:18:56 [jEdit I/O #2] [message] SftpLogger: SSH_MSG_NEWKEYS sent                     
10:18:56 [jEdit I/O #2] [message] SftpLogger: SSH_MSG_NEWKEYS received                 
10:18:56 [jEdit I/O #2] [message] SftpLogger: SSH_MSG_SERVICE_REQUEST sent             
10:18:56 [jEdit I/O #2] [message] SftpLogger: SSH_MSG_SERVICE_ACCEPT received          
10:18:56 [jEdit I/O #2] [message] SftpLogger: Authentications that can continue: publickey,keyboard-interactive,password
10:18:56 [jEdit I/O #2] [message] SftpLogger: Next authentication method: publickey    
10:18:56 [jEdit I/O #2] [message] SftpLogger: Authentications that can continue: keyboard-interactive,password
10:18:56 [jEdit I/O #2] [message] SftpLogger: Next authentication method: keyboard-interactive    
10:18:56 [jEdit I/O #2] [message] SftpLogger: Disconnecting from sles10x64 port 22     
10:18:56 [jEdit I/O #2] [error] BrowserIORequest: java.io.IOException: com.jcraft.jsch.JSchException: Auth fail
10:18:56 [jEdit I/O #2] [error] BrowserIORequest:  at ftp.SFtpConnection.(SFtpConnection.java:105)    
10:18:56 [jEdit I/O #2] [error] BrowserIORequest:  at ftp.ConnectionManager.getConnection(ConnectionManager.java:320)
10:18:56 [jEdit I/O #2] [error] BrowserIORequest:  at ftp.FtpVFS.getConnection(FtpVFS.java:451)   
10:18:56 [jEdit I/O #2] [error] BrowserIORequest:  at ftp.FtpVFS._listFiles(FtpVFS.java:218)  
10:18:56 [jEdit I/O #2] [error] BrowserIORequest:  at org.gjt.sp.jedit.browser.BrowserIORequest.listDirectory(BrowserIORequest.java:159)
10:18:56 [jEdit I/O #2] [error] BrowserIORequest:  at org.gjt.sp.jedit.browser.BrowserIORequest.run(BrowserIORequest.java:90)         
10:18:56 [jEdit I/O #2] [error] BrowserIORequest:  at org.gjt.sp.util.WorkThread.doRequest(WorkThread.java:213)    
10:18:56 [jEdit I/O #2] [error] BrowserIORequest:  at org.gjt.sp.util.WorkThread.doRequests(WorkThread.java:180)
10:18:56 [jEdit I/O #2] [error] BrowserIORequest:  at org.gjt.sp.util.WorkThread.run(WorkThread.java:154)   
10:18:56 [jEdit I/O #2] [error] ErrorListDialog$ErrorEntry: sftp://vswfl@sles10x64:22/:
10:18:56 [jEdit I/O #2] [error] ErrorListDialog$ErrorEntry: Cannot list directory: java.io.IOException: com.jcraft.jsch.JSchException: Auth fail

The solution was to modify the sshd_config in /etc/ssh on the sles10 server:
and replaced:
PasswordAuthentication no 
with
PasswordAuthentication yes

 After this change the SFTP-login and file system browsing in jEdit worked.

Nov 20, 2010

Netbeans 7.0 beta is read for download

Netbeans 7.0beta is ready for download.


I installed on OpenIndiana with jdk 6U22.

The plugin repository contain the python packages.
The installation took very long on my system for the jython core package.

Oct 28, 2010

Using lookbehind Regular Expression for searching in jEdit

Im searching for a string in a logfile, but the string shouldn't be preceded by
two other strings:

($<!(word1|word2)\|)search

The search string is search, which should not preceded
by word1 or word2 followed by a pipe and than the search string.
When there are special characters in the strings, they have to be
escaped.

Oct 19, 2010

Installed NetBeans 7.0 Milestone 2 on OpenIndiana Build 147

I've installed NetBeans 7.0 Milestone 2 on my OpenIndiana Installation Build 147 without problems.

The Python-Module is available from the repository.

PMD, FindBugs, CheckStyle from https://sqe.dev.java.net/ can not be
installed, because it requires maven > 1.0, and 7.0 Milestone 2 installs
maven 2.0, something with the check is wrong.

Oct 15, 2010

Sending datablock in Python with > 65536 bytes fails

In a Simulation Script, I used the ThreadingTCPServer from SocketServer.

The simulation data which should be sent back is larger than 65536 bytes,
but the other side just hang around and doesn't receive everything.

Both parts are executed on the same machine with Solaris 10.

To get all the data over the network, I'm now using a loop sending just
blocks of 10000 bytes and sleeping between with time.sleep( 0.3 ) some time.

I think, the network buffer of the OS isn't large enough to hold the full data
and therefore drops some of it, causing the missing parts on the receiver side.

Oct 11, 2010

Resolving merge conflicts in mercurial

In case of a merge conflict, mercurial gives some hint about it.
You can view the state with the command:

hg resolve -l
If you've resolved a conflict, you have to tell mercurial about this fact:

hg resolve -m file/which/is/resovled

Mercurial has an option to work with multiple patch queues

Today I encountered the command qqueue in Mercurial.
I haven't found a useful documentation about qqueue except here.

The command allows you to have mutlipel patch queues in a repository,
between which you can switch.

So having a set of patches in one queue and another set of patches in
a different queue.

Sep 28, 2010

Debugging memory leaks with DTrace and mdb

Some time ago I wrote about debugging memory problems with libumem.

Now I've a different approach using dtrace and mdb to find the source code position.

First a let the program execute and finish running under dtrace.
The dtrace-Script is from http://blogs.sun.com/sanjeevb/.


# cat ./memleak.d

#!/usr/sbin/dtrace -s

pid$1:libc.so.1:malloc:entry
{
        self->trace = 1;
        self->size = arg0;
}
pid$1:libc.so.1:malloc:return
/self->trace == 1/
{
        printf("Ptr=0x%p Size=%d", arg1, self->size);
        ustack();
        self->trace = 0;
        self->size = 0;
}

pid$1:libc.so.1:realloc:entry
{
        self->trace = 1;
        self->size = arg1;
        self->oldptr = arg0;
}

pid$1:libc.so.1:realloc:return
/self->trace == 1/
{
        printf("Ptr=0x%p Oldptr=0x%p Size=%d", arg1, self->oldptr, self->size);
        ustack();
        self->trace = 0;
        self->size = 0;
}

pid$1:libc.so.1:calloc:entry
/self->trace == 1/
{
        self->trace = 1;
        self->size = arg1;
}

pid$1:libc.so.1:calloc:return
/self->trace == 1/
{
        printf("Ptr=0x%p Size=%d", arg1, self->size);
        ustack();
        self->trace = 0;
        self->size = 0;
}

pid$1:libc.so.1:free:entry
{
        printf("Ptr=0x%p ", arg0);
}

The result output from the dtrace-Script is postprocessed with a
Perl-Script checking if alloced memory is freed again:


#!/usr/bin/perl

# findleaks.pl

use Data::Dumper;

my %hash = ();

while (<>) {
        if ((/malloc:return Ptr=([^ ]*) Size=(.*)/) || 
            (/calloc:return Ptr=([^ ]*) Size=(.*)/)) {
                $hash{$1} = { size => $2 };
  while (<>) {
   last if /^$/;
   $hash{$1}->{stack} .= $_;
  }
        }
        elsif (/free:entry Ptr=([^ ]*)/) {
                if (exists $hash{$1} and $hash{$1}) {
                        $hash{$1} = '';
                }
        }
 elsif (/realloc:return Ptr=([^ ]*) Oldptr=([^ ]*) Size=(.*)/) {
  if ($1 eq $2) {
   if (exists $hash{$1} and $hash{$1}) {
    $hash{$1} = { size => $3 };
    $hash{$1}->{stack} = '';
    while (<>) {
                          last if /^$/;
                           $hash{$1}->{stack} .= $_;
                  }
   } 
  } else {
    $hash{$1} = '';
    $hash{$2}= { size => $3 };
    $hash{$2}->{stack} = '';
    while (<>) {
                          last if /^$/;
                           $hash{$2}->{stack} .= $_;
                  }
  }
 }

}

foreach my $key (keys %hash) {
 next if not $hash{$key}->{size};
 print "Ptr=$key Size=", $hash{$key}->{size}, "\n";
 print $hash{$key}->{stack}, "\n---------\n";
}

Now we get a list of memory allocations which are not freed after closing
the application.

Such an entry might look like
---------
Ptr=0x81c64f8 Size=20
              libumem.so.1`malloc+0x3e
              libstdc++.so.6`_Znaj+0x1b
              libxerces-c.so.28`_ZN11xercesc_2_818IconvLCPTranscoder9transcodeEPKc+0xc4
              libxerces-c.so.28`_ZN11xercesc_2_89XMLString9transcodeEPKc+0x22
              libvsEAI.so404`readFunction+0x39
              libvsEAI.so404`bcfEAIRepositoryInit+0x5a9
              libvsopCsiBdOOPool.so404`ctrl_call_bcf+0x106
              libvsopCsiBdOOPool.so404`ctrl_call_list+0x1bc
              libvsopCsiBdOOPool.so404`ctrl_gosub_list+0xb2
              libvsopCsiBdOOPool.so404`ctrl_call_bcf+0x7dd
              libvsopCsiBdOOPool.so404`ctrl_call_list+0x1bc
              libvsopCsiBdOOPool.so404`ctrl_gosub_list+0xb2
              libvsopCsiBdOOPool.so404`ctrl_call_bcf+0x7dd
              libvsopCsiBdOOPool.so404`ctrl_call_bcf+0x795
              libvsopCsiBdOOPool.so404`ctrl_call_bcf+0x795
              libvsopCsiBdOOPool.so404`ctrl_call_list+0x1bc
              libvsopCsiBdOOPool.so404`prog_control+0x9a
              progvs_prog`vsop_main+0x5a2
              libvszwflx2Bd.so404`main+0x196
              progvs_prog`_start+0x80

To get the position in the readFunction  method, make a core of the application by using
gcore [-F]

and start in mdb with mdb
mdb <core file name >
> libvsEAI.so404`readFunction::dis
libvsEAI.so404`readFunction:    pushl  %ebp
libvsEAI.so404`readFunction+1:  movl   %esp,%ebp
libvsEAI.so404`readFunction+3:  pushl  %edi
libvsEAI.so404`readFunction+4:  pushl  %esi
libvsEAI.so404`readFunction+5:  pushl  %ebx
libvsEAI.so404`readFunction+6:  call   +0x5    
libvsEAI.so404`readFunction+0xb:popl   %ebx
libvsEAI.so404`readFunction+0xc:addl   $0x1527d,%ebx
libvsEAI.so404`readFunction+0x12:       subl   $0xd8,%esp
libvsEAI.so404`readFunction+0x18:       leal   0xfffef969(%ebx),%eax
libvsEAI.so404`readFunction+0x1e:       pushl  %eax
libvsEAI.so404`readFunction+0x1f:       movl   0x8(%ebp),%edi
libvsEAI.so404`readFunction+0x22:       call   -0x620e 
libvsEAI.so404`readFunction+0x27:       movl   %eax,-0x88(%ebp)
libvsEAI.so404`readFunction+0x2d:       leal   0xfffef7a1(%ebx),%eax
libvsEAI.so404`readFunction+0x33:       pushl  %eax
libvsEAI.so404`readFunction+0x34:       call   -0x6220 
libvsEAI.so404`readFunction+0x39:       movl   %eax,-0x8c(%ebp)
libvsEAI.so404`readFunction+0x3f:       leal   0xfffef972(%ebx),%eax
libvsEAI.so404`readFunction+0x45:       pushl  %eax
libvsEAI.so404`readFunction+0x46:       call   -0x6232 
libvsEAI.so404`readFunction+0x4b:       movl   %eax,-0x90(%ebp)
libvsEAI.so404`readFunction+0x51:       leal   0xfffef978(%ebx),%eax
libvsEAI.so404`readFunction+0x57:       pushl  %eax
libvsEAI.so404`readFunction+0x58:       movl   %eax,-0xb0(%ebp)
libvsEAI.so404`readFunction+0x5e:       call   -0x624a 
libvsEAI.so404`readFunction+0x63:       leal   0xfffef97b(%ebx),%edx
Because of the offset from the stack trace  libvsEAI.so404`readFunction+0x39 we see in the disassembly, that the second call to libxerces-c.so.28`_ZN11xercesc_2_89XMLString9transcodeEPKc+0x22 is the problem.


The method called is
>echo "_ZN11xercesc_2_89XMLString9transcodeEPKc" | c++filt
xercesc_2_8::XMLString::transcode(char const*)





Sep 21, 2010

SFTP withing jedit doesn't work in OpenIndiana

I use a lot the FTP plugin from jEdit.
This plugin allows you to open a SFTP connection to a remote host via ssh and
work with files from the remote host, as if they are local. The plugin is
available via the file browser.

You can load and save the files.

Within OpenIndiana this just doesn't work anymore.
The activity.log shows:
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: Remote version string: SSH-2.0-Sun_SSH_1.0.1
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: Local version string: SSH-2.0-JSCH-0.1.43
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: CheckCiphers: aes256-ctr,aes192-ctr,aes128-ctr,aes256-cbc,aes192-cbc,aes128-cbc,3des-ctr,arcfour,arcfour128,arcfour256
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: aes256-ctr is not available.
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: aes192-ctr is not available.
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: aes256-cbc is not available.
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: aes192-cbc is not available.
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: arcfour256 is not available.
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: SSH_MSG_KEXINIT sent
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: SSH_MSG_KEXINIT received
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: kex: server->client aes128-cbc hmac-md5 none
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: kex: client->server aes128-cbc hmac-md5 none
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: SSH_MSG_KEXDH_INIT sent
8:39:58 AM [jEdit I/O #3] [message] SftpLogger: expecting SSH_MSG_KEXDH_REPLY
8:39:59 AM [jEdit I/O #3] [message] SftpLogger: ssh_rsa_verify: signature false
8:39:59 AM [jEdit I/O #3] [message] SftpLogger: Disconnecting from onbahaspa port 22
8:39:59 AM [jEdit I/O #3] [error] BrowserIORequest: java.io.IOException: com.jcraft.jsch.JSchException: verify: false
8:39:59 AM [jEdit I/O #3] [error] BrowserIORequest:  at ftp.SFtpConnection.(SFtpConnection.java:105)
8:39:59 AM [jEdit I/O #3] [error] BrowserIORequest:  at ftp.ConnectionManager.getConnection(ConnectionManager.java:320)
8:39:59 AM [jEdit I/O #3] [error] BrowserIORequest:  at ftp.FtpVFS.getConnection(FtpVFS.java:451)
8:39:59 AM [jEdit I/O #3] [error] BrowserIORequest:  at ftp.FtpVFS._canonPath(FtpVFS.java:194)
8:39:59 AM [jEdit I/O #3] [error] BrowserIORequest:  at org.gjt.sp.jedit.browser.BrowserIORequest.listDirectory(BrowserIORequest.java:158)
8:39:59 AM [jEdit I/O #3] [error] BrowserIORequest:  at org.gjt.sp.jedit.browser.BrowserIORequest.run(BrowserIORequest.java:90)
8:39:59 AM [jEdit I/O #3] [error] BrowserIORequest:  at org.gjt.sp.util.WorkThread.doRequest(WorkThread.java:213)
8:39:59 AM [jEdit I/O #3] [error] BrowserIORequest:  at org.gjt.sp.util.WorkThread.doRequests(WorkThread.java:180)
8:39:59 AM [jEdit I/O #3] [error] BrowserIORequest:  at org.gjt.sp.util.WorkThread.run(WorkThread.java:154)
8:39:59 AM [jEdit I/O #3] [error] ErrorListDialog$ErrorEntry: sftp://hartter@onbahaspa:22/~/:
8:39:59 AM [jEdit I/O #3] [error] ErrorListDialog$ErrorEntry: Cannot list directory: java.io.IOException: com.jcraft.jsch.JSchException: verify: false
The verification fails. I had written to the OpenIndiana Mailinglist and 
the successful suggestion from Onno Molenkamp was, to remove the 
sun.security.pkcs11.SunPKCS11 provider from /usr/jdk/latest/jre/lib/security/java.security

After removing and renumbering the providers there, the SFTP Plugin works again in OpenIndiana. 

 

Sep 16, 2010

Upgraded to OpenIndiana 147 from OpenSolaris Build 134

Now I upgraded from OpenSolaris Build 134 to OpenIndiana Build 147.

Because just testing in VirtualBox fails. The ISO boots and I can install the
system, but during the startup from disk, the kernel likes to update the
microcode and fails.

The upgrade works as usual see the Wiki for more information.

I had the same problem as describe in the wiki with the download of
thunderbird.

Just uninstalled thunderbird and added the strange hostname
 ~0~pkg-origin.openindiana.org with an IP from nslookup to my local hosts files.

After this the upgrade worked with some repetitions because of Error 503 Service unavailble.

After restarting, I didn't get my german keyboard layout.

After searching, I rememberd the fact, that Build 145 changed the keyboard
to be a SMF service.
See the BugIusse @ Illumos

# svccfg
svc:> select keymap:default
svc:/system/keymap:default> setprop keymap/layout = German
svc:/system/keymap:default> refresh
svc:/system/keymap:default> exit




Sep 10, 2010

Changing the message of a mercurial Patch before commiting into the repository

When using Mercurial Queues to work with patches, you can set a message,
when starting a patch.

When you like to change the commit message, when you qfinish the patch,
you have no chance currently.

The only way is to just push the patch you like.
Prepare a file or add the text directly to the qrefresh command.
hg qrefresh -l /path/to/msgfile
or
hg qrefresh -e "my commit text"

Sep 9, 2010

Python pygtk based MergeTool for Mercurial

I've found a merge tool named gpyfm, which is a rewrite of the old TeamWare file merge tool used by Sun Engineers.

Excerpt from the Homepage: 

gpyfm was originally written by David Marker (assitant ON Nevada gatekeeper). Richard Lowe, one of the project leads for SCM Migration.

Here is a picture from the tutorial of the merge tool:

Sep 8, 2010

Compiling Qt 4.5.3 on OpenSolaris

Because the tortoisehg  is changing to PyQt instead of PyGtk, I attempted to
compile the Qt Package from Nokia ( former Trolltech ).

I used the Sun Studio Compilers, but ran into a compile problem, where I had
to set an additional compile/link flag see here for the message.

The configure option I used was:

CC=/opt/sunstudio12.1/bin/cc CXX=/opt/sunstudio12.1/bin/CC CXXFLAGS="-library=stlport4" LDFLAGS="-library=stlport4" ./configure --prefix=/tools/qt/4.5.3 -opensource

After this, just a gmake and gmake install and everything was fine.

Sep 3, 2010

Moving source changes to a previous patch in Mercurial with Mercurial Queues ( MQ )

I started to use Mercurial Queues  to collect my changes in a patch.
Now I have more patches applied in my local repository.

When detecting an error, I changed the error in the code, but it belongs
to an earlier patch than the topmost which is now active.

To get the changes there, I do now

hg diff > /tmp/patch
hg qgoto targetpatch
hg import --no-commit /tmp/patch
hg qrefresh

This allows me to move source changes to a different patch .

Sep 2, 2010

Getting information in screen when something happens on an other shell

Some time ago, I started to use screen in my terminal instead of opening
multiple registers or gnome-terminals. See my starting entry here.

Now, I've running some simulation scripts which receive messages. When you
are on a different  shell in screen and something happens on an other screen-shell, you can get notified by a special key sequence.

Go the the shell in screen, where you like to receive notifications and press
-


After this you get a hint, when something changes in the output. 


Aug 28, 2010

Netbeans 6.10 M1 & Python Plugins are available.

Netbeans 6.10 Milestone 1 is ready for download. The plugin site contains
the Python Plugins and a lot more.

A Hex-Editor:

Aug 27, 2010

Upgrade meld to Version 1.3.1 from Sourceforge in OpenSolaris

OpenSolaris has the packge version 1.1.5.1 of meld installed.

SourceForge has the version 1.3.1 of meld.

Meld is a nice comparison tool which can compare files and directories.

Installation goes not as fine on OpenSolaris as necessary.
You have to change in the GNUmakefiles the install command with ginstall
The INSTALL file has the path definitions where to store the files.
After the make install is finished, you have to modify
  • $INSTALL/bin/meld and adjust the setting of sys.path, so that the lib of meld can be found by python because the default is to /usr/local
  • $INSTALL/lib/meld/paths.py must be patched to set the path to the installation because all the values are for /usr/local/
After this, the new meld can be started.

The following Images are links to the meld homepage.


Aug 26, 2010

Getting the changes of a MQ ( Mercurial Queue ) Patch, when it is already stored with qrefresh

Mercurial supports with the Mercurial Queues Extension a mode,
where you can collect your changes into a patch, which can be added
and removed to the working copy. See Stacy Marshall's Weblog for a
tutorial.

The problem is, when you issue
hg qrefresh
to update the changes to the current path, a
hg status
doesn't show you any change, although
[ewer@sunray1:/users/trinomic/ewer/tmp/hgMq]>hg qapplied
salutation
goodBye

shows applied patches and qseries show more patches available

[ewer@sunray1:/users/trinomic/ewer/tmp/hgMq]>hg qseries
salutation
goodBye
translateGoodBye


To get the changes you've done in a patch you can use the standard diff
operation of Mercurial:

[ewer@sunray1:/users/trinomic/ewer/tmp/hgMq]>hg log -r qparent:qtip
changeset:   0:cb74f3bb0f52
tag:         qparent
user:        Ewald Ertl
date:        Thu Aug 26 13:21:59 2010 +0200
summary:     First ci of hello.c

changeset:   1:97e29574fe18
tag:         qbase
tag:         salutation
user:        Ewald Ertl
date:        Thu Aug 26 13:24:42 2010 +0200
summary:     Change salutation

changeset:   2:e5a01dbef110
tag:         goodBye
tag:         qtip
tag:         tip
user:        Ewald Ertl
date:        Thu Aug 26 13:24:42 2010 +0200
summary:     Say Goodbye

shows you all changes of all patches currently pushed to the working directory.

To get the changes of the salutation patch use
[ewer@sunray1:/users/trinomic/ewer/tmp/hgMq]>hg diff -r qparent:salutation
diff -r cb74f3bb0f52 -r 97e29574fe18 hello.c
--- a/hello.c   Thu Aug 26 13:21:59 2010 +0200
+++ b/hello.c   Thu Aug 26 13:24:42 2010 +0200
@@ -1,4 +1,4 @@
 int main(int argc, char* argv[])
 {
-       printf( "Hello World\n" );
+       printf( "Hallo Welt\n" );
 }
You can take the names of the patches stored as tags in the log or the revision numbers, you get from the log command.

Netbeans seems to ignore tab size

I'm using netbeans on OpenSolaris and Solaris 10.

In a project some files ( with a extensions .tra ) were shown with wrong
tab sizes, also I do not expand tab to spaces and uses indent size 4 and tab size 4. Even changing the values didn't change anything.

Now I've changed the association of the extension to c-files and the display
is correct. In Options-Miscellaneous-Files

Aug 25, 2010

Reordering patches in a mercurial queues ( hg mq )

I have converted a Repository from Subversion to Mercurial - From a centralized Repository to a distributed Repository, although I use Mercurial with a centralized master repositroy.

The reason for changing to Mercurial for me was to have the whole content
locally, even when I do not have a connection to the central server repository and the Mercurial Queues Extension.

I have some changes, which are not ready for commitment, so in Subversion I had a lot of working directories but MQ allows to use patches, which can be applied and removed.

If the order of the patches is not what you want, a reorder is necessray:

[ewer:sunray1:/users/trinomic/ewer/entw/vsop]$ hg qseries
eaiTacReference     
vspipeCompile       
oldDemoWfl4EaiServe
 

applying vspipeCompile also pushes eaiTacReference

[ewer:sunray1:/users/trinomic/ewer/entw/vsop]$ hg qpush vspipeCompile
Wende eaiTacReference an
Wende vspipeCompile an
Patch vspipeCompile ist leer
jetzt bei: vspipeCompile

qpush has an option --move to reorder the patches.

[ewer:sunray1:/users/trinomic/ewer/entw/vsop]$ hg qpop -a
Entferne (obersten) oldDemoWfl4EaiServer
Entferne (obersten) vspipeCompile
Entferne (obersten) eaiTacReference
Patchschlange ist jetzt leer
[ewer:sunray1:/users/trinomic/ewer/entw/vsop]$ hg qpush --move oldDemoWfl4EaiServer
Wende oldDemoWfl4EaiServer an
jetzt bei: oldDemoWfl4EaiServer
[ewer:sunray1:/users/trinomic/ewer/entw/vsop]$ hg qapplied
oldDemoWfl4EaiServer

I think, as long as the patches do not depend on each other this a way
to remove some change sets.

Aug 24, 2010

Using a Mercurial repository of a different user with a .hgrc file ends in Not trusting file /repo/.hg/hgrc from untrusted user me, group mygroup

When you access a Mercurial repository of a different user, you get an error for security reasons.
 
Not trusting file /repo/.hg/hgrc from untrusted user me, group mygroup
It could be possible to parametrize actions in the hgrc File, which the
user working with hg does not want.

In my case, the other use is a working user, so I trust the file and the settings
in the repository, so a configured my  ~/.hgrc by an additional section:

 
[trusted]
users = *
groups = *


I got this info from here.

Aug 21, 2010

Upgraded to OpenSolaris Build 134 from Build 145

The regular OpenSolaris Development Repositories with regular binary updates are stopped since a long time.

The last change was the Illumos project. This project attempts to replace the
close source bits of OpenSolaris.

Here is also a description how to update.

I just worked throught the description and updated from http://91.194.74.69:10000.


The first problem after Upgrading I experienced, was an english keyboard
layout on my german notebook.


The problem is, that the keyboard setting is now an SMF-Service.



# svccfg
svc:> select keymap:default
svc:/system/keymap:default> setprop keymap/layout = German
svc:/system/keymap:default> exit
svcadm refresh keymap:default
 After this I just rebooted and the german keyboard was back again.
The hint to this problem was found at Giovanni Tirloni blog.


Also the graphical boot screen works now on my Laptop

root@solewer:~# prtdiag
System Configuration: FUJITSU SIEMENS CELSIUS H270
BIOS Configuration: Phoenix Z118D4FR.113 - R081 - 4807 12/11/2009
On Build 134, I had to remove the splashscreen, fore and background lines and the grapics-boot in the grub menu to be able to start.

Aug 20, 2010

Path manipulation in python on different platforms

Since now, I've used the posixpath module without any much thinking about
in my python scripts. It wasn't a problem since now, because all scripts worked
on Solaris/Linux, but now a script has to run on windows and
the functionsj of  posixpath module returned wrong results in my opinion, but
it was just my opinion and python was right.

I used the wrong module switching from posixpath to os.path solved the issues.

os.path handles the setting to the correct system itself and selects
posixpath, ntpath or what is suitable.

Thanks to Python!

Aug 17, 2010

Gnome-Panels auto-hide feature stops sometimes to work

On our SunRay-Environment with Solaris 10  it sometimes happens that the autohide feature of the gnome-panel just stops to work.

I found a workaround here.

ps -fu | grep gnome-panel 

kill -TERM

Aug 15, 2010

Thunderbird 3.1.2 -> ColoredDiffs

In my mail-client thunderbird I get e-mails containing the diff-output from
version control systems like subversion or mercurial.
Here I use the plugin coloreddiffs, which interprets the output and displays
a nice text format.

This plugin was not compatible with the last 3.1.x version of thunderbird,
but yesterday I checked the add-ons and now this beautiful plugin works
again.

Thunderbird 3.1.2 -> Lightning Plugin for Solaris

I'm running on Solaris and use thunderbird as my mail-client.

Until now I used an older version because the lightning plugin ( calendar ) was not available for the 3.1.x version for the Solaris platform.
But now it's available. A version for x86 and sparc is available.

I use the x86 version in the latest 3.1.2 version of thunderbird and it connects
to a webcal without problems. Even some troubles with charactersets seem to
be gone.

Jul 28, 2010

Removing ^M from files in Windows

For my previous problem with the uuencode on windows, I had to remove
the ^M from the files.

  • Using jEdit to load the uuencoded file and switch the line encoding of
    the current buffer and store the file again. 
  • Using gVim ( vi Improved on Windows ) is at the start a little problem,
    because there the key - is mapped to a different function
    as on Solaris.
    • You have to set the file format to unix
          :set ffs       ---> fileformats=dos,unix
        :set ffs=unix
    • Reload the file with :e  
    • Replace the ^M with
      :%s/--m//g
    • Store the file
 

uuencode in windows -> Problems with 0x0D0x0A ( CR/LF ) endings in the uuendoded file.

For sending data I used uuencode on the solaris platform. When adding a '#' at the first start line in the created uuencode file, some mail scanner do not recognize the content.

On solaris:

uuencode [name of the file] [name of the file on the target host] > encodedfile.uuencode

uudecode encodedfile.uuencode

would create the file on the target system. 

Now I've to do this in Windows:

uuencode-Tools can be found http://www.bastet.com/ .

This tool work a little different:

uuencode [Source File] [targetfile uuencoede]

There is no naming of the file on the target like on solaris.

The resulting encoded file has the windows lineendings CR/LF.

On Solaris the uudecode doesn't find the end line and therefore does
nothing. To get it to work use vi and remove the CR on the last line containing "end", or prepare the file on the windows platform.

Jul 15, 2010

How to recover a MySQL database with lost root password

I couldn't remember the root password I set for testing on my mysql database.
There is a recipe for recovering the database:

Start the databse with the option --skip-grant-tables an log in with mysql.
Because of the option you're not asked for a password.

Set a new password with


update user set password=PASSWORD("NEW-ROOT-PASSWORD") where User='root';

and restart the database.

see  http://www.cyberciti.biz/tips/recover-mysql-root-password.html for the
full description.

showing the full environment of a process in AIX

On a Solaris box you get the full environment of a running process by
using the command:

pargs -e

[ewer@sunray1:/>pargs -e 21437
21437:  ./cpubar.i386
envp[0]: UTDEVROOT=/tmp/SUNWut/sessions/15/unit
envp[1]: MANPATH=/usr/local/man:/opt/sfw/man:/usr/man:/usr/local/man:/opt/sfw/man:/usr/man:/usr/dt/man:/usr/man:/usr/openwin/share/m
an
envp[2]: SSH_AGENT_PID=11675
envp[3]: DTSOURCEPROFILE=true
...

On the AIX-System, the proc* commands do not have such an option.
Here the ps command can help to get the environment:

root@aixhaspa:/home/vswfl/tmp
# ps -ef | grep prog
    ewer 499794 741434   0 10:05:14      -  0:00 /home//vswfl/bin/prog
root@aixhaspa:/home/vswfl/tmp
# ps eww 499794
    PID    TTY STAT  TIME COMMAND
 499794      - A     0:00 /home//vswfl/bin/prog _=/home//vswfl/bin/prog LANG=de_DE.ISO8859-1 LOGIN=root MALLOC_DEBUG=STOP,WATCH,RW LC_MONETARY=de_DE.ISO8859-1 LC_TIME=de_DE.ISO8859-1 SSH_TTY=/dev/pts/9 VSOP=/opt/vsop/V4.03_00 PATH=/opt/sfw/bin:/usr/ccs/bin:/home//bin/bin.:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin:/usr/java14/jre/bin:/usr/java14/bin:/opt/freeware/bin:/opt/apache-ant-1.7.1/bin:/opt/freeware/bin:/opt/apache-ant-1.7.1/bin....

How to determine the process for an open port on AIX

To find the process which has a port opened on AIX you do the following:
( from http://www.ibmsystemsmag.com/aix/tipstechniques/6666p1.aspx )
netstat -Aan | grep


# netstat -Aan | grep 17458
f10006000c60c398 tcp4       0      0  127.0.0.1.17458    127.0.0.1.58037    ESTABLISHED
f10006000e15bb98 tcp4       0      0  127.0.0.1.58037    127.0.0.1.17458    ESTABLISHED
f10006000c61a398 tcp4       0      0  *.17458            *.*                LISTEN
root@aixhaspa:/home/vswfl/tmp

to determine the TCP Control block f10006000c61a398.

The Utility rmsock helps to find the process ( if you do not have lsof )
# rmsock f10006000c61a398 tcpcb
The socket 0xc61a008 is being held by proccess 741434 (vsopd).

The other way would be to use kdb.
At the end of the output you see also the process ID.

# kdb
The specified kernel file is a 64-bit kernel.
Preserving 1418178 bytes of symbol table
First symbol __mulh
           START              END
0000000000001000 0000000003E5C050 start+000FD8
F00000002FF47600 F00000002FFDC940 __ublock+000000
000000002FF22FF4 000000002FF22FF8 environ+000000
000000002FF22FF8 000000002FF22FFC errno+000000
F100070F00000000 F100070F10000000 pvproc+000000
F100070F10000000 F100070F18000000 pvthread+000000
PFT:
PVT:
id....................0002
raddr.....000000000A000000 eaddr.....F200800040000000
size..............00080000 align.............00001000
valid..1 ros....0 fixlmb.1 seg....0 wimg...2
(0)> sockinfo
sockinfo

[-d]
TypeOfAddress can be socket, inpcb, unpcb, rawcb, ripcb, or tcpcb.

(0)> sockinfo f10006000c61a398 tcpcb
---- TCPCB ----(@ F10006000C61A398)----
    seg_next......@F10006000C61A398  seg_prev......@F10006000C61A398 
    t_softerror... 00000000 t_state....... 00000001 (LISTEN)
    t_timer....... 00000000 (TCPT_REXMT)
    t_timer....... 00000000 (TCPT_PERSIST)
    t_timer....... 00000000 (TCPT_KEEP)
    t_timer....... 00000000 (TCPT_2MSL)
    t_rxtshift.... 00000000 t_rxtcur...... 00000006 t_dupacks..... 00000000
    t_maxseg...... 000005B4 t_force....... 00000000
    t_flags....... 00000000 ()
    t_oobflags.... 00000000 ()
    t_template....@0000000000000000  t_inpcb.......@F10006000C61A290 
    t_iobc........ 00000000 t_timestamp... FA99CA01 snd_una....... 00000000
    snd_nxt....... 00000000 snd_up........ 00000000 snd_wl1....... 00000000
    snd_wl2....... 00000000 iss........... 00000000
    snd_wnd....... 0000000000000000 rcv_wnd....... 0000000000000000
    rcv_nxt....... 00000000 rcv_up........ 00000000 irs........... 00000000
    snd_wnd_scale. 00000000 rcv_wnd_scale. 00000000 req_scale_sent 00000000
    req_scale_rcvd 00000000 last_ack_sent. 00000000 timestamp_rec. 00000000
    timestamp_age. 00000008 rcv_adv....... 00000000 snd_max....... 00000000
    snd_cwnd...... 000000003FFFC000        snd_ssthresh.. 000000003FFFC000
    t_idle........ 00000008 t_rtt......... 00000000 t_rtseq....... 00000000
    t_srtt........ 00000000 t_rttvar...... 00000006 t_rttmin...... 00000002
    max_rcvd...... 0000000000000000        max_sndwnd.... 0000000000000000
    t_peermaxseg.. 000005B4 snd_in_pipe... 00000000
    sack_data.....@0000000000000000         snd_recover... 00000000
    snd_high...... 00000000 snd_ecn_max... 00000000 snd_ecn_clear. 00000000
    t_splice_with.@0000000000000000         t_splice_flags 00000000


-------- TCB --------- INPCB  INFO ----(@ F10006000C61A290)----
    next........@0000000000000000  prev........@0000000000000000 
    head........@0000000004364900  faddr_6.....@F10006000C61A2B0 
    iflowinfo... 00000000 fport....... 00000000 fatype...... 00000000
    oflowinfo... 00000000 lport....... 00004432 latype...... 00000000
    laddr_6.....@F10006000C61A2C8  socket......@F10006000C61A008 
    ppcb........@F10006000C61A398  route_6.....@F10006000C61A2E8 
    ifa.........@0000000000000000  flags....... 00000400
    proto....... 00000000 tos......... 00000000 ttl......... 0000003C
    rcvttl...... 00000000 rcvif.......@0000000000000000 
    options.....@0000000000000000  refcnt...... 00000000
    lock........ 0000000000000000  rc_lock..... 0000000000000000
    moptions....@0000000000000000  hash.next...@F10001003E9654B0 
    hash.prev...@F10001003E9654B0  timewait.nxt@0000000000000000 
    timewait.prv@0000000000000000  inp_v6opts  @0000000000000000 
    inp_pmtu....@0000000000000000 

---- SOCKET INFO ----(@ F10006000C61A008)----
    type........ 0001 (STREAM)
    opts........ 0006 (ACCEPTCONN|REUSEADDR)
    linger...... 0000 state....... 0180 (PRIV|NBIO)
    pcb.....@F10006000C61A290  proto...@000000000435B288 
    lock....@F10006000E16E140  head....@0000000000000000 
    q0......@0000000000000000  q.......@0000000000000000 
    q0len....... 0000 qlen........ 0000 qlimit...... 0400
    timeo....... 0000 error....... 0000 special..... 0A08
    pgid.... 0000000000000000  oobmark. 0000000000000000

snd:cc...... 0000000000000000  hiwat... 0000000000004000
    mbcnt... 0000000000000000  mbmax... 0000000000010000
    lowat... 0000000000001000  mb......@0000000000000000 
    sel.....@0000000000000000  events...... 0000
    iodone.. 00000000          ioargs..@0000000000000000 
    lastpkt.@0000000000000000  wakeone. FFFFFFFFFFFFFFFF
    timer...@0000000000000000  timeo... 00000000
    flags....... 0000 ()
    wakeup.. 00000000          wakearg.@0000000000000000 
    lockwtg. FFFFFFFFFFFFFFFF

MBUF LIST

rcv:cc...... 0000000000000000  hiwat... 0000000000004000
    mbcnt... 0000000000000000  mbmax... 0000000000010000
    lowat... 0000000000000001  mb......@0000000000000000 
    sel.....@0000000000000000  events...... 0001
    iodone.. 00000000          ioargs..@0000000000000000 
    lastpkt.@0000000000000000  wakeone. FFFFFFFFFFFFFFFF
    timer...@0000000000000000  timeo... 00000000
    flags....... 0008 (SEL|NOTIFY)
    wakeup.. 00000000          wakearg.@0000000000000000 
    lockwtg. FFFFFFFFFFFFFFFF

MBUF LIST

    tpcb....@0000000000000000  fdev_ch.@F100010054710640 
    sec_info@0000000000000000  qos.....@0000000000000000 
    gidlist.@0000000000000000  private.@0000000000000000 
    uid..... 00000000 bufsize. 00000000 threadcnt00000000
    nextfree@0000000000000000 
    siguid.. 00000000 sigeuid. 00000000 sigpriv. 00000000
    sndtime. 0000000000000000  sec  0000000000000000  usec
    rcvtime. 0000000000000000  sec  0000000000000000  usec
    saioq...@0000000000000000  saioqhd.@0000000000000000 
    accept.. FFFFFFFFFFFFFFFF  frcatime 00000000
    isnoflgs 00000000 ()
    rcvlen.. 0000000000000000  frcaback@0000000000000000 
    frcassoc@0000000000000000  frcabckt 0000000000000000
    iodone.. 00000000          iodonefl 00000000 ()
    ioarg...@0000000000000000  refcnt.. 0000000000000001
    trclev........... 0001


proc/fd:  181/5


proc/fd: fd: 5
              SLOT NAME     STATE      PID    PPID          ADSPACE  CL #THS

pvproc+02D400  181*vsopd    ACTIVE 00B503A 0000001 00000001D8B1F480   0 0001

Jun 16, 2010

Netbeans 6.9 Release is available for download

The Netbeans 6.9 Release is available for download.

The Python Modules are also available for installation in
the Plugin-Manager.

So far the release works on my OpenSolaris Build 134.

Jun 9, 2010

Mantis 1.2.1 running on Solaris with coolstack and Authentication on Scalix Mail-Server

I worked on the installation of mantis 1.2.1. This is a bugtracking software
in PHP and using a database to store the bugs. In my case this is mysql.

I'm running on a SPARC Solaris 10 box with the software from coolstack.

This are precompiled packages of MySQL, Apache, PHP.

I configured mantis to Authentication during sending e-mails.

Therefore I had to activate tls in the config
/**                                 
 * This control the connection mode to SMTP server. Can be 'ssl' or 'tls'
 * @global string $g_smtp_connection_mode
 */                             
 $g_smtp_connection_mode = 'tls';
and set the g_smtp_username and g_smtp_password to a valid login.

But this still fails.
Mantis has already a prepackaged PHPMailer, but after adding some logging
information, I found, that php must be configured to used openssl.

Therefore /opt/coolstack/php5/lib/php.ini has to be edited to activate openssl
for the tls encryption:

extension=openssl.so
After this, the apache has also to be restarted with


svcadm restart svc:/network/http:apache22-csk

and e-mail sending from mantis works. 

Jun 2, 2010

ssh login fails with active certificats, because they do not match and there is no password request.

I've got an AIX server, where I'd like to login as a different user, but
the SSH-Certificates I've loaded, do not match.

The login fails without requesting the password for the account:

[ewer@solewer:~]$ssh gvs@aix
Received disconnect from XXX.XXX.XXX.XXX: 2: Too many authentication failures for gvs

After changing the MaxAuthTries in /etc/ssh/sshd_config on the AIX and restarted
the SSH-Service with

stopsrc -g ssh
startsrc -g ssh

I can now login into the AIX server because the SSH-Shell asks for the password.

Jun 1, 2010

Using jconsole on a Solaris with a JDK 1.5.x

For using the jconsole tool from the 1.5 JDK a special system property must be
set when starting the VM for a local connection:


-Dcom.sun.management.jmxremote
A full documentation is here for JDK 1.6 it is here


An insecure remote configuration would be:

-Dcom.sun.management.jmxremote.port=5555 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false


This disables the default usage of SSL and the password  check.

May 31, 2010

Debugging memory problems on solaris with libumem

pmap -x showed an increasing memory usage of an application.

After searching, I found  a lot of hints using libumem for debugging
memory issues in Solaris / OpenSolaris.

Hints are here , here and here and also a lot more.

On Build 134 I started the application with:

# libumem
LD_PRELOAD=libumem.so.1
export LD_PRELOAD
##UMEM_DEBUG=default
UMEM_DEBUG=default,firewall=1
export UMEM_DEBUG
UMEM_LOGGING=transaction
export UMEM_LOGGING
UMEM_OPTIONS=backend=mmap
export UMEM_OPTIONS
After starting the application, I attached the mdb with the command:
mdb -p
>::sysbp _exit
>::cont

After this I let the application run and  shut down. During shutdown the
debugger stopped short before finishing:


mdb: stop on entry to _exit
mdb: target stopped at:
0xfe8c3f68:     nop  

Now we trapped in the exit function of the process and verify the
recordings of libumem:
 
> ::umem_verify
Cache Name                      Addr     Cache Integrity    
umem_magazine_1                 fe826010 clean
umem_magazine_3                 fe826390 clean
umem_magazine_7                 fe826710 clean
umem_magazine_15                fe826a90 clean
umem_magazine_31                fe827010 clean
umem_magazine_47                fe827390 clean
umem_magazine_63                fe827710 clean
umem_magazine_95                fe827a90 clean
umem_magazine_143               fe828010 clean
umem_slab_cache                 fe828390 clean
umem_bufctl_cache               fe828710 clean
umem_bufctl_audit_cache         fe828a90 clean

Here every buffer is clean and no memory overwriting occured, otherwise
there would be a message like:
 umem_alloc_1152                  8098a90 1 corrupt buffer
Show open memory allocations:
> ::findleaks
BYTES             LEAKED VMEM_SEG CALLER
8192                   1 fef39000 MMAP
------------------------------------------------------------------------
           Total       1 oversized leak, 8192 bytes

CACHE     LEAKED   BUFCTL CALLER
fe7d3010       1 fae39eb8 libldap50.so`ldap_x_calloc+0x2d
fe7d0710       6 fae39c60 libldap50.so`ldap_x_malloc+0x29
fe7d0710       1 fae39f30 libldap50.so`ldap_x_malloc+0x29
fe7d0a90      10 fae39e40 libldap50.so`ldap_x_malloc+0x29
fe7d0390       3 fab805f0 libstdc++.so.6`_Znwj+0x29
fe7d0390      17 f9c4e480 libstdc++.so.6`_Znwj+0x29
fe7d0390       2 fab80500 libstdc++.so.6`_Znwj+0x29
fe7d0390      21 fb026ad0 libstdc++.so.6`_Znwj+0x29
fe7d0390       3 fab80398 libstdc++.so.6`_Znwj+0x29
fe7d0390      28 fa91d168 libstdc++.so.6`_Znwj+0x29
fe7d0390      22 fa66df28 libstdc++.so.6`_Znwj+0x29
fe7d0710       1 fa081878 libstdc++.so.6`_Znwj+0x29
fe7d0710       1 faae2148 libstdc++.so.6`_Znwj+0x29
fe7d9a90       1 fde2ce40 lib
XXXXXX.so403`scf_XXXXXX+0x3c
fe7d9a90       1 fd97b078 lib
XXXXXX.so403`scf_XXXXXX+0x3c
fe7d0710       1 fb0842f8 lib
XXXXXX.so403`scf_malloc+0x48
fe7d1010       1 fb084370 lib
XXXXXX.so403`scf_malloc+0x48
fe7dda90       1 fa82f4c0 lib
XXXXXX.so403`scf_malloc+0x48
fe7df390       1 fa0818f0 lib
XXXXXX.so403`scf_malloc+0x48
fe7d3710       1 fe7b48f0 lib
XXXXXX.so403`init_libXXXXXX+0x18
------------------------------------------------------------------------
   Total     123 buffers, 25112 bytes
Analyse a specific buffer:
> fb0842f8::bufctl_audit
            ADDR  BUFADDR  TIMESTAMP    THREAD
                    CACHE    LASTLOG    CONTENTS
        fb0842f8  f9f16000
a926cc9ecf6a     1
                  fe7d0710     fe8033e8     0
                 libumem.so.1`umem_slab_alloc+0x1b7
                 libumem.so.1`umem_cache_alloc+0xe5
                 libumem.so.1`umem_alloc+0xcd
                 libumem.so.1`malloc+0x2a
                 lib
XXXXXX.so403`scf_malloc+0x48
                 libvsmsgCsi.so403`scf_
XXXXXX+0x46b
                 libvsmsgCsi.so403`bcf_
XXXXXX+0x1a1
                 lib
XXXXXX.so403`ctrl_XXXXXX+0x106
                 lib
XXXXXX.so403`ctrl_XXXXXX+0x1bc
                 lib
XXXXXX.so403`ctrl_XXXXXX+0xb2
                 lib
XXXXXX.so403`ctrl_XXXXXX+0x7dd
                 lib
XXXXXX.so403`ctrl_XXXXXX+0x1bc
                 lib
XXXXXX.so403`prog_XXXXXX+0x9a
                
XXXXXX?main+0x140
                 lib
XXXXXX.so403`main+0x196

The real memory pointer in the executable is f9f16000 + 8.

The length of the data can be calculated by dumping the memory:


> f9f16000/10X
0xf9f16000:     2579            3a109a87        2f6a392f        51414134
                4a5a6b53        42416752        41455141        4c4


and calculate 2579-8 in hex seems to be the size of the allocated buffer.

If the leak occured more times, there is only the last entry in the
::findleaks output.  In the column LEAKED is the number of
occurrences of the leak.


To get all buffers issued the following:


::walk leak 
or
::walk leakbuf

and this shows you all leaking buffers, which can be inspected with
::bufctl_audit

May 27, 2010

GCC compile problem on AIX 6.1 as non root user. Getting cc1: error: /usr/local/include: Permission denied

On a p520 with AIX 6.1 I installed the GCC Packages from http://www.perzl.org/aix/index.php?n=Main.Gcc.

The had the version 4.2.4.

When trying to compile a simple c file I get the following message, when I'm a normal user:

[vsop:aixhaspa61:/entw/vsop/tmp]$ gcc -o a a.c
cc1: error: /usr/local/include: Permission denied
After searching for a solution, I found this thread, which has the same problem on solaris.  

After creating a /usr/local/include folder and changing the access rights,
the compilation also works for a non-root user. 

FindBugs, PMD, Checkstyle, Dependency finder from SQE is now in kenai for netbeans update

After upgrading to Netbeans 6.9 RC1 I could not install the SQE
( Software Quality Environment ) from the dev.java.net site.

The refered to kenai for netbeans > 6.7.1.


Use this link for the update center  or go to the following site for more
information.

May 26, 2010

Netbeans 6.9 RC1 is ready for download

 The Netbeans 6.9 RC 1 is ready for download at:
http://dlc.sun.com.edgesuite.net/netbeans/6.9/rc/

The Python Plugins are available for installation.

The installation was fine on my OpenSolaris Build 134.

The python modules seems to work.

Zones on AIX 6.1 -> Workload Partitions

On an AIX system you can also create zones like in Solaris 10 but here
they are named WPAR ( workload partitions ).

the commands are

mkwpar -n
lswpar
startwpar
stopwpar
The default directory is /wpars if not defined otherwise in mkwpar.

Smitty also contains a menu entry for WPAR maintenance, where you have
an option to add a network interface to the WPAR.

May 25, 2010

sftp login via jEdit failed on new installed AIX 6.1 with ssh from the CD|s

We installed a AIX 6.1 on a new p520. To allow the login via ssh, I installed
the SSH-Package from the CD.

But the open request in jEdit failed with a

java.io.IOException: com.jcraft.jsch.JSchException: failed to send channel request

After searching for the error, I found out, that /etc/ssh/sshd_config had a
wrong path entry for the sftp server.
After setting to /usr/sbin/sftp-server, the login worked via jEdit.