Lubuntu volume keys (not working)

To get them work edit the /home/$USER/.config/openbox/lubuntu-rc.xml. Replace the commands within the <command> statements to:

<!-- Keybinding for Volume management -->
 <keybind key="XF86AudioRaiseVolume">
 <action name="Execute">
 <command>amixer -D pulse sset Master 5%+</command>
 </action>
 </keybind>
 <keybind key="XF86AudioLowerVolume">
 <action name="Execute">
 <command>amixer -D pulse sset Master 5%-</command>
 </action>
 </keybind>

Kicad schematic editor slow

If there are performance issues with Kicad and the schematics editor running on a ATI Radeon GPU hardware consider to add a xorg option in the file

/usr/share/X11/xorg.conf.d/20-radeon.conf:

Section "Device"
    Identifier "Radeon"
    Driver "radeon"
    Option "AccelMethod" "exa"
    Option "MigrationHeuristic" "greedy"
    Option "EXAPixmaps" "false"
EndSection

The option EXAPixmaps is documented here: https://www.x.org/archive/X11R7.6/doc/man/man4/radeon.4.xhtml

Simple Cups print server script

Hello,

I’ve set up a print server with auto shutdown capability.
It checks if an idle timeout is reached, if there are active print jobs and if the idle timeout is greater than the uptime the server shuts down.
It also has a lock option if you want to have the server online (You could enable the lock with the ~/.xsession and/or the ~/.bashrc file).

#!/bin/bash

IDLE=30		#idle time in min

echo "Shutdown script"
echo "#########################################"
echo ""

if [[ "$1" == "lock" ]];
	then
	touch /var/lock/shutdown.sh.lock
fi

if [[ "$1" == "unlock" ]];
        then
        	rm -f /var/lock/shutdown.sh.lock
		echo "Lock file removed, exiting"
		exit 0
fi

if [ -f /var/lock/shutdown.sh.lock ];
	then
		LOCK=1
		echo "Lock file exists, exiting"
		exit 0
	else
		LOCK=0
fi

MODTIME=`stat -c %Y /var/log/cups/page_log | awk '{ printf $1 "n"}'`
TIME=`date +%s`
SECS=$(echo "$IDLE*60" | bc)
TEMP=`echo "$MODTIME+$SECS" | bc`
UPTIME=$(cat /proc/uptime | awk '{ printf $1 }')
UPTIME=$(echo $UPTIME / 1 | bc)
lpstat -t | grep -q "now printing"
PRINTING=$?

echo "Uhrzeit $TIME"
echo "Uptime $UPTIME"
echo "Idle secs $SECS"
echo "Temp $TEMP"
echo "Printing $PRINTING"

if  (( ( "$TEMP" < "$TIME" ) && ( "$UPTIME" > "$SECS" ) &! $LOCK  && $PRINTING )); 
	then
		echo "Printer spooler system shutdown because of idle timeout." | wall
		#echo $TEMP "<" $TIME
		/sbin/halt -p
	else
		echo "Printer spooler system: Timeout not reached"
fi

Have fun!

ltsp ubuntu 12.04 lts.conf fix for tftp

Hi,

If you are wondering if your thin-client doesn’t recognise the options with the

netkit-tftpd

in the lts.conf file placed in the tftp-boot dir please replace your

/opt/ltsp/i386/usr/share/ltsp/init-ltsp.d/05-getltsconffile

to this one

# get the lts.conf via tftp

# $filename comes from net-eth0.conf and is usually "/<path>/pxelinux.0".
# If it contains a path, we want to construct "/<path>/lts.conf".
# If it doesn't, we want just "lts.conf" without inserting a slash, as some tftp
# servers have problems with it. Finally, if $filename isn't set, we want to
# default to "ltsp/i386/lts.conf".
if [ -n "$SERVER" ]; then
    fileonly=${filename##*/}
    pathonly=${filename%$fileonly}
    lts_conf_temp=$(mktemp)
    tftp "$SERVER" -c get ${pathonly:-ltsp/i386/}lts.conf $lts_conf_temp >/dev/null
    # only overwrite lts.conf if it has non-zero size.
    if [ -s "$lts_conf_temp" ]; then
        mv "$lts_conf_temp" /etc/lts.conf
    else
        rm "$lts_conf_temp"
    fi
fi

# Get the lts.conf vars into the environment
. /usr/share/ltsp/ltsp_config

..or install the tftpd-hpa package!

Have fun!

vsftpd 2.3.5 writeable chroot

Hi,

using Ubuntu LTS 12.04 you’ll need to patch the vsftpd sources for using the “writeable chroot” implementation.

I’ve taken the patch from:

http://wl500g.googlecode.com/svn-history/r3735/trunk/vsftpd/030-writeable_chroot.patch

I’ve uploaded the patched source tarball for you:
http://www.tuxstef.org/download/vsftpd-2.3.5-writeable_chroot.patch.tar.bz2

Don’t fortget to change vsftpd.conf:

allow_writable_root=YES

Have fun!