rulururu

post Merry Christmas!

December 25th, 2006

Filed under: General — Brenton Alker @ 00:15

Well, It’s that time of year again. Time to visit the family, eat and drink too much and have a holiday.
Hope everyone has a safe and happy Christmas!

post Auto-start ESD/ESound in XFCE

December 23rd, 2006

Filed under: Linux, Operating Systems, Ubuntu — Brenton Alker @ 15:20

As you may be aware I am a relatively recent convert to Ubuntu. As such I am still tweaking my desktop to my liking (Who am I kidding, I don’t think I’ll ever finish tweaking it).

I was previously running Gnome (Ubuntu’s default) Desktop, except with XFWM as by Window Manager, as I have never liked Metacity (Gnome’s default WM). Today, I changed my default session (from the "Options" menu in the GDM — the graphical login screen) to XFCE, as many of the Gnome features I don’t use anyway, and I have always liked XFCE, it was on my desktop in my Gentoo day’s (that or Openbox).

Everything seemed to work fine. There were a few things I needed to configure because they were handled by Gnome application previously, but on the whole most things were very similar. The first issue I noticed was I had no sound (There is almost always music playing on my machine, as it should be). After some investigation, I discovered that ESD hadn’t started:

$ ps x | grep esd
5981 pts/1 S+ 0:00 grep esd

A quick search led me to a post on the Ubuntu Forums which wasn’t directly very helpful, but it indicated that, at least I wasn’t the only one. And it also inspired my solution.

I wrote a quick script to start ESD, but only if it isn’t already running (thanks to the problem encountered in the aforementioned post)

~/bin/startesd

#!/bin/sh
APP="/usr/bin/esd"
ARGS="-nobeeps"
if [ `pidof $APP` ]; then
#Do Nothing - already running
return
else
$APP $ARGS&
fi;

Then, by adding an entry to run that script into XFCE’s (new to me, but apparently not so new) "autostart-editor"

$ xfce4-autostart-editor

or "Autostarted Applications" in the settings menu.

I had sound, without having to manually start ESD each time.

The only other configuration I need to get round to doing it configuring my multimedia keys… but that can wait ’till some other time.

post OpenVPN, The Super SSH tunnel

December 21st, 2006

Filed under: Debian, Linux, Operating Systems — Brenton Alker @ 18:30

I have long marvelled at the ability of ssh to tunnel connections, and regularly use this feature to give myself access to services behind firewalls, in offices, far far away… As such, In spite of the seeming ubiquity of the concept, I have never seen the benifit of a VPN. But recently, after discovering OpenVPN set up on one of the servers at work (One for which I’m not the primary admin).

I looked through the configuration and it looked significantly simpler than I had anticipated. So I took it upon myself to join my home network with that of the one in the office (Why?… Why not?)

It was fairly simple, after reading through and following the tips in the official How-To I had a basic VPN connection with a shared key for encryption.

On my local box, the configuration looked like:

/etc/openvpn/tunnel.conf

dev tun
remote my.office.domain
float
ifconfig 10.0.0.2 10.0.0.1
secret .keys/office.key
verb 3
ping 30
route 192.168.0.0 255.255.255.0

And on the box in the back room at work:

dev tun
remote everyone-here.is-a-geek.com
float
ifconfig 10.0.0.1 10.0.0.2
secret .keys/brenton.key
verb 3
ping 30

Note: Both are class C networks, My home IP range is 192.168.1.xxx and the one at work is 192.168.0.xxx This makes life easier, because the networks don’t overlap, otherwise I believe some form of NAT would be required. Once the Tunnels are set up and both services are started

/etc/init.d/openvpn start

the machines should be able to ping each other across the VPN

From work:

$ping 10.0.0.2
PING 10.0.0.2 (10.0.0.2) 56(84) bytes of data.
64 bytes from 10.0.0.2: icmp_seq=1 ttl=64 time=45.0 ms
64 bytes from 10.0.0.2: icmp_seq=2 ttl=64 time=28.4 ms

This configuration even adds and tears down the routing rule (only set up on my local machine at the moment) that forward traffic to the "other" network through the tunnel (The "route" line in my configuration). Unfortunately, because these machines are not the default gateways for their networks, some configuration on the gateway may be required to get them to forward everyone’s traffic (not just that originating from the connected systems) through the tunnel. I’ll post it when I figure it out. OR if anyone knows, please comment!

ruldrurd
Next Page »
Powered by WordPress, Web Design by Laurentiu Piron Monitored by SiteUpTime
Entries (RSS) and Comments (RSS)