[[toc]]+ ##FFA500 |Installing HORDE on a Centos 4 Server##----Since Horde is such a large part of what we are doing, I have made a whole seperate section to working with Horde.As of this writing the versions we are using are:++ Horde Version* Horde: 3.1.1++ Horde Applications* Agora: 0.1-cvs* Ansel: 0.1-cvs* Chora: H3 (2.0.1)* Gollem: H3 (1.0.2)* Hermes: 0.1-cvs* Imp: H3 (4.1)* Ingo: H3 (1.1)* Jonah: 0.1-cvs* Kronolith: H3 (2.1)* Mimp: H3 (1.0-RC1)* Mnemo: H3 (2.1)* Nag: H3 (2.1)* Nic: 0.1-cvs* Passwd: H3 (3.0)* Rakim: 0.1-cvs* Sam: 0.1-cvs* Swoosh: 0.1-cvs* Turba: H3 (2.1)** Wicked: 0.1-cvs||http://horde.org||http://www.horde.org/source/modules.php||To install Horde you need to have the modules and upgrades done as outline in BuildingACentosServer.++ Get the local domain name.<code>export DOMAINNAME=`cat /etc/sysconfig/network|grep DOMAINNAME|cut -d= -f2`exportexport HOSTNAME=`cat /etc/sysconfig/network|grep HOSTNAME|cut -d= -f2`sed -ie 's/.*memory_limit.*$/memory_limit = 64M/' /etc/php.ini \\&& grep memory_limit /etc/php.ini</code>++ Installing pear dependencies.We need to make sure that all the pear modules are installed and of the latest versions.Run the following code in a SSH session as root.<code>/etc/init.d/httpd restartpear install XML_RPCpear upgrade XML_RPCpear upgrade PEAR-1.3.6pear install Logpear install Mail_Mimepear install Mailpear install Filepear install Datepear install Auth_SASLpear install Archive_Tarpear install Net_SMTPpear install Net_UserAgent_Detectpear install Net_URLpear install HTTP_Requestpear install HTML_Commonpear install HTML_Template_ITpear install HTTPpear install Cachepear install Console_Getoptpear install XML_SVGpear install SOAPpear install XML_Parserpear install XML_RPCpear install XML_Serializerpear install Services_Weatherpear install Text_Wikipear install Net_DNSpear install Net_Pingpear install Net_Traceroutepear upgrade Archive_Tar pearpearpear upgrade-allpear channel-update pear.php.netpear upgrade-all</code>This is an overkill, but at least it makes sure we ##red|REALLY## have everything!++ Install HordeDown load the latest production copies of HORDE.<code><code> tar -zxf /mnt/$version/utilities/horde/horde-3* -C /var/www/html/cd /var/www/html/mv horde-3* hordecd /var/www/html/horde</code>We use a network mounted copy of all our setup files so the /mnt/$version refers to a location you set up as needed.<code><code> # remove from list as neededfor i in agora ansel chora gollem hermes imp ingo jonah klutz kronolith mimp mnemo nag nic passwd rakim sam swoosh turba vacation whups wickeddotar -zxf /mnt/$version/utilities/horde/$i* -C /var/www/html/hordemv $i-* $idonedone </code>+++ mysqlJust for fun we stop and start mysql<code>/etc/init.d/mysqld stop/etc/init.d/mysqld start/etc/init.d/mysqld/etc/init.d/mysqld start</code>+++ Horde ConfigurationNowNow we create all the needed configuration files.<code> cd<code> cd /var/www/html/horde/configforfor foo in *.dist; do cp $foo `basename $foo .dist`; donefor i in agora ansel chora gollem hermes imp ingo jonah klutz kronolith mimp mnemo nag nic passwd rakim sam swoosh turba vacation whups wickeddocd /var/www/html/horde/$i/configfor foo in *.dist; do cp $foo `basename $foo .dist`; donedonechown -R apache.apache /var/www/html/horde</code>+++ Horde PasswordsYou need to edit /var/www/html/horde/scripts/sql/create.mysql.sql and put in your own desired password that Horde will use to access the MYSql database.Now create all the Horde database tables.<code>mysql -uroot -p$passwdmysql < /var/www/html/horde/scripts/sql/create.mysql.sqlecho -n Horde -mysql -uroot horde -p$passwdmysql < /var/www/html/horde/kronolith/scripts/sql/kronolith.mysql.sqlecho -n kronolith -mysql -uroot horde -p$passwdmysql < /var/www/html/horde/mnemo/scripts/sql/mnemo.sqlecho -n mnemo -mysql -uroot horde -p$passwdmysql < /var/www/html/horde/nag/scripts/sql/nag.sqlecho -n nag -mysql -uroot horde -p$passwdmysql < /var/www/html/horde/turba/scripts/sql/turba_objects.mysql.sqlecho -n turbamysql -uroot horde -p$passwdmysql < /var/www/html/horde/hermes/scripts/sql/hermes.sqlecho -n hermesmysql -uroot horde -p$passwdmysql < /var/www/html/horde/jonah/scripts/sql/jonah.sqlecho -n jonahmysql -uroot horde -p$passwdmysql < /var/www/html/horde/nic/scripts/sql/nic.sqlecho -n nicmysql -uroot horde -p$passwdmysql < /var/www/html/horde/rakim/scripts/sql/rakim.sqlecho -n rakimmysql -uroot horde -p$passwdmysql < /var/www/html/horde/sam/scripts/sql/spamd_sql.mysql.sqlecho -n sammysql -uroot horde -p$passwdmysql < /var/www/html/horde/swoosh/scripts/sql/swoosh.sqlecho -n swooshmysql -uroot horde -p$passwdmysql < /var/www/html/horde/wicked/scripts/sql/wicked.sqlecho -n wicked</code>$passwdmysql is the varable that holds the password for the root user in mysql, you need to use what ever you have set.++ Sendmailnow let apache be a trusted user in sendmail.<code>echo apache>>/etc/mail/trusted-users</code>++ DovecotEdit /etc/dovecot.conf with what protocols you are going to use, we allow imap imaps pop3 pop3s.Lets restart everything.<code>sed -ie 's/.*#protocols = imap imaps.*$/protocols = imap imaps pop3 pop3s/' /etc/dovecot.conf \\&& grep "protocols = imap" /etc/dovecot.conf/etc/init.d/dovecot restart/etc/init.d/httpd restart/etc/init.d/mysqld/etc/init.d/mysqld stop/etc/init.d/mysqld/etc/init.d/mysqld start/etc/init.d/mysqld/etc/init.d/mysqld start/etc/init.d/vsftpd restart</code> ++</code> ++ Imp Server ConfigurationMake your changes to /var/www/html/horde/imp/config/servers.php to reflect the name of your server.Here is an example:<code><code> $servers['imap'] = array('name' => 'IMAP Server','server' => 'mail.example.com','protocol' => 'imap/notls','port' => 143,'folders' => '','namespace' => '','maildomain' => 'example.com','smtphost' => 'mail.example.com','realm' => 'example.com','preferred' => '');</code>ThisThis is the script that we use to carry out the correct changes needed with /var/www/html/horde/imp/config/servers.php<code> sed<code> sed -ie 's/.*'\''server'\''=>=> '\''imap.example.com'\'',.*$/ '\''server'\''=> '\'''$HOSTNAME''\'',/' /var/www/html/horde/imp/config/servers.php=> '\'''$HOSTNAME''\'',/' /var/www/html/horde/imp/config/servers.php \\&&&& grep "'server'=> '" /var/www/html/horde/imp/config/servers.php sed -ie=> '" /var/www/html/horde/imp/config/servers.php sed -ie 's/.*'\''maildomain'\'' => '\''example.com'\'',.*$/ '\''maildomain'\''=> '\'''$DOMAINNAME''\'',/' /var/www/html/horde/imp/config/servers.php \\ &&=> '\'''$DOMAINNAME''\'',/' /var/www/html/horde/imp/config/servers.php \\ && grep "'maildomain'=> '" /var/www/html/horde/imp/config/servers.php sed -ie 's/.*'\''smtphost'\'' =>=> '" /var/www/html/horde/imp/config/servers.php sed -ie 's/.*'\''smtphost'\'' => '\''smtp.example.com'\'',.*$/ '\''smtphost'\'' => '\'''$HOSTNAME''\'',/' /var/www/html/horde/imp/config/servers.php \\&&&& grep "'smtphost' => '" /var/www/html/horde/imp/config/servers.phpsedsed -ie 's/.*'\''realm'\'' => '\'''\'',.*$/ '\''realm'\'' => '\'''$DOMAINNAME''\'',/' /var/www/html/horde/imp/config/servers.php \\&&&& grep "'realm' => '" /var/www/html/horde/imp/config/servers.php</code> ++</code> ++ Look and Feel at Logon<code> sed<code> sed -ie 's/.*<h1 align="center">.*$/<h1 align="center"><?php echo $title ?><br> <img src=..\/themes\/graphics\/title.jpg><br><font color=white>for School<font color=black><\/h1>/' \\/var/www/html/horde/imp/templates/login/login.inc/var/www/html/horde/imp/templates/login/login.inc \\&&&& grep "<h1 align="\""center"\"">" /var/www/html/horde/imp/templates/login/login.incmvmv /var/www/html/horde/imp/config/motd.php /var/www/html/horde/imp/config/motd.php.org/bin/cat/bin/cat << EOF >> /var/www/html/horde/imp/config/motd.php<?php echo<?php echo "<p align=center><a<a href=http://".\$_SERVER['HTTP_HOST']."/iserver/faq/using_horde.pdftitle='Clicktitle='Click here for a Manual on the Use of your WebMail'target=_blank>Needtarget=_blank>Need Help? Click <img border=0 src=http://".\$_SERVER['HTTP_HOST']."/iserver/images/help.gif>HereHere for a Manual.</a><br>";?>EOFcat /var/www/html/horde/imp/config/motd.php.org >> /var/www/html/horde/imp/config/motd.php</code>++ Register Modules<code>pico /var/www/html/horde/config/registry.php</code>Make active the following modules if you have installed them.||jonah||hermes||gollem||agora||ansel||swoosh||wicked||++ TestingIn a web browser goto yoursite/horde/test.php and yoursite/horde/imp/test.php and see that everything is going okay.++ Configure in HordeGo to yoursite/horde and you are presented with the Administrators page.Set up Horde as needed.Here are some of the settngs that we use.||||**Horde**||||General||NOTHING TO DO||||Database||Database server/host ||||"||Username to connect to the database as Password to connect with||||"||Database name to use ||||Authentication||Which users should be treated as administrators (root, super-user) by Horde?||||"||What backend should we use for authenticating users to Horde?||||"||The application which is providing authentication Horde Sign Up ||||Sign Up||NOTHING||||Logging||NOTHING||||Preference System||What preferences driver should we use?||||"||Driver||"||Driver configuration||||"||The name of the preference table in the database [horde_prefs] ||||!DataTree System||What backend should we use for Horde !DataTree storage?||||"||Driver configuration||||"||The name of the data table in the database [horde_datatree] ||||Groups||NOTHING||||Cache System||NOTHING||||Token System||NOTHING||||Mailer||NOTHING||||Virtual File Storage||NOTHING||||Custom Session Handler||NOTHING||||Image Manipulation||NOTHING||||MIME Detection||NOTHING||||Hostname->Country Lookup||NOTHING||||Problem Reporting||If problem reporting is enabled in an application's menu, where should problem report emails be sent? ||||Menu Settings||The URL of an image for the top of the Horde menu. The image should be no larger than 140 pixels wide by 40 pixels high to prevent the frame from scrolling.||||"||If a logo is displayed in the Horde menu, what URL (if any) should it link to? ||||Custom Function Hooks||NOTHING||||Portal Block Configuration||NOTHING||||Kolab Groupware Server||NOTHING||||||**Address Book Setup**||||Menu||Menu Settings||Add Items as desired ||||||**Calendar Setup**||||Reminder Settings||Server name from which reminder emails should be sent.||||"||Email address from which reminder emails should be sent. ||||||**File Manager Setup**||||Menu Settings||Add Items as desired ||||||**Filters Setup**||||Menu Settings||Add Items as desired ||||||**Mail Setup**||||External Utilities and Menu||Add Items as desired ||||User Capabilities and Constraints||NOTHING||||Mail Server||NOTHING||||Mailbox and Fetchmail||NOTHING||||Message and Spam||NOTHING||||Compose||NOTHING||||Custom Hooks||NOTHING||||Other settings||NOTHING||||||**Notes Setup**||||Menu Settings||Add Items as desired ||||||**Tasks Setup**||||Menu Settings||Add Items as desired ||++ Now try logging on to horde.+++ Can't logon?Check : /var/www/html/horde/imp/config/servers.phpCheck : /etc/hostsCheck : /etc/hosts.allowCheck : /etc/sysconfig/network+++ Logon very slow?Check: that you have hashed out any addresses books settings in turba/config/sources.php that you are not using+++ Horde runnning slow?The most common reason for Horde to run slow is that the Address Book section is trying to access Address Books and Address Book systems that do not exist.Edit /var/www/html/horde/turba/config/sources.phpDelete all the sections except<code>$cfgSources['localsql'] = array(</code>To do this find the first<code><code> );</code>that denotes the end of the localdsql section.And delete everything after this.----+ ##FFA500 |Upgrading HORDE##----As features and upgrades become available for HORDE we will need to upgrade them. This secion deals with upgrading all of HORDE and just sepected modules of HORDE.++ Upgrading HORDE+++ Upgrading pear<code>pear upgrade PEAR-1.3.6pear upgrade-allpear upgrade pearpear channel-update pear.php.netpear install SOAPpear install XML_Parserpear install XML_RPCpear install XML_Serializerpear install Services_Weatherpear install Text_Wikipear install Net_DNSpear install Net_Pingpear install Net_Traceroutepear upgrade-all</code>+++ Get Horde<code>mkdir /zone/hordecd /zone/hordewget *ansel*wget *gollem*wget *horde*wget *imp*wget *kronolith*wget *mnemo*wget *nag*wget *passwd*wget *rakim*wget *sam*wget *turba*wget *vacation*wget *whups*wget *wicked*</code>+++ Archive the current copy of Horde<code>mv /var/www/html/horde /var/www/html/horde.old</code>+++ Create the New Horde<code>tar -zxf /zone/horde/horde-3* -C /var/www/html/cd /var/www/html/mv horde-3* hordecd /var/www/html/hordefor i in ansel gollem imp ingo kronolith mnemo nag passwd rakim sam turba vacation whups wickeddotar -zxf /zone/horde/$i* -C /var/www/html/hordemvmv $i-* $idonedone /etc/init.d/mysqld stop/etc/init.d/mysqld start/etc/init.d/mysqld/etc/init.d/mysqld startcd /var/www/html/horde/configfor foo in *.dist; do cp $foo `basename $foo .dist`; donefor i in ansel gollem imp ingo kronolith mnemo nag passwd rakim sam turba vacation whups wickeddocd /var/www/html/horde/$i/configfor foo in *.dist; do cp $foo `basename $foo .dist`; donedonecd /var/www/html/horde/turba/config/rm -f sources.phpwget http://202.174.163.41/files/horde/sources.txtmv sources.txt sources.phpchown -R apache.apache /var/www/html/hordepico /var/www/html/horde/config/registry.php</code>Edit this file above and make active: wicked, sam, ansel, rakim, whupsCheck for database upgrades at this point!Run any database scripts for new modules.<code>export DOMAINNAME=`cat /etc/sysconfig/network|grep DOMAINNAME|cut -d= -f2`export HOSTNAME=`cat /etc/sysconfig/network|grep HOSTNAME|cut -d= -f2`sed -ie 's/.*'\''server'\'' => '\''imap.example.com'\'',.*$/ '\''server'\'' => '\'''$HOSTNAME''\'',/' /var/www/html/horde/imp/config/servers.php \\&& grep "'server' => '" /var/www/html/horde/imp/config/servers.phpsed -ie 's/.*'\''maildomain'\'' => '\''example.com'\'',.*$/ '\''maildomain'\'' => '\'''$DOMAINNAME''\'',/' /var/www/html/horde/imp/config/servers.php \\&& grep "'maildomain' => '" /var/www/html/horde/imp/config/servers.phpsed -ie 's/.*'\''smtphost'\'' => '\''smtp.example.com'\'',.*$/ '\''smtphost'\'' => '\'''$HOSTNAME''\'',/' /var/www/html/horde/imp/config/servers.php \\&& grep "'smtphost' => '" /var/www/html/horde/imp/config/servers.phpsed -ie 's/.*'\''realm'\'' => '\'''\'',.*$/ '\''realm'\'' => '\'''$DOMAINNAME''\'',/' /var/www/html/horde/imp/config/servers.php \\&& grep "'realm' => '" /var/www/html/horde/imp/config/servers.php</code>++ Look and Feel at Logon<code>sed -ie 's/.*<h1 align="center">.*$/<h1 align="center"><?php echo $title ?><br> <img src=..\/themes\/graphics\/title.jpg><br><font color=white>for School<font color=black><\/h1>/' \\/var/www/html/horde/imp/templates/login/login.inc \\&& grep "<h1 align="\""center"\"">" /var/www/html/horde/imp/templates/login/login.incmv /var/www/html/horde/imp/config/motd.php /var/www/html/horde/imp/config/motd.php.org/bin/cat << EOF >> /var/www/html/horde/imp/config/motd.php<?phpecho "<p align=center><a href=http://".\$_SERVER['HTTP_HOST']."/iserver/faq/using_horde.pdftitle='Click here for a Manual on the Use of your WebMail'target=_blank>Need Help? Click <img border=0 src=http://".\$_SERVER['HTTP_HOST']."/iserver/images/help.gif>Here for a Manual.</a><br>";?>EOFcat /var/www/html/horde/imp/config/motd.php.org >> /var/www/html/horde/imp/config/motd.php</code></code> ++ Register Modules<code>pico /var/www/html/horde/config/registry.php</code>Make active the following modules if you have installed them.||jonah||hermes||gollem||agora||ansel||swoosh||wicked||