Use Google to find mp3’s

One of the best methods I’ve found to get hard to find music is google. Now I do buy a shit load of cd’s, but some of the stuff I like just isn’t available any more and is pre cd.. I’m talking old tape here.. so anyway this is the google string I use;

intitle:index.of +”last modified” +”parent directory” +(mp3|wma|ogg) +”Song Name Goes Here” -htm -html -php -asp

WTF Java!

Okay so this morning I log into one of our terminal servers to update the Java Virtual Machine and I get greeted with this;

Now I know we’re in a global market melt down and all that rubbish but seriously I think this is going a bit far don’t you. Australia gets the boot but I bet Saudi Arabia is cool. Given my close affinity with Sun I’ve taken this quite personally, so I think I will go kick a Sun Ray while I wait for the apprentice at Sun to fix it.

Gnome Quick Launch in Solaris

Saw this asked on IRC today, seemed like an easy one but apparently not very evident. The Gnome “start menu” if you will, in a default Solaris installation contains some quick launch links, whose right contextual menu doesn’t provide for a way of removing them.

Each of these contain a entry in their /usr/share/applications desktop file that looks like;

Categories=Application;Office;X-Sun-Quick-Start;X-Sun-Supported;

it’s the entry of X-Sun-Quick-Start that causes these applications to appear on the top level of the start menu structure, simply removing this entry from the categories line will stop them appearing.

Maybe an option to delete these from within the menu preferences would have been a nice idea in hindsight.

Big Week…

So it’s been a pretty full on week this week, both at work and at home.

First off my lovely wife decided to buy a new fridge, my wallet screams out in pain. Cause of course it can’t be a small thing, no she goes for the 4 french door stainless model. Oh well, maybe when it comes time for a new tv in the lounge she won’t complain too loudly when I buy a 46? Sony XBR Bravia.

So then on Tuesday my sister (biologically my cousin, but cause she lived with us growing up I call her my sister.) Rebecca flies into town. Now Rebecca is 9 years older then me, and joined the Navy at 17. This year she’s served 23 years in the Royal Australian Navy and is currently a Chief.

I have really enjoyed seeing Bec, it’s been 13 years since we last got togeather, and my wife had never met her. This is what happens when you only spend 3 weeks a year in Australia and the rest at sea I guess. I almost envy her, as a child it was always my dream to follow in her and my brothers foot steps and join the Navy as well.

She’s looking pretty good for 39 I’d say.. and my daughter Dana immediately knew she was family and got most upset if Bec put her down. I just wish I got that side of the families genes.

Moving onto Wednesday at work we get our new workplace health and safety manager, the verdict is still out as to weather or not we will start a betting pool on this one. George seems like a nice enough bloke, don’t know if he is Langs stuff yet, but he might supprise me.

He is however doing better then the last person, who we started a pool on immediately as all my staff could tell they weren’t staying long. Indeed they only lasted 9 weeks, I was a bit off I only gave them 3 weeks.

Added to this one of my developers has been tossing up what to do, they have come to the conclusion they hate coding and don’t know what to do. I can sympathise as IT is not a very static friendly occupation, no matter what segment your in. However I feel he is clouding the issue, he tells me he doesn’t like the stresses coding causes him at home and the fact he takes work home.

I take on this is, no matter what you do in IT the project will always follow you home, and the fact by it’s very nature it changes constanly means you are always working or learning in your own time just to keep ahead. I don’t think he or his other half understand this and it is causing them personal relationship issues.

What he hates is fighting with the missus, and that’s understandable, however I don’t wish him to confuse the two issues. At any rate I have resolved myself to the fact I am looking for a new developer next week. I think this has been comming awhile and the fact his missus is only 3 weeks from completing her masters and has a confirmed job, he no longer needs to work.

I am having him document everything he is on at the moment and will take it from there. I would be very supprised if tomorrow he doesn’t resign.

Friday I’m at home chilling after a busy week, and Nitty falls on slashes her elbow open, and I mean well open.. bits of her insides are hanging out and I start to feel faint, cover that shit up.

After 20 minutes in the emergency room they give her a tetnus injection and then it’s 4 bloodly hours till they manage to put 6 stiches in it.. damn it there goes my Friday night.

Saturday I head down to JB hi fi and finnaly get a Asus EEE PC, not the 901 running linux as I had hoped, but due to shitty supplies and now ETA’s I cbf waiting any longer and Langs buys me a 1000H. In fact I’m using it now. Very cool, they are just so portable thy can be used any where, and so far the battery life is awesome.

Gotta head need to be in Sunwell in an hour and have to take a shower an all that, here’s a pic of my oscars since they are growing up so fast.

Untar all archives in directory

I spotted someone today manually untaring about 45 archives in a single directory this morning and when I asked why they told me they didn’t know any better. So like I showed them, I am posting it here as well;

for a in `ls -1 *.tar.gz`; do tar -zxvf $a; done

This will list all files in the directory ending in tar.gz then run them through the tar utility to extract them, note this is for the bash shell.

ZiPhone to unlock iPhones

As some of you know my wife has been using a Apple iPhone since last December, and as such I have belong the resident iPhone unlocker for all and sundry that needs it done. Just this week I have done six for various relatives of the boss.

Normally this is an annoying and manual task as laid out by http://iphone.unlock.no/ but this morning I found out about a just released tool called ZiPhone. It’s available for OSX and Windows platforms and I must say unlocking, activating and installing apps has never been easier, it is literally a 3 minute process now and takes out all the guess work any idiot could unlock a iPhone now.

Get it now from http://www.ziphone.org/.

** Quick note I’ve noticed Ziphone uses older sources, so the first thing you need to do in the installer is reinstall “community sources” so you are able to install packages other wise you will get a “failing to download package” message.

Functional spec definitions

Functional specifications are not technical specifications. Seems people get these two confused as being one and the same. While I am not aware of any universally textbook definitions for the two I hold the following to be true;

1. A functional specification describes how a product will work entirely from the user’s perspective. It doesn’t care how the thing is implemented. It talks about features. It specifies screens, menus, dialogs, and so on.

2. A technical specification describes the internal implementation of the program. It talks about data structures, relational database models, choice of programming languages and tools, algorithms, etc.

Zimbra Outlook Connector

With Zimbra versions before 5.0.3 whenever you do a system upgrade and hence and upgrade of the Zimbra outlook connector it would create a new outlook profile and clobber the autocomplete type settings.

So to combat this backup the following file;

c:\documents & settings\$username\application data\microsoft\outlook\$profilename.nk2

Zimbra Backup

A mate of mine has started to use the OSS version of Zimbra, and asked me how to best back it up this morning as the OSS version misses out on the backup/restore functions of the NE version.

So what follows is my recommendation, I’m sure others are all ready doing it this way so certainly not something new;

Stop Zimbra using “zmcontrol stop” and check it has ended with “zmcontrol status” as the “zimbra” user.

I have a kill all user processes script I like to run as well just to be sure everything has stopped;

#!/bin/bash
USER=$1
MYNAME=`basename $0`
if [ ! -n “$USER” ]
then
echo “Usage: $MYNAME username” >&2
exit 1
elif ! grep “^$USER:” /etc/passwd >/dev/null
then
echo “User $USER does not exist!” >&2
exit 2
fi
while [ `ps -ef | grep “^$USER” | wc -l` -gt 0 ]
do
PIDS=`ps -ef | grep “^$USER” | awk ‘{print $2}’`
echo “Killing ” `echo $PIDS | wc -w` ” processes for user $USER.”
for PID in $PIDS
do
kill -9 $PID 2>&1 >/dev/null
done
done
echo “User $USER has 0 processes still running.”

script usage is simply ./killuser $username, the script will then systematically nuke all processes belonging to that user. First used to free up server resources when I was working as an operator and needed more cpu cycles to speed my tasks up 🙂

right so next run;

1. “rsync -ra /opt/zimbra /backup –progress”
2. “tar -zcvf /tmp/zimbra.backup.tgz -C /backup”
3. “ncftpput -u $username -p $password $server /zimbrabackups /tmp/zimbra.backup.tgz”

make sure your ftp server has space, as my backups run at about 300 – 400 GB.

This is a CRON Job script I use by the way to automate the process;

#!/bin/bash

# Zimbra Backup Script
# Requires ncftp to run
# This script is intended to run from the crontab as root
# Free to use and free of any warranty!

# Live sync before stopping Zimbra to minimize sync time with the services down
# Comment out the following line if you want to try single cold-sync only
rsync -avHK –delete /opt/zimbra/ /backup/zimbra

# which is the same as: /opt/zimbra /backup
# Including –delete option gets rid of files in the dest folder that don’t exist at the src
# this prevents logfile/extraneous bloat from building up overtime.

# Stop Zimbra Services
sudo -u zimbra /opt/zimbra/bin/zmcontrol stop
sleep 20

# Sync to backup directory
rsync -avHK –delete /opt/zimbra/ /backup/zimbra

# Restart Zimbra Services
sudo -u zimbra /opt/zimbra/bin/zmcontrol start

# Create a txt file in the backup directory that’ll contain the current Zimbra
# server version. Handy for knowing what version of Zimbra a backup can be restored to.
sudo -u zimbra zmcontrol -v > /backup/zimbra/conf/zimbra_version.txt
# or examine your /opt/zimbra/.install_history

# Create archive of backed-up directory for offsite transfer
# cd /backup/zimbra
tar -zcvf /tmp/zimbra.backup.tgz -C /backup/zimbra .

# Transfer file to backup server
ncftpput -u $username -p $password server /zimbrabackups /tmp/zimbra.backup.tgz

Snippets about SRSS

Just a few notes about SRSS and CAM so I don’t keep forgetting;

  • To increase the number of default CAM users from 25 run /opt/SUNWbb/bin/bbmkuser -m utcu 150000 75 (or the number of desired users)
  • Increase Worker threads from 8 to 24 in /etc/opt/SUNWut/auth.props
  • utdesktop -e “TokenID, Name, Location”
  • utxconfig -t TokenID -r “Resolution”