Sharing iCal Calendars

August 25th, 2010

From the day our household obtained more than one Macintosh computer, the problem of sharing calendars between multiple macs and multiple users of the macs have plagued me. How do I make my calendar visible to my wife? How can I see her calendar? iCal has always had the ability to publish calendars on the net, and so that’s what we’ve done. At first we published to my work’s WebDAV server. Then when that went away we found the site, www.icalx.com. Users can publish and exchange calendars via the site. We used that for several years. However, I was uncomfortable with the idea of storing my schedule on a public server on the internet. I wanted to setup my own calendar server.

A bit of googling led me to this site: Sebastian Mogilowskis Blog with step by step instructions on how to set it up.

The above link allows one to setup a single directory where all calendars will be stored. I wanted each user to have their own directory, and also have a public and private calendar areas. The solution is simple.

In the apache configuration add the following directive to the VirtualHost section for the calendar web server

<directory /path/to/calendar/dir/*>
AllowOverride AuthConfig Limit
</directory>

Then instead of inserting the “Auth*” directives in the <location> block of the web server config file for the calendar server, you can put it in the .htaccess file found in each user’s calendar directory. For example my calendar directory is: /path/to/calendar/dir/edsel
I would place a .htaccess file in there with the following contents:

AuthName "Calendar"
AuthType Basic
AuthUserFile "/path/to/htpasswd/file"
<limit GET PUT>
require valid-user
</limit>

This makes the calendars stored in /path/to/calendar/dir/edsel available to all users in my htpasswd file, effectively making it publicly available to authorized users of my system.
Then I create a /path/to/calendar/dir/edsel/private with the following .htaccess file:

AuthName "Calendar"
AuthType Basic
AuthUserFile "/path/to/htpasswd/file"
<limit GET PUT>
require user edsel
</limit>

That makes the private directory only accessible to the user ‘edsel’ which is me.

Other users can have a similar directory structure and .htaccess configuration. By ensuring that the .htaccess file in the private directory only lists the owner of that directory, we ensure that its contents remain private.

Now I can host my own calendar sharing site.

This solution is fine and dandy until you begin to have the need to modify other users’ calendars. For example, my wife may want to add our date on Wednesday night to my calendar. With this setup it isn’t possible, since iCal only gives you read-only access to calendars you subscribe to over the network.

Maybe I’ll try Apple’s calendar server soon to see if it has that additional capability… Stay tuned.

-- Posted in Geeks Paradise

iscsi and LDOMs

August 18th, 2010

This post should be filed in the “don’t do this at home” category.

So I have a server running Solaris 10 x86 release 10/09. I decided to play with the iSCSI implementation on this Solaris release. Note that this is the native Solaris 10 iSCSI target implementation, not the OpenSolaris COMSTAR iSCSI implementation.

First off, this implementation of iSCSI target runs in userland (as opposed to the in-kernel implementation of COMSTAR).

I also have a T series machines with LDOMs. Wouldn’t it be great if I can setup LDOMs on the T series system to boot from my iSCSI server? It would be a poor man’s SAN boot.

So I did all the necessary setup required. I created the iSCSI target volumes backed by ZFS volumes on the storage server and enabled the iscsi initiator on the T series primary domain so that the iSCSI targets are accessible. I can now access the iSCSI targets as local disks on the primary domain of the T series machine.

I created the guest LDOM on the T series machine, then proceeded to create the necessary vds-devs and vdisks on the T series so that the iSCSI targets will be visible to the guest LDOM. All is well.

The guest LDOM sees its disks. Solaris install went perfectly well on the guest LDOM, and the system ran fine for a while. Yes there were performance issues related to the iSCSI target disks since I was running only on a Gigabit network with no Jumbo frames support and I’m using the standard Solaris 10 iSCSI implementation (which is plagued with performance issues). But in general the guest LDOM ran OK.

Then something happened on the iSCSI server which needed it to be rebooted. I rebooted the iSCSI server without shutting down the guest LDOM that uses the iSCSI target as a boot disk. This proved to be a very bad idea. This resulted in the boot disk (iSCSI volume) getting corrupted that the guest LDOM crashed, and it won’t boot anymore complaining with the following error:


Boot device: disk File and args:
Warning: Fcode sequence resulted in a net stack depth change of 1

The file just loaded does not appear to be executable.

The only way to recover was to re-install the guest LDOM (or restore from backup).

So kids, don’t do this at home. Don’t reboot the iSCSI server without first shutting down the LDOMs that use the iSCSI volumes, or you could risk data corruption.

-- Posted in Geeks Paradise

Apple’s Mail.app Bugs

July 15th, 2010

I’m getting increasingly frustrated with Apple’s Mail.app on OSX. It’s a great mail program but it does have some very annoying bugs. This blog entry will be used as a catalog of the bugs I find with Mail.app.

1. Loses IMAP server connectivity - occasionally a small triangle with an exclamation mark will appear beside some mail boxes. Clicking it will popup a message indicating “the connection to port 993 of the mail server timed out”. Manually connecting to that port on that server from a terminal using telnet works fine, but Mail.app cannot reconnect. The only way to resolve it is to restart Mail.app

2. Cannot delete files sent as attachments - Once you send a file as an attachment, it cannot be deleted without quitting Mail. If the file is on a remote volume mounted from a server, you will not be able to eject the volume until you quit Mail. This can cause problems with the Finder in particular if you are a mobile user and you disconnect from the network where that share is mounted from. Finder can freeze and take long to respond. Work around is quit mail before deleting the file and before ejecting a network volume.

3. Mail.app occasionally loses “sent” emails - I haven’t been able to determine what causes this, or where that lost e-mail goes. The e-mail gets sent, the recipient receives it (I’ve verified this), but the message isn’t in my “outbox” or “On my Mac -> Sent” folder or in the Sent folder on my IMAP server. Yes, I’ve configured Mail.app to store “Sent” messages on the server. This usually works, but in rare occasions, some sent mail does not get stored in the Sent folder.

-- Posted in Geeks Paradise

Beyond Right and Wrong

January 29th, 2010

I have been asked many times by many people the following question: “Is it wrong to do …?”, or “is it right to do …?” I also hear many people say ,”there’s nothing wrong with …” as a defense to something they have done. It’s as if we are trying to draw a fence between right and wrong, and then we try to stay as close to that fence as we can, and if possible we try to push the boundary of that fence farther away to include more and more things and activities that we would like to do. It seems that we are trying to find the minimum requirement that will please our God, and then only trying to accomplish that minimum requirement. We are like a student that is going into an exam with the goal of only making a passing mark. Is this how our relationship with God should be, just accomplishing the bare minimum? On the contrary we are being urged in Matthew 5:48 to be perfect. Our goal shouldn’t simply be to pass the exam, but to gain a perfect score, 100% plus all the extra credit!

Right vs. Wrong? That is not the right question. The question is how close can you get to the ideal of God? Just because an activity is “not wrong” does not make it perfect. If we simply ask ourselves if something is right or wrong, we are short changing ourselves. We are not allowing ourselves to be our best, to achieve that perfection that God so desires. Instead, the question that we need to ask ourselves is whether or not our actions, thoughts or words will more accurately reflect Christ.

-- Posted in Bible, Religion and Philosophy

Integrity

September 26th, 2009

“… our God whom we serve is able to deliver us from the furnace of blazing fire; and He will deliver us out of your hand, O king. But even if He does not… we are not going to serve your gods…” - Daniel 3:17-18.

Are we able to utter such a prayer? Do we really believe that God will deliver us? And are we able to maintain our integrity and faith even if God does not deliver us? Are there times when we let our integrity slip just for the sake of not being singled out as “weird” or “different”? Are there times when we conform to the ways of the world just to accommodate our friends and families?

-- Posted in Bible, Religion and Philosophy