Open Source && Programming && Life
Needed to get my VMWare Server install running in Hardy. It broke sometime during the Gutsy -> Hardy upgrade when we got the 2.4.26 kernel series...
Since I hope that VMWare will eventually package up a new release, I really didn't want to muck around too much with uninstalling and reinstalling from tarballs...
The solution was to use patches found on the vmware community forum to quickly patch up the vmware modules and install them into the kernel modules dir.
vmware-server-1.04-hardy-fix.sh
#!/bin/bashHere's the original Ubuntu repo for VMWare server 1.04 on Gutsy btw:
# created from instructions @ http://communities.vmware.com/thread/121847
vmware_source_path=/usr/lib/vmware-server/modules/source
vmware_patches_path=.
cd ${vmware_patches_path}
wget http://communities.vmware.com/servlet/JiveServlet/download/849321-5394/vmmon-2.6.24.patch
wget http://communities.vmware.com/servlet/JiveServlet/download/849321-5395/vmnet-2.6.24.patch
cp ./vm{mon,net}-2.6.24.patch /tmp
cd /tmp
for dir in vm{mon,net}; do
tar xf ${vmware_source_path}/${dir}.tar
cd ${dir}-only
patch -p1 < ../${dir}-2.6.24.patch # patch the module source
make && mkdir /lib/modules/`uname -r`/vmware-server # make the modules dir
sudo cp *.ko /lib/modules/`uname -r`/vmware-server # copy the modules
cd ..
# tar cf ${dir}.tar ${dir}-only
# sudo cp ${dir}.tar ${vmware_source_path}
done
sudo depmod -a # make the modules visible to the kernel
sudo /etc/init.d/vmware-server stop # restart vmware services
sudo /etc/init.d/vmware-server start #
## Uncomment the following two lines to add software from Canonical's 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the respective vendors
## as a service to Ubuntu users.
deb http://archive.canonical.com/ubuntu gutsy partner
# To open a terminal in Easy Mode hit 'Ctrl+Alt+T'
# Install KDE 'Advanced mode'
sudo aptitude update
sudo aptitude install ksmserver kicker
# Install FreeNX
wget http://http.us.debian.org/debian/pool/main/o/openssh/openssh-server_4.3p2-9_i386.deb
wget http://http.us.debian.org/debian/pool/main/o/openssh/ssh_4.3p2-9_all.deb
wget http://http.us.debian.org/debian/pool/main/b/binutils/binutils_2.17-3_i386.deb
sudo dpkg -i openssh-server_*_i386.deb ssh_*_all.deb binutils_*_i386.deb
if [ -z "$(grep NX /etc/apt/sources.list)" ]; then sudo sh -c 'echo -e "\n#Free NX\ndeb http://mirror.ubuntulinux.nl dapper-seveas freenx" >> /etc/apt/sources.list'; fi
sudo aptitude update
sudo aptitude install freenx
# this should be done as the user you will login as...
sudo ssh $USER@127.0.0.1 'exit' # Type 'yes' accept local key
sudo sh -c 'echo "AuthorizedKeysFile /var/lib/nxserver/home/.ssh/authorized_keys2" >> /etc/ssh/sshd_config'
sudo nxserver --adduser $USER
sudo /etc/init.d/ssh restart
sudo nxserver --restart
Get yourself the 1.5.0 client (win32 version is mirrored here), create a session pointing to your eeePC's ip address make sure you are on KDE as your Desktop type. You must login with the Login user and whatever password you typed when you first logged into the eeePC.
If you want to simulate the limitations of the eeePC's physical screen you can set the Display to Custom and set W: 800 and H: 480.
Note: I find some apps won't run unless you open a terminal window and type 'xhost +', not sure why this is required.
Here's a screenie of KDE mode with display restricted down to 800x480.
Here's what it would have looked like if everyone had a riding vote and a party list vote and they had voted them the same way (for the party of the candidate they voted for). A bit unrealistic, but still interesting:
The legislature would have looked quite different, a minority government for the Liberals with strong opposition representation by the Conservatives, the NDP and the Green party, more importantly much lower wasted vote.
The xls spreadsheet I used to calculate it
Certainly something to think about...
Decided to go have a look at the wikipedia page on Quake Wars to see when it would be coming out... As it turns out the game will be released in early October (2nd or 10th) and a demo was released yesterday!
I'm looking forward to this for a while, as it is sure to reveal how inadequate my PC is for playing modern games. :P
Since I had trouble finding a torrent of this demo I thought I'd mirror it here for others:-----> QuakeWars Demo torrent file
Right now it's Windows only, but Id is usually pretty good about putting out Linux clients.
Quick steps to getting Webmin + Virtualmin up and running on Ubuntu Dapper LTS:
wget http://prdownloads.sourceforge.net/webadmin/webmin_1.360_all.deb
wget http://download.webmin.com/download/virtualmin/webmin-virtual-server_3.44.gpl_all.deb
wget http://download.webmin.com/download/virtualmin/webmin-virtual-server-theme_4.4_all.deb
aptitude install libnet-ssleay-perl libauthen-pam-perl libio-pty-perl libmd5-perl # Webmin reqs
aptitude install apache2 mysql-server webalizer bind # Virtualmin reqs
a2enmod suexec
a2enmod actions
/etc/init.d/apache2 force-reload
rm /etc/webmin/apache/site # delete webmin apache config cache, will only exist if you have a previous webmin install
dpkg -i webmin_1.360_all.deb webmin-virtual-server-theme_4.4_all.deb webmin-virtual-server_3.44.gpl_all.deb
# surf to your new webmin site on your server using SSL on port 10000 - i.e. https://www.mysite.com:10000/
I've repacked my working Ubuntu FreeNX install and updated it to work on Gutsy.
Add my repo to your /etc/apt/sources.list:
# FreeNX for AMD64
deb http://www.northern.ca/projects/freenx/ ./
Then follow the instructions at http://www.northern.ca/projects/freenx/!freeNX_for_Ubuntu_AMD64.txt
I've mirrored the Windows client there, I don't have the original linux NX clients, though they might be found at http://mirror.ubuntulinux.nl/dists/dapper-seveas/freenx/
NOTE: Users dist-upgrading to Gutsy must manually sudo aptitude install dbus-x11 to satisfy the dependency of FreeNX (otherwise you will your sessions stop working with no real indication as to why - NX> 707 SSL tunneling: 0 - Killed by signal 15. ). Due to the splitting of the dbus package into dbus + dbus-x11 anyone going from Feisty -> Gutsy may have to manually install dbus-x11.
If you are running i386 get the binary package from here: http://www.andrew.net.au/~apollock/mythstream/mythstream_0.17.2-2_i386.deb
Otherwise if you're on AMD64 like me, you can roll your own using the following instructions I cooked up:
cd ~
wget http://www.andrew.net.au/~apollock/mythstream/mythstream_0.17.2.orig.tar.gz
wget http://www.andrew.net.au/~apollock/mythstream/mythstream_0.17.2-2.diff.gz
tar -zxvf mythstream_0.17.2.orig.tar.gz
sudo aptitude -y install dpkg-dev debhelper g++
sudo aptitude -y install qt3-dev-tools libmyth-0.20-dev fftw-dev
zcat mythstream_0.17.2-2.diff.gz | patch -p0
cd mythstream-0.17.2.orig/
chmod +x debian/rules
debian/rules
make
debian/rules binary-arch
cd ~
sudo aptitude -y install libxml-dom-perl libxml-xql-perl
sudo dpkg -i mythstream_0.17.2-2_$(dpkg --print-architecture).deb
next up you'll have to configure mythstream as per the instructions... so
zcat /usr/share/doc/mythstream/INSTALL.gz | less # jump to section "5)"Then restart mythtv-frontend and away you go....
nano /usr/share/mythtv/library.xml /usr/share/mythtv/media_settings.xml /usr/share/mythtv/themes/MythCenter-wide/theme.xml # edit as per the instructions in the INSTALL file
Ubuntu Studio was officially released earlier today. Ubuntu Studio is a multimedia focused distribution of Ubuntu 7.04 that preinstalls Audio, Graphical and Video playback and editing software packages with the OS when it is installed. One of the projects that is part of this initial Ubuntu Studio release is the DJ software project Mixxx that I work on. :D
At present the only ISO offered is i386, I was told on the IRC channels that it is not a liveCD, so you can't boot up and play without installing.
I've mirrored the torrent here as their server is getting hammered at present.Seems there is no portable way to resolve the FQDN, one way to get this info on Solaris 8 (an OS a bit on the barren side tooling-wise) is to ask the mailer as follows:
FQDN=`/usr/lib/mail/sh/check-hostname|cut -d" " -f7`
Nano .nanorc syntax colour highlighting for Ubuntu/Debian apt package source repos list (source.list and /etc/apt/sources.list.d/)
# Debian/Ubunut Packages config
syntax "deb-sources-lists" "\.list$"
color yellow "\s(http|ftp)://.*$"
color green "^\s?deb(-src)?"
color brightgreen "\s(http|ftp)://.[^ ]*"
color brightblack "#(\s)?deb .*$"
color white "#.*$"
Had some trouble getting my fax modem to connect to a fax machine for longer for 30 seconds at a time. I found the solution in this message, which is to prefix your dialing with *99-<fax number>.
There is some speculation that this temporarily bumps your Vonage usage/bandwidth quality setting to the highest level (mine is set to the middle quality settings of 50kps; running via a RTP300 phone adaptor), I'm not entirely sure what it does but it anecdotally worked in my case. :D
Hopefully this tip will prove helpful to other Vonage and VoIP subscribers.
Let's do something about that shall we? :D
Plan B (plan A was to build from source, the repo is a mess, argh!) is to install Zimbra in a i386 chroot. Here's how we do it:
Mostly-Automated-Ubuntu-Dapper-Zimbra-Chroot Install Script [zimbra-install.sh] (last changed Feb 20, 2007)
Notes:- Read before running it.
- Slicehost, my new hosting provider (use this sign-up link to give me a small referral kickback) starts me with Dapper... No need to upgrade, however if you do when you go to bootstrap the chroot, whatever the current distro is will be what is installed to the chroot.
base chroot + Zimbra install takes 1.7G+ before any user data
- if you get errors like: /opt/zimbra/bin/zmshutil: eval: line 49: syntax error near unexpected token `(' during install.sh... exit the chroot rerun the mount proc and mount dev (see below), wipe out zimbra and rerun install (see bottom block)
- Mysql is particular about localhost and localhost.domain, so make sure localhost entry proceeds everything else. Zimbra's MySQL won't start without a localhost entry.
- Watch your ports, if you are running a web server or mail servers on the host system (outside the chroot), you'll want to tell Zimbra to find other ports to use then the defaults.
- Check out the Zimbra setup and install logs in chroot's /tmp folder for errors
#!/bin/bash
#
# zimbra-install.sh - Mostly Automated Ubuntu Zimbra Chroot Install Script by Garth Dahlstrom (C) 2007
# Developed to install Zimbra on an Ubuntu AMD64 host system inside a i386 chroot (Zimbra binaries are i386 only).
#
# License: GPL V2
#
# DISCLAIMER: USE AT YOUR OWN RISK! AND ONLY IF YOU UNDERSTAND WHAT THE SCRIPT IS DOING!
#
# Kickstarting the script:
# aptitude update && aptitude -y install curl nano && curl http://stacktrace.org/archive/.nanorc | tr -d '\r' > ~/.nanorc # get cURL, then use it to grab Nano syntax colouring file
# nano zimbra-install.sh && clear && chmod +x zimbra-install.sh && bash -x ./zimbra-install.sh # paste the contents of this script into Nano and you're off
# set chroot directory
export CHROOT=/opt/zimbra-chroot # change this to where you want your zimbra ubuntu distro chroot to live
export CHROOT_LABEL=zimbra
export ZIMBRA_TGZ_URL=http://umn.dl.sourceforge.net/sourceforge/zimbra/zcs-4.5.1_GA_660.UBUNTU6.tgz
if [ -z "$CHROOT" ]; then echo -e '\E[31m'"\033[1m$0 - ERROR:\033[0m" CHROOT must be set otherwise the install will happen on the host system\! && sleep 20 && exit; fi
if [ `hostname|grep '\.'|wc -l` -eq 0 ]; then echo -e '\E[31m'"\033[1m$0 - ERROR:\033[0m" hostname must be a FQDN resolvable via DNS and/or hosts file \(use hostname to set it\) && sleep 20 && exit; fi
if [ ! -f /etc/timezone ]; then tzconfig; fi # configure timezone on host
# You must be root to complete this... `sudo su -`
if [ $UID -ne 0 ]; then echo -e '\E[31m'"\033[1m$0 - ERROR:\033[0m" You must be root to run this && sleep 20 && exit; fi
# halt if there's already a distro there... we won't be the ones to kill it
if [ -f $CHROOT/etc/lsb-release ]; then echo -e '\E[31m'"\033[1m$0 - ERROR:\033[0m" A distribution already exists at the CHROOT target location \($CHROOT\). Can not continue\! && sleep 20 && exit; fi
# Install Chroot
sed -ie "s/#*[ ]*deb \(.*\) universe$/deb \1 universe/" /etc/apt/sources.list # make sure 'universe' deb repository is enabled
export ZIMBRA_TGZ=`echo $ZIMBRA_TGZ_URL| rev | cut -d/ -f1 | rev`
if [ ! -f $ZIMBRA_TGZ ]; then
echo && echo -e '\E[33m'"\033[1m$0 - NOTE:\033[0m" Starting Zimbra install tarball in the background w/ cURL, while Zimbra chroot is being prepped and bootstrapped && echo
curl --silent --show-error --remote-name $ZIMBRA_TGZ_URL &
fi
aptitude update && aptitude -y install debootstrap dchroot libpam-chroot # once everything works, also consider installing 'fail2ban' to protect from attacks
if [ `grep $CHROOT /etc/dchroot.conf | wc -l` -eq 0 ]; then echo $CHROOT_LABEL $CHROOT >>/etc/dchroot.conf; fi
# build chroot
mkdir -p $CHROOT
debootstrap --arch i386 `grep DISTRIB_CODENAME /etc/lsb-release|cut -d= -f2` $CHROOT http://archive.ubuntu.com/ubuntu # Initalize Ubuntu chroot
if [ ! -d $CHROOT/dev ] || [ `mount | grep $CHROOT/dev | wc -l` -eq 0 ]; then # (re)mount dev for the chroot
mkdir -p $CHROOT/dev # mount dev starts
umount $CHROOT/dev
sleep 2
mount --bind /dev $CHROOT/dev # so that networking works inside chroot
fi
if [ ! -d $CHROOT/proc ] || [ `ls $CHROOT/proc | wc -l` -eq 0 ]; then # (re)mount proc for the chroot
mkdir -p $CHROOT/proc # mount proc starts
umount $CHROOT/proc
sleep 2
mount -t proc proc $CHROOT/proc
fi
cp /etc/timezone $CHROOT/etc/timezone && cp /etc/localtime $CHROOT/etc/localtime # copy timezone info from host to chroot
rm $CHROOT/bin/sh && ln -s /bin/bash $CHROOT/bin/sh # Zimbra wants bash as default shell
echo 127.0.0.1 localhost >>$CHROOT/etc/hosts; # must be first for MySQL5 server to resolve DNS via localhost or Zimbra will not start!
# Set chroot hostname to be the same as the host environment
if [ `grep $(hostname) $CHROOT/etc/hosts|wc -l` -eq 0 ]; then
echo `ifconfig eth0 | grep Bcast | cut -d: -f2 | cut -d' ' -f1` `hostname` >>$CHROOT/etc/hosts;
fi
if [ `ps aux | grep -v grep | grep $ZIMBRA_TGZ_URL | wc -l` -ge 1 ]; then echo -e '\E[33m'"\033[1m$0 - NOTE:\033[0m" cURL is still downloading... foregrounding cURL to wait for it to finish.; fg; fi # Must have whole Zimbra tarball before we can continue.
mkdir -p $CHROOT/opt/zimbra && cp $ZIMBRA_TGZ $CHROOT/opt/ && tar --directory=$CHROOT/opt -zxvf $ZIMBRA_TGZ
if [ `grep universe $CHROOT/etc/apt/sources.list|wc -l` -eq 0 ]; then echo deb http://archive.ubuntu.com/ubuntu `grep DISTRIB_CODENAME /etc/lsb-release | cut -d= -f2` universe>>$CHROOT/etc/apt/sources.list; fi # Enable Universe
curl http://stacktrace.org/archive/.nanorc | tr -d '\r' > $CHROOT/root/.nanorc && cp $CHROOT/root/.nanorc $CHROOT/opt/zimbra # Syntax highlighting for Nano
echo && echo -e '\E[33m'"\033[1m$0 - NOTE:\033[0m" Adding Zimbra group and Zimbra system user account to host and syncronizing /etc/passwd \& /etc/group with chroot
# Create Zimbra groups in host and mirror into chroot
export chroot_prefix=chroot-
for zimbra_group in ssl-cert postfix postdrop zimbra; do
addgroup --system ${chroot_prefix}${zimbra_group}
dchroot -c $CHROOT_LABEL "addgroup --system --gid `cat /etc/group | grep ${chroot_prefix}${zimbra_group}: | cut -d: -f3` ${zimbra_group}"
done
# Create Zimbra users in host and mirror into chroot
adduser --system --disabled-password --disabled-login --no-create-home --home $CHROOT/var/lib/fetchmail --shell /bin/sh z-fetchm
adduser --system --disabled-password --disabled-login --no-create-home --home $CHROOT/var/spool/postfix --shell /bin/false z-postfi
adduser --system --disabled-password --no-create-home --home $CHROOT/opt/zimbra --shell /bin/bash --ingroup ${chroot_prefix}zimbra zimbra
# mirror users
dchroot -c $CHROOT_LABEL "adduser --system --disabled-password --disabled-login --no-create-home --home /var/lib/fetchmail --shell /bin/sh --uid $(cat /etc/passwd | grep z-fetchm: | cut -d: -f3) fetchmail"
dchroot -c $CHROOT_LABEL "adduser --system --disabled-password --disabled-login --no-create-home --home /var/spool/postfix --shell /bin/false --uid ` cat /etc/passwd | grep z-postfi: | cut -d: -f3` postfix"
dchroot -c $CHROOT_LABEL "adduser --system --disabled-password --no-create-home --home /opt/zimbra --shell /bin/bash --ingroup zimbra --uid ` cat /etc/passwd | grep zimbra: | cut -d: -f3` zimbra"
dchroot -c $CHROOT_LABEL "adduser zimbra postfix"
echo && echo -e '\E[33m'"\033[1m$0 - NOTE:\033[0m" If necessary $0 will add pam_chroot configurations to your sshd server. SSHd will be restarted.
if [ `grep $CHROOT /etc/security/chroot.conf | wc -l` -eq 0 ]; then echo zimbra $CHROOT >>/etc/security/chroot.conf; fi
if [ `grep pam_chroot.so /etc/pam.d/ssh | wc -l` -eq 0 ]; then echo \# Set up user chroot from /etc/security/chroot.conf. >>/etc/pam.d/ssh && echo session required pam_chroot.so >>/etc/pam.d/ssh; fi
/etc/init.d/ssh restart
dchroot -c $CHROOT_LABEL "dpkg-reconfigure locales" # finish chroot set-up
echo -e '\E[33m'"\033[1m$0 - NOTE:\033[0m" Choose \"No Configuration\" for the chroot\'s MTA, if prompted by aptitude. && sleep 5
dchroot -c $CHROOT_LABEL "aptitude update && aptitude -y install nano wget slay patch psmisc cron openssh-client file libidn11 curl fetchmail libpcre3 libgmp3c2 libexpat1 libxml2 libstdc++6 openssl" # install zimbra prerequsites, skip MTA config
echo -e '\E[33m'"\033[1m$0 - NOTE:\033[0m" Starting Zimbra install in chroot... && sleep 2
dchroot -c $CHROOT_LABEL "cd /opt/zcs && ./install.sh" # Start the install
echo -e '\E[33m'"\033[1m$0 - NOTE:\033[0m" Restarting chroot syslogd \(required so /var/log/zimbra will be bigger then 0\)
dchroot -c $CHROOT_LABEL "/etc/init.d/sysklogd restart" # restart syslog to pick-up Zimbra config changes to /etc/syslog.conf
echo -e '\E[33m'"\033[1m$0 - NOTE:\033[0m" Patching Monitoring and Queue fixes and restarting Zimbra...
dchroot -c $CHROOT_LABEL "cd /opt/zimbra/libexec && curl http://stacktrace.org/index_html/20070212-Zimbra-on-Ubuntu64/UbuntuMonitoringAndQueueFix.patch | patch --ignore-whitespace --forward; /etc/init.d/zimbra stop && sleep 10 && /etc/init.d/zimbra start" # Apply patch and restart Zimbra
echo -e '\E[33m'"\033[1m$0 - NOTE:\033[0m" If you need to go back into the chroot to finish the install you can do so by typing \`export CHROOT=$CHROOT \&\& chroot $CHROOT\`
Other Stuff
During the install, I found it necessary + handy to wipe out and start over until I was able to eliminate the errors from the Zimbra setup/install logs and get everything running, if you need to do that here's the quickest way:
## See what's running
# ps aux|grep zimbra # see what is running as zimbra user
## Wiping out zimbra
# slay zimbra # kill all process running under zimbra user
# dpkg --get-selections | grep zimbra- | cut -f1 | xargs dpkg --purge # wipe out zimbra packages in dpkg
# rm -rf /opt/zimbra # wipe out all zimbra files
# slay zimbra && dpkg --get-selections | grep zimbra- | cut -f1 | xargs dpkg --purge && rm -rf /opt/zimbra # exterminate zimbra in 1 line
## Redo the install after wiping it out
cd /opt/zcs && ./install.sh
Post Install Fixes
Forward/Reply Buttons don't work because of a Javascript error: rule has no properties
This is a problem with Timezones on Windows machines, there is a patch from Microsoft (WindowsXP-KB928388-x86-ENU.exe). Details can be read about this problem here. There is an official Zimbra Bug here.
Fix Monitoring and Email Queues within zimbraAdmin (as of Feb 20 this patch is applied by the installer script automatically):
After applying the following patch you'll be able to see Email Queues in zimbraAdmin, if when clicking on the Monitoring->Mail Queues you get a pop-up error dialog complaining about a zimbraRemoteManagementPrivateKeyPath error message, then follow the steps in this thread (and specifically here)./opt/zimbra/libexec/UbuntuMonitoringAndQueueFix.patch (created from instructions @ http://www.zimbra.com/forums/showthread.php?t=4950):
--- zmgengraphs.orig 2007-02-13 08:46:58.000000000 -0500Apply the patch using this command:
+++ zmgengraphs 2007-02-13 08:47:36.000000000 -0500
@@ -27,6 +27,7 @@
use strict;
use lib '/opt/zimbra/zimbramon/lib';
use Zimbra::Util::Common;
+use lib '/opt/zimbra/zimbramon/lib/i386-linux-thread-multi';
$|=1;
# Exit if software-only node.
exit(0) unless (-f '/opt/zimbra/conf/localconfig.xml');
--- zmlogprocess.orig 2007-02-13 08:45:43.000000000 -0500
+++ zmlogprocess 2007-02-13 08:46:36.000000000 -0500
@@ -28,7 +28,7 @@
use lib "/opt/zimbra/zimbramon/lib";
use Zimbra::Util::Common;
-
+use lib "/opt/zimbra/zimbramon/lib/i386-linux-thread-multi";
use DBI;
use Time::Local;
cd /opt/zimbra/libexec && cat UbuntuMonitoringAndQueueFix.patch | patch --ignore-whitespace --forward; /etc/init.d/zimbra stop && sleep 10 && /etc/init.d/zimbra start # Apply patch and restart Zimbra
Enabling ZimbraAdmin on https
/opt/zimbra/apache-tomcat-5.5.15/conf/ZimbraAdminSSL.patch--- zimbraAdmin.web.xml.in.orig 2007-02-01 22:00:58.000000000 -0500Apply the patch using this command:
+++ zimbraAdmin.web.xml.in 2007-02-17 19:06:31.000000000 -0500
@@ -11,7 +11,7 @@
</context-param>
<context-param>
<param-name>admin.allowed.ports</param-name>
- <param-value>7071</param-value>
+ <param-value>443, 7071</param-value>
</context-param>
<!-- =============
--- service.web.xml.in.orig 2007-02-17 18:59:55.000000000 -0500
+++ service.web.xml.in 2007-02-17 19:04:13.000000000 -0500
@@ -67,7 +67,7 @@
<servlet-class>com.zimbra.soap.SoapServlet</servlet-class>
<init-param>
<param-name>allowed.ports</param-name>
- <param-value>7071</param-value>
+ <param-value>443, 7071</param-value>
</init-param>
<!-- Admin servlet allows both admin and user commands -->
<init-param>
@@ -152,7 +152,7 @@
<servlet-class>com.zimbra.cs.service.StatsImageServlet</servlet-class>
<init-param>
<param-name>allowed.ports</param-name>
- <param-value>7071</param-value>
+ <param-value>443, 7071</param-value>
</init-param>
<load-on-startup>7</load-on-startup>
</servlet>
cd /opt/zimbra/apache-tomcat-5.5.15/conf && cat ZimbraAdminSSL.patch | patch --ignore-whitespace --forward; /etc/init.d/zimbra stop && sleep 10 && /etc/init.d/zimbra start # Apply patch and restart Zimbra
This is a continuation of "Soundgraph iMON PAD + VFD LIRC kernel modules the Debian-way"...
...
test -e include/linux/autoconf.h -a -e include/config/auto.conf || ( \
echo; \
echo " ERROR: Kernel configuration is invalid."; \
echo " include/linux/autoconf.h or include/config/auto.conf are missing."; \
echo " Run 'make oldconfig && make prepare' on kernel src to fix it."; \
echo; \
/bin/false)
mkdir -p /usr/src/lirc-0.8.1pre2/drivers/lirc_dev/.tmp_versions
rm -f /usr/src/lirc-0.8.1pre2/drivers/lirc_dev/.tmp_versions/*
make -f scripts/Makefile.build obj=/usr/src/lirc-0.8.1pre2/drivers/lirc_dev
gcc -Wp,-MD,/usr/src/lirc-0.8.1pre2/drivers/lirc_dev/.lirc_dev.o.d -nostdinc -isystem ....
/usr/src/lirc-0.8.1pre2/drivers/lirc_dev/lirc_dev.c:35:26: error: linux/config.h: No such file or directory
...
### Patch the lirc-modules.tar.gz file to work with Linux 2.6.19+
### Run this before trying to build with 'module-assistant --text-mode --kernel-dir /usr/src/linux-source-`uname -r` build lirc'
if [ "`uname -r|cut -d- -f1|sed 's/\.//g'`" -ge "2619" ]; then
cd /usr/src
mkdir patch-lirc-for-2.6.20+
cd patch-lirc-for-2.6.20+
tar -zxf /usr/src/lirc-modules.tar.gz
grep -r "linux/config.h" * | cut -d: -f1 | xargs sed -i 's-linux/config.h-linux/autoconf.h-g'
mv -i /usr/src/lirc-modules.tar.gz /usr/src/lirc-modules-unpatched.tar.gz
tar -czf /usr/src/lirc-modules.tar.gz .
cd /usr/src
rm -rf patch-lirc-for-2.6.20+
fi
EDIT (Feb 9): there's also a patch that will likely go into Debian (upstream) which does something similar to the above code, but is version safe for older kernels... that is here: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=400494;msg=5;filename=lirc-config.patch;att=1 [Debian Bug Link] [Ubuntu Bug Link]
Finally when I tried to build my imon module my compile dumped with some crap error relating to Windows MCE IR device modules:
...Since I don't care about MCE support at the moment, the solution for that one was to rerun dpkg-reconfigure and unselect the mceusb/mceusb2 modules and build again:
/usr/src/lirc-0.8.1/drivers/lirc_mceusb2/lirc_mceusb2.c: In function ‘request_packet_async’:
/usr/src/lirc-0.8.1/drivers/lirc_mceusb2/lirc_mceusb2.c:237: warning: passing argument 6 of ‘usb_fill_int_urb’ from incompatible pointer type
/usr/src/lirc-0.8.1/drivers/lirc_mceusb2/lirc_mceusb2.c:245: warning: passing argument 6 of ‘usb_fill_int_urb’ from incompatible pointer type
/usr/src/lirc-0.8.1/drivers/lirc_mceusb2/lirc_mceusb2.c:266: error: ‘SLAB_ATOMIC’ undeclared (first use in this function)
/usr/src/lirc-0.8.1/drivers/lirc_mceusb2/lirc_mceusb2.c:266: error: (Each undeclared identifier is reported only once
/usr/src/lirc-0.8.1/drivers/lirc_mceusb2/lirc_mceusb2.c:266: error: for each function it appears in.)
...
dpkg-reconfigure lirc-modules-source # ditch building mceusb2 and mceusb modules if they give trouble.
After the rest of the build and install, did a quick restart to confirmed that everything is back up and running (you can follow the older post's restart steps if you'd prefer not to reboot).
Spent some time Saturday making my friend's old Radeon 9200 do AIGLX+Beryl
on my Mythbox.
Followed the AIGLX for Edgy set-up guide on the offical Beryl wiki here: http://wiki.beryl-project.org/index.php/Install/Ubuntu/Edgy/AiGLX. Next I needed to put my Radeon card into accelerated rendering mode, so I followed the driver info block here: http://doc.gwos.org/index.php/BerylOnEdgy#Radeon_Driver (I added the part for 9200 owners after I figured everything below out).
A couple of things gave me grief and I was fortunate to get through them all eventually. Here they are, hopefully they will save others some troubles:- First problem was getting the video card to do 1600x1200, I knew this was possible as I had a Radeon 9000 in my old X1000 Presario which was able to do 1920x1200... After much searching and tweaking I found the block yielded best results for my Viewsonic VP201b:
Section "Monitor"
Identifier "Generic Monitor"
ModelName "Viewsonic vp201b"
#ModelName "Viewsonic vp201s"
VendorName "VSC"
HorizSync 30-75
VertRefresh 50-60
Option "DPMS"
# Option "ReducedBlanking" # Radeon will scale low res to 1600x1200 without this line!!
Option "DDCMode" "off"
DisplaySize 410 310
Modeline "1600x1200" 162.0 1600 1664 1856 2160 1200 1201 1204 1250 +hsync +vsync # Default detected
# Modeline "1600x1200" 130.25 1600 1648 1680 1760 1200 1203 1207 1235 # 1920x1200 low flicker
EndSectionThanks to this page: http://suif.stanford.edu/~csapuntz/rv280-linux-dvi.html for the ReducedBlanking tip that goes with the 1920x1200->1600x1200 modeline... that was what first enabled me to get X to start at 1600x1200, eventually I went with a different modeline.
- I had had an Nvidia 6200 video card in this box until recently to get the "Radeon" driver to do direct rendering the Nvidia GLX libs have to get removed. So do this if you are Upgrading from an Nvidia to an ATI:
sudo aptitude purge nvidia-glx
- Finally I had trouble getting direct rendering (`glxinfo | grep rendering` in an xterm to check) going (likely caused because I had removed agpgart from my kernel modules list to help my Nvidia card)... In my /var/log/Xorg.0.log I was seeing:
(WW) RADEON(0): [agp] AGP not available
To solve this the solution was to add the bold line at the bottom of my "Device" block below:
(EE) RADEON(0): [agp] AGP failed to initialize. Disabling the DRI.
Section "Device"
Identifier "ATI Technologies, Inc. RV280 [Radeon 9200]"
# Driver "ati"
Driver "radeon"
BusID "PCI:1:0:0"
ChipId 0x514D
Option "DRI" "true"
Option "ColorTiling" "on"
Option "EnablePageFlip" "true"
## Some may experience very poor performance without hashing the following line.
Option "AccelMethod" "EXA"
## If above is hashed, change the following to "XAANoOffscreenPixmaps"
Option "EXANoOffscreenPixmaps"
# Option "XAANoOffscreenPixmaps"
Option "RenderAccel" "true"
Option "AGPMode" "8" # <- x may be 2 or 4 depending on your system
Option "AGPFastWrite" "on"
Option "BusType" "PCI" # If agpgart is not in lsmod listing, Radeon 9200 will complain of no AGP and disable DRI without this line!
EndSection
After all that I finally have a working, albeit slow, AIGLX+Beryl desktop. :D
I noticed today as I contemplate writing up some memoirs of my recent trip, that most of the non-technology related entries get buried under the volume of technical posts, to make things a bit easier I've added a "not tech" tag for content that is not technology related.
I've also added a tab called "blog (non tech)" into the page tabs right next to the full blog tab, clicking on the new tab will take you to a page with all of the non-technical entries listed (you'll see only the headline and lead-in, you have to click on the headline to read the full entry).
Latest Joy is mythfrontend will segfault when trying to start up with a message as follows:
006-10-01 13:38:29.253 Registering MythMusic Media Handler 1/2 as a media handler ext()
2006-10-01 13:38:29.254 Registering MythMusic Media Handler 2/2 as a media handler ext(ogg,mp3,aac,flac)
SIP listening on IP Address 192.168.0.102:5060 NAT address 192.168.0.102
SIP: Cannot register; proxy, username or password not set
Segmentation fault
The problem can be solved by doing the following:
sudo dpkg --force-depends --purge mythphone
Be careful not to let adept/aptitude reinstall mythphone_0.20-0.4ubuntu1_amd64.deb until at least the build is incremented or else the problem will come back.
If anyone knows a better fix, please share it.
Ubuntu's build of LCDproc 0.5.0-1 broke my previously working LCDproc set-up...
Here's how I troubleshot and fixed it:
# -- This Side = Step tried # -- This Side = What you should see if things work & what I got instead
sudo /etc/init.d/LCDd start # this should write "LCDProc Server" to the VFD display
ps aux | grep -i lcd # if it were working you'd see /usr/sbin/LCDd, in my case there was nothing
sudo /usr/sbin/LCDd # this failed for me complaining it couldn't find server/drivers/imon.so, this told me to look in etc
grep -i "server/drivers" /etc/* # found 'DriverPath=server/drivers/' /etc/LCDd.conf
locate imon.so # found that DriverPath should be '/usr/lib/lcdproc/'
# OR
dpkg -L lcdproc | grep imon.so # another (probably better way) to find what DriverPath should be
So the fix was to edit /etc/LCDd.conf like so:
--- LCDd.conf.orig 2006-09-30 23:54:12.000000000 -0400
+++ LCDd.conf 2006-09-30 23:54:31.000000000 -0400
@@ -76,7 +76,7 @@
# the driver modules and will thus not be able to
# function properly.
# NOTE: Always place a slash as last character !
-DriverPath=server/drivers/
+DriverPath=/usr/lib/lcdproc/
Incorrect DriverPath was the first problem.
The second issue prevents /etc/init.d/LCDd from correctly starting the lcdproc server... it has to do with some command line switches passed to LCDd which should have some values after them, but the values are missing so LCDd bombs... here's the patch for that one:
--- /etc/init.d/LCDd.orig 2006-10-01 01:20:56.000000000 -0400
+++ /etc/init.d/LCDd 2006-10-01 01:19:55.000000000 -0400
@@ -14,7 +14,7 @@
NAME=LCDd
DESC=LCDd
DESC="LCDd"
-DAEMON_OPTS="-s -f -c /etc/LCDd.conf"
+DAEMON_OPTS="-s true -f true -c /etc/LCDd.conf"
test -x $DAEMON || exit 0
Final step of restarting lcdproc `/etc/init.d/LCDd start`...
We should be back in business! :)
Bad substitution on install
If you get the follow error when installing/upgrading mythweb:
/var/lib/dpkg/info/mythweb.postinst: 31: Syntax error: Bad substitution
You'll need to patch the post-install script, changing the shell from sh to bash as follows:
--- /var/lib/dpkg/info/mythweb.postinst.orig 2006-09-30 01:27:29.000000000 -0400
+++ /var/lib/dpkg/info/mythweb.postinst 2006-09-30 01:25:42.000000000 -0400
@@ -1,4 +1,4 @@
-#! /bin/sh
+#!/bin/bash
set -e
Once you've done that, rerun `sudo aptitude upgrade` and it should install cleanly.
Apache Permissions, PHP, etc
If you can't get mythweb permissions so that it is viewable via Apache, refer to the MythWeb section of http://www.northern.ca/projects/mythslug/README
data/tv_icons directory is not writable
If when attempting to browse to the "Listings" you get:
Error
data/tv_icons directory is not writable by www-data. Please check permissions.
change the permissions on the directory to "world-writable" like so:
sudo chmod 777 /usr/share/mythtv/mythweb/data/tv_icons
SeriesId can't be null when creating a scheduled recording
If you see the following error when you go to create or save a scheduled recording:
error string: SQL Error: Column 'seriesid' cannot be null [#1048]
You'll need to apply the fix for bug #2366 grab the patch to fix it from here. (http://cvs.mythtv.org/trac/attachment/ticket/2366/mythweb-seriesid_programid_not_null.patch)
# Assuming mythweb-seriesid_programid_not_null.patch was downloaded to your Desktop
cat ~/Desktop/mythweb-seriesid_programid_not_null.patch | sudo patch --forward /usr/share/mythtv/mythweb/includes/recording_schedules.php
MythTV 0.19 was working well enough, but it will be good to have extra polish and enhancements with 0.20.
I'll probably update to the new release once the .debs for MythPlugins gets to bugfix version 0.20a. Can't wait to see how it runs...
Special Thanks to Debian developer Christian Marillat for packaging it so quickly!
The packages are available from the Debian Multimedia project, see the mirror page for the closest mirror with your $ARCH.
This is how I built LIRC to support my Soundgraph iMON PAD + VFD, this is the most Debian-way I could do it (on Kubuntu/Edgy/x86-64).
### Building the LIRC Modules
# remove venky's stand-alone driver or else you will not be able to load lirc_imon properly
rmmod imon_vfd # remove it from /etc/modules if it's in there
aptitude install modules-assistant curl
# Prepare Linux Kernel Source directory that looks like the currently running kernel
module-assistant fakesource # start a rebuild here after updating kernel
cp /boot/config-`uname -r` /usr/src/linux-source-`uname -r`/.config
cd /usr/src/linux-source-`uname -r`/
make oldconfig && make prepare
# Fetch LIRC and compile
module-assistant -f get lirc-modules-source
dpkg-reconfigure lirc-modules-source # no auto-build, yes install maintainers config
# Patch iMON PAD remote driver to have mouse and keyboard support for pad.
cd /usr/src/modules/lirc/drivers/lirc_imon/ && curl http://vorticon.no-ip.info/pub/patches/lirc-0.8.0-imon-keys-kernel.patch | patch --forward
# Build LIRC drivers
cd /usr/src/
rm lirc-modules-`uname -r`_*.deb # delete old package to force a rebuild
module-assistant --text-mode --kernel-dir /usr/src/linux-source-`uname -r` build lirc
# Remove any existing copy from kernel memory
/etc/init.d/lirc stop
/etc/init.d/LCDd stop
export YourRemotesLIRCKernelModule=lirc_imon
rmmod $YourRemotesLIRCKernelModule
# Install newly built kernel module
cd /usr/src/
dpkg -i lirc-modules-`uname -r`_*.deb
depmod
modprobe $YourRemotesLIRCKernelModule # edit the export a couple of lines up
/etc/init.d/LCDd start # restart LCDd
/etc/init.d/lirc start # restart lirc