Virtual Hosts with Apache

The Apache Web Server offers the possibility to run multiple web-sites with different hosts simultaneously. The pages www.MeineSeite.de and www.Beispiel.de can therefore run on the same server and Apache. A requirement for this is that every host is connected to a virtual host in Apache.
On Linux (Debian/Ubuntu) virtual hosts are defined in the directory /etc/apache2/sites-available/. By default there is already one file named default created for one virtual host. It might look like this.

Category: 

Localisation of Debian

After Debian is installed on the BeagleBone, the localization must be adjusted so that the correct fonts are available.
By default, the location is set to "en_US", but this font can not display German characters and some special characters.
So the correct fonts must be installed.

So in Debian type the command

dpkg-reconfigure locales

A menu will appear where you can easily select to install fonts.

spdns Dynamic DNS Update-Client

Dyn stops its free service.

I've chosen Spdns as an alternative. A service of Secure Point GmbH .
One may invest up to 5 hosts there and can choose between several top-levels-domains.
Registration is simple and straightforward and requires only a username/password and an email-address for submission.
You can reach the service at spdns.de .

The only problem was that my router has no way to deal with this service.

PostgreSQL PostGIS create template_postgis

If spatial data need to be stored in a database, usually PostgreSQL with its PostGIS-extension is the first choice.
In order to create databases that can work with geographic data, you must specify a template when creating the database, which copies the necessary extensions, data types and functions to the new database. This template is usually named template_postgis and is generated automatically, when the PostGIS extension is installed .

Category: 

Beaglebone Black Heartbeat LED

If the BeagleBone Black is running as small server in continuous operation like mine, the flashing heartbeat LED is sometimes quite disturbing. It should indicate whether the system is still working, but as it continues to flash when the server has already set his service, it doesn't really make any sense in that case.

The BeagleBone Black has 4 built-in LEDs that can be affected by the user. They are denoted by usr0 to usr3.
The settings for them are in the folder /sys/class/leds/

Swap-File on a Beaglebone Black

If you want to use a Beaglebone Black or Raspberry Pi as a small server, it makes sense to give him a little swap space.
But if you you are not able to use an own swap-partition, you can use a swap-file.

This can be done in a few steps

  1. Create a file in the desired size
    The easiest way is to use the universal tool dd. The command is:
    dd if=/dev/zero of=/Path-to-File/swapfile bs=1M count=size of the paging file

    So if you want to have a 128 (256, 512) megabyte swap file, the command would be:

Using Raspberry Pi or Beaglebone Black as Mail-Server

If you are working with more than one computer you might know this problem - your incoming and outgoing mails are spread over your several computers and often enough you have to search one specific mail on several machines.

To avoid that an IMAP-Mailbox with enough storage ist the best solution. But if you are not in the comfortable situation that someone has already done that for you, you might want to build one on your own.

I decided to use my Raspberry Pi to achieve that.

Pages