Ever heard of HiveMail? We’ll it’s a program which lets you run your own email server and provide your users with email addresses on your domain. This program uses PHP and MySQL to manage emails.
It’s a bit complicated to install, but once you get is installed, it runs smoothly.
There’s a pretty complete guide provided which explains how to install the whole thing.
I bought this program a while back and tried to install it on a domain for test.
After following the detailed steps in the guide, the Fata error I got was:
Fatal error: Cannot redeclare hash_update() in /home/*****/public_html/****/hivemail/includes/functions.php on line 58
Well, after a lot of research, the last solution was to comment out the whole “hash_update()” function in the “functions.php” file.
To comment out this function, just open the “functions.php” file which is located in “includes” folder under Hivemail root, and find : function hash_update(… and add double slashes ” // ” on the begining of each line of the function.
That solves this error and you can continue the installation.
After having installed the program, I used the PIPE method for the email gateway and everything seemed to be OK.
But when I tried to send emails to my hivemail address; the emails were getting bounced back. and the message said:

This message was created automatically by mail delivery software.

A message that you sent could not be delivered to one or more of its
recipients. This is a permanent error. The following address(es) failed:

pipe to |/home/****/hivemail_process.php
generated by administrator@MyDomain.com
local delivery failed

The following text was generated during the delivery attempt:
—— pipe to |/home/****/hivemail_process.php
generated by administrator@MyDomain.com ——

Error in argument 1, char 3: option not found
Usage: php [-q] [-h] [-s] [-v] [-i] [-f <file>]
php <file> [args…]
-a              Run interactively
-C              Do not chdir to the script’s directory
-c <path>|<file> Look for php.ini file in this directory
-n              No php.ini file will be used
-d foo[=bar]    Define INI entry foo with value ‘bar’
-e              Generate extended information for debugger/profiler
-f <file>        Parse <file>.  Implies `-q’
-h              This help
-i              PHP information
-l              Syntax check only (lint)
-m              Show compiled in modules
-q              Quiet-mode.  Suppress HTTP Header output.
-s              Display colour syntax highlighted source.
-v              Version number
-w              Display source with stripped comments and whitespace.
-z <file>        Load Zend extension <file>.

—— This is a copy of the message, including all the headers. ——
I could send emails FROM the hivemail program, but I was not able to recieve any mails.
After Googling a while, here’s the solution I found, and IT WORKS!!
on hivemail install guide it says:
“Next, you will need to set the default address for your domain, so
all email not sent to known POP3 accounts is routed to HiveMail?. To
do this, login to cPanel and click the ‘Mail’ link from the main
page. Click ‘Default Address’ on the resulting page. Then click ‘Set
Default Address’.
On the next page, choose the domain that you wish to route HiveMail?
emails from. (Usually, you will want to set this to yourdomain.com,
unless you are planning to offer email@subdomain.yourdomain.com or
something similar.)
Type a pipe (the | character) followed by the to the
hivemail_process.php file that you uploaded above, so it looks
similar to this:
|/home/mysite/hivemail_process.php”)

but in fact you need to do |/usr/bin/php -q /path/to/your/hivemail_process.php
So, after installing, you may want to add some skins, to do so; create a “skins” folder inside you hivemail installation root and upload each skin’s folder there, and in the admin control panel, go to skin manager and import the “.skn” file.
That’s all about how to install and run HiveMail. If you need more information, don’t hesitate to post in the comments.
More is available on www.Hive2.com