
I had to change the hostname in one of Solaris zones today, and just out of curiousity looked into /etc/init.d/network script. That’s how I learned a new (to me) option of the uname command, which seems to be specific to Solaris: uname -S <newhostname>.
So here’s a very simple procedure for updating the hostname of your [...]
>
Read More... |
Digg This!

Now that some of the systems I have to regularly patch are Solaris 10 ones, I have to get used to the new patch return codes which one can see when applying one of the Sun’s recommended patchsets. It’s similar to the Solaris 8/9 patchset installation codes, but there are more codes added to the [...]
>
Read More... |
Digg This!

Just a few days ago I’ve been busy configuring one of the Solaris 10 zones on a DMZ server, and sure enough I hit one of the most common IP-related issues with non-global zones.
Shared IP configuration for non-global Solaris zones
By default, non-global zones will be configured with a shared IP functionality. What this means is [...]
>
Read More... |
Digg This!

inetadm command is used for observing and managing inetd services in Solaris 10.
If you run this command without any parameters, you’ll simply get a list of all the services it manages along with their current status:
solaris# inetadm
ENABLED STATE FMRI
enabled online svc:/application/x11/xfs:default
enabled online svc:/application/font/stfsloader:default
enabled offline svc:/application/print/rfc1179:default
enabled online svc:/network/rpc/gss:default
disabled disabled svc:/network/rpc/mdcomm:default
disabled disabled svc:/network/rpc/meta:default
disabled disabled svc:/network/rpc/metamed:default
disabled disabled svc:/network/rpc/metamh:default
...
I needed to start a time service on my system:
solaris# inetadm | grep time
disabled disabled svc:/network/daytime:dgram
disabled disabled svc:/network/daytime:stream
disabled disabled svc:/network/time:dgram
disabled disabled svc:/network/time:stream
To enable or disable a certain network service, you have [...]
>
Read More... |
Digg This!

inetadm command is used for observing and managing inetd services in Solaris 10.
If you run this command without any parameters, you’ll simply get a list of all the services it manages along with their current status:
solaris# inetadm
ENABLED STATE FMRI
enabled online svc:/application/x11/xfs:default
enabled online svc:/application/font/stfsloader:default
enabled offline svc:/application/print/rfc1179:default
enabled online svc:/network/rpc/gss:default
disabled disabled svc:/network/rpc/mdcomm:default
disabled disabled svc:/network/rpc/meta:default
disabled disabled svc:/network/rpc/metamed:default
disabled disabled svc:/network/rpc/metamh:default
...
I needed to start a time service on my system:
solaris# inetadm | grep time
disabled disabled svc:/network/daytime:dgram
disabled disabled svc:/network/daytime:stream
disabled disabled svc:/network/time:dgram
disabled disabled svc:/network/time:stream
To enable or disable a certain network service, you have [...]
>
Read More... |
Digg This!

I think I’ve covered the basics of updating your OpenSolaris using BFU before. This is the post: OpenSolaris BFU. Back then I’ve explained the basics of BFUing.
Today I simply would like to tell a bit more about the contents of a BFU archive, using the latest available one as an example: ON b41.
After you download [...]
>
Read More... |
Digg This!

One of our users has asked me to help with PAM authentication for Apache 2 on one of our remote servers.
It did seem like a rather trivial task - download mod_auth_pam, compile it for Apache 2, make sure everything works. The remote server uses NIS, I could freely log onto it.
And you know what? It [...]
>
Read More... |
Digg This!

Your next step in observing PHP with DTrace could easily be the following script. It times how much time (in nanoseconds) each Apache process has spent running a particular PHP function.
This script generates a table of Apache PIDs and PHP scripts started within, and later you’ll get a table of all the functions with PIDs [...]
>
Read More... |
Digg This!

I just couldn’t wait any longer, and decided to try something with ZFS. And what do you know? I’ve found a very useful advice from Ben Rockwood, which allows us use regular files created with mkfile as virtual disks for ZFS. VERY useful, especially when you really want to play with such a great technology [...]
>
Read More... |
Digg This!

When you’re writing a DTrace script, often you’d like to pass some parameter in command line. Such an easy task might be really hard unless you read a docs.sun.com section about DTrace scripting, particularly a section about command line parameters macros.
As with sh or bash, you can access command line parameters via $0..$9 macroses. But [...]
>
Read More... |
Digg This!

Many of you have already heard about Solaris 10 zones - it’s a virtualization technology which allows you to create isolated and secure environments for running applications. For end-users these environments look just like separate abstract machines with Solaris 10 installed on them. Inside each zone, all the processes don’t see anything happening in all [...]
>
Read More... |
Digg This!

Many of you have already heard about Solaris 10 zones – it’s a virtualization technology which allows you to create isolated and secure environments for running applications. For end-users these environments look just like separate abstract machines with Solaris 10 installed on them. Inside each zone, all the processes don’t see anything happening in all [...]
>
Read More... |
Digg This!

Quite often it is more important for you to see the whole picture, rather than to know each case when a particular probe fires. For instance, observing a process which consumes a lot of CPU time according to prstat, we ask ourselves: what is this process doing? And often we think about the overall number [...]
>
Read More... |
Digg This!

Macro variables are meant to make your life MUCH easier when scripting with DTrace. Names of such variables must begin with a $ sign, and DTrace will automatically replace all the macro variables with the appropriate values when parsing your script.
Full list of macro variables can be found here, I will only talk about $target [...]
>
Read More... |
Digg This!

One of the most useful (for me) options in DTrace is flowindent. All it does is indent the entry to each function with “->”, and mark the return from this function with “<-”. Doesn’t seem like much, does it? But just look at the results!
The following example catches all the probes of the fbt provided. [...]
>
Read More... |
Digg This!