Wake on WAN using OpenWRT 12.09

If you have the need to wake up machines on your local LAN from the outside, there are a few steps you need to take to get it working with OpenWRT (12.09) Select an unused IP address (which you are certain will never, ever be used). I will be using 192.168.1.254 in the following Log into OpenWRT and go to System → Startup → Local Startup (the text input at the bottom of the page) and add this line above exit 0: ip neigh add 192.168.1.254 lladdr ff:ff:ff:ff:ff:ff nud permanent dev br-lan Save (or Submit depending on the theme used) Go to _System _→ Software and verify the package ip is installed. If not, do so. Go to _Network _→ Firewall → Port forwards and add a new rule like this: (select custom to enter the internal IP address). Save and apply Reboot the router That’s it. Now wake on lan should work from the WAN (Internet) as well. ...

August 12, 2013 · 1 min · alj

IPv6 with tunnelbroker.net, ChicagoVPS and Ubuntu

I have recently moved my hosting to a couple of VPSes at ChicagoVPS and wanted to use IPv6 tunnelbroker.net ChicagoVPS uses OpenVZ which presents a couple of problems $ ifconfig sit0 sit0: error fetching interface information: Device not found $ sudo modprobe ipv6 FATAL: Module ipv6 not found. It turns out, this is a fairly common problem though OpenVZ is supposed to support IPv6. Luckily, someone made a small userland program tb-tun, which “tunnels” IPv6 tunnels through a TUN/TAP device. ...

January 6, 2013 · 3 min · alj

iptables on a ChicagoVPS (OpenVZ) VPS

iptables is not always easy to deal with so I prefer to use Uncomplicated firewall (ufw) in Ubuntu, because it simplifies configuring and maintaining my firewall rules. Unfortunately, ufw does not play nice with OpenVZ containers so I decided to find something else. In the end (after testing various things) I decided to install the package iptables-persistent which is not as sexy as ufw but gets the job done. iptables-persistent uses two configuration files /etc/iptables-persistent/rules.v4 and /etc/iptables-persistent/rules.v6 ...

January 6, 2013 · 2 min · alj

Wake on LAN from WAN with a TP-Link router

If you have a computer on your local network you want to wake from the Internet and you have a TP-Link router (in this case a TL-WDR4300) you are in luck. First, create a virtual server (or port forwarding) in which we forward an arbitrary port to port 9 at the IP address of the machine you wish to turn on (Go to Forwarding → Add New): If you test as this point, it will work. But at a later point it will not. This is because the MAC address of the machine you wish wake will be flushed from the router’s ARP table. ...

December 27, 2012 · 2 min · alj

Running Symantec Veritas Cluster Manager on Ubuntu

Update 2020-01-03: A lot has changed since this article was originally published. Veritas was bought by Symantec which in turn was bough by Broadcom. As a result, the link below does no longer work - but I will leave the post online in case someone needs it. At some point Veritas has release the Cluster Manager (Java Console) for Linux. Of course, Linux means Red Hat (and other RPM based flavours). Luckily it isn’t too hard making it work on Ubuntu (and friends). ...

October 17, 2011 · 1 min · alj

Ubuntu Natty: Fixing "unknown locale" in Python

The fix itself is the same as for Python 2.5 – only the line numbers have changed. Open the file /usr/lib/python2.7/locale.py and find the line containing en_gb (line 921) and add these lines (this works for Danish locales): 'en_dk': 'en_DK.ISO8859-1', 'en_dk.iso88591': 'en_DK.ISO8859-1', 'en_dk@euro': 'en_DK.ISO8859-15', In order to avoid this change getting overwritten by packages updates, I use dpkg-divert: $ sudo dpkg-divert --add --rename --divert /usr/lib/python2.7/locale.py.real /usr/lib/python2.7/locale.py $ sudo cp /usr/lib/python2.7/locale.py.real /usr/lib/python2.7/locale.py If you wish to remove the diversion (if the package is fixed to support you locale at some point) simply run ...

June 27, 2011 · 1 min · alj

Tip: Change the Chrome proxy settings when running Xubuntu (Xfce)

For a long time, in the olden days, I ran Xubuntu – mainly because I loved the simplicity of the desktop (and also because it was a lot lighter on my machine, a Thinkpad T40, than GNOME. And I just have no love for KDE). Then some changes were made to the menu system (or the way to edit it) which annoyed the hell out of me – that combined with a new, more powerful machine, I decided to switch to GNOME, which I’ve been running for a couple of years. ...

June 13, 2011 · 3 min · alj

Ubuntu: Install Percona XtraBackup

Percona XtraBackup is an open-source hot backup utility for MySQL that doesn’t lock your database during the backup. It can back up data from InnoDB, XtraDB, and MyISAM tables on MySQL 5.0 and newer servers, and it has many advanced features. Commercial support contracts are available. For a high-level overview of the features, including a feature comparison, please see the XtraBackup homepage. Luckily installing XtraBackup is pretty easy $ sudo apt-key adv --keyserver keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A $ echo "deb http://repo.percona.com/apt maverick main" | sudo tee -a /etc/apt/sources.list $ sudo apt-get update<br /> $ sudo apt-get install xtrabackup I wrapped the backup program in a small shell script ...

June 13, 2011 · 1 min · alj

Natty Narwhal: Problems connecting to servers behind (Cisco) firewalls using ssh

After upgrading to Natty Narwhal I couldn’t connect to my Linux based jump host (connected via VPN): OpenSSH_5.8p1 Debian-1ubuntu2, OpenSSL 0.9.8o 01 Jun 2010 debug1: Reading configuration data /home/alj/.ssh/config debug1: Applying options for * debug1: Applying options for smallpox.xxx.dk debug1: Reading configuration data /etc/ssh/ssh_config debug1: Applying options for * debug1: Connecting to smallpox.xxx.dk [xxx.xxx.xxx.xxx] port 22. debug1: Connection established. debug1: identity file /home/alj/.ssh/id_rsa type -1 debug1: identity file /home/alj/.ssh/id_rsa-cert type -1 debug1: identity file /home/alj/.ssh/id_dsa type 2 debug1: Checking blacklist file /usr/share/ssh/blacklist.DSA-1024 debug1: Checking blacklist file /etc/ssh/blacklist.DSA-1024 debug1: identity file /home/alj/.ssh/id_dsa-cert type -1 debug1: identity file /home/alj/.ssh/id_ecdsa type -1 debug1: identity file /home/alj/.ssh/id_ecdsa-cert type -1 debug1: Remote protocol version 2.0, remote software version OpenSSH_5.5p1 Debian-4ubuntu4 debug1: match: OpenSSH_5.5p1 Debian-4ubuntu4 pat OpenSSH* debug1: Enabling compatibility mode for protocol 2.0 debug1: Local version string SSH-2.0-OpenSSH_5.8p1 Debian-1ubuntu2 debug1: SSH2_MSG_KEXINIT sent debug1: SSH2_MSG_KEXINIT received debug1: kex: server->client aes128-ctr hmac-md5 [email protected] debug1: kex: client->server aes128-ctr hmac-md5 [email protected] debug1: SSH2_MSG_KEX_DH_GEX_REQUEST(1024<1024<8192) sent debug1: expecting SSH2_MSG_KEX_DH_GEX_GROUP Read from socket failed: Connection reset by peer The key seem to be that Natty uses OpenSSH 5.8p1 – This problem seem to affect clients newer than 5.7p1, when connecting to older servers. And the problem seem to be restricted to connecting through some firewalls, I have no problem on my home network and when connecting to hosts running iptables. ...

March 21, 2011 · 2 min · alj

Ubuntu Natty: Making a Gobi 2000 wireless modem work

In the pre-10.04 days it was possible to make a Gobi 200(0) modem work by installing gobi_loader and using it to load the firmware for the modem. However, with the release of Ubuntu 10.04 (which sports a shiny 2.6.35 kernel) gobi_loader stopped working. Because gobi_loader (according to the homepage) does not support 2.6.32+ I stopped caring and used my Huwai stick instead. Recently one my colleagues noted that after upgrading to 10.10 the wireless broadband connection seemed to be available from time to time – and having recently upgraded to Natty (11.04) I decided to see if I could get it to work again. ...

February 25, 2011 · 2 min · alj