在Ubuntu 9.04/9.10 桌面版上安装 Open-Xchange 社区开源免费版 2009.12.23
注意:
1 本文以Ubuntu9.04桌面版为系统,如果您是9.10或者8.04的, 文章中都有特别注释说明
2
主要步骤流程引用网站:
http://www.open-xchange.com/wiki/index.php?title=Quick_install_guide_for_the_Server_Edition_Ubuntu8.04
其他的小问题引用网站写在具体的问题上面喽
3 所有的安装与配置, 必须以
root用户登录ubuntu
时间:
2009.12.23, 圣诞节前!耶稣爱你!山上的城,灯台上的灯 -- 北京守望,福音派改革宗
联系文章作者:
北京守望 小方 lanshunfang##gmai.com 别忘了把##替换成@
安装:
安装PGP 签名
引用网站: http://www.open-xchange.com/wiki/index.php?title=Importing_OX_Buildkey
方法:
1 如果使用apt-get的东东来安装社区开源免费版, 则
$wget http://software.open-xchange.com/oxbuildkey-community.pub -O - | apt-key add -
// 其他版的pgp 签名自己上引用网站去找去
2 如果使用rpm来安装, 则自己上引用网站上去啃英文去
添加安装库 repostory
引用网站:
1 主引用网站
2 不同Ubuntu版本的库地址获取: http://download.opensuse.org/repositories/server:/OX:/ox6/
$sudo vim /etc/apt/sources.list
// 打开后, 在文档最后添加
deb http://download.opensuse.org/repositories/server:/OX:/ox6/xUbuntu_9.04/ /
// 其他版本的, 请参照上面的引用网站修改上面的地址哦
$
sudo aptitude update
// 如果出现PGP签名问题, 就说明你
“安装PGP 签名”没有搞好了
安装Apache2 PHP5 Mysql5
这个步骤就不用多说了,如果你还没有安装, 就可以上网google安装方法喽 :)
初始化open-Xchange数据库
$
sudo aptitude install mysql-server /
open-xchange open-xchange-authentication-database /
open-xchange-admin-client open-xchange-admin-lib /
open-xchange-admin-plugin-hosting open-xchange-admin-plugin-hosting-client /
open-xchange-admin-plugin-hosting-lib open-xchange-configjump-generic /
open-xchange-admin-doc open-xchange-contactcollector /
open-xchange-conversion open-xchange-conversion-engine /
open-xchange-conversion-servlet open-xchange-crypto /
open-xchange-data-conversion-ical4j open-xchange-dataretention /
open-xchange-dataretention-csv open-xchange-genconf open-xchange-genconf-mysql /
open-xchange-imap open-xchange-mailfilter /
open-xchange-management open-xchange-monitoring /
open-xchange-passwordchange-database open-xchange-passwordchange-servlet /
open-xchange-pop3 open-xchange-publish open-xchange-publish-basic /
open-xchange-publish-infostore-online open-xchange-publish-json /
open-xchange-publish-microformats open-xchange-push-udp /
open-xchange-resource-managerequest open-xchange-server /
open-xchange-settings-extensions open-xchange-smtp /
open-xchange-spamhandler-default open-xchange-sql open-xchange-subscribe /
open-xchange-xerces-sun open-xchange-subscribe-json /
open-xchange-subscribe-microformats open-xchange-subscribe-crawler /
open-xchange-templating open-xchange-threadpool open-xchange-unifiedinbox /
open-xchange-admin-plugin-hosting-doc open-xchange-charset /
open-xchange-control open-xchange-easylogin /
open-xchange-group-managerequest open-xchange-i18n open-xchange-jcharset /
open-xchange-sessiond open-xchange-calendar-printing /
open-xchange-user-json open-xchange-gui-wizard-plugin /
open-xchange-report-client /
open-xchange-configjump-generic-gui /
open-xchange-gui open-xchange-gui-wizard-plugin-gui /
open-xchange-online-help-de /
open-xchange-online-help-en open-xchange-online-help-fr
// 这个步骤会下载好多东西, 如果你的mysql数据库已经安装, 则大约会下载89.3MB的东东
配置服务器和数据库:
确保mysql 启动:
$
/etc/init.d/mysql start
添加Open-Xchange 二进制包到 Linux Path
$
echo PATH=$PATH:/opt/open-xchange/sbin/ >> ~/.bashrc && . ~/.bashrc
确保mysql的root密码, 在安装时为空, 安装之后再还原
// OX的initconfigdb只能工作在mysql 的 root用户访问不需要密码, 清除空Mysql 的root 用户密码
$mysql -uroot -p
// 输入密码
mysql> use mysql
mysql> UPDATE user SET password=PASSWORD("") WHERE user='root';
mysql> FLUSH PRIVILEGES;
mysql> QUIT
配置OX数据库:
$
/opt/open-xchange/sbin/initconfigdb --configdb-pass=db_password-a
// 上面的红色部分是数据库密码, 由于太简单, 所以建议你按照你的需要来修改
// 如果你之前安装过OX,这次可以在最后添加 -i 参数来删除之前的所有安装
// 以下是open-exchange的预置用户信息:
- The MySQL 数据库用户
- 用户名: openexchange
- 密码: db_password
- 权限: All privileges
- The Open-Xchange Admin Master
- Username: oxadminmaster
- Password used at this guide: admin_master_password
- Responsibility: Manage contexts, manage all kinds of low level server configuration
- The Context Admin
- Username: oxadmin
- Password used at this guide: admin_password
- Responsibility: Manage users/groups/resources inside a context
$/opt/open-xchange/sbin/oxinstaller --no-license /
--servername=oxserver --configdb-pass=
db_password
/
--master-pass=
admin_master_password
--ajp-bind-port=localhost
// 同理, 上面的密码部分自己决定喽, --configdb-pass=
db_password 当然就是上一步骤设定的密码喽
// OX支持群集服务器安装, 如果你使用群集,你则需要修改
--ajp-bind-port=*
启动服务
$
sudo /etc/init.d/open-xchange-admin start
在OX服务中注册本地机器
$
sudo /opt/open-xchange/sbin/registerserver -n oxserver -A oxadminmaster -Padmin_master_password
// 上面的密码自己决定喽(用户名不可更改),
admin_master_password是上个步骤你指定的
创建filestore,并在OX服务中注册
// 这个文件夹用来存储所有的用户上传文件, 下面以/var/opt/filestore为例, 你可以任意修改
$
sudo mkdir/var/opt/filestore
$
sudo chown open-xchange:open-xchange /var/opt/filestore
$
sudo /opt/open-xchange/sbin/registerfilestore -A oxadminmaster -Padmin_master_password/
-tfile:///var/opt/filestore
注册群件groupware数据库
$
sudo /opt/open-xchange/sbin/registerdatabase -A oxadminmaster -Padmin_master_password/
-n oxdatabase -pdb_password-m true
配置OX服务
启用Apache2的相关模块
$ sudo a2enmod proxy
$ sudo a2enmod proxy_ajp
$ sudo a2enmod expires
$ sudo a2enmod deflate
$ sudo a2enmod headers
$
sudo /etc/init.d/apache2 force-reload
创建配置文件 :mod_proxy_ajp
vim /etc/apache2/conf.d/proxy_ajp.conf
// 文件内容
<Proxy *>
Order deny,allow
allow from all
</Proxy>
ProxyPass /axis2 ajp://127.0.0.1:8009/axis2 smax=0 ttl=60 retry=5
ProxyPass /ajax ajp://127.0.0.1:8009/ajax smax=0 ttl=60 retry=5
ProxyPass /servlet ajp://127.0.0.1:8009/servlet smax=0 ttl=60 retry=5
ProxyPass /infostore ajp://127.0.0.1:8009/infostore smax=0 ttl=60 retry=5
ProxyPass /publications ajp://127.0.0.1:8009/publications smax=0 ttl=60 retry=5
修改Apache虚拟主机,在默认网站上显示OX Gui
-- 关于启用Apache2虚拟主机, 请Google 搜索
$ vim /etc/apache2/sites-available/default
//
/var/www/必须是虚拟主机的document_root, 如果你之前已经修改了,则你需要还愿, 或者可能做一个软链接也行, 只是我不想试了, 因为这个东西应该是企业最优先的, 而且让以后升级方便。最好修改其他东西。
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot/var/www/
<Directory/var/www/>
AllowOverride None
Order allow,deny
allow from all
RedirectMatch ^/$ /ox6/
</Directory>
ExpiresActive On
ExpiresByType image/gif "access plus 23 hours"
ExpiresByType image/png "access plus 23 hours"
ExpiresByType image/jpg "access plus 23 hours"
ExpiresByType image/jpeg "access plus 23 hours"
ExpiresByType text/javascript "access plus 23 hours"
ExpiresByType text/css "access plus 23 hours"
ExpiresByType text/html "access plus 23 hours"
ExpiresByType application/x-javascript "access plus 23 hours"
<Files ~ "/.(js|css|gif|jpe?g|png)$">
Header append Cache-Control "public"
</Files>
DeflateFilterNote ratio
AddOutputFilterByType DEFLATE text/html text/plain text/xml text/css application/x-javascript application/javascript
BrowserMatch ^Mozilla/4 gzip-only-text/html
BrowserMatch ^Mozilla/4/.0[678] no-gzip
BrowserMatch /bMSI[E] !no-gzip !gzip-only-text/html
Header append Vary User-Agent env=!dont-vary
</VirtualHost>
重启Apache2
$ sudo /etc/init.d/apache2 restart
最后 , 启动激动人心的OX
$ sudo /etc/init.d/open-xchange-groupware start
好的, 如果你的Document_Root还有文件夹权限没有搞错, 则当你访问: http://你的服务器IP或者网址/ 则会显示登录框了
创建OX使用环境和用户及删除
创建使用情境角色和情境管理员, 所谓情境, 可以理解为一个公司工作环境(或者子公司工作环境).
$/opt/open-xchange/sbin/createcontext -A oxadminmaster -P
admin_master_password
-c 1 /
-u oxadmin -d "
Context Admin" -g Admin -s User -p
admin_password
-L defaultcontext /
-e
oxadmin@example.com
-q 1000000 --access-combination-name=all
以CEO global(北京思尔豪国际咨询有限公司)为例, 磁盘配额1TB,
/opt/open-xchange/sbin/createcontext -c 3 -q 1000000 -N "CEOglobal" -u "admin" -d "Admin of CEOglobal" -g "Paul" -s "Morris" -p password -e paul.morris@example.org -A oxadminmaster -P *000000 --access-combination-name=all
创建用户及参数解释
$/opt/open-xchange/sbin/deleteuser -A oxadmin -Padmin_password-c 3 -u testuser -i 3
创建和管理用户组 ---- 用户组可以理解为公司的各个部门: