Thursday, February 11, 2010

Kontact + LDAP lookup + Lotus Notes

In bucking the company policy to use Lotus Notes, I find myself in a precarious situation where I run into problems and there's nobody I can ask for help. In this particular instance, even the combined knowledge of the internet failed me, mostly due to the terrible state of documentation for the Kontact project.

Herein, I provide the technique I used to get the Compose Message window to prepopulate to/cc/bcc fields with data from a Notes LDAP server.

First, be sure you know your authentication information for Notes LDAP. I'm using a concatenation of CN and O, but you may be able to get away with just using login and password.

From Kontact, select Contacts.
In the Address Books panel, select + (to add a new address book)
Name the Resource Configuration something like "Notes LDAP"
For Bind DN, use your DN. Mine is "CN=Richard C Schreiber, o=RSA
For Password, use your notes password
For Host, use the hostname or IP address for the Notes server
For Sub-Tree query, check it.
For Read-Only, check it.

You should see the list of contacts populate from the Notes server. If you don't, an alternate login token.

Make sure the newly created address book is checked.

Next, compose a new message and type a few letters into the address field and you should see the names populate from your LDAP server.

I played with this for days before it magically started working. There may be a Notes authentication problem where it appears that your configuration is not working correctly, but really that Notes is just ignoring your requests.

Monday, January 18, 2010

Bathroom progress

Today the vanity, countertop and medicine cabinets were delivered. I posted that this means that the heat is on, to which a few of my Facebook friends replied requesting photos. Here they are!

Sunday, January 17, 2010

My new favorite cinnamon bun recipe.

Made these last night and they are outstanding! (If I do say so myself). Capturing the recipe in case it disappears.

http://baking.about.com/od/sweetrolls/r/ultimtecinnroll.htm

Ultimate Cinnamon Roll with Vanilla Frosting

Ingredients
•1-1/2 packages (about 3-1/4 teaspoons) dry yeast
•1/4 cup warm water
•1/2 cup shortening
•1/3 cup sugar
•1-1/2 teaspoon salt
•1 cup milk
•1 egg
•4 to 5 cups sifted flour
•melted butter
•brown sugar
•cinnamon
•raisins (optional)

Vanilla Frosting
•2 cups powdered sugar
•1 tablespoon butter, melted
•1 teaspoon vanilla
•milk or cream (2 to 4 tablespoons)

Preparation:
Add the warm water to the yeast and soak 10 minutes.
Scald milk; pour over the shortening. Add sugar and salt and cool to tepid. Add the dissolved yeast and beaten egg. Add 4 cups flour adding one at a time beating after each addition.

Dough should be soft yet firm enough to handle. Knead on floured board until elastic and smooth. Avoid too much flour. Turn dough into well oiled bowl. Let rise for 1-1/2 hours.

Press dough down and divide into workable size. Roll dough out into a rectangle. Cover with melted butter. Layer with a generous thick layer* of brown sugar. Sprinkle on cinnamon* as desired. If you like raisins, layer on a layer of raisins. Roll up jellyroll fashion.

Using a scissors or a piece of string, cut off slices about 1 to 1-1/2 inches thick. Place slices in an 8 or 9 inch round greased cake pan. Place one slice in the middle and other slices around it. Press rolls down to even out and fill pan. Let rise until rolls fill the pan generously...about another hour.

Bake in a 350 degree F oven about 15 - 20 minutes. If rolls get too brown, cover with a piece of tine foil until the end of baking. Do not over bake rolls.

Remove immediately from pan by inverting onto a plate and then tip over onto another plate to right the rolls.

For the Frosting:
In a medium bowl, place sugar, butter and vanilla. Then stir in enough milk or cream to reach a thick, hardly-able to stir consistency.

Spread over warm rolls as soon as they are placed on a plate to let the frosting melt and run into the rolls.

* I was pretty generous with both the brown sugar and cinnamon. I ended up with about a 1/2 inch layer of brown sugar completely covered with cinnamon. - Carroll

Wednesday, November 25, 2009

"no resources found, item cannot be added"

I kept getting this message from kmail or kpim or kontact or whatever you want to call it when I tried to create a calendar entry or to-do item. I thought it had to do with creating a new identity which I had done earlier.

Found out it was caused because my "Default Calendar" in my calendar list was unchecked. Once I checked the "Default Calendar" entry, all the errors stopped.

THIS IS EXACTLY WHY I'm a big proponent of actionable dialog messages. By itself, this message means nothing to an average user. Add to it "ensure that your local calendar is active" and it would have taken me like 2 seconds to fix it and I wouldn't have had to post a blog.

Thursday, November 12, 2009

Windows XP x64 and Kubuntu dual boot... Remove kubuntu and prepare for pain

So I've been using Windows XP x64 and Kubuntu side by side for a while but I was sick of dual booting. So I installed Sun's VirtualBox and installed Kubuntu there. Now I don't have to reboot the PC to run Linux when I have to do Linux'y things.

Yesterday I decided to remove the Kubuntu partitions and reclaim the disk space for Windows (since I had 1g left). So I remove the partitions and reboot.

I was faced with a Grub error 22 screen and I couldn't proceed. Seems that /boot was a directory off of / and / didn't exist anymore. So Grub had no configuration data to go on.

Ohh, I remember, I thought. I'll just rewrite my MBR and that'll get rid of Grub. So I boot to the Windows XP x64 recovery console and issue the command fixmbr. Then reboot and no change - still Grub error 22.

Hmm, maybe I didn't save? Maybe I need fixboot? Maybe fixmbr then fixboot? Maybe fixboot then fixmbr? Maybe I need to specify the disk to fixmbr? Maybe I need to specify the partition? Maybe I need to specify the disk and partition? Maybe X64 doesn't use the MBR? Maybe it's a GUID thing? Maybe I'm going insane? None of it worked.

After 6 hours I was ready to simply reinstall Windows but then I thought, maybe if I reinstall Kubuntu, Grub will fix itself? So I reinstall Kubuntu, reboot and behold, a valid Grub screen with a choice to go to Windows XP that worked!

For what it's worth, I manually partitioned, creating a 1g /boot, 1 10g / and a 2g swap. So hopefully, I can reclaim the 10g and 2g, leaving Grub on /boot and configuring Grub to automatically boot to Windows XP.

Wednesday, November 4, 2009

Bash variable assigment modifiers

I always seem to forget this about bash variable assignment shortcuts and always have a hard time finding it.

Rather than:

if [ "" = "$var" ]; then
$var=hello
fi

Use
var=${var:-hello}

Conversely, rather than:
if [ "" != "$var" ]; then
$var=hello
fi

Use
var=${var:+hello}

There's also:
if [ "" = "$var" ]; then
echo "Error, variable var must be set"
else
b=$var
fi

And:
b=${var:?Error, variable var must be set}


There are others too, but I find these ones most useful. Check bash man page for full set.

Wednesday, October 14, 2009

More Progress On Bathroom

In this week's edition, we see more destruction and some progress on new drains and supplies to the third floor bathroom.