Ubuntu 10.04 server installation PDF Print E-mail
User Rating: / 3
PoorBest 
Written by Bart Dorlandt   
Sunday, 30 May 2010 15:13
Article Index
Ubuntu 10.04 server installation
Configuration System
Configuration Webserver
Configuration Mailserver
Used Links
All Pages

This is my "not-to-forget-steps-when-installing-ubuntu-server" document. It can be incomplete on its own. If you miss anything, take a look at the links I used.

Install a minimal server with F4 from the install screen.

Packages

Next you see a list of packages, but what for? These packages are used to run a system with the following services:

  • webserver with support for a mysql backend which supports php. This configuration allows you to run joomla and gallery2 for example. NOTE: we will be downgrading PHP5.3 to PHP5.2 because of joomla. (1.5.18)
  • Mailserver using postfix, dovecot, sasl, amavis, clamav, fetchmail, spamassassin. With this you have a complete mailsystem for a secure and spamfree mailbox. Also I use dovecot for quotas and it allows to have server based filters using the sieve plugin.
  • Subversion to have a versioning system on your scripts (like CVS)

It also delivers some security:

  • rootkit check tool by rootkit hunter
  • denying access from unwanted system with the use of denyhosts

Before we begin installing packages. We first make sure we have the right sources from karmic for PHP5.2.

Add the folliwng to /etc/apt/sources.list.d/karmic.list

deb http://nl.archive.ubuntu.com/ubuntu/ karmic main restricted
deb-src http://nl.archive.ubuntu.com/ubuntu/ karmic main restricted
deb http://nl.archive.ubuntu.com/ubuntu/ karmic-updates main restricted
deb-src http://nl.archive.ubuntu.com/ubuntu/ karmic-updates main restricted
deb http://nl.archive.ubuntu.com/ubuntu/ karmic universe
deb-src http://nl.archive.ubuntu.com/ubuntu/ karmic universe
deb http://nl.archive.ubuntu.com/ubuntu/ karmic-updates universe
deb-src http://nl.archive.ubuntu.com/ubuntu/ karmic-updates universe
deb http://nl.archive.ubuntu.com/ubuntu/ karmic multiverse
deb-src http://nl.archive.ubuntu.com/ubuntu/ karmic multiverse
deb http://nl.archive.ubuntu.com/ubuntu/ karmic-updates multiverse
deb-src http://nl.archive.ubuntu.com/ubuntu/ karmic-updates multiverse
deb http://security.ubuntu.com/ubuntu karmic-security main restricted
deb-src http://security.ubuntu.com/ubuntu karmic-security main restricted
deb http://security.ubuntu.com/ubuntu karmic-security universe
deb-src http://security.ubuntu.com/ubuntu karmic-security universe
deb http://security.ubuntu.com/ubuntu karmic-security multiverse
deb-src http://security.ubuntu.com/ubuntu karmic-security multiverse

execute the following commands: (as root)

echo -e "Package: php5\nPin: release a=karmic\nPin-Priority: 991\n"  | sudo tee /etc/apt/preferences.d/php > /dev/null
apt-cache search php5-|grep php5-|awk '{print "Package:", $1,"\nPin: release a=karmic\nPin-Priority: 991\n"}'|sudo tee -a /etc/apt/preferences.d/php > /dev/null
apt-cache search -n libapache2-mod-php5 |awk '{print "Package:", $1,"\nPin: release a=karmic\nPin-Priority: 991\n"}'| sudo tee -a /etc/apt/preferences.d/php > /dev/null
echo -e "Package: php-pear\nPin: release a=karmic\nPin-Priority: 991\n"  | sudo tee -a /etc/apt/preferences.d/php > /dev/null

apt-get update
apt-get install libapache2-mod-php5 php-db php-net-sieve php-net-socket php-pear php5 php5-cli php5-common php5-curl php5-dev php5-gd php5-idn php5-imagick php5-imap php5-mcrypt php5-memcache php5-ming php5-mysql php5-ps php5-pspell php5-recode php5-snmp php5-sqlite php5-tidy php5-xmlrpc php5-xsl phpmyadmin phpsysinfo

You'll get a warning that a few packages will be downgraded. And that is a good thing in this case.

Security / tools / connectivity

denyhosts gnupg nmap openssh-server ssh traceroute screen subversion ntp ntpdate rkhunter whois policykit lynx

Webserver (including packages for gallery/joomla, like ffmpeg, imagemagick, gd)

apache2-mpm-itk  mailgraph mysql-server imagemagick ffmpeg libapache2-mod-auth-mysql jhead

Mailserver

postfix postfix-mysql postgrey sasl2-bin libpam-mysql amavisd-new clamav fetchmail spamassassin dovecot-imapd dovecot-pop3d clamav-daemon zoo unzip bzip2 libnet-ph-perl libnet-snpp-perl libnet-telnet-perl nomarch lzop pax arj unrar cabextract fetchmailconf zip razor pyzor php-pear libhtml-parser-perl libdb-file-lock-perl libnet-dns-perl mailutils pflogsumm rar

 

DCC (part of the anti spam solution)

Unfortunately, DCC isn't part of the repository, so we do it by hand. You might want to check for a newer version. I found the files here. (I took the karmic files)

cd /tmp
wget http://ppa.launchpad.net/jonasped/ppa/ubuntu/pool/main/d/dcc/dcc-common_1.3.113-0ubuntu1~ppa1~karmic1_i386.deb wget http://ppa.launchpad.net/jonasped/ppa/ubuntu/pool/main/d/dcc/dcc-server_1.3.113-0ubuntu1~ppa1~karmic1_i386.deb

dpkg -i dcc-common_1.3.113-0ubuntu1~ppa1~karmic1_i386.deb dpkg -i dcc-server_1.3.113-0ubuntu1~ppa1~karmic1_i386.deb

Here is the output of dpkg --get-selections. file. You may install it all by using:

dpkg --set-selections < file
apt-get dselect-upgrade


Last Updated on Wednesday, 02 June 2010 13:29
 


Related items: