Thursday, October 11, 2007

Zimbra MySql connection using MySql Clients

Zimbra uses MySql database and when you try to connect to mysql under zimbra user with following details, it might throw access errors.

user : zimbra
password : [no password]
host: localhost  ( or wherever you have installed the zimbra)

Also , if you already have your own mysql installed before ,  it might conflict for the mysql clients like CocoaMySQL.  To make it work you need to specify the right socket path. Specify 


Once you specify above socket it exactly knows what mysql db to connect to. You can make this work for phpMyAdmin or any other MySQL clients.

Sunday, September 30, 2007

Setup Zimbra on your home machine to receive emails from your domain

This was a fun exercise to get Zimbra setup on my laptop to receive emails for some domain that I have registered. Fun came in different shape and size (what I really mean is highs and lows of frustration point). So here it goes.
I have a domain e.g. and I wanted to route all the emails sent for this domain to my laptop where I have setup Zimbra. Before you do this few points to remember and work on
  • You need static IP address or publicly available domain so that MX server can point to your static IP or domain.
  • If you have firewall setup at your home, you will have to open couple of ports to make it work.
(You can skip this step if you have static IP address)

I have DSL at home, so the Dynamic IP address and I have to get a static IP so that mails can be routed consistently to the same IP or domain. So find your outside world IP address first , best way to get this go to and it will tell you your IP address seen by the world. Next thing to do is, map your dynamic IP to some static domain. DynDns provides this kind of support for free. Go ahead and signup and get the free service where you can pick DynDNS domain to map to your dynamic IP address. Let's say you picked from the list.

(Note: Make sure you choose "Specific mailserver will route all mail for my DynDNS host" option in mail routing section and specify your actual domain hosting providers mailserver hostname)

Next step is go your hosting provider where you have your domain hosted ( . Go to your domain's DNS settings and change your Mail server (MX record) to Other mail server option and set

MX 1 / Prio -> 1

Now to your home network firewall setting and open port 80 (http) and 25 ( SMTP) for incoming connections, so that outside world can access your machine on above ports (80 for http connection and 25 for SMTP mail relay). Some firewalls might have port forwarding option also.

Now lets start cranking with Zimbra. Download and install Zimbra as per your operating system specifications. Follow the Zimbra quick start guide for installation . In short
  • Stop anything running on port 80 before you start the install
  • When installation starts it will ask you for domain name and say localhost (do not say , ignore the message installation script message about not finding MX record mapped to localhost.
Once installation is complete , script will try to start the zimbra server. Hopefully server started properly go to https://localhost:7071/zimbraAdmin/ login with the admin username/password you created while installation. You will see localhost already under domains. Now you will have to go create new domain with (your actual domain name) and user for that domain. e.g by going to accounts option.

That should do it. Now you can go to any of your email clients and send an email to and you will see email coming right to your zimbra server. To check email click on in accounts option and click on "View Mail" option on right hand top pane.

Tuesday, August 21, 2007

acts_as_attachment error : undefined method `find_or_initialize_by_thumbnail_and_parent

You will possibly be seeing this error when you use acts_as_attachment for thumbnailing.

undefined method `find_or_initialize_by_thumbnail_and_parent'

Basically acts_as_attachment is trying to use dynamic finders ( Good article on that is here ) to find and create new object if it is not found. Developers use acts_a_attachment ( instead of attachument_fu; successor of acts_a_attachment works only Rails 1.2 onwards) because it works with older version of Rails (1.1.6) and when you execute thumbnailing you get above message and the reason the dynamic method find_or_initialize_by_thumbnail_and_parent that internally calls find_or_initialize which is available in Edge rails onwards and Rails 1.1.6 does not have that. So kinda defeats the purpose of using acts_a_attachment for Rails 1.1.6.

In any case don't be disappointed and here is the fix ,so you can use everything as it is. Go to your vendors/plugins/acts_as_attachment/lib/technoweenie/acts_as_attachment/instance_methods.rb and look for method find_or_initialize_thumbnail , you need to patch this method to make it work with Rails 1.1.6 ( basically find and create new object seperately)

Replace following

def find_or_initialize_thumbnail(file_name_suffix)
respond_to?(:parent_id) ?
thumbnail_class.find_or_initialize_by_thumbnail_and_parent_id(file_name_suffix.to_s, id) :



        def find_or_initialize_thumbnail(file_name_suffix)
respond_to?(:parent_id) ?
(file_name_suffix.to_s, id) ||>file_name_suffix.to_s,
:parent_id=>id) :>file_name_suffix.to_s)
This should do the trick.

Friday, August 17, 2007

Facebook micro application success trend started

Angel community was watching when Facebook platform launched and they were expecting plenty of applications to launch under Facebook umbrella rapidly and eventually some one will cash in the success in terms of user base. 

I guess exactly same thing happened to Where I have been. Here is the news ( TripAdvisor buys Facebook app for $3 million). This again proves few simple things about consumer space

  • User base, User base, User base
  • Data is more valuable than Technology
Now the race is on and applications will be more aggressive to pan out, attract more and more people. Facebook proved its platform strength after all. 

Thursday, August 16, 2007

Our first Ajuby meetup

Even though we have been in quite a few silicon valley ruby meetups with low key Ajuby push by dropping one page Ajuby brochure on the front door, We had our first formal Ajuby meetup today. It went well . Not everyone showed up who RSVP'd for the meetup, there were handfull.

We started with little introduction of Ajuby on how it started, why kind of slides. Then we dived right into high level features of our last release 0.5 ( which I blogged in a seperate post last time). As we were passing thru slides, audience were curious and questions about vision, business model and eventually couple of guys were interested in looking at actual code. I eventually opened Textmate and started walking everyone thru the Ajuby code base. I guess people were curious to know how different Ajuby is from conventional Rails application. Answer was simple, Ajuby is an Rails application with additional directories custom to Ajuby.

Whole take from this exercise was wonderful, curious eyes with valid questions, Discussions will possibly take feedback to feature path, we are helping ourselves and others.

We have a long way to go in this process, lot to learn, lot to provide to the community because we have got from community so much all these years.

Sunday, July 15, 2007

iPhone Frenzy.

I just could not stop writing about iPhone. Looking at the craze generated by apple's usual brilliant marketing machine, people went nuts buying iPhone and there are huge group of people who bought iPhone just for pure tinkering and push the mobile development to its limit.

We have seen mobile development for so many years, but what is happening with iPhone front is nothing like any other mobile revolution we have seen so far.

Look at the applications developed for iPhone in a hack-a-thon. If you go thru this list, quite a few of them are potential crowd pullers. If executed well can lead to big money making machine.

On the other hand, I'm wowed ! by speed of development. We will see more of these. iPhone can possibly build parallel world of social communication and media and convert lot of people use mobile phone to do everything that they would do on a personal computer, I mean everything right from emails, chatting with friends, business collaboration and transactions. For developers and nerd community Apple might come up with lightweight portable programming platform , where you can dock iPhone , pipe it to big screen and do your application development.

Sunday, July 01, 2007

Ajuby releas 0.5 brings business mashup building one step closer

Ajuby Release 0.5
We are glad to announce Ajuby release 0.5 today. It is very exciting get this release out after long and late hours of work, with tons of fixes and UI consistency across browsers (IE/Firefox/Safari).

This is a milestone release for Ajuby team in terms making integration platform availability (for building Web services/SOAP/XML exchange) , sample applications demonstrating possibility of mashups (SugarCRM and Basecamp conglomerate).

Here is the release information in detail

You can also check out the Ajuby blog for up to date information

To get your hands on this release

It just keeps getting better as wide adoption Rails based application increases, Ajuby slides itself in a right spot to make developers and user community to build integrations to popular business applications like Salesforce, SugarCRM , productivity tools like basecamp and storage solution like Amazon S3 rapidly.