A blog about my experiences with bioinformatics, operating systems, and random other technologies and bits.

Tuesday, June 19, 2007

Useful Solaris tips for Linux Users

Since I'm coming from Linux, I thought it would be useful to start a long entry about Solaris tips for Linux users. I'll update this entry with new tips as I find them.

ldconfig and ld.so.conf solaris equivalents (taken from the blog of Chris Miles):

If you're a Linux admin on Solaris and are looking for the Solaris equivalent of ldconfig and /etc/ld.so.conf read on.

The command you are looking for is crle(1) - this is the equivalent of Linux's ldconfig but even more powerful. Read the man pages to crle for all the details. But here's a quick howto - how to add /usr/local/lib to the default ls.so.1 path. Run crle with no arguments to see the default paths.
mad[~] crle

Default configuration file (/var/ld/ld.config) not found
Default Library Path (ELF): /lib:/usr/lib (system default)
Trusted Directories (ELF): /lib/secure:/usr/lib/secure (system default)
Use crle -u -l /usr/local/lib to add /usr/local/lib to the default ld.so.1 path.
mad[~] sudo crle -u -l /usr/local/lib
mad[~] crle

Configuration file [version 4]: /var/ld/ld.config
Default Library Path (ELF): /lib:/usr/lib:/usr/local/lib
Trusted Directories (ELF): /lib/secure:/usr/lib/secure (system default)

Command line:
crle -c /var/ld/ld.config -l /lib:/usr/lib:/usr/local/lib
And that's it really. The configuration is stored in /var/ld/ld.config but crle should always be used to manipulate it. Hope that is useful.

prstat can be used instead of top, and is supposedly more robust.

No comments: