Doth quoth the DaveM

Solaris Companion IPS repository

Tuesday Sep 23, 2008

I previously blogged about getting NMH from the Solaris Companion web site. I went to the web site again and read further down the page and noticed there was a IPS repository. This is easier for OpenSolaris than downloading a package and then adding it. Here are the steps I followed to install gnuplot:

pfexec pkg set-authority -O http://pkg.sunfreeware.com:9000/ sunfreeware.com
pfexec pkg refresh
pfexec pkg install IPSFWgplot
    

Works great.

Like this post? del.icio.us | furl | slashdot | technorati | digg

Sound in OpenSolaris on VMware

Monday Sep 22, 2008

One of the things missing when you install OpenSolaris in a VMware virtual machine is audio. Apparently the driver for the audio device that VMware emulates isn't redistributable, so it isn't included as part of OpenSolaris.

To solve this, I grabbed a copy of the Open Sound System drivers package and followed the installation instructions. After a reboot, I had sound.

Like this post? del.icio.us | furl | slashdot | technorati | digg

Another way to get OpenSolaris BE names with build numbers

Monday Sep 22, 2008

Last week I blogged about OpenSolaris BE and build names. Another way to accomplish this is on your next image update. Create an OpenSolaris boot environment, mount it, update it, unmount it, and activate it. This is steps 4 through 9 of Updating Your System to OpenSolaris Development Builds.

Like this post? del.icio.us | furl | slashdot | technorati | digg

Got NMH from Solaris Companion CD project

Friday Sep 19, 2008

Yesterday I mentioned that I needed to install MH or NMH on my home OpenSolaris virtual machine. I took at look at the Sunfreeware site and discovered NMH is part of the Sun Companion CD Project. I grabbed the Solaris package from there and installed it with pkgadd. Nice and quick, works great.

Like this post? del.icio.us | furl | slashdot | technorati | digg

Updated to build 98

Friday Sep 19, 2008

I updated my laptop running OpenSolaris from build 97 to build 98 yesterday. No issues at all. Gotta go update at home too.

Like this post? del.icio.us | furl | slashdot | technorati | digg

Migrated home virtual machine to OpenSolaris

Thursday Sep 18, 2008

Last night I finally threw the switch and migrated my main virtual machine at home from Solaris Express snv_79 to OpenSolaris. Well, actually, I finally had the new OpenSolaris virtual machine ready and the data migrated so I could power off the Solaris Express virtual machine.

I still have a few missing pieces left to deal with. First, I need to get tkbiff installed. I also need MH or NMH. I've used MH and later NMH on and off for many years. It provides command line tools to scan folders, send mail, sort mail, burst digests, and more. Now I use Gnus within XEmacs, but I'm on one mailing list that only comes in digest form, and I used the MH burst command to break the digests apart into single e-mail messages. I also occasionally use the MH scan command to quickly scan a folder for an item of interest, particularly if I don't have XEmacs running. It's much quicker to run scan than to start XEmacs and then Gnus within XEmacs.

The other item of interest is that I'm finally migrating away from fvwm2 with fvwm-themes to GNOME. I started using GNOME a few months ago when Sun gave me a laptop and told me to run OpenSolaris. I've grown to like it well enough, though I miss a few of fvwm's capabilities. But now my work and home environments will be more similar, and that's more efficient for me. I've gotten more used to the GNOME mouse clicks and have found they just don't work with my FVWM setup! :)

Like this post? del.icio.us | furl | slashdot | technorati | digg

OpenSolaris BE names equivalent to build numbers

Thursday Sep 18, 2008

I recently read a thread on one of the OpenSolaris mailing lists about how BE (boot environment) names don't reflect anything about the OpenSolaris build it contains. It occurred to me that since pkg image-update finds a BE named opensolaris-N and then creates a new BE named opensolaris-N+1, you could rename your current BE opensolaris-buildnumber and pkg image-update would "just do it". This only works if you upgrade at every build. If you don't, the number gets off, but you can fix that by renaming BEs or by creating BEs for the missing builds with the appropriate names.

Having done all this, my system shows this for BEs:

BE             Active Mountpoint Space  Policy Created          
--             ------ ---------- -----  ------ -------          
opensolaris-96 -      -          37.92M static 2008-09-05 10:14 
opensolaris-97 -      -          18.31M static 2008-09-11 15:59 
opensolaris-98 NR     /          13.78G static 2008-09-18 11:36 
    

[2] Comments
Like this post? del.icio.us | furl | slashdot | technorati | digg

Oops!

Wednesday Aug 27, 2008

Some weeks back, my manager gave me a HP Compaq 8510p laptop to use, on condition that I install OpenSolaris, use it, and report problems. Sounded good to me, so I grabbed it.

Over the past several weeks, I've gotten OpenSolaris and various tools I use installed and working nicely, and was pretty productive on the laptop. I figured out how to hook up and use the 24.1 inch monitor here at work[1], figured out how to customize the system using NWAM (NetWork Auto-Magic). Everything was going good.

I turned on my laptop on Sunday, and it gave me a grub> prompt. Oh oh. GRUB couldn't see anything. I thought maybe the laptop had taken a hard knock on a trip to downtown Austin on Saturday morning. Even scarier, I tried to recover using an OpenSolaris 2008.05 LiveCD I had around, but it gave me errors. At first I thought the errors were something seriously wrong with the system, but on closer inspection, noticed it was complaining about a bad sector on the CD. So I burned another CD, and it started fine. The OpenSolaris from the new copy of the LiveCD could see the partitions, but it couldn't access the ZFS pool on hard disk. At this point, I gave up and re-installed OpenSolaris 2008.05 from the CD. That went fine.

But during the install, I recalled that I had seen this when looking at the ZFS pool using zpool status on Friday:

  pool: rpool
 state: ONLINE
status: The pool is formatted using an older on-disk format.  The pool can
	still be used, but some features are unavailable.
action: Upgrade the pool using 'zpool upgrade'.  Once this is done, the
	pool will no longer be accessible on older software versions.
 scrub: none requested
config:

	NAME        STATE     READ WRITE CKSUM
	rpool       ONLINE       0     0     0
	  c5t0d0s0  ONLINE       0     0     0

errors: No known data errors
    

I had gone ahead and upgraded rpool. Hmm, could this be it? I then recalled reading something on some OpenSolaris e-mail list about this, where GRUB couldn't read the latest ZFS format, or if it could, you needed to update GRUB on the disk. There's an e-mail thread that discusses this. It turns out I *might* have been able to recover, had I had a nv94 or higher CD

So the moral of that story is to make sure you know what you're doing before upgrading a root ZFS pool. Also, make backups of system configuration information and scripts!

After I installed, I knew I'd need a few things to be productive:

  • Sun Studio Express
  • OpenOffice
  • Punchin
  • XEmacs
  • tkbiff
  • NWAM scripts

Sun Studio Express and OpenOffice were easy to get, I just grabbed them using from the IPS repository by using pkg install .... Punchin was a chicken and egg problem, in that I had to get punched in to get the packages. Fortunately, I have a Solaris Express VMware virtual machine on my home PC, and used that to punchin and grab the packages, then used scp to copy the packages and credentials to the laptop.

tkbiff was trivial. XEmacs was a bit more involved, though I was surprised how little it took to get it built and working. Turns out I remembered a few things from the first time around. I wanted to use the old X Athena widgets, but the header files disappeared from OpenSolaris several builds ago. But IPS lets you install old versions of packages, so I figured out which package and the version I needed and installed it.

NWAM has been more interesting, and is one area where I really wish I'd saved a backup copy of the scripts. Grr. You can write a script that NWAM invokes when there's a change in the system's network interfaces, and from that you can return a name. NWAM invokes bringup and teardown scripts associated with that name. So my typical way of working is wireless at home and wired at work. When I'm at work, I use NIS, at home, I don't. Sadly, I'm still working on getting these right, and when I do, I'll write up another blog entry about them.


Footnotes:

[1] If the monitor is connected and plugged in when Xorg starts, it just works, but it drivers the laptop display at 1920x1200, which the laptop doesn't support. So I use xrandr --output LVDS --off to make it work.

Like this post? del.icio.us | furl | slashdot | technorati | digg

First VirtualBox experience

Wednesday Feb 13, 2008

Yesterday we at Sun announced we are acquiring Innotek and their VirtualBox software. As someone who runs OpenSolaris in a VMware virtual machine on my home PC, I decided to give VirtualBox a try.

As other reviewers have mentioned, the installation package for Windows is quite small, around thirty megabytes or so (yes, I remember when that would be considered large). It installed easily and I was able to start it up and create a new virtual machine to install Solaris in very little time. The virtual machine wizard allows you to select machines for many operating systems, more than VMware.

I then tried installing Solaris Nevada 79a, a preview version of the latest SXDE release. I got to the nice install GUI, it started installing, but somewhere along the line decided it couldn't read the rest of the yet-to-be-installed packages from the DVD. Weird. I didn't try it again, as I had other things to do, but up to that point it was pretty smooth. To be fair, I'm not convinced this is a VirtualBox problem at this point, as I had problems with installs of Solaris Nevada 79 on VMware.

The other thing I found difficult to figure out was how to get 1280x1024 screen resolution. It appears to default to 1024x768 or even smaller, and VirtualBox complained about the 24 bit color depth and suggested I use 32, 16, 8 or 1. It seemed to work anyway, though.

At some point I'll try the install again and give a bit more detail about the various warning and error messages. So far VirtualBox seems okay, but I'm not going to abandon VMware for my personal use at this point.

[2] Comments
Like this post? del.icio.us | furl | slashdot | technorati | digg

SXDE.next

Wednesday Jan 23, 2008

I've been running Solaris 10 in a VMware virtual machine for several months. This has worked pretty well, and somewhere along the line VMware decided to support the VMware Tools with Solaris 10.

A few months back, Solaris management asked us engineers to test an early, internal version of the next Solaris Express Developer's Edition (SXDE), snv_79. I attempted to install this in a new virtual machine. The installer didn't work in that it failed to partition the disk. On a Sun internal mailing list I heard this has something to do with the disk driver, but that you could install from text installer. Okay, I did that and it worked fine. One other problem is that the VMware Tools don't seem to install correctly, but that's not such a big deal. One final issue I had was getting the hostname set correctly. I set the system up to use DHCP, and I tried various ideas I found in Sun's documentation and on the web, and finally remembered the trick is to put the hostname in /etc/nodename. This was very frustrating. I'll need to write this down, as I must have done this on the Solaris 10 machine earlier.

Last week we were asked to test the respin of the next SXDE, snv_79a. I created another virtual machine and this one installed as advertised. VMware Tools don't install right here either. The installer also set up /etc/nodename, so I didn't have to remember to do that. Very nice! It appears from the internal survey we were asked to fill out that snv_79b is in the works so we have a little more time to go before the next SXDE is released.

For the issue of VMware Tools, VMware open sourced some or all of the tools (I'm not sure) a few months back, so I suppose I could figure this out at some point if I ever care about it. Or just wait and keep trying occasionally until the tools install correctly.

Like this post? del.icio.us | furl | slashdot | technorati | digg

Strange interaction of VNC and ssh on recent Nevada build

Friday Nov 02, 2007

I recently started using Solaris Nevada (first build 75 and now build 76) rather than Solaris 10 Update 4 on my Ultra-45 at work. I usually have a VNC session to which I connect from home and occasionally from work. But since I converted to using Nevada I've occasionally had xscreensaver tell me that it can't open the display. This makes it impossible to unlock the display and I have to go either kill the VNC server or just kill xscreensaver.

This morning when this happened it finally dawned on me to check my Xauthority file. For some reason I checked the XAUTHORITY environment variable and much to my surprise it pointed to a file in /tmp that didn't exist. Example:

$ echo $XAUTHORITY
/tmp/ssh-xauth-_Raqkq/xauthfile
$ ls -l /tmp/ssh-xauth-_Raqkq/xauthfile
ls: /tmp/ssh-xauth-_Raqkq/xauthfile: No such file or directory
    

Huh, go figure. I realized at this point that I had connected to my work system from my home system using ssh with X forwarding. It appears that at some point the Nevada sshd was changed to use a temporary file for XAUTHORITY, and this change hasn't made it back to S10.

Now I start my VNC sessions by ssh without X forwarding or directly from my desktop X session, where XAUTHORITY is not set. I should probably do something with the env command to set up a known environment, but for now this works.

Like this post? del.icio.us | furl | slashdot | technorati | digg