pancakelizard

what to buy me for a present….

Posted on February 27, 2014

I've been told I'm pretty hard to buy for present-wise. Personally, i dont think that, but then i guess i know me best...

anyway, heres a bunch of ideas, suggestions, do's and don'ts if you're ever wondering what to buy me for my birthday/christmas/whenever.

first off, i have an amazon wishlist. this page is updated a few times a year, so have a look there and see if theres anything in particular, or use it as inspiration of what i like. I'll try and keep this updated too if anything changes.

things i definitely DON'T want:

  • novelty tat. that crap you get in christmas gift catalogues. theres very little i can think of that i dont hate
  • mugs (i dont drink coffee or tea. I already have several mugs i like but don't use. theres no point adding to that!)
  • clothes (especially socks. see also novelty tat above! - if i like something, ill buy it myself! the only exception to this is t-shirts, about which i'll get to later)
  • red wine or strange liqueurs (especially baileys) - the only exceptions to this would be cherry/raspberry flavoured things
  • flavoured chocolate or toffee. I like normal plain flavoured chocolate (ie plain/milk/dark/white. i prefer milk/white of those four), but anything involving orange/coffee/mint flavouring will make me realise you REALLY dont know me
  • anything involving aniseed/liquorice/coffee/banana
  • gift vouchers. unless its for amazon, or something like a specialist whisky/food shop.... John lewis/HMV/argos/love2shop vouchers is just pointless in my opinion

SO ONTO THE LIST OF IDEAS.....

booze is always a good bet. i like strongbow, dry white wine, fizzy wine (cava/etc, or champagne if you want to splash out!), port and single malt scotch whisky

vinyl is always a good bet too. especially if it's dancefloor fillers and classics. especially 90's hip-hop! i'd rather a couple of good 12" singles from robs records or a charity shop than almost any CD

speaking about music. unless you know me well, its probably pointless buying me music. unless it's classic vinyl. I have a *massive* record collection, and i tend to buy something i want anyway. the exception to this is something you think i dont already know about that i might like. this could go either way though! kinda the same for DVDs too...

whisky - i like scottish single malts. my tastes are more the speyside/islay malts. think jura, lagavulin glenmorangie. with that in mind i DO NOT like laphroig. its just a tad *too* peaty for me. lagavulin is about my enjoyable limit in that field. if in doubt, a whisky voucher is always appreciated (recently got one for weavers in notts, and used it to put towards a bottle i really wanted!)... i really dont tend to like the bottom end supermarket stuff. think bells/grants/grouse/etc . i dont mind irish/bourbon, as long as its something a bit different (ie not jack daniels or jim beam! pappy van winkles is on my bucket list and i would LOVE YOU FOREVER if you got me some of that!) - my go-to drinking whisky available randomly on offer in supermarkets would be glenmorangie or jura.

cooking- i love to cook, and good quality utensils are always welcome. my amazon wishlist is a good place to start with ideas for these. posh knives are a current favourite, as i bought some I.O. Shen knives not long ago, and am looking to expand my shiny sharp thing collection!

spicy things- exotic spicy things! just been on holiday to thailand/mexico/wherever? bring me back a random scary looking spicy thing. i love nothing more than going to asiana in town and coming back with packets and jars or strange and wonderful things. just make sure it's legal to bring home with you :)

books - whilst my reading list is pretty full right now, i'm a sucker for a nice book. especially cookery or pop culture (again, see my amazon wishlist for ideas along these lines)

t-shirts - the biggest possible size. preferably in dark colours. i like them baggy. geek/pop culture/tv. have a look on thinkgeek, threadless or last exit to nowhere. current favourites are ron swanson, walter white, or the wire themed.

flavours i really like: cherry, raspberry, spicy.
sweets/chocolate i like: pretzel M&Ms, red winegums, caramel/toffee (including bonfire!), reeses peanut butter

If all else fails and you cant think of anything... booze or amazon vouchers! i dont get nearly enough port or whisky for christmas these days...

Filed under: blog, HOWTO No Comments

samsung error: Voice Command – Unexpected server error occurred. Please try again.

Posted on June 19, 2013

My samsung Galaxy SII phone has been throwing up a voice command error all day so far today.

Voice Command - Unexpected server error occurred. Please try again.

It would seem i'm not alone. a quick google reveals other people have started experiencing this as well. I have tried the following remedy:

  •  SettingsApplicationsAll tab → scroll down to Voice Command.
  • From there click Force StopOK then Clear Data

I guess we'll see if this fixes it over the rest of today...

*edit 19 Jun*

it seems to work for some users, but not all. heres another suggestion as a bit of a more drastic workaround until samsung get their arses into gear and fix things properly:

  •  Settings → Applications → Running → Voice Command.
  • click on DISABLE

obviously you wont be able to use the voice command stuff whilst it is disabled, but then who actually uses that stuff? i know i dont...

Filed under: geek, HOWTO 3 Comments

turn your raspberry pi into a virtual DJ streaming device for a second room PA system

Posted on February 6, 2013

I finally found a great use for my #raspberrypi, i used it to provide a technological answer to a problem i faced as a DJ, when asked to run the audio i'm playing into the bar downstairs, so they can hear it in both rooms. the easy fix would have been run a 30m audio cable out of the window, downstairs, and into the bar. but thats a messy solution, involving a lot of effort and gaffa tape. This uses homeplugs (or wifi access points if that doesnt work) to do the same sort of thing. youll need virtualDJ and set it up in broadcast mode to stream the audio via the LAN.

heres my proof of concept version of it up and running:

raspberry pi test rig

you will need:

model B pi
a case (although this is optional and you could always make your own out of lego/cardboard/etc!
a microUSB PSU. my ipad charger works fine for this along with a normal microusb cable
a 4gb SD card (or bigger) although a 2gb will probably work ok too...
a couple of RJ45 cat5/6 ethernet cables
a pair of powerline ethernet "homeplug" devices - http://www.hotukdeals.com/search?action=search&keywords=homeplug - ive got a piar of 500mbit ones, but 100mbps plugs should in theory be enough for for job.

then, with the pi, set it up as follows:

this assumes you are partially familiar with TCP/IP networking, comfortable with a command-line interface, and using an ssh client on your pc, but all of which is pretty easy to pick up. its just a case of doing a bit of background reading.

download raspbian wheezy and "burn" to your SD card.

http://downloads.raspberrypi.org/images/raspbian/2012-12-16-wheezy-raspbian/2012-12-16-wheezy-raspbian.zip

if you havent done this before, use the guide at http://elinux.org/RPi_Easy_SD_Card_Setup

on your raspberry pi, plug into a hdmi screen with a usb keyboard and network cable into your switch/router:

run the raspi config and set it up accordingly (ie password, etc) then set up networking:
sudo raspi-config
cp /etc/network/interfaces /etc/network/interfaces.sav
sudo cp /etc/network/interfaces /etc/network/interfaces.sav
sudo pico /etc/network/interfaces

add the following (if not using wifi, the second bit for wlan0 isn't needed) to /etc/network/interfaces:

auto lo

iface lo inet loopback
#\iface eth0 inet dhcp

auto eth0
iface eth0 inet static
#your static IP
address 192.168.1.20
#your gateway IP
gateway 192.168.1.1
netmask 255.255.255.0
#your network address "family"
network 192.168.1.0
broadcast 192.168.1.255

allow-hotplug wlan0
iface wlan0 inet static
address 192.168.1.21
netmask 255.255.255.0
gateway 192.168.1.1
wireless-essid nottsdjdotcodotuk
# wpa-psk "<password of wireless network>"
# wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
# iface default inet dhcp
reboot, and check everything comes up ok:

sudo reboot

after the reboot, see if you can access if via your main desktop PC via the ethernet:

ssh pi@192.168.1.20
(or use puTTY if you are on a windows system)

assuming this works, you can do everything else from your main pc now, but dont unplug that hdmi/keyboard just yet in case something goes wrong!

install mpg123, sound card utils and update the firmware and OS:

sudo apt-get install alsa-utils
sudo apt-get install mpg123
sudo amixer cset numid=3 1sudo apt-get update
sudo apt-get upgrade
sudo apt-get install git-core
sudo wget http://goo.gl/1BOfJ -O /usr/bin/rpi-update && sudo chmod +x /usr/bin/rpi-update
sudo rpi-update
sudo reboot

run update once more after the reboot just to confirm you are on the latest firmware:

sudo rpi-update

check /etc/asound.conf exists and contains something like (this depends on the results of lsmod):

lsmod
sudo pico /etc/asound.conf

#pcm.mmap0 {
# type mmap_emul;
# slave {
# pcm "hw:0,0";
# }
#}
#
#pcm.!default {
# type plug;
# slave {
# pcm mmap0;
# }
#}
pcm.!default {
type hw
card 0
}

ctl.!default {
type hw
card 0
}
fire up virtualdj from your laptop/desktop, setting your ip address to 192.168.1.100 (or whatever your computer's IP address is) and making sure your firewall is either disabled of there is an appropriate hole for port 8000. play some music in vdj.

run mpg123 and test it streams ok from virtualdj:

mpg123 -ol http://192.168.1.100:8000/VirtualDJ.mp3

assuming this works ok, create a script to run it from boot:

sudo pico /etc/init.d/playaudiostart.sh

add in the following lines:

### BEGIN INIT INFO
# Provides: scriptname
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Start daemon at boot time
# Description: Enable service provided by daemon.
### END INIT INFO
#!/bin/bash
amixer cset numid=3 1
mpg123 -ol http://192.168.1.100:8000/VirtualDJ.mp3

make your script executable and bootable:

sudo chmod +x /etc/init.d/playaudiostart.sh
sudo insserv playaudiostart.sh

reboot the device, and test it autoboots and plays music from vDJ.

once all configured and tested, try it in a different room using your homeplug (or wifi) devices. once all tested at home, I went to the venue last week and made sure it all ran ok. it worked first time using the homeplugs, so i didnt even need to set up the wifi. RESULT! I'll post an update once i've actually gigged with it next month.

 

Filed under: geek, HOWTO 1 Comment

how to easily add a new keyfob to a mazda 626

Posted on May 11, 2012

so the keyfob for my 2003 mazda 626 died. i couldnt work out whether it was the microswitch or the battery, but after fiddling with it and replacing the battery, it still didnt work. after speaking with a dealer, it was looking like i was resigned to either forking out upwards of a hundred quid, or locking via the key in future. after a few days of doing this, i was sick of it!

but then thanks to google, i found out i could do it myself with mazda's own version of the konami code and an identical keyfob from ebay. the IDENTICAL FOB IS VITAL. check the model number, even one that looks the same might not necessarily work! Mine was a visteon 41601. there were at least two models that LOOK like mine, and some people may have had success with mixing models, but others had problems. so i didnt risk it. i won one on ebay for a fifth of the price of what a dealer was going to charge, and it arrived today. so heres how you program your car to work with the key (not the other way round!)....

  • sit in the drivers seat with the key OUT of the ignition
  • open the door
  • whilst open, attempt to lock the car using the button on the door
  • with the door still open, insert the key and turn the ignition ON (dont start the car, just move it clockwise two clicks so everything has power)
  • after a couple of seconds, turn the ignition off. turn it on and off again TWICE FURTHER (ie 3 times) leaving the key in the OFF position
  • close the door. Then open it. Then close it. Then open it. Then close it. Then open it.
  • the car will then go nuts for a second and lock/unlock the car. this means your car is ready!
  • press a button on your fob to pair it with your car. repeat for any other fobs up to a maximum of THREE. remove the key, and lock (or unlock) the door using the button on the door. the car will then lock and unlock a couple more times, and all the keyfobs should now work

and the best thing? i found a seller on ebay who does keyfob repairs! so for less than 15 quid, i had me a spare keyfob that now works in case i get my keys stolen. he replaced the microswitches and the battery, and now it is as good as new.

Filed under: blog, geek, HOWTO No Comments

Raspberry Pi and a Motorola Atrix Lapdock?

Posted on May 8, 2012

so my new #raspberrypi turned up this morning :)

here it is, sat alongside a laser-cut case i bought from ebay... i know the case cost almost half as much as the pi itself, but i'm lazy!

 

after a bit of fiddling, taking an eternity to peel off all of the protective green (and clear) plastic on the acrylic, i got it all together...

so, what am i going to do with the pi? good question, i'm unsure as yet. i wanted it because its a shiny new toy and i want to see what i can do with it!

one thing i do plan on doing though, is seeing if i can get it hooked up to the motorola atrix lapdock. if youve never come across it, it is an 11" screen, keyboard and ~8hr battery. basically a dumb netbook. you're *supposed* to dock it with the atrix mobile phone. but at £50 from ebuyer, i thought it might come in handy being able to use it with my samsung galaxy s2 mobile and/or the rasperry pi.

The lapdock should be arriving today. I'm also waiting on a Micro HDMI Type D Female to Micro HDMI Type D Female Connector as well as a Gold Adaptor HDMI Female to Mini HDMI male Converter, so in theory, i can hook up any hdmi device to the lapdock. Expect a full writeup once the bits arrive :)

 

Filed under: blog, geek, HOWTO 6 Comments

Revolutionise your TV / Movie watching

Posted on March 20, 2012

so i recently did a HOWTO on setting up an HP microserver with a bunch of apps and stuff youve probably never heard of. Today i'm going to go into a bit more detail, and with any luck, you too could have a nice, modern, streamlined way of getting (almost) all the TV you ever need. especially if you like watching US TV shows, but also works for a LOT of UK TV too...

so heres my current setup....

bedroom - HP Microserver with lots of storage, plugged into a 200mbps homeplug adapter going into:

downstairs lounge - homeplug network adapter going into appletv2 running XBMC and/or apple flash (black) plugged into my big TV.

The Microserver AUTOMATICALLY DOWNLOADS all of the TV shows i want usually a few hours after the episode has been broadcast in the US. As most of the stuff i watch is on at ~9pm, it generally grabs everything overnight, so it is waiting for me when i get home from work the next day (or if its a weekend, when i get out of bed!). it then streams the video through the mains electricity cabling downstairs to my appletv2 which is then used to view it on the TV. other devices can be used, but i chose these due their relatively low power consumption (compared to a full desktop PC switched on 24/7 and a PS3 as the viewing device, but these will work, you just may have to add a few extra steps in. work with what youve got!)

So how do you do this?

the backend programs you need are SABNZBD and SICK BEARD. both are COMPLETELY FREE and stupidly easy to set up and configure. However, you will probably need to pay out for a premium NEWSGROUPS provider. most ISPs dont usually have a decent usenet (aka newgroups) feed these days, and even if they did, it probably wouldnt be nearly as fast as someone like supernews. Once you have a newsgroups account, you need access to an indexer. A good free nzb index site is: www.nzb.su and you can find more NZB providers at http://wiki.sabnzbd.org/nzb-sources.

OK, so you have your index, newsgroup provider, and have installed and configured sabnzbd and sickbeard. now what?

simples. click ADD SHOW, find the show you want to watch from the list, and then click OK. you could download previous episodes too, or select whether you want standard definition of HD episodes, but thats up to you.

add in all the shows you want, and it just goes off and downloads any new episodes of the shows. completely automatically! its like setting a season pass on your sky plus or tivo, but without actually having to wait for a UK channel to pick up your new favourite show (seriously, why the hell hasnt workaholics been shown in the UK yet? or the league? or Parks & Recreation? its ridiculous!) it's almost as if the media companies dont want us to watch their stuff!

Filed under: geek, HOWTO No Comments

HOWTO hack your netflix so you can watch US content

Posted on March 19, 2012

i recently signed up for a trial of NETFLIX in the uk. even after a tiny amount of time, it is already better than LOVEFILM's offerings, and the quality of streaming is infinitely better.

But the choice of content is still relatively poor, especially if you have experienced it whilst in the US. they have *loads* of cool stuff there that we dont get.

So how do we fiddle it so that netflix serves us the stuff from the US instead of the UK? and while we're doing that, how about all that cool content for US TV shows on the tv networks (HBO and showtime for example) websites that is restricted because we dont live in the US.... well, its easy.

Unblock-us.com is your friend. you get a month long trial for $0.99, and when coupled with your netflix trial (1 month free for signup, plus quidco.com are doing £15 cashback on account signups so you are basically getting 3 1/2 months of netflix for FREE!. unblock-us is then $5 (canadian, works out at £2.46) a month or $50 a year (£24.64, or £2.05 a month if you pay for a year at a time)

and what do you get for this? some of the great stuff you can now watch includes:

Arrested Development
Parks & Recreation
The League
Workaholics
Archer
30 Rock
Blue Mountain State
Portlandia
Daniel Tosh - completely serious
Louis CK Live
Tucker & Dale vs Evil
Friday Night Lights
Rescue Me
Greek
Red State
Rubber
Troll Hunter
Hobo With a Shotgun
American: The Bill Hicks Story
I could go on... and on... and on...... but that list there should get you through the first few months of viewing! I'm currently watching GREEK, and am probably going to move onto FRIDAY NIGHT LIGHTS after that.

So what do you need to do to get this working?

its not difficult, and is documented on the unblock-us website, but basically, you change your DNS servers in the network settings on your laptop/ipad/appletv/playstation 3/xbox360/router/whatever. it takes a few minutes, even if you are as a big a technophobe as my mum!

Whilst I originally used my PS3 to view the US netflix content, i have since modified my appletv2 to also show the US content (and moved the ps3 back to my normal UK DNS so i can switch libraries quickly and easily if i wanted to watch something that was UK-only) If you dont have an appletv, you really should think about getting one. jailbreak it and install XBMC and/or apple flash (black) media players and it will soon become an irreplaceable way of watching TV. i use it so much, i'm seriously considering dumping my virgin media TIVO, as i barely watch anything live nowadays (see my previous post about setting up sickbeard and sabnzbd. i'll be going into more detail with that soon...)

so yeah. youve probably already signed up for netflix, i know loads of people who have. just give unblock-us a week's free trial, and if that doesnt make you decide immediately to stump up the extra £2.05 a month, i dont know what will!

*UPDATE - 03 Sep 2012*

just to clarify, to watch the US content, you dont need a specific US netflix account, your UK subscription will work just fine! same as a US subscription will let you view UK content via Unblock-us.com - there is now an option on the site to let you choose which content you want to watch (UK, US or Canadian).. just select your preferred country and fire up netflix on your device (once youve configured DNS, that is!), its that simple!

set up a HP Microserver with Ubuntu and everything you need

Posted on February 17, 2012

this isnt the final version of this, but it has been sat here for a while, so figured i should at least share my initial progress on it

So i bought a HP microserver. loaded it full of drives and stuck ubuntu server on it. below is a bit of a HOWTO/build script. DO NOT RUN IT AS A SCRIPT. it will not work. instead read through it and do it by hand in chunks. you WILL need to change some stuff.

but it should give you a good start into building your own with sabnzbd, sick beard, squeezebox server, and loads more. Since doing this, i have moved from greyhole to GLUSTER as my JBOD filesystem as well as installing AFP as samba performance on my mac was poor. I'll get round to finishing it off at some point...

enjoy!

 

################################################ ubuntu 11.04 server setup:

select region/keyboard settings as needed
enter servername. in this case i am using "microserver"
disk setup as appropriate (i used guided with lvm) and
set up username/password (in my case i used "wanye" and dont encrypt your home folder
enter proxy information if necessary
select "install security updates automatically"
select "OpenSSH server" from the list of server modules to install (we will install the rest later as we need them)
remove cd/usb and reboot when completed
log in and find the ip address of the server (in my case 192.168.1.238)
config files needed:
/etc/lighttpd/lighttpd.conf
/root/.rtorrent.rc
/var/www/rutorrent/conf/config.php
/etc/default/sabnzbdplus
/home/wanye/rtorrentInit.sh

(optional) binary files needed:
squeezeboxserver_7.6.1_all.deb (or latest version from mysqueezebox.com)

(optional) web server frontend link page:
index.html
icon-webmin.png
pixel.png
rtorrent.png
rutorrent.png
sabnzbd.png
sickbeard.png
squeezebox.png
(to be copied to /var/www once completed)
################################################ network config and initial setup

#set up static IP address instead of DHCP and add hosts entries
sudo nano /etc/hosts
-------------------
127.0.0.1 localhost microserver
192.168.1.250 microserver
192.168.1.10 nas #This is optional and depends on your personal setup
-------------------

sudo nano /etc/network/interfaces
-------------------
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).

# The loopback network interface
auto lo
iface lo inet loopback

# The primary network interface
auto eth0
iface eth0 inet static
address 192.168.1.250
netmask 255.255.255.0
gateway 192.168.1.1

-------------------

sudo nano /etc/resolv.conf
-------------------
### ensure your DNS servers are listed
192.168.1.1
194.168.4.100
194.168.8.100
-------------------

################################################ reboot
sudo shutdown -r now
################################################ install additional modules needed for things
sudo apt-get install git-core python smbfs subversion libncurses5-dev libsigc++-2.0-dev libcurl4-openssl-dev build-essential screen wget unzip unrar php5 pkg-config libperl-dev libterm-readline-gnu-perl php5-cgi php5-curl php5-cli ffmpeg

################################################ mount samba share on NAS/server
sudo mkdir /mnt/nas
sudo nano /etc/fstab

##### add in the following
//nas/share /mnt/nas cifs guest,uid=1000,iocharset=utf8,codepage=unicode,unicode 0 0

sudo mount -a
################################################ install webmin
sudo nano /etc/apt/sources.list

add the following to the bottom:
-------------------
deb http://download.webmin.com/download/repository sarge contrib
deb http://webmin.mirror.somersettechsolutions.co.uk/repository sarge contrib
-------------------

wget http://www.webmin.com/jcameron-key.asc

sudo apt-key add jcameron-key.asc
sudo apt-get update
sudo apt-get install webmin

sudo nano /etc/webmin/miniserv.users
##### add your username to list
sudo /etc/init.d/webmin restart

try logging into https://192.168.1.250:10000/ as your user

################################################ install rtorrent and gui
sudo apt-get install lighttpd
sudo nano /etc/lighttpd/lighttpd.conf
OR
sudo cp /home/wanye/lighttpd.conf /etc/lighttpd/lighttpd.conf
sudo /etc/init.d/lighttpd restart
##### add settings as required for rtorrent

# create download directory for rtorrent
sudo mkdir /data /data/torrentdownloads /data/torrentdownloads/.session

### compile libtorrent from source
cd /tmp
sudo wget http://libtorrent.rakshasa.no/downloads/libtorrent-0.12.9.tar.gz
sudo tar zxfv libtorrent-0.12.9.tar.gz
cd libtorrent-0.12.9
sudo ./configure
sudo make
sudo make install
### compile xmlrpc-c from source
cd /tmp
sudo svn checkout http://xmlrpc-c.svn.sourceforge.net/svnroot/xmlrpc-c/stable xmlrpc-c
cd xmlrpc-c/
sudo ./configure
sudo make
sudo make install
### compile rtorrent from source
cd /tmp
sudo wget http://libtorrent.rakshasa.no/downloads/rtorrent-0.8.9.tar.gz
sudo tar zxfv rtorrent-0.8.9.tar.gz
cd rtorrent-0.8.9
sudo ./configure --with-xmlrpc-c
sudo make
sudo make install

sudo ldconfig

### install rutorrent and plugins from svn

cd /var/www/
sudo svn co http://rutorrent.googlecode.com/svn/trunk/rutorrent
sudo svn up
### plugins dl
cd /var/www/rutorrent/
sudo rm -rf plugins/
sudo svn co http://rutorrent.googlecode.com/svn/trunk/plugins/
sudo svn up

### configure rtorrent
sudo nano /root/.rtorrent.rc
OR
sudo cp /home/wanye/.rtorrent.rc /root/.rtorrent.rc

sudo nano /var/www/rutorrent/conf/config.php
OR
sudo cp /home/wanye/config.php /var/www/rutorrent/conf/config.php
sudo chmod -R 747 /var/www/rutorrent/
sudo chown -R www-data:www-data /var/www/rutorrent/share/
sudo /etc/init.d/lighttpd restart

#### set it to autostart on reboot
sudo cp /home/wanye/rtorrentInit.sh /etc/init.d/rtorrent
sudo chmod +rx /etc/init.d/rtorrent
sudo update-rc.d rtorrent defaults

#### install mediainfo module for rutorrent plugin
sudo apt-get install --reinstall python-software-properties && sudo dpkg-reconfigure python-software-properties
sudo add-apt-repository ppa:shiki/mediainfo
sudo apt-get update
sudo apt-get install mediainfo

################################################ reboot and test rtorrent autostarts ok
sudo shutdown -r now
################################################ install sabnzbd, sickbeard, couchpotato and usenet tools

# install sabnzbd
echo "deb http://ppa.launchpad.net/jcfp/ppa/ubuntu $(lsb_release -c -s) main" | sudo tee -a /etc/apt/sources.list && sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:11371 --recv-keys 0x98703123E0F52B2BE16D586EF13930B14BB9F05F
sudo apt-get update
sudo apt-get install sabnzbdplus
sudo nano /etc/default/sabnzbdplus
##### set up sab config

/etc/init.d/sabnzbdplus start

------------------------------
# [required] user or uid of account to run the program as:
USER=wanye

# [optional] full path to the configuration file of your choice;
# otherwise, the default location (in $USER's home
# directory) is used:
CONFIG=

# [optional] hostname/ip and port number to listen on:
HOST=192.168.1.250
PORT=8080
-------------------------------

####### point your web browser at http://192.168.1.250:8080 and follow setup instructions
# install couchpotato movie grabber
cd /usr/local/sbin
sudo git clone http://github.com/RuudBurger/CouchPotato.git
sudo mv CouchPotato couchpotato
cd couchpotato
sudo python CouchPotato.py -d
cd /usr/local/sbin/couchpotato
sudo cp initd /etc/init.d/couchpotato
sudo chmod a+x /etc/init.d/couchpotato
sudo update-rc.d couchpotato defaults
sudo /etc/init.d/couchpotato start

####### point your web browser at http://192.168.1.250:5001 and follow setup instructions

# install sickbeard tv grabber
sudo apt-get install python-cheetah
git clone git://github.com/midgetspy/Sick-Beard.git my-sickbeard-install
python SickBeard.py

################################################ install squeezebox server
sudo dpkg -i squeezeboxserver_7.6.1_all.deb

####### point your web browser at http://192.168.1.250:9000 and follow setup instructions
################################################ install greyhole for later use
wget https://github.com/downloads/gboudreau/Greyhole/greyhole-0.9.12-1.amd64.deb
sudo apt-get install samba
sudo apt-get -f install
sudo dpkg -i greyhole-0.9.12-1.amd64.deb

################################################ reboot
sudo shutdown -r now

copy web frontend links to /var/www - index.html and shortcut icons
point web browser at http://192.168.1.250 and ensure tall the links work ok.

removing line numbers from the bash history

Posted on September 15, 2011

i set up a server recently, but something got messed up and i had to reinstall, so instead of building it all again by hand, i simply took the contents of the bash history and edited it down to a script that will autoinstall everything in future.

history | sed 's/^ *[0-9]* *//' > serverinstallscript.sh

is the commend needed to remove the lines in front so you can easily create your own bash script...

Filed under: geek, HOWTO No Comments

ubuntu 10.10 network icon disappearing overnight and losing wireless connection.

Posted on August 19, 2011

I started having this problem a couple of days ago, my work laptop (usually on 24/7)would lose its network connections in ubuntu 10.10 overnight, however, any virtualbox machines would still keep whatever (wired) connection they were using. this has been happening the last two nights for some reason.

anyway, after checking various logs, i came across the "cfg80211: All devices are disconnected, going to restore regulatory settings" error, and googling brought me to http://azitech.wordpress.com/2010/02/22/deauthenticating-reason3/

All the posts helped, but after killing the single instance of wpa_supplicant, it still wasnt working.

in my case, the network-manager applet icon had also disappeared from my menubar. after running "nm-applet" my connections all came back to life. job done!

wanye@mylaptop:~$ tail /var/log/messages
Aug 18 16:11:07 mylaptop kernel: [28937.420256] usb 2-1.2: USB disconnect, address 5
Aug 18 22:00:22 mylaptop kernel: [49850.084038] cfg80211: Calling CRDA to update world regulatory domain
Aug 18 22:00:33 mylaptop kernel: [49862.749263] cfg80211: World regulatory domain updated:
Aug 18 22:00:33 mylaptop kernel: [49862.749268] (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
Aug 18 22:00:33 mylaptop kernel: [49862.749270] (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
Aug 18 22:00:33 mylaptop kernel: [49862.749273] (2457000 KHz - 2482000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
Aug 18 22:00:33 mylaptop kernel: [49862.749280] (2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
Aug 18 22:00:33 mylaptop kernel: [49862.749283] (5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
Aug 18 22:00:33 mylaptop kernel: [49862.749286] (5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
Aug 19 07:41:16 mylaptop rsyslogd: [origin software="rsyslogd" swVersion="4.2.0" x-pid="1079" x-info="http://www.rsyslog.com"] rsyslogd was HUPed, type 'lightweight'.

wanye@mylaptop:~$ dmesg
[49850.003854] iwlagn 0000:02:00.0: ACTIVATE a non DRIVER active station id 0 addr 00:xx:xx:xx:xx:31
[49850.046225] wlan0: deauthenticating from 00:xx:xx:xx:xx:31 by local choice (reason=3)
[49850.084028] cfg80211: All devices are disconnected, going to restore regulatory settings
[49850.084035] cfg80211: Restoring regulatory settings
[49850.084038] cfg80211: Calling CRDA to update world regulatory domain
[49862.749263] cfg80211: World regulatory domain updated:
[49862.749268] (start_freq - end_freq @ bandwidth), (max_antenna_gain, max_eirp)
[49862.749270] (2402000 KHz - 2472000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[49862.749273] (2457000 KHz - 2482000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
[49862.749280] (2474000 KHz - 2494000 KHz @ 20000 KHz), (300 mBi, 2000 mBm)
[49862.749283] (5170000 KHz - 5250000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)
[49862.749286] (5735000 KHz - 5835000 KHz @ 40000 KHz), (300 mBi, 2000 mBm)

wanye@mylaptop:~$ tail -40 /var/log/daemon.log
Aug 18 16:24:16 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: group handshake -> complete
Aug 18 16:24:35 mylaptop wpa_supplicant[1324]: WPA: Group rekeying completed with 00:xx:xx:xx:xx:31 [GTK=TKIP]
Aug 18 16:24:35 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: completed -> group handshake
Aug 18 16:24:35 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: group handshake -> completed
Aug 18 17:08:11 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: completed -> group handshake
Aug 18 17:08:11 mylaptop wpa_supplicant[1324]: WPA: Group rekeying completed with 00:xx:xx:xx:xx:31 [GTK=TKIP]
Aug 18 17:08:11 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: group handshake -> completed
Aug 18 17:23:48 mylaptop dhclient: DHCPREQUEST of 192.168.2.30 on wlan0 to 192.168.2.1 port 67
Aug 18 17:23:48 mylaptop dhclient: DHCPACK of 192.168.2.30 from 192.168.2.1
Aug 18 17:23:48 mylaptop NetworkManager[1109]: (wlan0): DHCPv4 state changed reboot -> renew
Aug 18 17:23:48 mylaptop NetworkManager[1109]: address 192.168.2.30
Aug 18 17:23:48 mylaptop NetworkManager[1109]: prefix 24 (255.255.255.0)
Aug 18 17:23:48 mylaptop NetworkManager[1109]: gateway 192.168.2.1
Aug 18 17:23:48 mylaptop NetworkManager[1109]: nameserver '192.168.2.1'
Aug 18 17:23:48 mylaptop NetworkManager[1109]: domain name 'Belkin'
Aug 18 17:23:48 mylaptop dhclient: bound to 192.168.2.30 -- renewal in 37383 seconds.
Aug 18 17:38:21 mylaptop wpa_supplicant[1324]: WPA: Group rekeying completed with 00:xx:xx:xx:xx:31 [GTK=TKIP]
Aug 18 17:38:21 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: completed -> group handshake
Aug 18 17:38:21 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: group handshake -> completed
Aug 18 17:38:41 mylaptop wpa_supplicant[1324]: WPA: Group rekeying completed with 00:xx:xx:xx:xx:31 [GTK=TKIP]
Aug 18 17:38:41 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: completed -> group handshake
Aug 18 17:38:41 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: group handshake -> completed
Aug 18 17:38:44 mylaptop wpa_supplicant[1324]: WPA: Group rekeying completed with 00:xx:xx:xx:xx:31 [GTK=TKIP]
Aug 18 17:38:44 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: completed -> group handshake
Aug 18 17:38:44 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: group handshake -> completed
Aug 18 18:43:38 mylaptop wpa_supplicant[1324]: WPA: Group rekeying completed with 00:xx:xx:xx:xx:31 [GTK=TKIP]
Aug 18 18:43:38 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: completed -> group handshake
Aug 18 18:43:38 mylaptop NetworkManager[1109]: (wlan0): supplicant connection state: group handshake -> completed
Aug 18 22:00:20 mylaptop NetworkManager[1109]: (wlan0): device state change: 8 -> 3 (reason 38)
Aug 18 22:00:20 mylaptop NetworkManager[1109]: (wlan0): deactivating device (reason: 38).
Aug 18 22:00:20 mylaptop NetworkManager[1109]: (wlan0): canceled DHCP transaction, DHCP client pid 2092
Aug 18 22:00:21 mylaptop wpa_supplicant[1324]: CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
Aug 18 22:00:22 mylaptop avahi-daemon[1113]: Withdrawing address record for 192.168.2.30 on wlan0.
Aug 18 22:00:22 mylaptop avahi-daemon[1113]: Leaving mDNS multicast group on interface wlan0.IPv4 with address 192.168.2.30.
Aug 18 22:00:22 mylaptop avahi-daemon[1113]: Interface wlan0.IPv4 no longer relevant for mDNS.
Aug 18 22:00:29 mylaptop ntpd[2199]: sendto(172.16.198.81) (fd=20): Invalid argument
Aug 18 22:01:34 mylaptop ntpd[2199]: sendto(172.16.198.81) (fd=20): Invalid argument
Aug 18 22:02:38 mylaptop ntpd[2199]: sendto(172.16.198.81) (fd=20): Invalid argument
Aug 18 22:03:41 mylaptop ntpd[2199]: sendto(172.16.198.81) (fd=20): Invalid argument
Aug 18 22:03:53 mylaptop ntpd[2199]: Deleting interface #4 wlan0, 192.168.2.30#123, interface stats: received=0, sent=768, dropped=4, active_time=50101 secs

wanye@mylaptop:~$ ps -ef|grep wpa_supplicant
root 1324 1 0 Aug18 ? 00:00:00 /sbin/wpa_supplicant -u -s
wanye 10435 4846 0 08:29 pts/1 00:00:00 grep --color=auto wpa_supplicant
wanye@mylaptop:~$ ps -ef|grep network
wanye 10437 4846 0 08:31 pts/1 00:00:00 grep --color=auto network

wanye@mylaptop:~$ sudo kill 1324
[sudo] password for wanye:
wanye@mylaptop:~$ ps -ef|grep wpa_supplicant
root 10441 1 0 08:32 ? 00:00:00 /sbin/wpa_supplicant -u -s
wanye 10448 4846 0 08:32 pts/1 00:00:00 grep --color=auto wpa_supplicant

wanye@mylaptop:~$ nm-applet
** Message: applet now removed from the notification area
** Message: applet now embedded in the notification area
** (nm-applet:10554): DEBUG: old state indicates that this was not a disconnect 0
** (nm-applet:10554): DEBUG: foo_client_state_changed_cb
** (nm-applet:10554): DEBUG: foo_client_state_changed_cb