From ArchWiki
Revision as of 06:57, 17 June 2010 by Ptmkenny (talk | contribs) (reworked the installation section, added more resources section)
Jump to: navigation, search

This template has only maintenance purposes. For linking to local translations please use interlanguage links, see Help:i18n#Interlanguage links.

Local languages: Català – Dansk – English – Español – Esperanto – Hrvatski – Indonesia – Italiano – Lietuviškai – Magyar – Nederlands – Norsk Bokmål – Polski – Português – Slovenský – Česky – Ελληνικά – Български – Русский – Српски – Українська – עברית – العربية – ไทย – 日本語 – 正體中文 – 简体中文 – 한국어

External languages (all articles in these languages should be moved to the external wiki): Deutsch – Français – Română – Suomi – Svenska – Tiếng Việt – Türkçe – فارسی


This document describes how to set up Drupal (6.x) with Apache, MySQL or PostgreSQL, PHP, and Postfix! This document assumes that you have some sort of LAMP (Apache, MySQL, PHP) or LAPP (Apache, PostgreSQL, PHP) server already setup.


Install Drupal

from Arch repositories

pacman -S drupal

manual install

  1. Download the latest package from http://drupal.org and extract it.
  2. Move the folders to apache's htdocs folder.
  3. Open a web browser, and navigate to "localhost"
  4. Follow the on-screen instructions.

Installing GD

You may need the GD library for your Drupal installation.

  1. Install the package
    # pacman -S php-gd
  2. Open the file /etc/php/php.ini with your editor of choice, e.g.
    # nano /etc/php/php.ini
  3. Find the line that starts with, ";extension=gd.so" and change it to, "extension=gd.so". (Just remove the preceding ";"). If this line is not present, add it. This line may be in the "Dynamic Extensions" section of the file, or toward the very end of the file.
  4. Restart the Apache web server
    /etc/rc.d/httpd restart

Installing Postfix

In order to send e-mails with Drupal, you will need to install postfix. Drupal uses e-mails for account verification, password recovery, etc.

  1. Install Postfix
    # pacman -S postfix 
  2. Configure Postfix as needed
    # nano /etc/postfix/main.cf 
    All that you should have to do is change the hostnames under "Internet Host and Domain Names"
     myhostname = hostname1 

    And then start the Postfix service:
    # /etc/rc.d/postfix start
  3. Send a test e-mail to yourself
     mail myusername@localhost 
    (Enter a subject, some words in the body, then press ctrl+d to exit and send the letter) Wait 10 seconds, and then type mail to check your mail. If you've gotten it, excellent.
  4. Make sure Port 25 is fowarded if you have a router so that mails can be sent to the internet at large
  5. Open the file /etc/php/php.ini with your editor of choice, e.g.
    # nano /etc/php/php.ini
  6. Find the line that starts with, ;sendmail_path="" and change it to, sendmail_path="/usr/sbin/sendmail -t -i"
  7. Restart the Apache web server
    /etc/rc.d/httpd restart

Tips and Tricks

Scheduling with Cron

Drupal recommends running cron jobs hourly. Cron can be executed from the browser by visiting localhost/cron It is also possible to run cron via script by copying the appropriate file from the "scripts" folder into "/etc/cron.hourly" and making it executable.

Xampp Compatibility

The 5.x and 6.x series of Drupal do not support PHP 5.3, and as a result are incompatible with the latest release of Xampp. Currently, the last Drupal-compatible version of Xampp is 1.7.1.

Note: Xampp's PHP memory limit currently defaults to 8MB. Also, Xampp ignores php.ini files in the Drupal directory. To fix this:

  1. edit Xampp's php.ini file using your favorite editor.
    nano /opt/lampp/etc/php.ini
  2. Search for the "memory_limit" line, and replace it with an appropriate value. (Most Drupal installations are happy with 32M, but sites with a lot of modules may need 100M or more.)
  3. Restart Xampp.
    /opt/lampp/lampp restart

More Resources