Avoid preload under Lucid

Since Ubuntu 8.04 one of the first packages I have installed after a fresh system install was preload. So I did this also for Lucid but discovered that it does not work well together with ureadahead.

preload is a daemon that fetches libraries and binaries into memory based on statistics of your application usage. Often used applications will start up faster.

ureadahead
will read all files that are used during boot into memory so that the different start up scripts and services do not need to be loaded individually. It will improve the boot performance.

The combination of both does not work well. Boot time did increase significantly and even worse: sometimes my screenlets did not start up after login.

After removing preload everything was good again: quick boot times and reliable start of my start up applications.

Back to top

VNC viewer with panning

Once in a while I want to take over my desktop machine from my notebook.

On my desktop I can simply run

x11vnc -loop

to fire up the VNC server.

On the notebook I can connect via

vncviewer <hostname or ip of desktop>

Because the desktop screen is much bigger than the notebook screen, I have to deal with scrollbars in the viewer application to navigate on the big desktop screen.

My notebook has Intel graphics, so I can use xrandr to enable panning on a bigger virtual screen. So I wrote this little script to connect to my desktop pc sirius:

#!/bin/sh
HOSTNAME="sirius"
LOCAL_RES="1366x768"
REMOTE_RES="1920x1200"
xrandr --output LVDS1 --panning "$REMOTE_RES"
vncviewer $HOSTNAME
xrandr --output LVDS1 --panning "$LOCAL_RES"

With this script the notebook screen switches to a big virtual screen with panning (screen window follows the mouse) before starting the remote desktop viewer. So no scrollbar handling an more :-)

Back to top

Tweak gdm for web browsing without login

With the new gdm its possible to tweak the login screen to do some fancy stuff (see forum post http://ubuntuforums. … thread.php?t=1333683). By following these steps we can enable web browsing without user login.

1. To allow a network connection:

sudo cp /usr/share/app-install/desktop/nm-applet.desktop /usr/share/gdm/autostart/LoginWindow

2. Install alltray (needed to get Firefox into the bottom tray):

sudo apt-get install alltray

3. To add Firefox in the bottom tray:
Drag and drop Firefox from the menu to your desktop and copy it to the autostart directory of user gdm:

sudo cp /home/<user>/Desktop/firefox.desktop /usr/share/gdm/autostart/LoginWindow/

Change the desktop file to start Firefox in alltray:

sudo sed -i 's/^Exec=/Exec=alltray /' /usr/share/gdm/autostart/LoginWindow/firefox.desktop

4. Logout again to see the changes of gdm.
If you have created your wireless connections as a normal user before and flagged the connection data to be used for all users, wireless should work without setting up a password. Else you have to follow the instructions in the forum post ( http://ubuntuforums. … thread.php?t=1333683) to set up the network.

There is only one issues, but I can live with it. The Firefox tray starter will vanish after closing Firefox and the browser can not be started again from the login screen.

Back to top