Archive for May 23rd, 2009

Rule Of Thumb

Saturday, May 23rd, 2009

We use email as part of the monitoring solutions at work. There are always a few dozen alerts issued during the working day (sometime considerably more if we have a problem…..or sometimes just a problem with the monitoring system itself :o)

To keep some sot of order on my inbox, I have created sets of rules that either move, delete or do some other action with msgs that are pushed onto me. During the working day this is all automatic and working fine.

However, out of hours presents a slight issue. we use Blackberry devices to stay in touch with our email boxes during the evenings so that we receive the email alerts from the monitoring system. A Blackberry enterprise server (BES) sits adjacent to the exchange server and watches the inbox of certain people. If a new message hits the inbox, the BES will push a copy of the email out to the blackberry mobile device. But here’s the problem, if my rules are left running active, the messages get sorted before they actually hit the inbox…….so the BES never sees them and I don’t get a copy sent to me :o(

The work around for this is pretty simple, I just deactive my rules when I leave the office at night. This does sometimes however result in my arriving to an inbox *full* with unsorted alert messages. To clear my inbox down, I have to manually run my rule sets aginst my inbox, and for the number of rules I have that’s a lot of clicking for first thing in the morning.

So I thought I would have a look at automating this task with the built in office visual basic. My first stumbling block here is pretty big. I am not a programmer/coder by any stretch of the imagination. All other office applications will allow you to get the bones of a macro down by recording your actions in the application. The vba editor then presents you with the code for the actions you just carried out, and you can flesh the code out a bit to make it more slightly more generic and vastly more useful.

Outlook does not have this recording feature :o( so, you have to start pretty much from a blank slate. The office installed help file are however incredibly useful and concicse and following them I was able lash the following together

Sub runrules()
Dim colRules As Outlook.Rules
Dim oRule As Outlook.Rule
Dim oInbox As Outlook.Folder
Set oInbox = Application.Session.GetDefaultFolder(olFolderInbox)
Set colRules = Application.Session.DefaultStore.GetRules
For Each oRule In colRules
oRule.Execute showprogress:=True
Next
End Sub

It’s pretty short, not terribly verbose and contains no error checking, but it does do the trick (it was more verbose while I was working it out, I had msgboxes popping at various stages informing me what certain objects and their values were)

I think I’m gonna share this with my boss as he has even more inbox mail rules than I do :oO

Score those brownie points !

Home NAS To The Rescue

Saturday, May 23rd, 2009

My 500gb lacie external mac mini storage unit decided it was no longer going to work :o(

The fault seemed to be with the bus interface of the casing, rather than the drive itself. The drive is a bulk standard ide drive which gets converted to a usb port connection on the outside of the case via an internal cross connector.

First off I tried connecting the device to a PC instead of the Mac to see if anything could be seen/salvaged at all (the Mac mini’s role is an mp3 file repository for the Sonos wireless hi-fi units around the home……no Mac mini = no music !! gaaaaaaahhhhhhh :o(

I opened the case and extracted the physical drive and connected it to a PC using a standard ide cable. The PC recognised the drive no problem, but clearly Windows does not understand the Mac OSX file system without some help.

Luckily, macdrive to the rescue. Once installed I could read all files on the mac volume and was able to copy them across to a more reliable drive.

Next step was to provide new storage. Almost losing 10 years worth of music collecting was quite a panic, so I wanted the new solution to provide some piece of mind. enter the Qnap TS209 Pro II nas server.

ts-209 pro ii

The device costs just under £230 from scan.co.uk without drives. Offically Qnap only support the device with 1tb drives fitted, but I have seen reports of people running them with 1.5TB drives (probably 2TB drives by now !). A pair of 1tb seagate drives cost £63 each so the whole thing came in for under £400.

The device is small enough to fit into the little cupboard next to my media unit and runs almost silent, even during write operations. The device is powered by a marvell cpu running at 500Mhz and configuration is managed by a well designed web interface.

Embedded applications include ftp server, web server, mysql database server and more, although I don’t need any of these as I just need somewhere to dump files. Having x2 drives the configuration options are either RAID 0 striping across the x2, which will improve read/write performance, but provides no resiliency, or RAID 1 mirroring which halves the total storage capacity but provides piece of mind.

The initial setup requires a direct ethernet connection from a PC/Mac directly into the units ethernet port. Once you have assigned the device a tcp/ip address you can connect it to the network and finish the setup.

You have the option to select either NTFS, FAT and EXT3 filesystems so you can use it with both PC and Mac/Linux/Unix systems. My only gripe with it would be the pre-configured shares defined on the system. There are shares such as Qdownload, Qweb, Qusb etc. etc. (you get the idea) that you cannot remove. You can however mark the shares as hidden so they don’t show up on the network so this is not a major show stopper.

Performance seems ok. The device has been handling simultaneous read/write requests from me, my flatmate, a visiting friend, a x3 sonos wi-fi players without any blips or stutters. All in all, money well spent and I sleep much better at night knowing my data is duplicated.