From iRedMail
Necessary Packages
1. Install iRedMail LDAP Version
Install Debian 6.0 with net-install and remember don’t create user “sogo” during installation… it will be created when you install “SOGo”.
Now follow instruction on this page to install iRedMail with LDAP backend and iRedAdmin Open Source edition. (it’s very simple)
http://code.google.com/p/iredmail/wiki/Installation_on_Debian
After installation is complete, reboot your system:
2. Install iRedAdmin-PRO-LDAP
Buy the last version of iRedAdmin-PRO-LDAP from http://www.iredmail.org/admin_buy.html and follow these simple instructions to install it.
| Terminal:
|
# tar xjf iRedAdmin-Pro-LDAP-x.y.z.tar.bz2 -C /usr/share/apache2/
# cd /usr/share/apache2/
# rm -i /usr/share/apache2/iredadmin
# ln -s iRedAdmin-Pro-LDAP-x.y.z/ iredadmin
# cp iRedAdmin-0.1.4/settings.ini iRedAdmin-Pro-LDAP-x.y.z/
# chown -R iredadmin:iredadmin iRedAdmin-Pro-LDAP-x.y.z/
# chmod -R 0755 iRedAdmin-Pro-LDAP-x.y.z/
# chmod -R 0640 iRedAdmin-Pro-LDAP-x.y.z/settings.ini
# /etc/init.d/apache2 restart
|
3. Install SOGo with MYSQL
- Add repository on “/etc/apt/sources.list”:
| File: /etc/apt/sources.list
|
# SOGo
deb http://inverse.ca/debian squeeze squeeze
|
- Install SOGo, SOPE-mysql and memcached:
| Terminal:
|
# apt-get update
# apt-get install sogo sope4.9-gdl1-mysql memcached
|
- after you must:
- restart mysql service;
- remove “tmpreaper” warning;
- fix memcached ipv6 error (only on squeeze).
| Terminal:
|
# /etc/init.d/mysql restart
# vi /etc/tmpreaper.conf
|
| File: /etc/tmpreaper.conf
|
Change “SHOWWARNING=true” to “SHOWWARNING=false”
|
| Terminal:
|
# vi /etc/memcached.conf
|
| File: /etc/memcached.conf
|
Change “-l 127.0.0.1” to “-l localhost”
|
| Terminal:
|
# /etc/init.d/memcached restart
|
- Create the database for user “sogo”:
| Terminal:
|
# mysql -u root –p
mysql> CREATE DATABASE sogo;
mysql> GRANT ALL ON sogo.* TO sogo@localhost IDENTIFIED BY "yoursogomysqlpsw";
mysql> flush privileges;
mysql> exit
|
- Enable a few modules on apache and restart it:
| Terminal:
|
# a2enmod proxy
# a2enmod proxy_http
# a2enmod headers
# a2enmod rewrite
# /etc/init.d/apache2 restart
|
Now need to make the SOGo configuration file. For a simple use I attach my GNUstepDefaults (/home/sogo/Gnustep/Default/GNUstepDefaults).
You can copy it and must change:
- password of user “sogo” on mysql;
- password on “bindPassword” with your “Manager LDAP password”;
- set your “baseDN” and “bindDN”.
| Terminal:
|
# su sogo
$ vi /home/sogo/GNUstep/Defaults/.GNUstepDefaults
|
| File: /home/sogo/Gnustep/Default/GNUstepDefaults
|
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//GNUstep//DTD plist 0.9//EN" "http://www.gnustep.org/plist-0_9.xml">
<plist version="0.9">
<dict>
<key>NSGlobalDomain</key>
<dict>
</dict>
<key>sogod</key>
<dict>
<key>NGImap4DisableIMAP4Pooling</key>
<string>YES</string>
<key>NGUseUTF8AsURLEncoding</key>
<string>YES</string>
<key>OCSFolderInfoURL</key>
<string>mysql://sogo:YOURSOGOMYSQLPSW@localhost:3306/sogo/sogo_folder_info</string>
<key>OCSSessionsFolderURL</key>
<string>mysql://sogo:YOURSOGOMYSQLPSW@localhost:3306/sogo/sogo_sessions_folder</string>
<key>SOGoACLsSendEMailNotifications</key>
<string>YES</string>
<key>SOGoAppointmentSendEMailNotifications</key>
<string>YES</string>
<key>SOGoAuthenticationMethod</key>
<string>LDAP</string>
<key>SOGoCalendarDefaultRoles</key>
<array>
<string>PublicViewer</string>
</array>
<key>SOGoDraftsFolderName</key>
<string>Drafts</string>
<key>SOGoFoldersSendEMailNotifications</key>
<string>YES</string>
<key>SOGoForceIMAPLoginWithEmail</key>
<string>YES</string>
<key>SOGoForwardEnabeled</key>
<string>YES</string>
<key>SOGoIMAPServer</key>
<string>localhost</string>
<key>SOGoLDAPContactInfoAttribute</key>
<string>YES</string>
<key>SOGoLanguage</key>
<string>Italian</string>
<key>SOGoMailDomain</key>
<string>yourdomain.com</string>
<key>SOGoMailListViewColumnsOrder</key>
<array>
<string>Flagged</string>
<string>Attachment</string>
<string>Priority</string>
<string>From</string>
<string>Subject</string>
<string>Unread</string>
<string>Date</string>
<string>Size</string>
</array>
<key>SOGoMailingMechanism</key>
<string>smtp</string>
<key>SOGoOtherUsersFolderName</key>
<string>Other Users</string>
<key>SOGoProfileURL</key>
<string>mysql://sogo:YOURSOGOMYSQLPSW@localhost:3306/sogo/sogo_user_profile</string>
<key>SOGoSMTPServer</key>
<string>localhost</string>
<key>SOGoSentFolderName</key>
<string>Sent</string>
<key>SOGoSharedFolderName</key>
<string>Cartella Condivisa</string>
<key>SOGoTimeZone</key>
<string>Europe/Rome</string>
<key>SOGoTrashFolderName</key>
<string>Trash</string>
<key>SOGoUserSources</key>
<array>
<dict>
<key>CNFieldName</key>
<string>cn</string>
<key>IDFieldName</key>
<string>mail</string>
<key>UIDFieldName</key>
<string>uid</string>
<key>baseDN</key>
<string>o=domains,dc=yourdomain,dc=com</string>
<key>bindDN</key>
<string>cn=Manager,dc=yourdomain,dc=com</string>
<key>bindFields</key>
<string>mail</string>
<key>bindPassword</key>
<string>YOURLDAPMANAGERPSW</string>
<key>canAuthenticate</key>
<string>YES</string>
<key>displayName</key>
<string>Rubrica Condivisa</string>
<key>hostname</key>
<string>127.0.0.1</string>
<key>id</key>
<string>public</string>
<key>isAddressBook</key>
<string>YES</string>
<key>port</key>
<string>389</string>
<key>scope</key>
<string>sub</string>
</dict>
</array>
<key>SOGoVacationEnabeled</key>
<string>YES</string>
<key>WOMessageUseUTF8</key>
<string>YES</string>
<key>WOParsersUseUTF8</key>
<string>YES</string>
<key>WOPort</key>
<string>20000</string>
<key>WOUseRelativeURLs</key>
<string>NO</string>
</dict>
</dict>
</plist>
|
| Terminal:
|
$ /etc/init.d/sogo restart
$ exit
|
GNUstepDefaults is configured and SOGo should start correctly!! if you find an error when restarting SOGo, please re-check the config file.
Now miss only apache configuration;
- open /etc/apache2/conf.d/SOGo.conf and modify proxy settings for correct redirect when you logon to SOGo:
| Terminal:
|
# vi /etc/apache2/conf.d/SOGo.conf
|
| File: /etc/apache2/conf.d/SOGo.conf
|
<Proxy http://127.0.0.1:20000/SOGo>
## adjust the following to your configuration
RequestHeader set "x-webobjects-server-port" "80"
RequestHeader set "x-webobjects-server-name" "sogo.yourdomain.com"
RequestHeader set "x-webobjects-server-url" "http://sogo.yourdomain.com"
## When using proxy-side autentication, you need to uncomment and
## adjust the following line:
RequestHeader set "x-webobjects-remote-user" "%{REMOTE_USER}e"
RequestHeader set "x-webobjects-server-protocol" "HTTP/1.0"
RequestHeader set "x-webobjects-remote-host" %{REMOTE_HOST}e env=REMOTE_HOST
AddDefaultCharset UTF-8
Order allow,deny
Allow from all
</Proxy>
|
- If you want set permanent redirect to SOGo, copy and paste this line at the end of “/etc/apache2/conf.d/SOGo.conf” file:
| File: /etc/apache2/conf.d/SOGo.conf
|
Redirect permanent /index.html http://sogo.yourdomain.com/SOGo
|
- Restart apache and reboot system:
| Terminal:
|
# /etc/init.d/apache2 restart
# reboot
|
- After system restart you can start to use iRedMail + SOGo with these url:
https://sogo.yourdomain.com/iredadmin (or https://ipaddress/iredadmin)
http://sogo.yourdomain.com/SOGo (or http://ipaddress/SOGo)
Bye bye and good work!!
Pedron Luciano