Alfresco 4 + MySQL + Ubuntu 12.04

Alfresco 4.0.e + MySQL 5.5 + Ubuntu 12.04.1 64 Bit

Installasi ini menggunakan OS Ubuntu 12.04.1 Server 64 Bit.
Mengingat bawaan dari paket alfresco menggunakan postgreSQL maka tutorial dibawah ini untuk koneksi ke MySQL. Tapi apabila mau diubah ke postgreSQL maka tinggal disesuaikan aja.

Alfresco di install pada direktori /opt/alfresco-4.0.e

Pastikan bahwa tidak terinstall java sebelumnya.
Semua installasi dibawah ini dalam mode root.
Installasi Oracle Java

  • Download aplikasinya di http://www.oracle.com/technetwork/java/javase/downloads/jdk7u7-downloads-1836413.html jangan lupa untuk memilih yang 64 bit lalu di ekstrak
  • tar xfvz jdk-7u7-linux-x64.tar.gz
  • mkdir -p /opt/alfresco-4.0.e
  • mv jdk1.7.0_07 /opt/jdk1.7.0_07
  • chown -R root:root /opt/jdk1.7.0_07
  • pico /etc/profile
    Tambahkan baris terakhir dengan :

    JAVA_HOME=/opt/jdk1.7.0_07
    PATH=$PATH:$HOME/bin:$JAVA_HOME/bin
    JRE_HOME=/opt/jdk1.7.0_07/jre
    PATH=$PATH:$HOME/bin:$JRE_HOME/bin
    export JAVA_HOME
    export JRE_HOME
    export PATH

  • update-alternatives –install “/usr/bin/java” “java” “/opt/jdk1.7.0_07/bin/java” 1
  • update-alternatives –install “/usr/bin/javac” “javac” “/opt/jdk1.7.0_07/bin/javac” 1
  • update-alternatives –install “/usr/bin/javaws” “javaws” “/opt/jdk1.7.0_07/bin/javaws” 1
  • update-alternatives –set java /opt/jdk1.7.0_07/bin/java
  • update-alternatives –set javac /opt/jdk1.7.0_07/bin/javac
  • update-alternatives –set javaws /opt/jdk1.7.0_07/bin/javaws
  • /etc/profile
  • java -version
    Pastikan bahwa keluaran merupakan java 64 bit yang baru diinstall
    java version “1.7.0_07”
    Java(TM) SE Runtime Environment (build 1.7.0_07-b10)
    Java HotSpot(TM) 64-Bit Server VM (build 23.3-b01, mixed mode)

Installasi MySQL, ImageMagick, FFMpeg, LiberOffice

  • apt-get install mysql-server mysql-client
  • apt-get install imagemagick ffmpeg liberoffice

Installasi SWFTools

  • apt-get install python-software-properties
  • add-apt-repository ppa:guilhem-fr/swftools
  • apt-get update
  • apt-get install swftools

Installasi Tomcat 7

Installasi Alfresco

  • wget http://dl.alfresco.com/release/community/build-00007/alfresco-community-4.0.e.zip
    Download pada http://wiki.alfresco.com/wiki/Community_file_list_4.0.e
  • apt-get install unzip
  • unzip alfresco-community-4.0.e.zip
  • mv bin /opt/alfresco-4.0.e/
  • mv licenses /opt/alfresco-4.0.e/
  • mv web-server/endorsed/* /opt/alfresco-4.0.e/tomcat/endorsed/
  • mv web-server/shared/* /opt/alfresco-4.0.e/tomcat/shared/
  • mv web-server/lib/* /opt/alfresco-4.0.e/tomcat/lib/
  • mv web-server/webapps/* /opt/alfresco-4.0.e/tomcat/webapps/
  • mkdir /opt/alfresco-4.0.e/extras
  • pico /opt/alfresco-4.0.e/extras/db_setup.sql
    Isi dengan berikut :

    create database alfresco default character set utf8 collate utf8_bin;
    grant all on alfresco.* to ‘alfresco’@’localhost’ identified by ‘my_password’ with grant option;

  • pico /opt/alfresco-4.0.e/extras/db_remove.sql
    Isi dengan berikut :

    drop database alfresco;
    revoke all privileges, grant option from ‘alfresco’@’localhost’;
    drop user ‘alfresco’@’localhost’;

  • mysql -u root -p < /opt/alfresco-4.0.e/extras/db_setup.sql
  • pico /opt/alfresco-4.0.e/alfresco.sh

    #!/bin/sh
    # Start or stop Alfresco server
    # Set the following to where Tomcat is installed
    ALF_HOME=/opt/alfresco-4.0.e
    cd “$ALF_HOME”
    APPSERVER=”${ALF_HOME}/tomcat”
    export CATALINA_HOME=”$APPSERVER”

    # Set any default JVM values
    #export JAVA_OPTS=’-Xms512m -Xmx1024m -Xss1024k -XX:MaxPermSize=256m -XX:NewSize=256m -server’
    export JAVA_OPTS=’-Xms512m -Xmx768m -Xss768k -XX:MaxPermSize=256m -XX:NewSize=256m -server’
    export JAVA_OPTS=”${JAVA_OPTS} -Dalfresco.home=${ALF_HOME} -Dcom.sun.management.jmxremote”

    #
    if [ “$1” = “start” ]; then
    “${APPSERVER}/bin/startup.sh”
    # if [ -r ./virtual_start.sh ]; then
    # sh ./virtual_start.sh
    # fi
    # if [ -r ./start_oo.sh ]; then
    # sh ./start_oo.sh
    # fi
    elif [ “$1” = “stop” ]; then
    “${APPSERVER}/bin/shutdown.sh”
    # if [ -r ./virtual_start.sh ]; then
    # sh ./virtual_stop.sh
    # fi
    # if [ -r ./start_oo.sh ]; then
    # killall soffice.bin
    # fi
    fi

  • chmod ug+x /opt/alfresco-4.0.e/alfresco.sh
  • pico /opt/alfresco-4.0.e/tomcat/shared/classes/alfresco-global.properties
    Isi dengan dibawah ini dan sesuaikan datanya :

    ###############################
    # Common Alfresco Properties
    ###############################
    #
    # Sample custom content and index data location
    #
    dir.root=/opt/alfresco-4.0.e/alf_data
    #
    # Sample database connection properties
    #
    db.name=alfresco
    db.username=alfresco
    db.password=my_password
    db.host=localhost
    db.port=3306
    #
    # External locations
    #————-
    ooo.exe=/usr/bin/soffice
    ooo.enabled=true
    jodconverter.officeHome=/usr/lib/libreoffice
    jodconverter.portNumbers=8101
    jodconverter.enabled=true
    img.root=/usr
    swf.exe=/usr/bin/pdf2swf
    ffmpeg.exe=/usr/bin/ffmpeg
    #
    # Property to control whether schema updates are performed automatically.
    # Updates must be enabled during upgrades as, apart from the static upgrade scripts,
    # there are also auto-generated update scripts that will need to be executed. After
    # upgrading to a new version, this can be disabled.
    #
    db.schema.update=true
    #
    # MySQL connection
    #
    db.driver=org.gjt.mm.mysql.Driver
    db.url=jdbc:mysql://${db.host}:${db.port}/${db.name}
    #db.driver=org.gjt.mm.mysql.Driver
    #db.url=jdbc:mysql://localhost/alfresco340?useUnicode=yes& amp;characterEncoding=UTF-8
    # ALTER DATABASE alfresco SET ALLOW_SNAPSHOT_ISOLATION ON;
    #
    #db.driver=net.sourceforge.jtds.jdbc.Driver
    #db.url=jdbc:jtds:sqlserver://localhost:1433/alfresco
    #db.txn.isolation=4096
    #PostgreSQL connection (requires postgresql-8.2-504.jdbc3.jar or equivalent)
    #db.driver=org.postgresql.Driver
    #db.url=jdbc:postgresql://localhost:5432/alfresco

    # Index Recovery Mode
    #————-
    index.recovery.mode=AUTO

    # Outbound Email Configuration
    #————-
    #mail.host=
    #mail.port=25
    #mail.username=anonymous
    #mail.password=
    #mail.encoding=UTF-8
    #mail.from.default=alfresco@alfresco.org
    #mail.smtp.auth=false
    #
    # Alfresco Email Service and Email Server
    #————-
    # Enable/Disable the inbound email service. The service could be used by processes other than
    # the Email Server (e.g. direct RMI access) so this flag is independent of the Email Service.
    #————-
    #email.inbound.enabled=true
    # Email Server properties
    #————-
    #email.server.enabled=true
    #email.server.port=25
    #email.server.domain=alfresco.com
    #email.inbound.unknownUser=anonymous
    # A comma separated list of email REGEX patterns of allowed senders.
    # If there are any values in the list then all sender email addresses
    # must match. For example:
    # .*\@alfresco\.com, .*\@alfresco\.org
    # Allow anyone:
    #————-
    #email.server.allowed.senders=.*
    #
    # The default authentication chain
    # To configure external authentication subsystems see:
    # http://wiki.alfresco.com/wiki/Alfresco_Authentication_Subsystems
    #————-
    authentication.chain=alfrescoNtlm1:alfrescoNtlm
    # The password for the default principal (only used for LDAP sync)
    #ldap.synchronization.java.naming.security.credentials=secret
    #
    # URL Generation Parameters (The ${localname} token is replaced by the local server name)
    #————-
    #alfresco.context=alfresco
    #alfresco.host=${localname}
    #alfresco.port=8080
    #alfresco.protocol=http
    #
    #share.context=share
    #share.host=${localname}
    #share.port=8080
    #share.protocol=http
    cifs.enabled=true
    ftp.enabled=true
    cifs.serverName=${localname}
    cifs.hostannounce=true
    imap.server.enabled=false
    #imap.server.port=143
    #imap.server.host=
    # Default value of alfresco.rmi.services.host is 0.0.0.0 which means ‘listen on all adapters’.
    # This allows connections to JMX both remotely and locally.
    #
    alfresco.rmi.services.host=0.0.0.0
    #
    # RMI service ports for the individual services.
    # These seven services are available remotely.
    # Assign individual ports for each service for best performance
    # or run several services on the same port. You can even run everything on 50500 if needed.
    # Select 0 to use a random unused port.
    #avm.rmi.service.port=50501
    #avmsync.rmi.service.port=50502
    #attribute.rmi.service.port=50503
    #authentication.rmi.service.port=50504
    #repo.rmi.service.port=50505
    #action.rmi.service.port=50506
    #wcm-deployment-receiver.rmi.service.port=50507
    #monitor.rmi.service.port=50508

  • /opt/alfresco-4.0.e/alfresco.sh start
    Apabila berjalan dengan benar maka dapat mengakses alamat berikut http://my_ipaddress:8080/alfresco
    Dan dapat login pada http://my_ipaddress:8080/share

Untuk ngebuat init scriptnya bisa merujuk di http://wiki.alfresco.com/wiki/Installing_Labs_3_Stable_on_Debian_Etch#INIT_Scripts

Apabila mengalami masalah dalam installasi dapat mengecek pada file :
tail -f /opt/alfresco-4.0.e/alfresco.log
Lalu bisa cek ke http://www.lucasmanual.com/mywiki/Alfresco

Selain itu juga pastikan bahwa hostname dapat di ping dan reply :
ping `hostname`

Proses start alfresco membutuhkan hardware yang rada besar maka dari itu proses up nya rada lama.

Referensi :
http://www.wikihow.com/Install-Oracle-Java-on-Ubuntu-Linux
http://www.ubuntugeek.com/how-to-install-swftools-in-ubuntu-12-0411-10-using-ppa.html
http://diegobenna.blogspot.com/2011/01/install-tomcat-7-in-ubuntu-1010.html
http://www.minoraddition.com/2012/01/23/installing-alfresco-4-0-c-on-ubuntu-server-11-10-32bit/
http://tpeelen.wordpress.com/2012/01/04/installing-alfresco-3-x-4-x-on-32bit-ubuntu/
http://wiki.alfresco.com/wiki/Installing_Labs_3_Stable_on_Debian_Etch#INIT_Scripts
http://www.lucasmanual.com/mywiki/Alfresco

Iklan
Ditulis dalam Tutorial. 3 Comments »

RedMine 2.0.3 + MySQL + Apache + Passenger + Subversion + Backlog + Sendmail + Ubuntu 12.04

RedMine 2.0.3 + Apache + Passenger + Subversion + Backlog + Sendmail + Ubuntu 12.04

Dah lama nda buat tutorial. Kali ini cara install redmine dan kawan-kawannya.
Menggunakan Ubuntu 12.04.1 dan terkadang untuk paket yang lainnya harus disesuaikan versinya.
Semua perintah dibawah menggunakan root atau bisa menggunakan sudo. Harap baca referensi dari tutorial ini untuk pengetahuan lebih lanjut.

Installasi RedMine 2.0.3

  • wget http://rubyforge.org/frs/download.php/76259/redmine-2.0.3.tar.gz
    Download aplikasinya di http://www.redmine.org/projects/redmine/wiki/Download atau bisa langsung ke http://rubyforge.org/frs/download.php/76259/redmine-2.0.3.tar.gz lalu di ekstrak
  • tar xfvz redmine-2.0.3.tar.gz
  • mv redmine-2.0.3 /usr/share/redmine
  • chown -R root:root /usr/share/redmine
  • chown www-data /usr/share/redmine/config/environment.rb
  • ln -s /usr/share/redmine/public /var/www/redmine
  • mysql -u root -p
    Buat database untuk redmine nya. Harap sesuaikan passwordnya.
  • mysql>CREATE DATABASE redmine character SET utf8;
  • mysql>CREATE user ‘redmine’@’localhost’ IDENTIFIED BY ‘my_password’;
  • mysql>GRANT ALL privileges ON redmine.* TO ‘redmine’@’localhost’;
  • mysql>exit
  • cp /usr/share/redmine/config/database.yml.example /usr/share/redmine/config/database.yml
    Konfigurasikan koneksi redmine ke database mysql
  • pico /usr/share/redmine/config/database.yml
    Sesuaikan dengan entry berikut :

    production:
    adapter: mysql2
    database: redmine
    host: localhost
    username: redmine
    password: my_password
    encoding: utf8

  • apt-get install ruby1.9.3 libmysqlclient-dev
  • apt-get install libmagickcore-dev libmagickwand-dev
  • gem install bundler
  • cd /usr/share/redmine
  • bundle install –without development test postgresql sqlite
  • rake generate_secret_token
  • RAILS_ENV=production rake db:migrate
  • RAILS_ENV=production rake redmine:load_default_data
  • mkdir /usr/share/redmine/public/plugin_assets
  • chown -R www-data:www-data /usr/share/redmine/files /usr/share/redmine/log /usr/share/redmine/tmp /usr/share/redmine/public/plugin_assets
  • chmod -R 755 /usr/share/redmine/files /usr/share/redmine/log /usr/share/redmine/tmp /usr/share/redmine/public/plugin_assets
  • ruby script/rails server webrick -e production
    Lalu selanjutnya test apakah sudah bisa diakses redmine homepage nya yaitu ke alamat http://ip_address:3000.

Apabila sudah berhasil maka langkah selanjutnya adalah mengintegrasikan redmine ke apache melalui passenger

  • tasksel install lamp-server
  • gem install passenger
  • apt-get install libcurl4-openssl-dev libssl-dev apache2-prefork-dev libapr1-dev libaprutil1-dev
  • passenger-install-apache2-module
  • pico /etc/apache2/mods-available/passenger.load
    Pastikan folder versi sesuai dengan yang di install. Isi dengan berikut :

    LoadModule passenger_module /var/lib/gems/1.9.1/gems/passenger-3.0.17/ext/apache2/mod_passenger.so

  • a2enmod passenger
  • pico /etc/apache2/mods-available/passenger.conf
    Pastikan folder versi sesuai dengan yang di install. Isi dengan berikut :

    PassengerRoot /var/lib/gems/1.9.1/gems/passenger-3.0.17
    PassengerRuby /usr/bin/ruby1.9.1

  • pico /etc/apache2/sites-available/default
    Sesuaikan dengan isian berikut :

    DocumentRoot /var/www/redmine
    ServerAdmin user@example.com
    LogLevel warn
    ErrorLog /var/log/apache2/redmine_error
    CustomLog /var/log/apache2/redmine_access combined

    Options Indexes FollowSymLinks MultiViews
    AllowOverride None
    Order allow,deny
    allow from all
    RailsBaseURI /redmine
    PassengerResolveSymlinksInDocumentRoot on

  • pico /etc/apache2/apache2.conf
    Tambahkan di baris akhir :

    Include /etc/apache2/mods-available/passenger.conf

  • /etc/init.d/apache2 restart
    Apabila semuanya dapat berjalan dengan baik maka dapat diakses pada website http://ip_address

Selanjutnya adalah untuk subversionnya

  • apt-get install subversion libapache2-svn libapache2-mod-perl2
  • ln -s /usr/share/redmine/extra/svn/Redmine.pm /usr/lib/perl5/Apache/Redmine.pm
  • ln -s /usr/share/redmine/extra/svn/Redmine.pm /usr/lib/perl5/Apache2/Redmine.pm
  • pico /etc/apache2/conf.d/svn.config
    Isi dengan berikut :

    PerlLoadModule Apache::Redmine

    DAV svn
    SVNParentPath “/var/svn”
    Order deny,allow
    Deny from all
    Satisfy any

    PerlAccessHandler Apache::Authn::Redmine::access_handler
    PerlAuthenHandler Apache::Authn::Redmine::authen_handler
    AuthType Basic
    AuthName “Redmine Subversion Repository”

    #read-only access

    Require valid-user
    Allow from 127.0.0.1
    # Allow from another-ip
    Satisfy any

    # write access

    Require valid-user

    ## for mysql
    RedmineDSN “DBI:mysql:database=redmine;host=localhost”
    RedmineDbUser “redmine”
    RedmineDbPass “my_password”

  • mkdir -p /var/svn
  • chown -R www-data:www-data /var/svn
  • chmod 0750 /var/svn
  • a2enmod dav_svn
  • /etc/init.d/apache2 restart
  • Apabila subversion sudah terinstall dan terintegrasi dengan apache selanjutnya adalah mengintegrasikan dengan redmine. Sehingga ketika membuat project dan menambahkan repository maka subversion secara otomatis membuat svn nya.

    • Akses ke redmine menggunakan webbrowser dengan user admin pass admin
      Klik administration->settings->repositories
      Aktifkan “Enable WS for repository management” lalu “generate API key”
    • pico /etc/cron.d/redmine
      Jangan lupa untuk mengubah [my API key]. Isi dengan berikut :

      * * * * * root ruby /usr/share/redmine/extra/svn/reposman.rb –redmine localhost/redmine –scm Subversion –svn-dir /var/svn –owner www-data –url file:///var/svn –key=[my API key] >> /var/log/reposman.log

    Installasi backlog

    • apt-get install git libxslt1-dev libxml2-dev
    • cd /usr/share/redmine/plugins
    • git clone https://github.com/backlogs/redmine_backlogs.git redmine_backlogs
    • cd redmine_backlogs
    • git tag
      Catat informasi dari versi yang terakhir. Pada kali ini adalah versi 0.9.26
    • git checkout v0.9.26
    • cd /usr/share/redmine
    • bundle install –without test development
    • RAILS_ENV=production bundle exec rake db:migrate
    • RAILS_ENV=production bundle exec rake redmine:load_default_data
    • bundle exec rake generate_secret_token
    • bundle exec rake redmine:plugins:migrate RAILS_ENV=production
    • bundle exec rake redmine:backlogs:install RAILS_ENV=production
    • chown -Rv www-data:www-data /usr/share/redmine/tmp
      Apabila sudah selesai selanjutnya aktifkan backlog pada redminenya

    Installasi sendmail untuk redmine

    • apt-get install sendmail
    • sendmailconfig
      Jawab semua pertanyaan dengan yes
    • pico /usr/share/redmine/config/configuration.yml
      Isi dengan berikut :

      production:
      email_delivery:
      delivery_method: :sendmail

    Kira-kira seperti itu installasi nya … Apabila masih ada error silahkan liat ke referensinya atau googling 😀

    Ref :
    http://grandslam90.wordpress.com/2012/05/22/howto-redmine-2-0-0-passenger-subversion-repositories-in-ubuntu-12-04/
    http://www.redmine.org/projects/redmine/wiki/HowToInstallRedmineOnUbuntuServer
    http://www.redmine.org/projects/redmine/wiki/Download
    https://github.com/backlogs/redmine_backlogs/wiki/Installation-of-Backlogs-in-Redmine-2.0
    http://nokogiri.org/tutorials/installing_nokogiri.html
    http://www.redminebacklogs.net/en/installation.html
    http://www.redmine.org/projects/redmine/wiki/HowTos

    Ditulis dalam Tutorial. 2 Comments »

    Postfix + Mailgraph + pflogsumm + Ubuntu 08.04

    Postfix + Mailgraph + pflogsumm + Ubuntu 08.04

    Asumsi bahwa postfix dan ubuntu sudah terinstall dengan baik.
    Installasi Mailgraph

    • apt-get install rrdtool mailgraph
    • pico /etc/default/mailgraph
      Apabila terinstall amavis, maka setinganya sebagai berikut

      BOOT_START=true
      MAIL_LOG=/var/log/mail.log
      IGNORE_LOCALHOST=true

    • /etc/init.d/mailgraph start

    Selanjutnya bisa diakses pada website nya yaitu http://localhost/cgi-bin/mailgraph.cgi

    Apabila tidak dapat diakses, maka dapat menjalankan
    cp -p /usr/lib/cgi-bin/mailgraph.cgi /usr/lib/cgi-bin/
    Atau pastikan bahwa lokasi direktori dari apache cgi-bin nya adalah benar.

    Install pflogsumm

    • apt-get install pflogsumm
    • pico /etc/cron.daily/postfix_report.sh

      #!/bin/bash
      gunzip /var/log/mail.log.0.gz
      echo -e “From: system@example.com\nSubject: Daily Mail Statistics on `hostname –fqdn`\nTo: \n\n`cat /var/log/mail.log.0 /var/log/mail.log | pflogsumm -d yesterday –problems_first`”|sendmail -t
      gzip /var/log/mail.log.0
      exit 0

    • chmod 755 /etc/cron.daily/postfix_report.sh

    Ref :
    http://www.howtoforge.com/mail_statistics_mailgraph_pflogsumm_p2

    Ditulis dalam Tutorial. 2 Comments »

    Zarafa + Ubuntu 8.04

    Sekarang saatnya installasi zarafa di ubuntu 8.04. Ada baiknya untuk menerapkan shorewall sehingga dapat lebih mengingkatkan keamanannya.

    Zarafa + Postfix + OpenLDAP + AMaViS + SpamAssassin + Razor + ClamAV + phpLDAPadmin + Apache + PHP + MySQL + OpenSSL + dan lain lain … 😛

    Menuju proses installasi …
    download zarafa pada http://www.zarafa.com/download-zarafa
    zarafa-6.40.1-ubuntu8.04-i386 pada ubuntu 8.04 32bit

    apt-get update
    apt-get upgrade
    tasksel install lamp-server
    mysql -u root -p
    mysql> create database zarafa;
    mysql> grant all privileges on zarafa.* to ‘zarafa’@’localhost’ identified by ‘password’;
    mysql> quit
    apt-get install wget
    tar cfvz zarafa-6.40.1-ubuntu8.04-i386.tar.gz
    cd zarafa-6.40.1-ubuntu8.04-i386
    ./install.sh

    #postfix & postfix-ldap
    apt-get install postfix postfix-ldap

    cat > /etc/postfix/ldap-aliases.cf < /etc/postfix/ldap-users.cf < /etc/postfix/access_table <SetValue($i,’login’,’anon_bind’,false);

    #slapd
    apt-get install install slapd ldap-utils

    #tambahkan pada file /etc/ldap/slapd.conf
    include /etc/ldap/schema/zarafa.schema
    loglevel 0

    cp /usr/share/doc/zarafa/zarafa.schema.gz /etc/ldap/schema/
    gunzip /etc/ldap/schema/zarafa.schema.gz

    ref : http://www.zarafa.com/wiki/index.php/LDAP_integration

    #download template untuk phpldapadmin zarafa
    apt-get install unzip phpldapadmin
    wget http://www.zarafa.com/wiki/images/2/2d/Phpldapadmintemplates.zip
    unzip Phpldapadmintemplates.zip
    cp -R templates/* /etc/phpldapadmin/templates

    ref : http://www.zarafa.com/wiki/index.php/PhpLDAPadmin_Template

    #create user
    ref : https://help.ubuntu.com/community/Zarafa
    http://www.zarafa.com/wiki/index.php/ZCP_on_Ubuntu_8.04_LTS

    #zarafa ldap
    cp /etc/zarafa/ldap.openldap.cfg /etc/zarafa/ldap.cfg

    #ubah file /etc/zarafa/ldap.cfg
    ldap_user_unique_attribute = uid
    ldap_loginname_attribute = uid
    ldap_groupmembers_relation_attribute = uid
    ldap_user_type_attribute_value = zarafa-user
    ldap_bind_user = cn=admin,dc=company,dc=com
    ldap_bind_passwd =
    ldap_search_base = dc=company,dc=com
    ldap_user_search_filter = (objectClass=zarafa-user)
    ldap_group_search_filter = (objectClass=zarafa-group)
    ldap_company_search_filter = (objectClass=zarafa-company)
    ldap_company_system_admin_relation_attribute = uid

    ref : http://doc.zarafa.com/6.40/Administrator_Manual/en-US/html/_ConfigureOpenLDAP.html

    #ubah file /etc/zarafa/ldap.cfg untuk quota
    ldap_quota_multiplier = 1048576

    http://forums.zarafa.com/viewtopic.php?f=11&t=1443

    #buat serifikat untuk outlook
    mkdir /etc/zarafa/ssl
    chmod 700 /etc/zarafa/ssl
    cd /etc/zarafa/ssl
    sh /usr/share/doc/zarafa/ssl-certificates.sh server

    ref : http://doc.zarafa.com/6.40/Administrator_Manual/en-US/html/_configure_language.html#_ssl_connections_and_certificates

    #ubah /etc/zarafa/server.cfg untuk menggunakan mode ssl untuk outlook
    server_ssl_enabled = yes
    server_ssl_port = 237
    server_ssl_ca_file = /etc/zarafa/ssl/server.pem
    server_ssl_key_file = /etc/zarafa/ssl/demoCA/cacert.pem
    server_ssl_key_pass =

    #buat serifikat untuk webaccess, phpldapadmin, pop3s, imaps, smtp auth
    openssl genrsa -out /etc/ssl/private/privkey.pem 2048
    openssl req -new -x509 -key /etc/ssl/private/privkey.pem -out /etc/ssl/certs/cert.pem -days 1095

    #ubah /etc/zarafa/gateway.cfg untuk pop3s dan imaps
    pop3s_enable = yes
    imaps_enable = yes
    ssl_private_key_file = /etc/ssl/private/privkey.pem
    ssl_certificate_file = /etc/ssl/certs/cert.pem
    ssl_verify_client = no

    ref : http://doc.zarafa.com/6.40/Administrator_Manual/en-US/html/_configure_zarafa_gateway_imap_and_pop3.html
    http://doc.zarafa.com/6.40/Administrator_Manual/en-US/html/_configure_zarafa_caldav.html

    #postfix & sasl2-bin untuk smtp auth melaui zarafa imap
    apt-get install sasl2-bin
    gpasswd -a postfix sasl

    #ubah file /etc/default/saslauthd
    START=yes
    MECHANISMS=”rimap”
    MECH_OPTIONS=”127.0.0.1″
    THREADS=0
    OPTIONS=”-c -m /var/spool/postfix/var/run/saslauthd -r”

    #buat file /etc/postfix/sasl/smtpd.conf
    cat > /etc/postfix/sasl/smtpd.conf << EOF
    pwcheck_method: saslauthd
    mech_list: plain login
    EOF

    #ubah /etc/postfix/main.cf
    smtpd_tls_auth_only = yes

    smtpd_tls_security_level = may
    smtpd_tls_key_file = /etc/ssl/private/privkey.pem
    smtpd_tls_cert_file = /etc/ssl/certs/cert.pem
    smtpd_tls_session_cache_database = sdbm:/var/lib/postfix/smtpd_scache
    smtpd_tls_received_header = yes
    smtpd_tls_session_cache_timeout = 3600s
    tls_random_source = dev:/dev/urandom

    #smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
    smtpd_sender_restrictions = permit_mynetworks, permit_sasl_authenticated

    smtpd_sasl_auth_enable = yes
    broken_sasl_auth_clients = yes

    #ubah /etc/postfix/main.cf
    #smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem
    #smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key
    #smtpd_use_tls=yes
    #smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
    #smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache

    #ubah file /etc/postfix/master.cf dan sisipkan
    submission inet n – – – – smtpd
    -o smtpd_tls_security_level=encrypt
    -o smtpd_sasl_auth_enable=yes
    -o broken_sasl_auth_clients=yes
    -o smtpd_client_restrictions=permit_sasl_authenticated,reject
    -o smtpd_recipient_restrictions=permit_sasl_authenticated,reject_unauth_destination
    -o smtpd_sender_restrictions=permit_sasl_authenticated,reject
    -o milter_macro_daemon_name=ORIGINATING
    smtps inet n – – – – smtpd
    -o smtpd_tls_wrappermode=yes
    -o smtpd_sasl_auth_enable=yes
    -o broken_sasl_auth_clients=yes
    -o smtpd_client_restrictions=permit_sasl_authenticated,reject_unauth_destination
    -o smtpd_recipient_restrictions=permit_sasl_authenticated,reject_unauth_destination
    -o smtpd_sender_restrictions=permit_sasl_authenticated,reject_unauth_destination
    -o milter_macro_daemon_name=ORIGINATING

    ref : http://www.kitserve.org.uk/content/zarafa-debian-how-part-2-sasl-and-autolearning-spamassassin
    http://forums.zarafa.com/viewtopic.php?f=9&t=918

    #ubah apache untuk menggunakan mode ssl untuk webaccess
    a2enmod ssl rewrite

    #ubah file /etc/apache2/sites-available/default
    #NameVirtualHost *
    NameVirtualHost *:80
    NameVirtualHost *:443

    #ubah file /etc/apache2/sites-available/zarafa-webaccess

    SSLEngine On
    SSLCertificateFile /etc/ssl/certs/cert.pem
    SSLCertificateKeyFile /etc/ssl/private/privkey.pem

    #ubah file /etc/apache2/conf.d/phpldapadmin

    SSLEngine On
    SSLCertificateFile /etc/ssl/certs/cert.pem
    SSLCertificateKeyFile /etc/ssl/private/privkey.pem

    ref : http://www.zarafa.com/wiki/index.php/Securing_Zarafa_WebAccess_with_SSL

    #spamassassin, clamav & amavisd-new
    apt-get install amavisd-new spamassassin clamav-daemon
    apt-get install arj bzip2 cabextract cpio file gzip lha nomarch pax rar unrar unzip unzoo zip zoo lzop

    gpasswd -a amavis clamav
    gpasswd -a clamav amavis

    #ubah /etc/postfix/main.cf
    content_filter = smtp-amavis:[127.0.0.1]:10024

    #ubah /etc/postfix/master.cf
    #pickup fifo n – – 60 1 pickup
    pickup fifo n – – 60 1 pickup
    -o content_filter=
    -o receive_override_options=no_header_body_checks

    smtp-amavis unix – – – – 5 smtp
    -o smtp_data_done_timeout=1200
    -o smtp_send_xforward_command=yes
    -o disable_dns_lookups=yes
    -o max_use=20
    127.0.0.1:10025 inet n – – – – smtpd
    -o content_filter=
    -o local_recipient_maps=
    -o relay_recipient_maps=
    -o smtpd_restriction_classes=
    -o smtpd_delay_reject=no
    -o smtpd_client_restrictions=permit_mynetworks,reject
    -o smtpd_helo_restrictions=
    -o smtpd_sender_restrictions=
    -o smtpd_recipient_restrictions=permit_mynetworks,reject
    -o smtpd_data_restrictions=reject_unauth_pipelining
    -o smtpd_end_of_data_restrictions=
    -o mynetworks=127.0.0.0/8
    -o smtpd_error_sleep_time=0
    -o smtpd_soft_error_limit=1001
    -o smtpd_hard_error_limit=1000
    -o smtpd_client_connection_count_limit=0
    -o smtpd_client_connection_rate_limit=0
    -o receive_override_options=no_header_body_checks,no_unknown_recipient_checks

    #tambahkan file /etc/amavis/conf.d/50-user
    $max_servers = 5;
    @local_domains_acl = ( “company.com”, “company.org”, “company.net” );

    #ubah file /etc/amavis/conf.d/15-content_filter_mode
    @bypass_virus_checks_maps = (
    \%bypass_virus_checks, \@bypass_virus_checks_acl, \$bypass_virus_checks_re);
    @bypass_spam_checks_maps = (
    \%bypass_spam_checks, \@bypass_spam_checks_acl, \$bypass_spam_checks_re);

    #ubah file /etc/amavis/conf.d/20-debian_defaults
    $final_spam_destiny = D_PASS;

    #razor
    apt-get install libnet-dns-perl libmail-spf-query-perl pyzor razor

    razor-admin -home=/etc/razor -create
    razor-admin -home=/etc/razor -register

    #ubah /etc/default/spamassassin
    ENABLED=1

    #ubah file /etc/spamassassin/local.cf
    required_score 8.0
    razor_config /etc/razor/razor-agent.conf

    #ubah file /etc/zarafa/dagent.cfg
    spam_header_name =

    ref : https://help.ubuntu.com/community/PostfixAmavisNew
    http://chiralsoftware.com/linux-system-administration/ubuntu-postfix-imap-dovecot-setup.seam
    http://www.kitserve.org.uk/content/how-install-zarafa-debian-lenny-postfix-procmail-spamassassin-clamassassin-spam-learning-and
    https://help.ubuntu.com/9.04/serverguide/C/mail-filtering.html
    http://spamassassin.apache.org/gtube/

    reboot

    untuk passwd pada webaccess .. bisa akses disini http://forums.zarafa.com/viewtopic.php?f=16&t=5205

    *setelah 20 harian dan beberapa kali rebuild vps di magnet* 😀
    *go magnet .. go*
    *nice*

    Ditulis dalam Tutorial. 2 Comments »

    Proxmox VE

    Proxmox Virtual Environment, solusi untuk masalah virtual machine. Ini cocok banget sebagai pengganti esxi server. Karena terlalu banyak hardware requirement pada esxi server, jadi sebagai solusi bisa menggunakan Proxmox VE. 😛

    Proxmox ini adalah distro yang mengkhususkan untuk masalah virtual machine, support KVM dan juga OpenVZ. Based on debian architecture.

    Sebagai tips pada proxmox ini yaitu :

    1. Untuk network server proxmox dapat menggunakan bonding + bridge namun dengan syarat ada 2 nic (Active Backup)
    2. Apabila membuat guest os, disarankan untuk menginstall acpid atau sejenisnya agar dapat dimanage power nya oleh web proxmox
    3. Apabila membuat guest os, disarankan untuk menggunakan KVM
    4. Apabila membuat guest os, disarankan untuk membuat backup. Jadi klo ada apa-apa tinggal restore installasi awal deh

    Sekedar hint mengenai proxmox dalam hal restore image yaitu :
    Sebelum restore, pastikan bahwa virtual machine sudah di remove lalu silahkan direstore pada command line server dengan format sebagai berikut
    qmrestore namaimage idvirtualmachine
    Contoh :
    # qmrestore vzdump-qemu-102-2010_07_16-09_05_01.tgz 102

    Referensi :
    http://pve.proxmox.com/

    Ubuntu 10.04 – Zimbra 6.0.7

    Update postingan zimbra

    Kali ini menginstall zimbra 6.0.7 GA pada ubuntu 10.04 LTS 64 bit server
    Dikarenakan zimbra versi ini tidak full support dengan ubuntu 10.04, maka harus ada tips & trik tersendiri dalam hal installasinya.
    Asumsi bahwa ubuntu dalam keadaan fresh installation.

    • Tahap awal yaitu pastikan bahwa semua paket ubuntu sudah diupgrade
      # apt-get update
      # apt-get upgrade
    • Setelah itu, install paket yang dibutuhkan oleh zimbra
      # apt-get install sysstat libperl5.10
    • Pastikan bahwa isi dari /etc/hosts dan /etc/hostname sudah benar dan sinkron, yaitu sesuai dengan FQDN nya. Apabila ternyata menggunakan ip private (dibelakang nat) maka pake tips yang ada diakhir tutorial ini
      # pico /etc/hosts
      # pico /etc/hostname
    • Download file installasi zimbra dengan jenis debian 5 yang 64 bit
      # wget -c http://files2.zimbra.com/downloads/6.0.7_GA/zcs-6.0.7_GA_2473.DEBIAN5_64.20100616222328.tgz
      # tar -xzvf zcs*
      # cd zcs*
    • Jalankan file installasi zimbra dengan opsi platform override, lalu isi pilihan paketnya ketika installasi. Jangan lupa untuk memastikan bahwa domain sudah disetup MX nya untuk diarahkan ke ubuntu 10.04
      # ./install.sh –platform-override
    • Setelah itu akan muncul main menu pada saat installasi. Isi admin password agar dapat ke proses selanjutnya

    Apabila terdapat pesan error seperti berikut :

    Initializing ldap…
    Running as zimbra user: /opt/zimbra/libexec/zmldapinit
    IO::Socket::INET: connect: Connection refused at /opt/zimbra/libexec/zmldapinit line 136.
    failed. (28416)

    Maka pastikan bahwa MX sudah benar .. dan ip harus sesuai dengan hasil query MX. Kemungkinan besar kesalahan terjadi pada /etc/hosts yang tidak sesuai dengan ip ubuntu
    Tipsnya yaitu dengan cara buat ip alias aja, jadi biar ip sesuai dengan hasil query MX. Tapi setelah proses installasi udah kelar, jangan lupa untuk hapus ip aliasnya atau direboot ubuntunya dan jangan lupa benerkan /etc/hostsnya. Sarankan banget pake ip public.
    # ifconfig eth0:0 202.187.45.xx

    DNS ERROR resolving MX for xxx.yourdomain.net
    It is suggested that the domain name have an MX record configured in DNS
    Change domain name? [Yes] yes
    Create domain: [xxx.yourdomain.net] yourdomain.net
    MX: xxx.yourdomain.net (202.187.45.xx)

    Interface: 192.168.1.2
    Interface: 202.187.45.xx
    Interface: 127.0.0.1
    done.
    Checking for port conflicts

    Selesai deh proses installasinya, selanjutnya adalah tinggal akses webmail nya pada http://namadomainlengkapubuntunya atau untuk mengakses webadminnya bisa dilihat pada https://namadomainlengkapubuntunya:7071

    Referensi :
    http://library.linode.com/email/zimbra/install-zimbra-ubuntu-10.04-lucid
    http://www.zimbra.com/downloads/os-downloads.html

    Ditulis dalam Tutorial. 2 Comments »

    Streaming Server – VLC – Ubuntu 10.04

    Selain menggunakan ffmpeg, dapat juga menggunakan vlc

    • Installasi vlc
      # apt-get install vlc
    • Masukan group nobody agar dapat mengakses file /dev/video0 untuk aplikasi vlc
      # usermod -a -G video nobody
    • Jalankan vlc dengan menggunakan user nobody
      # sudo -u administrator cvlc v4l2:///dev/video0:height=320:width=240 –sout ‘#transcode{vcodec=h264,vb=1024}:std{access=http,mux=ffmpeg{mux=flv},dst=0.0.0.0:8080/test.flv}}’
    • Selanjutnya dapat membuat file html untuk dapat mengakses ke http://ipaddressataunamadomainserver:8080/test.flv selain itu dapat juga diakses menggunakan player dari flowplayer, jwplayer atau sejenisnya

    Referensi :
    http://wiki.goodrobot.com/wiki/WebcamStreamingFlash
    http://forum.videolan.org/viewtopic.php?t=50991&f=4

    Ditulis dalam Tutorial. 2 Comments »