Debian Tutorials Copy/Paste tutorials for Debian based Linux distros

12Aug/114

How to install LAMP (Apache, PHP and MySql in Linux)

Trac
Here's a basic guide on how to get Apache2, PHP5 and MySql working on most Debian based distros in a few easy steps.

1. Install Apache2 and PHP5 (as an Apache module)

apt-get install apache2 php5 libapache2-mod-php5 php5-mysql

9Aug/110

Installing and configuring Trac and Subversion on squeeze

TracTrac is an enhanced wiki and issue tracking system for software development projects. Trac uses a minimalistic approach to web-based software project management.

Trac allows wiki markup in issue descriptions and commit messages, creating links and seamless references between bugs, tasks, changesets, files and wiki pages. A timeline shows all current and past project events in order, making the acquisition of an overview of the project and tracking progress very easy. The roadmap shows the road ahead, listing the upcoming milestones.

Install and configure Trac and subversion

1. Install required packages for both Trac and Subversion. We'll be using Apache to publish the Subversion repositories

apt-get install python-setuptools trac subversion libapache2-svn libapache2-mod-python
a2enmod dav_fs

5Aug/111

Installing eAccelerator

eAccelerator is a free open-source PHP accelerator & optimizer. It increases the performance of PHP scripts by caching them in their compiled state, so that the overhead of compiling is almost completely eliminated. It also optimizes scripts to speed up their execution. eAccelerator typically reduces server load and increases the speed of your PHP code by 1-10 times.

eAccelerator only works with mod_php or php in fastcgi mode. It can't be used in cgi or cli because eAccelerator needs to set up shared memory, and this can only be done when all php instances that need to access it are forks of the first process.

1. Download the eAccelerator source. The latest version is mirrored on www.debiantutorials.com as it's not available on the official site anymore.

cd /tmp
wget http://www.debiantutorials.com/static/eaccelerator-0.9.6.1.tar.bz2

31May/110

Running Apache2 virtual hosts as different users with mpm-itk

apache2-mpm-itk is an MPM (Multi-Processing Module) for the Apache web server. mpm-itk allows you to run each of your vhost under a separate uid and gid — in short, the scripts and configuration files for one vhost no longer have to be readable for all the other vhosts.

1. Install the apache2-mpm-itk package

apt-get install apache2-mpm-itk

9Jun/101

OpenID authentication with the mod_auth_openid Apache module

mod_auth_openid is an authentication module for the Apache 2 webserver. It handles the functions of an OpenID consumer as specified in the OpenID 2.0 specification.

After a user authenticates themselves, the user's identity will be available in the REMOTE_USER variable. A cookie named open_id_session_id is saved to maintain each user's session.

1. Install the module

apt-get install libapache2-mod-auth-openid

1Jun/101

Install mod_spamhaus Apache module to fight comment spam

mod_spamhaus is an Apache module for DNS Block Listing that protects web services by denying access to particular IP addresses. It can stop spam relaying via web form URL injection, and block HTTP DDoS attacks from bot-nets.

It queries sbl-xbl.spamhaus.org, taking advantage of the Spamhaus Block List (SBL) and the Exploits Block List (XBL).

1. Download the latest mod_spamhaus deb package from sid package repository (mod_spamhaus is not available for lenny but we can use the sid package)

wget http://ftp.us.debian.org/debian/pool/main/m/mod-spamhaus/libapache2-mod-spamhaus_0.7-1_i386.deb

2May/100

Installing EHCP (Easy Hosting Control Panel)

ehcpEHCP is a powerful, yet easy to install control panel that allows the user to manage services such as Web, FTP, Database and DNS servers.

The install script handles the installation and configuration of the required services. I recommend starting with a clean Debian system to avoid conflicts.

1. Download required EHCP files

wget http://www.ehcp.net/download

27Feb/103

Installing the GeoIP Apache module

This module allows you to determine which country, region, city, postal code, area code the visitor is coming from.

1. Install the module

apt-get install libapache2-mod-geoip

29Jan/100

Install XCache

XCache is a fast, stable PHP opcode cacher that has been tested and is now running on production servers under high load. It overcomes a lot of problems that has been with other competing opcachers such as being able to be used with new PHP versions.

1. Installing the XCache package

apt-get install php5-xcache

1Jan/101

Installing suPHP

suPHP is a tool for executing PHP scripts with the permissions of their owners. It consists of an Apache module (mod_suphp) and a setuid root binary (suphp) that is called by the Apache module to change the uid of the process executing the PHP interpreter.

1. Install suPHP

apt-get install libapache2-mod-suphp