Friday, September 28, 2007

Install Debian by USB Thumb Drive

The following script can make an USB Thumb Drive as a Debian installation disk. Insert the USB Thumb Drive into the PC before running the script. This script assumes the USB Thumb Drive is /dev/sda which may be different on your system.
Please note: Everything on the USB Thumb Drive will be erased after running this script.

#!/bin/bash
wget -c http://cdimage.debian.org/debian-cd/4.0_r1/i386/iso-cd/debian-40r1-i386-businesscard.iso
wget -c http://ftp.nl.debian.org/debian/dists/etch/main/installer-i386/current/images/hd-media/boot.img.gz
echo "Copy boot image..."
zcat boot.img.gz > /dev/sda
echo "Copy businesscard.iso..."
mount /dev/sda /mnt
cp debian-40r1-i386-businesscard.iso /mnt/businesscard.iso
umount /mnt
echo "Make disk bootable..."
syslinux /dev/sda

Saturday, September 8, 2007

Install Apache2 on Debian

The Debian source at http://ftp.hk.debian.org seems missing some files for Apache2. Therefore, I change the Debian source to http://http.us.debian.org. Edit the file /etc/apt/sources.list:
#
# deb cdrom:[Debian GNU/Linux 4.0 r0 _Etch_ - Official i386 NETINST Binary-1 20
deb cdrom:[Debian GNU/Linux 4.0 r0 _Etch_ - Official i386 NETINST Binary-1 2007
deb http://http.us.debian.org/debian/ etch main
deb-src http://http.us.debian.org/debian/ etch main
deb http://security.debian.org/ etch/updates main contrib
deb-src http://security.debian.org/ etch/updates main contrib

Run apt-get update every time you change the sources.list.
# apt-get update

Install Apache2:
# apt-get install apache2

Test the installation:
Point the browser to http://192.168.0.66/apache2-default/ and the following returns:

It works!

Reference:
http://www.debian.org/doc/manuals/apt-howto/ch-apt-get.en.html

Friday, September 7, 2007

Asterisk Call Files

Call files are like a shell script for Asterisk. A user or application writes a call file into /var/spool/asterisk/outgoing/ where Asterisk processes it immediately.

http://www.the-asterisk-book.com/unstable/call-file.html

On-line Book - Practical Asterisk 1.4 (unstable)


The "Practical Asterisk 1.4 (unstable)" is a work in progress English translation of the original German book of Stefan Wintermeyer. This early version is placed online to find bugs and feedback.

http://www.the-asterisk-book.com/unstable/