how to manually install WordPress on Debian Squeeze

aptitude install wordpress

cd /usr/share/doc/wordpress/examples
./setup-mysql -n wordpress solaris.subvento.local
a2enmod rewrite && a2enmod vhost_alias && /etc/init.d/apache2 restart

vim /etc/apache2/sites-available/default

Alias /blog /usr/share/wordpress

Options FollowSymLinks
AllowOverride Limit Options FileInfo
DirectoryIndex index.php

How to start a local moinmoin on Windows XP

#moinmoin
http://moinmo.in/DesktopEdition/HowToConfigure

C:\_Daten\Wiki\wiki\config -> hier liegt die Wiki Config Datei
http://localhost:8080/LanguageSetup?action=language_setup laufen lassen und danach

C:\_Daten\Wiki\wikiconfig.py ändern
Kommentar entfernen
page_front_page = u’FrontPage’ # change to some better value

C:\Python27\python.exe wikiserver.py
http://localhost:8080

Rsync Backup vom Mac zum Linux Server

Mounten des Linux Shares

Nicht vergessen, vorher ~/mnt/tux/joerg Verzeichnis anzulegen

mount -t smbfs //joerg@tux/joerg ~/mnt/tux/joerg

Danach mit Rsync kopieren

sync -rca -verbose -h ~/Pictures/ ~/mnt/tux/joerg/Backups/macbook/Pictures/

Wenn alles geklappt hat, noch den –delete  Befehl hinzufügen. Dieser löscht Dateien im Ziel, die es in der Quelle nicht mehr gibt.

no-ip – self made script

Sometimes my DSL Modem (that has a build in dyndns Client) hangs, and it stops updating
the no-ip.org Server.

I have some notes on my Atom based Linux Server at home and it bugs me if i can’t connect via
ssh from the office.

I wrote a script to mail me the new public ip address as soon as it is changing.
If you have a linux pc/server at home you can do the following by yourself:

put the following php script to your webserver – give it a fancy name like “myip.php”
<blockquote>&lt;? echo $_SERVER[‘REMOTE_ADDR’] ?&gt;</blockquote>
Start the following  script
<blockquote>crontab -l

# m h  dom mon dow   command
0   *   *   *  *    ~/bin/update_ip/update_ip.sh&gt;/dev/null 2&gt;&amp;1

&nbsp;</blockquote>
on your local linux server:
<blockquote>#!/bin/bash

cd ~/bin/update_ip

LAST_IP=`cat .last_ip`
IP=`curl -s -o – http://mywebserver/myip.php`
echo “last IP : $LAST_IP – new IP: $IP”
if [ $LAST_IP = $IP ];
then
echo `date +%d.%m.%y-%R` “ip unchanged”
else
echo “new ip: $IP”
cat .last_ip | mailx -s “New-IP $IP” MAILADR
echo “$IP” &gt; .last_ip
echo `date +%d.%m.%y-%R` “new IP :$IP” &gt;&gt;ip.log
fi

&nbsp;</blockquote>

Nagios – Citrix Monitoring – how to monitor the number of logged on users

Get the check_snmp_citrix Plugin from NagiosExchange

Download the ddl’s from here:  http://www.wtcs.org/snmp4tpc/snmp4ctx.htm

copy the files to all Terminal Servers.

Then

copy SNMP4CTX.dll %SystemRoot%\system32

snmp4ctx.reg

net stop “SNMP Service”
net start “SNMP Service”

add the following lines to your commands.cfg

# Citrix users
# check_snmp_citrix command definition
define command{
command_name check_snmp_citrix
command_line /usr/lib/nagios/plugins/check_snmp_citrix $HOSTNAME$ $ARG1$ $ARG2$ -w 21 -c 25
}

add the following lines to your services definitions:

define service {
use template1
name check-citrix-users
service_description Citrix check users
host_name  server1, server2
check_command check_snmp_citrix!SNMP-COMMUNITY-NAME!WFActive

}

Restart Nagios with /etc/init.d/nagios3 restart

Enjoy !

Grub2 Default boot configuration on Ubuntu 9.10

GRUB 2 is the new default boot loader for Ubuntu 9.10. If you would like to change if your pc boots either Ubuntu or Windows by default you have to do the following:

Get an overview of menuentries in /boot/grub/grub.cfg

joerg@phenom:~$ grep “menuentry” /boot/grub/grub.cfg
menuentry “Ubuntu, Linux 2.6.31-20-generic-pae” {
menuentry “Ubuntu, Linux 2.6.31-20-generic-pae (recovery mode)” {
menuentry “Ubuntu, Linux 2.6.31-19-generic-pae” {
menuentry “Ubuntu, Linux 2.6.31-19-generic-pae (recovery mode)” {
menuentry “Ubuntu, Linux 2.6.31-17-generic-pae” {
menuentry “Ubuntu, Linux 2.6.31-17-generic-pae (recovery mode)” {
menuentry “Ubuntu, Linux 2.6.31-16-generic-pae” {
menuentry “Ubuntu, Linux 2.6.31-16-generic-pae (recovery mode)” {
menuentry “Memory test (memtest86+)” {
menuentry “Memory test (memtest86+, serial console 115200)” {
menuentry “Windows 7 (loader) (on /dev/sda1)” {
joerg@phenom:~$

The first entry should be used as the standard.

Edit /etc/default/grub

sudo emacs /etc/default/grub

Search for GRUB_DEFAULT and change it to 0

GRUB_DEFAULT=0

If you would like to use Windows 7 by default the parameter in this example is 10 instead.

Save the file and update the configuration with

joerg@phenom:~$ sudo update-grub
[sudo] password for joerg:
Generating grub.cfg …
Found linux image: /boot/vmlinuz-2.6.31-20-generic-pae
Found initrd image: /boot/initrd.img-2.6.31-20-generic-pae
Found linux image: /boot/vmlinuz-2.6.31-19-generic-pae
Found initrd image: /boot/initrd.img-2.6.31-19-generic-pae
Found linux image: /boot/vmlinuz-2.6.31-17-generic-pae
Found initrd image: /boot/initrd.img-2.6.31-17-generic-pae
Found linux image: /boot/vmlinuz-2.6.31-16-generic-pae
Found initrd image: /boot/initrd.img-2.6.31-16-generic-pae
Found memtest86+ image: /boot/memtest86+.bin
Found Windows 7 (loader) on /dev/sda1
done
joerg@phenom:~$

Done.

Much more information about grub2 can be found here

How to automatically mount windows shares from Linux

Install the samba client

sudo apt-get install smbfs

Create a mountpoint

mkdir ~/mywindowsshare

Create file file called .smbcredentials

with the following content:

username=yourwindowsusername
password=yourwindowspassword

protect your password

sudo chmod 600 .smbcredentials

add the following line to /etc/fstab

//windowsservername/sharename /home/username/mywindowsshare smbfs iocharset=utf8,credentials=/home/username/.smbcredentials,iocharset=utf8,file_mode=0777,dir_mode=0777 0 0

Try to manually mount the share

sudo mount /home/username/mywindowsshare

Volia.