Log of setting up a "test" virtual server on apache2 under Linux.

Equipment HP Pavilion 6745C/700 MHz Celeron/256MB ram. I'm using gvim as an editor.

Step 1, Add host to /etc/hosts:
sudo gvim /etc/hosts
Before the IPv6 section (if you have one), add: latte

In this case "latte" is my virtual hostname.

Step 2, Add a new configuration file for the virtual host:
cd /etc/apache2/sites-available
cp default latte.conf
The naming of the configuration file is somewhat arbitrary, but I used {hostname description}.conf.

Step 3, Edit the configuration file:
sudo gvim latte.conf

Change the following lines and save your configuration file:
NameVirtualHost *

DocumentRoot /var/www

to the following:
NameVirtualHost latte

DocumentRoot /var/www/latte

Your original "DocumentRoot" may be different, but the new value should be the root directory for website files.

Step 4, Link to the configuration file in the "sites-enabled" directory:
cd /etc/apache2/sites-enabled/
sudo ln -s /etc/apache2/sites-available/latte.conf latte.conf

or in Debian (and by derivation, Ubuntu):
a2ensite latte.conf

Step 5, Reload the apache configuration file:
sudo /etc/init.d/apache2 reload

Step 6, Browse to your virtual server to check your work:
firefox http://latte

Manually adding a PCI display card.


  • HP Pavilion 6745C
  • 256 MB ram
  • Kubuntu 6.10 (Edgy Eft)
  • eVGA (nVidia) GeForce4 MX 4000 PCI

I've had persistent problems with the i810 on-board vga with virtually every install of Linux that I've tried with this PC (with the exception of damnsmalllinux). Between that and its poor performance, I added a MX 4000 to this PC. However, recent distributions have failed to even properly recognize the card at install/configuration time, so I had to take some indirect steps to add the device.

Step 1:
Install Kubuntu using i810. This required setting bios to use the "AGP" video card (in this case AGP=onboard video). I had the MX 4000 PCI card installed for this as well, but not hooked to a monitor.

Step 2:
Run "lspci" at a shell prompt. At the end of my listing was:

01:0d.0 VGA compatible controller: nVidia Corporation NV18 [GeForce4 MX 4000 AGP 8x] (rev c1)

Step 3:
At a shell prompt, run "sudo vim /etc/X11/xorg.conf" (substitute your favorite editor for vim). I copied and pasted the following section:

Section "Device"
Identifier "Intel Corporation 82810 ..."
Driver "i810"
BusID "PCI:0:1:0"

I modified my new section to read:

Section "Device"
Identifier "NVidia"
Driver "nv"
BusID "PCI:1:13:0"

The "Identifier" value must be copied in a later section, so the value doesn't matter as much as the consistency of that value. The 1:13:0 is from the lspci output (01:0d.0, where 0d in hex = 13 in decimal). "nv" is the free nVidia compatible driver. I may later apply the proper nVidia driver (instructions in a previous post).

Step 4:
Still in xorg.conf, I modified the "Screen" section (Section "Screen") by replacing "Intel Corporation 82810..." with "NVidia" on the Device line.

Section "Screen"
Identifier "Default Screen"
Device "Nvidia"

Step 5:
Save xorg.conf and restart X (Ctrl-Alt-Bksp on an X screen). X will now start on the nVidia card.

Step 6:
Reboot, switch bios to use "PCI" as the primary display. Save BIOS.

Step 7:
Plug monitor into nVidia card, and boot with new BIOS settings.

- Get both devices working on this PC as two separate displays.
- Install "proper" nVidia drivers.

Discovered bluetooth keyboard and mouse was not working.

More fallout from upgrading to Edgy Eft, my bluetooth keyboard and mouse no longer worked. This post on ubuntu forums was the best consolidated set of instructions on how to configure bluetooth (which worked without configuration before upgrade, by the way).

I ended using "/etc/init.d/bluetooth restart" instead of "/etc/init.d/bluez-utils restart". However, I've only been able to restore the connection to my mouse, not my keyboard.

HOWTO: Bluetooth Keyboard and Mouse

Needed to reinstall nvidia driver on Edgy Eft.

Did a distro upgrade on Kubuntu to 6.10. Everything was working nicely--firefox 2.0, etc... but I hadn't rebooted yet. My linux box isn't a critical system at work, it's subjected to the whims of the neighborhood power grid. Thus, it had to be turned on after the long weekend. This morning, I discovered that I needed to reinstall the nvidia drivers. The post linked to below contains the details, but if you had the nvidia splash screen prior to 6.10, the line below is probably all you need:

sudo aptitude install linux-generic linux-restricted-modules-`uname -r`

Install the Nvidia driver on Edgy Eft

In case there are module difference issues, different display driver versions are available from nVidia here.

select() system call in Linux vs. other *nix flavors

From the Linux Programmer's Manual:
"On Linux, the function select modifies timeout to reflect the amount of time not slept; most other implementations do not do this. This causes problem both when Linux code which reads timeout is ported to other operating systems, and when code is ported to Linux that reuses a struct timeval for multiple selects in a loop without reinitializing it. Consider timeout to be undefined after select returns."

Success for Dummies

This book is an excellent inspirational dummies book by Zig Ziglar. Covered in this book are topics from defining success to setting goals to staying focused and positive on your goals. Success in work, life, parenting, and marriage are covered. If you're familiar with any of Zig Ziglar's writing or courses, this book will have a familiar ring to it.