:: SVN with Apache on SuSE Linux

:: What is
Please take a look at this.

:: Installing Dependency
+ Installing Apache
+ Installing APR
[ linux:~ ] # mkdir download
[ linux:~ ] # cd download
[ linux:download ] # wget http://apache.pesat.net.id/apr/apr-1.3.8.tar.bz2
[ linux:download ] # cd apr-1.3.8/
[ linux:apr-1.3.8 ] # ./configure --prefix=/usr/local
[ linux:apr-1.3.8 ] # make && make install

+ Installing BerkeleyDB
[ linux:download ] # wget http://download.oracle.com/berkeley-db/db-4.8.24.tar.gz
[ linux:download ] # tar -xzf db-4.8.24.tar.gz
[ linux:download ] # cd db-4.8.24/build_unix/
[ linux:~/db-4.8.24/build_unix ] # ../dist/configure
[ linux:~/db-4.8.24/build_unix ] # make && make install
[ linux:~/db-4.8.24/build_unix ] # echo '/usr/local/BerkeleyDB.4.8/lib/' >> /etc/ld.so.conf
[ linux:~/db-4.8.24/build_unix ] # ldconfig

+ Installing APR-Utils
[ linux:download ] # wget http://apache.pesat.net.id/apr/apr-util-1.3.9.tar.bz2
[ linux:download ] # tar -xjf apr-util-1.3.9.tar.bz2
[ linux:download ] # cd apr-util-1.3.9/
[ linux:apr-util-1.3.9 ] # ./configure --prefix=/usr/local --with-apr=/usr/local --with-berkeley-db=/usr/local/BerkeleyDB.4.8
[ linux:apr-util-1.3.9 ] # make && make install

+ Installing NEON
[ linux:download ] # wget http://www.webdav.org/neon/neon-0.29.0.tar.gz
[ linux:download ] # tar -xzf neon-0.29.0.tar.gz
[ linux:download ] # cd neon-0.29.0/
[ linux:neon-0.29.0 ] # ./configure
[ linux:neon-0.29.0 ] # make && make install

:: Installing SubVersioN (SVN)
+ Downloading Subversion packages
[ linux:~ ] # cd download/
[ linux:download ] # wget http://subversion.tigris.org/downloads/subversion-1.6.6.tar.bz2
[ linux:download ] # tar -xjf subversion-1.6.6.tar.bz2

+ Configure Sqlite for Subversion
[ linux:download ] # wget http://www.sqlite.org/sqlite-amalgamation-3.6.13.tar.gz
[ linux:download ] # tar -xzf sqlite-amalgamation-3.6.13.tar.gz
[ linux:download ] # mkdir /root/download/subversion-1.6.6/sqlite-amalgamation
[ linux:download ] # cp sqlite-3.6.13/sqlite3.c /root/download/subversion-1.6.6/sqlite-amalgamation/

+ Compilling Subversion
[ linux:download ] # cd subversion-1.6.6/
[ linux:subversion-1.6.6 ] # ./configure --prefix=/usr/local/subversion --with-apxs=/usr/local/apache2/bin/apxs --with-apr=/usr/local --with-apr-util=/usr/local --with-neon=/usr/local --with-ssl
[ linux:subversion-1.6.6 ] # make && make install
[ linux:subversion-1.6.6 ] # echo '/usr/local/subversion/lib' >> /etc/ld.so.conf
[ linux:subversion-1.6.6 ] # ldconfig

:: Make Repository
[ linux:~ ] # mkdir /usr/local/subversion/repos
[ linux:~ ] # /usr/local/subversion/bin/svnadmin create --fs-type fsfs /usr/local/subversion/repos
[ linux:~ ] # ls /usr/local/subversion/repos/
conf db format hooks locks README.txt

:: Create and Add SVN users
+ Create user (admin)
[ linux:~ ] # /usr/local/apache2/bin/htpasswd -cmd /usr/local/subversion/repos/conf/svn-auth-file admin
New password: [adminpass]
Re-type new password: [adminpass]
Adding password for user admin

+ Add other users
[ linux:~ ] # /usr/local/apache2/bin/htpasswd -md /usr/local/subversion/repos/conf/svn-auth-file user
New password: [userpass]
Re-type new password: [userpass]
Adding password for user user

:: Testink
+ Importing svn
[ linux:~ ] # /usr/local/subversion/bin/svn import /usr/local/apache2/htdocs file:///usr/local/subversion/repos/trunk/dev -m 'test importing htdocs'

+ Checking svn
[ linux:~ ] # /usr/local/subversion/bin/svn checkout file:///usr/local/subversion/repos/trunk/dev #/svnwork

:: Configure SVN on Apache
+ Configure SVN work directory
[ linux:~ ] # chown -R wwwrun.www /usr/local/subversion/repos/

+ Configure Apache
[ linux:~ ] # vi /usr/local/apache2/conf/httpd.conf
#
# Make sure SVN modules loaded on Apache:
LoadModule dav_svn_module modules/mod_dav_svn.so
LoadModule authz_svn_module modules/mod_authz_svn.so

#
# Add line like this:
<Location /repos>
DAV svn
SVNPath /usr/local/subversion/repos/
AuthType Basic
AuthName "SVN Repos"
AuthUserFile /usr/local/subversion/repos/conf/svn-auth-file
Require valid-user
</Location>

+ Starting Apache server
[ linux:~ ] # /usr/local/apache2/bin/apachectl start
You can check this out on 'http://youripserver/repos'

:: Links
+ GoogleLinux
+ MarcGrabanSki
+ HowToForge

:: [re]Compile PHP Imap on OpenSUSE 11

:: What is
Please take a look at this.

:: Dependency
Make sure OpenSSL installed on your system.
[ linux:~ ] # rpm -qa | grep openssl
libopenssl0_9_8-0.9.8g-47.1
libopenssl-devel-0.9.8g-47.8
openssl-certs-0.9.8g-47.1
openssl-0.9.8g-47.1

:: Installing PHP Imap from Source
[ linux: ~ ] # mkdir download
[ linux: ~ ] # cd download/
[ linux:download ] # wget ftp://ftp.cac.washington.edu/imap/imap-2007a1.tar.Z
[ linux:download ] # tar -xzf imap-2007a1.tar.Z -C /usr/local/
[ linux:download ] # cd /usr/local/imap-2007a/
[ linux:imap-2007a ] # make slx SSLINCLUDE=/usr/include/openssl/
[ linux:imap-2007a ] # cp /usr/local/imap-2007a/c-client/c-client.a /usr/lib/libc-client.a
[ linux:imap-2007a ] # cp /usr/local/imap-2007a/src/c-client/mail.h /usr/include/
[ linux:imap-2007a ] # cp /usr/local/imap-2007a/src/c-client/rfc822.h /usr/include/
[ linux:imap-2007a ] # cp /usr/local/imap-2007a/c-client/linkage.h /usr/include/

:: [re]Compile PHP5 from Source
[ linux:~ ] # cd download/php-5.3.0/
[ linux:php-5.3.0 ] # ./configure [_other_options_] --with-imap=/usr/local/imap-2007a --with-imap-ssl=/usr/include/openssl
[ linux:php-5.3.0 ] # make && make install
I think that the previous PHP5 packages are stored in the directory /root/download/php-5.3.0
[_other_options_] are options used to compile the previous PHP5.

:: Testink
[ linux:php-5.3.0 ] # /usr/local/php5/bin/php -m | grep imap
imap

:: Restart Apache Service
[ linux:php-5.3.0 ] # /usr/local/apache2/bin/apachectl stop
[ linux:php-5.3.0 ] # /usr/local/apache2/bin/apachectl start

:: Links
+ GoogleLinux
+ DominionWeb

:: OpenVZ on CentOS

:: Whati is
Please take a look at this.

:: Install OpenVZ
Installing OpenVZ on CentOS

:: Using OpenVZ on CentOS
Before using OpenVZ, you must have a virtual machine template that will be used, it's usually stored in the /var/template/cache directory. you can create a virtual machine by your hands or download it at http://wiki.openvz.org/Download/template/precreated
+ Download a virtual machine template (CentOS 5)
[root@mail ~]# cd /vz/template/cache/
[root@mail cache]# wget http://download.openvz.org/template/precreated/centos-5-x86.tar.gz

+ Create VPS from CentOS 5 virtual machine template
[root@mail cache]# vzctl create 333 --ostemplate centos-5-x86 --config vps.basic --ipadd 10.100.100.35 --hostname tox.blackonsole.org
Creating container private area (centos-5-x86)
Performing postcreate actions
Container private area was created
where :
* 333 : VPS ID, you must using number for this options.
* centos-5-i386-minimal : name of os/virtual machine template
* vps.basic : file configuration for vps, you can take a look other script on /etc/vz/conf directory.
* 10.100.100.35 : IP Address used for VPS
* tox.blackonsole.org : hostname of VPS

+ Set IP resolver and root password for VPS
[root@mail cache]# vzctl set 333 --nameserver 202.158.3.7 --userpasswd root:rootpasswd --save
where:
* 333 : VPS ID for setting
* 202.158.3.7 : IP Address of resolver
* root:rootpasswd : set password for root user

+ Starting VPS
[root@mail cache]# vzctl start 333
* 333 : ID VPS

+ Show VPS list
[root@mail cache]# vzlist
CTID NPROC STATUS IP_ADDR HOSTNAME
333 3 running 10.100.100.35 tox.blackonsole.org

+ Enter to VPS
[root@mail ~]# vzctl enter 333
you can login to VPS with that command or ssh client by remote login.

:: Destroy VPS
[root@mail cache]# vzctl stop 333
Stopping container ...
Container was stopped
Container is unmounted
[root@mail cache]# vzctl destroy 333
Destroying container private area: /vz/private/333
Container private area was destroyed

:: Links
+ GoogleLinux
+ HowToForge

:: Install OpenVZ on CentOS

:: What is
Please take a look at this.

:: Making OpenVZ repository
[root@mail ~]# cd /etc/yum.repos.d/
[root@mail yum.repos.d]# wget http://download.openvz.org/openvz.repo
[root@mail yum.repos.d]# rpm --import http://download.openvz.org/RPM-GPG-Key-OpenVZ

:: Installing OpenVZ
In repository there are several versions of OpenVZ, choose one of them and install it in our system.

+ Search OpenVZ versions.
[root@mail yum.repos.d]# yum search ovzkernel
============================== Matched: ovzkernel ===============================
ovzkernel.i686 : Virtuozzo Linux kernel (the core of the Linux operating system)
ovzkernel-PAE.i686 : The Linux kernel compiled for PAE capable machines.
ovzkernel-PAE-debug.i686 : The Linux PAE kernel compiled with debug config
ovzkernel-PAE-devel.i686 : Development package for building kernel modules to
: match the PAE kernel.
ovzkernel-debug.i686 : The Linux kernel compiled with debug config
ovzkernel-devel.i686 : Development package for building kernel modules to match
: the kernel.
ovzkernel-ent.i686 : The Linux kernel compiled for huge mem capable machines.
ovzkernel-ent-debug.i686 : The Linux ent kernel compiled with debug config
ovzkernel-ent-devel.i686 : Development package for building kernel modules to
: match the ent kernel.
ovzkernel-xen.i686 : The Linux kernel compiled for Xen VM operations
ovzkernel-xen-devel.i686 : Development package for building kernel modules to
: match the kernel.

+ Installing OpenVZ kernel and utils
[root@mail yum.repos.d]# yum install ovzkernel vzctl vzquota

:: Configuring OpenVZ
+ Check current kernel used
[root@mail ~]# uname -ar
Linux mail 2.6.18-164.el5 #1 SMP Thu Sep 3 03:33:56 EDT 2009 i686 i686 i386 GNU/Linux

+ Configure OpenVZ on Grub Menu
[root@mail ~]# vi /boot/grub/menu.lst
#
# Make sure configuration for OpenVZ kernel in there.
# The configuration like this :
title CentOS OpenVZ (2.6.18-128.2.1.el5.028stab064.7)
root (hd0,0)
kernel /vmlinuz-2.6.18-128.2.1.el5.028stab064.7 ro root=/dev/LVM/system
initrd /initrd-2.6.18-128.2.1.el5.028stab064.7.img

+ Configuring sysctl.conf file
[root@mail ~]# vi /etc/sysctl.conf
#
# Change on those options like :
net.ipv4.ip_forward = 1
net.ipv4.conf.default.proxy_arp = 0
net.ipv4.conf.all.rp_filter = 1
net.ipv4.conf.default.send_redirects = 1
net.ipv4.conf.all.send_redirects = 0
net.ipv4.conf.default.forwarding =1
net.ipv4.icmp_echo_ignore_broadcasts = 1
kernel.sysrq = 1

+ Running sysctl
[root@mail ~]# sysctl -p

+ Configure vz.conf file
[root@mail ~]# vi /etc/vz/vz.conf
#
# change this configuration:
NEIGHBOUR_DEVS=all

:: Disable SELinux
[root@mail ~]# vi /etc/sysconfig/selinux
#
# Make sure this configuration is disable :
SELINUX=disabled

:: Reboot the box and checking the kernel
[root@mail ~]# reboot
[root@mail ~]# uname -a
Linux mail 2.6.18-128.2.1.el5.028stab064.7 #1 SMP Fri Aug 21 03:03:11 MSD 2009 i686 i686 i386 GNU/Linux
Now..your server running with OpenVZ kernel..

:: Links
+ GoogleLinux
+ HowToForge
+ OpenVZ

:: Installing Zimbra on CentOS

:: What is
Please take a look at this.

:: Install dependency
+ installing dependency packages
[ root:~ ]# yum install libtool-ltdl libtool-ltdl-devel sysstat gmp libstdc++ compat-libstdc++-33
+ Install and configure dns server

:: Installing Zimbra on CentOS
+ Download Zimbra packages
[ root:~ ]# wget http://h.yimg.com/lo/downloads/6.0.2_GA/zcs-6.0.2_GA_1912.RHEL5.20091020185714.tgz

+ Configure /etc/hosts file
[ root: ~ ]# vi /etc/hosts
#
# Change configure like [example]:
127.0.0.1 localhost.localdomain localhost
192.168.2.1 blackonsole.com mail

+ Extract and install Zimbra packages
[ root:~ ]# tar -xzf zcs-6.0.2_GA_1912.RHEL5.20091020185714.tgz
[ root:~ ]# cd zcs-6.0.2_GA_1912.RHEL5.20091020185714
[ root:zcs-6.0.2_GA_1912.RHEL5.20091020185714 ]# ./install.sh --platform-override
..
..
Select the packages to install

Install zimbra-ldap [Y]

Install zimbra-logger [Y]

Install zimbra-mta [Y]

Install zimbra-snmp [Y]

Install zimbra-store [Y]

Install zimbra-apache [Y]

Install zimbra-spell [Y]

Install zimbra-memcached [N]

Install zimbra-proxy [N]

..
..
#
# You can continue installation if you get this warning:

Using packages for a platform in which they were not designed for
may result in an installation that is NOT usable. Your support
options may be limited if you choose to continue.


Install anyway? [N] y

The system will be modified. Continue? [N] y

#
# On Zimbra Menu, Please change Admin Password :

3) zimbra-store:

Address unconfigured (**) items (? - help) 3

4) Admin Password

Select, or 'r' for previous menu [r] 4

Password for admin@blackonsole.com (min 6 characters): [PkfDPnJH] yourpasswd

#
# Back to Main Menu and then apply your configuration and continue installation :

Select, or 'r' for previous menu [r] r

*** CONFIGURATION COMPLETE - press 'a' to apply
Select from menu, or press 'a' to apply config (? - help) a
Save configuration data to a file? [Yes]
Save config in file: [/opt/zimbra/config.26172]
Saving config in /opt/zimbra/config.26172...done.
The system will be modified - continue? [No] yes

#
# Take a few minutes to finishing the installation

:: Testink
+ Login on Admin Web Interface
Open your web browser client and goto url: https://blackonsole.com:7071/zimbraAdmin/


+ Login on User web interface
Open your web browser client and goto url: http://blackonsole.com



:: Links
+ GoogleLinux
+ Zimbra
+ HowToForge

:: Procmail on FreeBSD 7.1

:: What is
Please take a look at this.

:: Dependency
Installing Postfix with SpamAssassin

:: Install Procmail over Port
[ root ]# cd /usr/ports/mail/procmail/
[ root ]# make install clean
[ root ]# rehash

:: Configuring Procmail
[ root ]# vi /usr/local/etc/procmailrc
#
# Add this line:
MAILDIR=$HOME/Maildir/
DEFAULT=$HOME/Maildir/
DROPPRIVS=yes
LOGFILE=$HOME/proc.log

#
# spam to Junk Recipe
:0
*^X-Spam-Status: Yes
.Junk/

:: Configuring Postfix
[ root ]# vi /usr/local/etc/postfix/main.cf
#
# Add/uncomment this options:
mailbox_command = /usr/local/bin/procmail

:: Reload Postfix Service
[ root ]# postfix reload

:: Testink
+ Sending email
[ root ]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 mail.freebsd.org ESMTP Postfix
mail from:akoe@freebsd.org
250 2.1.0 Ok
rcpt to:free@freebsd.org
250 2.1.5 Ok
data
354 End data with .
subject:procmail test

XJS*C4JDBQADN1.NSBN3*2IDNEN*GTUBE-STANDARD-ANTI-UBE-TEST-EMAIL*C.34X

.
250 2.0.0 Ok: queued as E4A913476C
quit
221 2.0.0 Bye
Connection closed by foreign host.

+ Checking the logs
[ root ]# less /home/free/proc.log
From akoe@freebsd.org Sat Oct 24 08:52:51 2009
Subject: procmail test
Folder: .Junk/new/1256349171.14992_0.freebsd.org 2608
If Procmail processed the message successfully, you should see output like that.

:: Links
+ GoogleBSD
+ Procmail

:: Cannot re-assign $this

:: Error message
"Cannot re-assign $this blablabla" on PHP5 script.

:: Solution
Change variable $this to $value

:: Example
from:
 foreach ($p_arr as $this) {
$p_char = ( $i%3==0 ? "r" : ( $i%3==1 ? "w" : "x" ) );
$perms .= ( $this=="1" ? $p_char : "-" ) . ( $i%3==2 ? " " : "" );
$i++;
}

change to :
 foreach ($p_arr as $value) {
$p_char = ( $i%3==0 ? "r" : ( $i%3==1 ? "w" : "x" ) );
$perms .= ( $value=="1" ? $p_char : "-" ) . ( $i%3==2 ? " " : "" );
$i++;
}

:: Links
+ GoogleLinux
+ PHP5

:: Install SpamAssassin on FreeBSD 7.1

:: What is
Please take a look at this.

:: Install Dependency
Installing Postfix Mail Server with Maildir/ support

:: Installing SpamAssassin with DCC over Port
[ root ]# cd /usr/ports/mail/p5-Mail-SpamAssassin/
[ root ]# make -D WITH_DCC install clean
[ root ]# rehash
please enable on DKIM and SPF_QUERY options.

:: Installing DCCd over Port
[ root ]# cd /usr/ports/mail/dcc-dccd/
[ root ]# make -D WITHOUT_SENDMAIL install clean
[ root ]# rehash

:: Configuring SpamAssassin
+ Configure Razor
[ root ]# razor-admin -home=/var/spool/spamd/.razor -create
[ root ]# razor-admin -home=/var/spool/spamd/.razor -register -user=postmaster@freebsd.org
[ root ]# chown -R spamd /var/spool/spamd/.razor/

+ Configure local.cf SpamAssassin
[ root ]# vi /usr/local/etc/mail/spamassassin/local.cf
#
# Add this line :
#
trusted_networks 10.100.100.
internal_networks 10.100.100.32
bayes_file_mode 0770
dns_available yes
razor_config /var/spool/spamd/.razor/razor-agent.conf
add_header all DCC _DCCB_ _DCCR_
add_header ham SCL 1
add_header spam SCL 9

+ Checking SpamAssassin file configuration
[ root ]# spamassassin --lint
It's successfully if you don't get some error messages.

+ Configure Posfix to sync with SpamAssassin
[ root ]# vi /usr/local/etc/postfix/master.cf 
#
# Edit this options like:
smtp inet n - n - - smtpd -o content_filter=spamd

#
# Scroll to the bottom and add this line :
spamd unix - n n - - pipe
flags=R user=spamd argv=/usr/local/bin/spamc -e /usr/local/sbin/sendmail -oi -f ${sender} -- ${recipient}

+ Reload Postfix
[ root ]# postfix reload

+ Configure SpamAssassin to start automatically at boot up.
[ root ]# vi /etc/rc.conf
#
# Add this line:
spamd_enable="YES"
spamd_flags="-u spamd -H /var/spool/spamd"

:: Starting Spamd and Postfix
[ root ]# /usr/local/etc/rc.d/sa-spamd start
[ root ]# postfix reload

:: Testink
+ Sending email
[ root ]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 mail.freebsd.org ESMTP Postfix
mail from:akoe@freebsd.org
250 2.1.0 Ok
rcpt to:free@freebsd.org
250 2.1.5 Ok
data
354 End data with .
subject: spam test

XJS*C4JDBQADN1.NSBN3*2IDNEN*GTUBE-STANDARD-ANTI-UBE-TEST-EMAIL*C.34X
.
250 2.0.0 Ok: queued as AAECA3476C
quit
221 2.0.0 Bye
Connection closed by foreign host.


+ Checking the email
[ root ]# cat /home/free/Maildir/new/1256346819.V46I34999M364545.freebsd.org
Return-Path:
X-Original-To: free@freebsd.org
Delivered-To: free@freebsd.org
Received: by mail.freebsd.org (Postfix, from userid 58)
id 3BD6B3499A; Sat, 24 Oct 2009 08:13:39 +0700 (WIT)
Received: from localhost by freebsd.org
with SpamAssassin (version 3.2.5);
Sat, 24 Oct 2009 08:13:39 +0700
From: akoe@freebsd.org
To: undisclosed-recipients:;
Subject: spam test
Date: Sat, 24 Oct 2009 08:13:24 +0700 (WIT)
Message-Id: <20091024011327.aaeca3476c@mail.freebsd.org>
X-Spam-SCL: 9
X-Spam-DCC:
X-Spam-Flag: YES
X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on freebsd.org
X-Spam-Level: **************************************************
X-Spam-Status: Yes, score=999.1 required=5.0 tests=ALL_TRUSTED,AWL,GTUBE
autolearn=no version=3.2.5
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="----------=_4AE254C3.C39769BC"

This is a multi-part message in MIME format.

------------=_4AE254C3.C39769BC
Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: inline
Content-Transfer-Encoding: 8bit

Spam detection software, running on the system "freebsd.org", has
identified this incoming email as possible spam. The original message
has been attached to this so you can view it (if it isn't spam) or label
similar future email. If you have any questions, see
The administrator of that system for details.

Content preview: XJS*C4JDBQADN1.NSBN3*2IDNEN*GTUBE-STANDARD-ANTI-UBE-TEST-EMAIL*C.34X
[...]

Content analysis details: (999.1 points, 5.0 required)

pts rule name description
---- ---------------------- --------------------------------------------------
-1.4 ALL_TRUSTED Passed through trusted hosts only via SMTP
1000 GTUBE BODY: Generic Test for Unsolicited Bulk Email
0.5 AWL AWL: From: address is in the auto white-list



------------=_4AE254C3.C39769BC
Content-Type: message/rfc822; x-spam-type=original
Content-Description: original message before SpamAssassin
Content-Disposition: inline
Content-Transfer-Encoding: 8bit

Return-Path:
Received: from localhost (localhost [127.0.0.1])
by mail.freebsd.org (Postfix) with SMTP id AAECA3476C
for ; Sat, 24 Oct 2009 08:13:24 +0700 (WIT)
subject: spam test
Message-Id: <20091024011327.aaeca3476c@mail.freebsd.org>
Date: Sat, 24 Oct 2009 08:13:24 +0700 (WIT)
From: akoe@freebsd.org
To: undisclosed-recipients:;

XJS*C4JDBQADN1.NSBN3*2IDNEN*GTUBE-STANDARD-ANTI-UBE-TEST-EMAIL*C.34X

------------=_4AE254C3.C39769BC--

:: Links
+ GoogleBSD
+ Gumph
+ BuildingaServerwithFreeBSD

:: Installing Squirrelmail on FreeBSD 7.1


:: What is
Please take a look at this.

:: Installing dependency
Installing Apache, MySQL and PHP

:: Install SquirrelMail over Port on FreeBSD
[ root ]# cd /usr/ports/mail/squirrelmail
[ root ]# make install clean

:: Configure SquirrelMail for Postfix
+ Configuring config.php
[ root ]# cd /usr/local/www/squirrelmail/
[ root ]# ./configure
select :
2. Server Settings
1. Domain
change:
[example.com]: freebsd.org (yourdomain.tld)
select :
A. Update IMAP Settings : localhost:143 (other)
8. Server software : other
change :
[other]: courier
select :
s (save configure)
q (quit)

+ Make soft link for SquirrelMail
[ root ]# cd /usr/local/www/apache22/data
[ root ]# ln -s /usr/local/www/squirrelmail webmail

:: Testink
Open url http://yourdomain.tld/webmail on web browser client and login email account on it.

:: Links

:: Install Chrome on Ubuntu

:: What is
Please take a look at this.

:: Configure Repositories for Google Chrome
[ tox : ~ ]$ sudo vi /etc/apt/sources.list
#
# Add this line:
# Ubuntu 9.04
deb http://ppa.launchpad.net/chromium-daily/ppa/ubuntu jaunty main
deb-src http://ppa.launchpad.net/chromium-daily/ppa/ubuntu jaunty main

##
# Ubuntu 9.10
deb http://ppa.launchpad.net/chromium-daily/ppa/ubuntu karmic main
deb-src http://ppa.launchpad.net/chromium-daily/ppa/ubuntu karmic main

:: Add PGP key
[ tox : ~ ]$ sudo apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 0xfbef0d696de1c72ba5a835fe5a9bf3bb4e5e17b5

:: Update repositories
[ tox : ~ ]$ sudo apt-get update

:: Installing Google Chrome web browser
[ tox : ~ ]$ sudo apt-get install chromium-browser

:: Testink
Open GoogleChrome on Application - Internet - Chromium Web Browser



:: Links
+ GoogleLinux
+ UbuntuGeek

:: Courier IMAP on Postfix

:: What is
Please take a look at this.

:: Installing dependency
Install Postfix
Install Courier Authlib on Postfix

:: Configure Postfix to use Maildir/
[ root ]# vi /usr/local/etc/postfix/main.cf
#
# Change on this options:
#
home_mailbox = Maildir/

+ Restart Postfix service
[ root ]# /usr/local/etc/rc.d/postfix restart
postfix/postfix-script: stopping the Postfix mail system
postfix/postfix-script: starting the Postfix mail system

+ Make Maildir on user home directory
[ root ]# su - free
$ pwd
/usr/home/free
$ maildirmake Maildir
$ ls Maildir
cur new tmp
$ exit

:: Installing Courier IMAP on FreeBSD over Port
[ root ]# cd /usr/ports/mail/courier-imap/
[ root ]# make install clean
[ root ]# rehash

:: Configure Courier IMAP on Postfix
+ imapd-ssl
[ root ]# vi /usr/local/etc/courier-imap/imapd-ssl
#
# Change on this options:
#
TLS_CERTFILE=/usr/local/etc/postfix/ssl/smtpd.pem

+ pop3d-ssl
[ root ]# vi /usr/local/etc/courier-imap/pop3d-ssl
#
# Change on this options:
#
TLS_CERTFILE=/usr/local/etc/postfix/ssl/smtpd.pem

:: Set Courier IMAP to automatically start on boot up
[ root ]# vi /etc/rc.conf
#
# Add this line
#
# IMAP
courier_imap_imapd_enable="YES"
courier_imap_imapd_ssl_enable="YES"

###
# POP3
courier_imap_pop3d_enable="YES"
courier_imap_pop3d_ssl_enable="YES"

:: Starting Courier IMAP and POP3 Service
[ root ]# /usr/local/etc/rc.d/courier-imap-imapd start
Starting courier_imap_imapd.
[ root ]# /usr/local/etc/rc.d/courier-imap-imapd-ssl start
Starting courier_imap_imapd_ssl.
[ root ]# /usr/local/etc/rc.d/courier-imap-pop3d start
Starting courier_imap_pop3d.
[ root ]# /usr/local/etc/rc.d/courier-imap-pop3d-ssl start
Starting courier_imap_pop3d_ssl.

:: Testink
+ imap
[ root ]# telnet localhost 143
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
* OK [CAPABILITY IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA IDLE ACL ACL2=UNION STARTTLS] Courier-IMAP ready. Copyright 1998-2008 Double Precision, Inc. See COPYING for distribution information.
aa login free freepass
aa OK LOGIN Ok.
ab select inbox
* FLAGS (\Draft \Answered \Flagged \Deleted \Seen \Recent)
* OK [PERMANENTFLAGS (\* \Draft \Answered \Flagged \Deleted \Seen)] Limited
* 0 EXISTS
* 0 RECENT
* OK [UIDVALIDITY 1255697795] Ok
* OK [MYRIGHTS "acdilrsw"] ACL
ab OK [READ-WRITE] Ok
ac logout
* BYE Courier-IMAP server shutting down
ac OK LOGOUT completed
Connection closed by foreign host.

+ imap with ssl
[ root ]# openssl s_client -connect localhost:993
..
..
..
---
* OK [CAPABILITY IMAP4rev1 UIDPLUS CHILDREN NAMESPACE THREAD=ORDEREDSUBJECT THREAD=REFERENCES SORT QUOTA IDLE AUTH=PLAIN ACL ACL2=UNION] Courier-IMAP ready. Copyright 1998-2008 Double Precision, Inc. See COPYING for distribution information.
aa login free freepass
aa OK LOGIN Ok.
ab logout
* BYE Courier-IMAP server shutting down
ab OK LOGOUT completed
closed

+ pop3
[ root ]# telnet localhost 110
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
+OK Hello there.
user free
+OK Password required.
pass freepass
+OK logged in.
quit
+OK Bye-bye.
Connection closed by foreign host.

+ pop3d with ssl
[ root ]# openssl s_client -connect localhost:995
..
..
..
Verify return code: 18 (self signed certificate)
---
+OK Hello there.
user free
+OK Password required.
pass freepass
+OK logged in.
quit
+OK Bye-bye.
closed

:: Links
+ GoogleBSD
+ CourierIMAP

:: Courier Authlib on FreeBSD 7.1

:: What is
Please take a look at this.

:: Installing Courier Authlib on FreeBSD over Port
[ root ]# cd /usr/ports/security/courier-authlib
[ root ]# make install clean
[ root ]# rehash

:: Configure Courier Authlib
[ root ]# vi /usr/local/etc/authlib/authdaemonrc
#
# Change on authmodulelist to use only authpam options:
#
authmodulelist="authpam"

:: Configuru Courier Authlib to automatically start on boot up
[ root ]# vi /etc/rc.conf
#
# Add this line:
#
courier_authdaemond_enable="YES"

:: Starting Courier Authlib
[ root ]# /usr/local/etc/rc.d/courier-authdaemond start

:: Testink
[ root ]# /usr/local/etc/rc.d/courier-authdaemond status
courier_authdaemond is running as pid 86658.

:: Links
+ GoogleBSD

:: Enable TLS/SSL and SASL2 on Postfix

:: What is
Please take a look at this.

:: Installing Postfix with support TLS/SSL and/or SASL2 on FreeBSD over Port
[ root ]# cd /usr/ports/mail/postfix25/
[ root ]# make config; make install clean
[ root ]# rehash
Select TLS/SSL and/or SASL2 on config menu.
and then on Cyrus-SASL2 config menu, disable OTP support.

:: Installing Cyrus-SASL2-Saslauthd over Port
[ root ]# cd /usr/ports/security/cyrus-sasl2-saslauthd/
[ root ]# make install clean
[ root ]# rehash
[ root ]# vi /usr/local/lib/sasl2/smtpd.conf
#
# Add this line:
pwcheck_method: saslauthd
mech_list: plain login

:: Configure Postfix and Cyrus-SASL2-Saslauthd to automatically start on boot up
[ root ]# vi /etc/rc.conf
#
# Add this line:
#
saslauthd_enable="YES"
saslauthd_flags="-a pam"
postfix_enable="YES"
sendmail_enable="NO"
sendmail_submit_enable="NO"
sendmail_outbound_enable="NO"
sendmail_msp_queue_enable="NO"

:: Generate SSL Certificate for Postfix
[ root ]# mkdir /usr/local/etc/postfix/ssl
[ root ]# cd /usr/local/etc/postfix/ssl/
[ root ]# openssl req -new -x509 -nodes -out smtpd.pem -keyout smtpd.pem -days 3650

:: Configuring Postfix with TLS/SSL and SASL2
+ Configure main.cf file
[ root ]# vi /usr/local/etc/postfix/main.cf
#
# Configure on this options:
#
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
home_mailbox = Mailbox
myhostname = mail.freebsd.org
mydomain = freebsd.org
myorigin = $mydomain
inet_interfaces = all

# SASL2 configure for posfix
#
smtp_sasl_auth_enable = yes
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
smtpd_sasl_local_domain = $mydomain
broken_sasl_auth_clients = yes
smtp_sasl_password_maps = hash:/usr/local/etc/sasldb2
smtpd_sender_restrictions = permit_sasl_authenticated, permit_mynetworks
smtpd_recipient_restrictions = permit_sasl_authenticated, permit_mynetworks, reject_unauth_destination

# TLS/SSL config
#
smtp_use_tls = yes
smtpd_use_tls = yes
smtp_tls_note_starttls_offer = yes
smtpd_tls_loglevel = 1
smtpd_tls_recieved_header = yes
smtpd_tls_session_cache_timeout = 3600s
tls_random_source = dev:/dev/urandom
smtpd_tls_key_file = /usr/local/etc/postfix/ssl/smtpd.pem
smtpd_tls_cert_file = /usr/local/etc/postfix/ssl/smtpd.pem
smtpd_tls_CAfile = /usr/local/etc/postfix/ssl/smtpd.pem

+ Configure master.cf file
[ root ]# vi /usr/local/etc/postfix/master.cf
#
# configure/uncomment on this configuration
#
submission inet n - n - - smtpd
-o smtpd_enforce_tls=yes
-o smtpd_sasl_auth_enable=yes
-o smtpd_client_restrictions=permit_sasl_authenticated,reject

:: Starting Saslauthd and Postfix Service
[ root ]# /usr/local/etc/rc.d/saslauthd start
[ root ]# /usr/local/etc/rc.d/postfix start

:: Testink
[ root ]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 mail.freebsd.org ESMTP Postfix
ehlo localhost
250-mail.freebsd.org
250-PIPELINING
250-SIZE 10240000
250-VRFY
250-ETRN
250-STARTTLS
250-AUTH NTLM LOGIN PLAIN GSSAPI DIGEST-MD5 CRAM-MD5
250-AUTH=NTLM LOGIN PLAIN GSSAPI DIGEST-MD5 CRAM-MD5
250-ENHANCEDSTATUSCODES
250-8BITMIME
250 DSN
starttls
220 2.0.0 Ready to start TLS
quit
exit
Connection closed by foreign host.

:: Links
+ GoogleBSD
+ YoCum

:: Install Postfix on FreeBSD 7.1

:: Whati is
Please take a look at this.

:: Installing Postfix v35 over Port
[ root ]# cd /usr/ports/mail/postfix25/
[ root ]# make install clean
[ root ]# rehash
Durring installation, you will asking to add user and group for Postfix service, answer this question with yes [ y ].

:: Configuring Postfix
+ Configure main Postfix configuration file (main.cf)
[ root ]# vi /usr/local/etc/postfix/main.cf
mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain
home_mailbox = Mailbox
myhostname = mail.freebsd.org
mydomain = freebsd.org
myorigin = $mydomain
inet_interfaces = all

#
# this just example..
# you can change the options whatever you want..
#
####

+ Configure Postfix to automatically running on boot up
[ root ]# vi /etc/rc.conf
#
# Add this options:
#
postfix_enable="YES"
sendmail_enable="NO"
sendmail_submit_enable="NO"
sendmail_outbound_enable="NO"
sendmail_msp_queue_enable="NO"

+ Disable Sendmail specific daily maintenance routines
[ root ]# vi /etc/periodic.conf
#
# Add this options:
#
daily_clean_hoststat_enable="NO"
daily_status_mail_rejects_enable="NO"
daily_status_include_submit_mailq="NO"
daily_submit_queuerun="NO"

+ Make new aliases.db for Postfix
[ root ]# rm /etc/aliases.db
[ root ]# newaliases
/etc/mail/aliases: 27 aliases, longest 10 bytes, 275 bytes total
[ root ]# cp /etc/mail/aliases.db /etc/

:: Starting Postfix service
[ root ]# killall sendmail
[ root ]# /usr/local/etc/rc.d/postfix start

:: Testink
+ Sending email
[ root ]# telnet localhost 25
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
220 mail.freebsd.org ESMTP Postfix
mail from:andi@freebsd.org
250 2.1.0 Ok
rcpt to: free@freebsd.org
250 2.1.5 Ok
data
354 End data with .
hi there..
.
250 2.0.0 Ok: queued as 198B7344A4
quit
221 2.0.0 Bye
Connection closed by foreign host.

+ Receiving mail
[ root ]# less /usr/home/free/Mailbox
From andi@freebsd.org Mon Oct 12 22:19:14 2009
Return-Path:
X-Original-To: free@freebsd.org
Delivered-To: free@freebsd.org
Received: from localhost (localhost [127.0.0.1])
by mail.freebsd.org (Postfix) with SMTP id 198B7344A4
for ; Mon, 12 Oct 2009 22:18:56 +0700 (WIT)
Message-Id: <20091012151905.198b7344a4@mail.freebsd.org>
Date: Mon, 12 Oct 2009 22:18:56 +0700 (WIT)
From: andi@freebsd.org
To: undisclosed-recipients:;

hi there..

:: Links
+ GoogleBSD
+ Postfix

:: Installing Samba33 on FreeBSD 7.1

:: What is
Please take a look at this.

:: Installing Samba v33
[ root ]# cd /usr/ports/net/samba33
[ root ]# make install clean
[ root ]# rehash

:: Configuring Samba
+ Configure smb.conf file
[ root ]# ee /usr/local/etc/smb.conf
##
# Configuration Workgroup
workgroup = BLACKONSOLE

#
# Server info
#
server string = Samba Server

#
# Make folder sharing [example]
#
[sharingsamba]
comment = For your sharing
path = /usr/local/share
public = yes
writable = no

#
# you can configuring on other options on this file.
#####

+ Running Samba service automatically on boot up
[ root ]# ee /etc/rc.conf
##
# Add this line:
samba_enable="YES"

:: Add user for Samba Server
The usernames you specify should match those of their existing system accounts.
[ root ]# smbpasswd -a free
New SMB password:[freeonsambapass]
Retype new SMB password: [freeonsambapass]

:: Starting Samba Server
[ root ]# /usr/local/etc/rc.d/samba onestart

:: Testink
[ root ]# smbclient -U free -L localhost
Enter free's password:[freeonsambapass]
Domain=[FREEBSD] OS=[Unix] Server=[Samba 3.3.7]

Sharename Type Comment
--------- ---- -------
IPC$ IPC IPC Service (Samba Server)
sharingsamba Disk For your sharing
free Disk Home Directories
Domain=[FREEBSD] OS=[Unix] Server=[Samba 3.3.7]

Server Comment
--------- -------

Workgroup Master
--------- -------
MSHOME SIDIQ
BLACKONSOLE FREEBSD

:: Links
+ GoogleBSD
+ Samba

:: Fixing Failed to create cache file: maildirwatch error

:: Error
Oct 10 03:12:59 servers imapd: Failed to create cache file: maildirwatch (user)
Oct 10 03:12:59 servers imapd: Error: Input/output error
Oct 10 03:12:59 servers imapd: Check for proper operation and configuration
Oct 10 03:12:59 servers imapd: of the File Access Monitor daemon (famd).
Oct 10 03:12:59 servers imapd: Failed to create cache file: maildirwatch (user)
Oct 10 03:12:59 servers imapd: Error: Input/output error
Oct 10 03:12:59 servers imapd: Check for proper operation and configuration
Oct 10 03:12:59 servers imapd: of the File Access Monitor daemon (famd).

:: Solution
[ root: ~ ]# vi /etc/xinetd.d/fam
#
# Add "flags = NOLIBWRAP" optionts
#
# so the configuration like :
#
service fam
{
socket_type = stream
protocol = tcp
wait = yes
user = root
group = root
server = /usr/sbin/famd
disable = yes
type = RPC UNLISTED
rpc_version = 2
rpc_number = 391002
flags = NOLIBWRAP
}

:: Restart famd
[ root : ~ ]# /etc/init.d/fam restart
Shutting down File Access Monitoring Daemon done
Starting File Access Monitoring Daemon done

:: Links
+ GoogleLinux
+ Wains

:: PureFTP on FreeBSD 7.1

:: What is
Please take a look at this.

:: Installing PureFTPd over Port
[ root ]# cd /usr/ports/ftp/pure-ftpd
[ root ]# make install clean
[ root ]# rehash

:: Configuring PureFTPd

+ Configure main pure-ftpd.conf
[ root ]# cd /usr/local/etc/
[ root ]# cp pure-ftpd.conf.sample pure-ftpd.conf
[ root ]# ee pure-ftpd.conf
#
# Change configuration for virtual like:
PureDB /usr/local/etc/pureftpd.pdb
CreateHomeDir yes

# you can change other options
# with whatever you want
#######

+ Enable Pure-FTPd to automatically running on boot up
[ root ]# ee /etc/rc.conf
#
# Add this line:
pureftpd_enable="YES"

+ Make virtual user home directory
[ root ]# pw user add virftp -s /sbin/nologin -w no -d /usr/home/virftp -c "virtual pure virtual ftp users" -m

+ Make virtual user for ftp access [ uftp ]
[ root ]# pure-pw useradd uftp -u virftp -g virftp -d /usr/home/virftp/uftp
Password:[ uftp user pass ]
Enter it again: [ uftp user pass ]
[ root ]# pure-pw mkdb

+ Enable Anonymous ftp user
[ root ]# pw user add ftp -s /sbin/nologin -w -no -d /usr/home/ftp -c "anonymous ftp user" -m
[ root ]# mkdir /usr/home/ftp/upload
[ root ]# chmod 777 /usr/home/ftp/upload/

:: Starting Pure-FTPd
[ root ]# /usr/local/etc/rc.d/pure-ftpd onestart

:: Testink
[ root ]# ftp localhost
Trying 127.0.0.1...
Connected to localhost.
220---------- Welcome to Pure-FTPd [privsep] ----------
220-You are user number 1 of 50 allowed.
220-Local time is now 07:23. Server port: 21.
220-IPv6 connections are also welcome on this server.
220 You will be disconnected after 15 minutes of inactivity.
Name (localhost:free): uftp
331 User uftp OK. Password required
Password:[ uftp user pass ]
230-User uftp has group access to: 1002
230 OK. Current directory is /
Remote system type is UNIX.
Using binary mode to transfer files.
ftp>

[ root ]# ftp localhost
Trying 127.0.0.1...
Connected to localhost.
220---------- Welcome to Pure-FTPd [privsep] ----------
220-You are user number 1 of 50 allowed.
220-Local time is now 07:06. Server port: 21.
220-IPv6 connections are also welcome on this server.
220 You will be disconnected after 15 minutes of inactivity.
Name (localhost:free): anonymous
230 Anonymous user logged in
Remote system type is UNIX.
Using binary mode to transfer files.
ftp>

:: Links
+ GoogleBSD
+ PureFTPd

:: Install GnomeShell on Ubuntu 9.04

:: What is
Please take a look at this.

:: Installing dependency
[ tox : ~ ]$ sudo apt-get install libgstreamer0.10-dev libcroco3-dev xserver-xephyr xulrunner-dev python-dev libreadline5-dev libwnck-dev libgnome-desktop-dev libgnome-menu-dev libffi-dev libgconf2-dev libdbus-glib-1-dev gtk-doc-tools gnome-common git-core flex bison automake

:: Installing GnomeShell
[ tox : ~ ]$ pwd
/home/zie
[ tox : ~ ]$ mkdir gnomeshell
[ tox : ~ ]$ cd gnomeshell/
[ tox : gnomeshell ]$ curl -O http://git.gnome.org/cgit/gnome-shell/plain/tools/build/gnome-shell-build-setup.sh
[ tox : gnomeshell ]$ sh gnome-shell-build-setup.sh

:: Building GnomeShell
[ tox : gnomeshell ]$ ~/bin/jhbuild build

:: Running GnomeShell
[ tox : gnomeshell ]$ cd /home/zie/gnome-shell/source/gnome-shell/src/
[ tox : src ]$ ./gnome-shell --replace
~OR~
[ tox : src ]$ ./gnome-shell

:: Screenshoot



:: Links
+ GoogleLinux
+ LiveGnome

:: Install/Enable PDO MySQL on FreeBSD

:: What is
Please take a look at this.

:: Installing dependency
+ Installing Apache2
+ Installing PHP5

:: Installing PDO MySQL
[ root ]# cd /usr/ports/databases/php5-pdo_mysql
[ root ]# make install clean

:: Restart Apache2 service
[ root ]# /usr/local/etc/rc.d/apache22 restart

:: Testink
[ root ]# php -m | grep pdo
pdo_mysql
pdo_sqlite

:: Links
+ GoogleBSD
+ DerKeiler

:: Installing PhpMyAdmin on FreeBSD 7.1

:: What is
Please take a look at this.

:: Installing MySQL Server
Please take a look at this

:: Installing PHPMyAdmin over Port
[ root ]# cd /usr/ports/databases/phpmyadmin
[ root ]# make config; make install clean
Select MYSQLI to enable MySQL database server.


:: Configuration PhpMyAdmin
[ root ]# cd /usr/local/www/phpMyAdmin/
[ root ]# ee config.inc.php
<?php
/*
* Add configuration like :
*
*/
$cfg['blowfish_secret'] = '4fj8Rv15ZFls16Lei23qrn42';
$i = 1;
$cfg['Servers'][$i]['connect_type'] = 'socket';
$cfg['Servers'][$i]['auth_type'] = 'cookie';
$cfg['Servers'][$i]['extension'] = 'mysqli';
?>

:: Testink
[ root ]# cd /usr/local/www/apache22/data/
[ root ]# ln -s /usr/local/www/phpMyAdmin phpmyadmin
open your web browser clients, and goto url : http:/yourip/phpmyadmin or http://domain.tld/phpmyadmin


:: Links
+ GoogleBSD
+ PhpMyAdmin

:: Installing PHP5 on FreeBSD 7.1

:: What is
Please take a look this.

:: Installing Apache2
Please take a look at this.

:: Install PHP5 over Port
[ root ]# cd /usr/ports/lang/php5
[ root ]# make config; make install clean
[ root ]# rehash
[ root ]# cd /usr/ports/lang/php5-extensions/
[ root ]# make config; make install clean
[ root ]# rehash
:: Make php.ini file for PHP5 configuration
[ root ]# cd /usr/local/etc/
[ root ]# cp php.ini-recommended php.ini

:: Configuring PHP5 to integrated with Apache2
[ root ]# ee /usr/local/etc/apache22/httpd.conf
#
# Add index.php on DirectoryIndex
<IfModule dir_module>
DirectoryIndex index.php index.html
</IfModule>

#
# Add this option on <IfModule mime_module>
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps

:: Restart Apache2 Service
[ root ]# /usr/local/etc/rc.d/apache22 restart

:: Testink
+ Make info.php file on Apache2 data directory:
[ root ]# ee /usr/local/www/apache22/data/info.php
add this line:
<?php
phpinfo();
?>

+ Take a look info.php
open your web browser client and goto http://ip/info.php or http://domain.tld/info.php


:: Links
+ GoogleBSD
+ PHP5

:: Installing Apache2 on FreeBSD 7.1

:: What is
Please take a look at this.

:: Installing Apache2 over Port
[ root ]# cd /usr/ports/www/apache22
[ root ]# make config; make install clean
[ root ]# rehash

:: Configuring Apache2
+ Configure httpd.conf file
[ root ]# ee /usr/local/etc/apache22/httpd.conf
#
# Configure at this options:
ServerAdmin contact@domain.tld
ServerName domain.tld

#
# and other options whatever you want..
####

+ Configure Apache to start automatically at boot up
[ root ]# ee /etc/rc.conf
#
# Add this options:
apache22_enable="YES"
apache22_http_accept_enable="YES"

:: Starting Apache2 Service
[ root ]# /usr/local/etc/rc.d/apache22 start

:: Testink
[ root ]# telnet localhost 80
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
[return]
[return]
GET / HTTP/1.0
[return]
HTTP/1.1 200 OK
Date: Wed, 07 Oct 2009 03:41:32 GMT
Server: Apache/2.2.13 (FreeBSD) mod_ssl/2.2.13 OpenSSL/0.9.8e DAV/2 PHP/5.2.11 with Suhosin-Patch
Last-Modified: Sat, 20 Nov 2004 20:16:24 GMT
ETag: "4019c-2c-3e9564c23b600"
Accept-Ranges: bytes
Content-Length: 44
Connection: close
Content-Type: text/html

<h1>It works!</h1>Connection closed by foreign host.

:: Links
+ GoogleBSD
+ Apache

:: Installing MySQL on FreeBSD 7.1

:: What is
Please take a look at this.

:: Installing MySQL Server over Port
[ root ]# cd /usr/ports/databases/mysql50-server/
[ root ]# make -D BUILD_OPTIMIZED install clean
[ root ]# rehash

:: Configuring MySQL Server
+ Installing db needed by MySQL
[ root ]# mysql_install_db --user=mysql

+ Running MySQLD
[ root ]# mysqld_safe &

+ Change root user password on MySQL
[ root ]# mysqladmin -u root password 'mysqldpassword'

+ Enable MySQL to start automatically at system startup
[ root ]# ee /etc/rc.conf 
#
# Add this configuration
mysql_enable="YES"

:: Testink
[ root ]# mysql -u root -p
Enter password: [mysqldpassword]
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 1
Server version: 5.4.2-beta-log FreeBSD port: mysql-server-5.4.2

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql>

~OR~

[ root ]# mysqlshow -u root -p
Enter password: [mysqldpassword]
+--------------------+
| Databases |
+--------------------+
| information_schema |
| mysql |
| test |
| testink |
+--------------------+

:: Links
+ GoogleBSD
+ MySQL
:: Cheap Web Hosting :: ~ only from Rp. 900/mo; 250Mb/mo of Bandwidth ~ :: Web Hosting Murah Meriah :: ~ mulai dari Rp. 900/bln; Bandwidth 250Mb/bln ~