Friday, 27 May 2016

For about 3 years I've been playing a virtual reality game called Ingress, basically you have to travel to places and by travel I meant physically go there, capture portals and link 3 together as a triangle, everything under that triangle is then under control of your team, there are two teams, the resistance and enlightened, the enlightened want to work with aliens to accelerate humans, the resistance want it to continue as normal. The game is run by Niantic, an offshoot of Google and is free, except for some of the stuff in the store and the vast amount of petrol you use travelling to portals.

It was great, you got to find things that you didn't know about and added to a day out, what eventually happens is you go out to find portals, capture them and ignore everything else and this wasn't helped when they introduced a badge called the "Sojourner Badge". This is like an Ingress addict badge, it forces you to hack a portal every 24 hours and if you don't you go right back to the start of the hacking streak. I missed one day on holiday last year and has to start again and eventually got my black or onyx badge, I felt nothing.

And very recently, Niantic have introduced a cheat detect routine in their software that has managed to get legitimate players banned while known cheats and spoofers are allowed to carry on.

Then there's the portal issues, there are quite a few fake or obsolete portals out there, you report them and Niantic say there is no evidence to support the removal. One local portal was a church until 2 years ago, it's now a block of flats, no evidence. There are obvious fake portals and so much more and it's stopped being fun to play. I do blame the Sojourner badge, it made me hack every 24 hours and it then became something I had to do as opposed to something I wanted to do.

I've gone for a name change from Agent37168, my old Geek Squad badge number to Th3MajorTom and that has not helped.

So, it's time to hang up the scanner for now, I've uninstalled the software and sent my account deletion email, it will take some time to come through and I may change my mind but at the moment I've had enough.

Sunday, 8 May 2016

Today is not a good day, my old faithful Asus EEBox which has been running almost constantly since 2008 decided to curl up and die, it's been running as a file server all this time amongst other things. The onboard had drive was just used to boot the OS, all data is store on two external 5TB drives.It was time to replace it and to see if a Raspberry Pi was up to the job. The Raspberry Pi I got was as part of a starter kit from PC World, it included a case, power supply, ethernet lead and micro USB lead.I downloaded Rapbian and wrote to the image to a card as shown on the website.I plugged everything, got some lights on the Pis but nothing on the ethernet socket, it was time to move it to the TV, unplug my other Pi and see what was happening, to my surprise it booted up and it all worked, I logged in via ssh and ran sudo raspi-config, set it all up, rebooted and reconnect. I took it back to where it's going to be located and again, no ethernet lights. After much buggering round it looks like the supplied micro USB lead isn't up to the job, there's too much of a voltage drop, the PI was now alive. I connected the external drives and set up fstab to mount the drives automatically, set up some samba shares and an nfs share, rebooted and was unable to connect to the nfs shares, again some research continued and it seems that there's an issue on Raspbian which means that the rcpbind service doesn't start automatically.I decided to get round this in a most unelegant way, I added some entries into the rc.local file with:sudo nano /etc/rc.localThis lot got pasted in just before the "exit 0" bit at the bottomservice smbd stopservice nfs-kernel-server stopmount -U b8828e80-d5c4-4747-a3f6-82eda807a34d /mnt/datamount -U dc3e664f-27da-4e62-b1ba-f5a220a836a6 /mnt/backups/rpcbind -wservice nfs-kernel-server restartexportfs -ravservice smbd restartNot all of it may be needed but it does work, I decided to mount my external drives here too, just in case one failed to mount on bootup, the pi isn't going to have a screen or keyboard connected and would hang at the boot screen.You just need to make the file executable with:sudo chmod +x /etc/rc.localAfter that it all worked quite nicely and I'm managing to play some music stored on the pi and watch some videos at the same time.Just in case you didn't know, you can install the required nfs files with:sudo apt-get install nfs-common nfs-kernel-serverAnd Samba can be installed with:sudo apt-get install samba samba-common-bin Following up on this as the external drives started to fill up I began to get problems with the little Pi running out of memory and crashing. Ok, it's not got a lot of memory but it worked well to start with so I decided to upgrade the firmware, setup the memory, remove the swapfile and move the OS to an external drive, in this case it's a 32GB USB drive.Let's remove the swapfile first with the following:sudo dphys-swapfile swapoffsudo dphys-swapfile uninstallsudo update-rc.d dphys-swapfile removeNext up, we need to update the firmware withsudo apt-get install rpi-updateand thensudo rpi-updateOnce it's all done, reboot and let's sort the memory, this time we run the config utilitysudo raspi-configSelect advanced options

Then the memory split option

Change this to 16 and select OK

Then Finish and reboot

And now we come to moving the OS onto an external drive, as mentioned before this is a 32GB USB drive, plug it in and rundmesg | tailIt should show the USB device at the end, in my case it identified it as /dev/sdaTime to wipe it and sort out the filesystem with:sudo fdisk /dev/sda (or whatever your USB device shows) Then it's "d" to delete the partition, "n" for a new partition, followed by "p" for primary, then select the defaults for the next three questions and finally "w" to write the partition.Now we format it with:sudo mkfs.ext4 /dev/sd?1And then we mount it to a temporary folder withsudo mkdir /mnt/tempsudo chmod 0777 /mnt/tempsudo mount /dev/sda? /mnt/tempOnce that's done it's time to copy all the files over but first we need to install rsync:sudo apt-get install rsyncsudo rsync -axv / /mnt/tempIt will take some time for this to complete, so go and have a coffee.Now we need to tell the pi to boot the OS from the stick, the micro SD card needs to stay in as it will initially start from this and then load everything from the USB stick.Let's backup the config file first with:sudo cp /boot/cmdline.txt /boot/cmdline.origNext we'll edit withsudo nano /boot/cmdline.txtThe original looks like this:dwc_otg.lpm_enable=0 console=serial0,115200 console=tty1 root=/dev/mmcblk0p2 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwaitIt's all on one line, we need to change the root=/dev/... bit to read root=/dev/sda1 or whatever your USB stick shows, we also need to add a delay to the end with rootdelay=5, it should look like the one below in the end.dwc_otg.lpm_enable=0 console=ttyAMA0,115200 kgdboc=ttyAMA0,115200 console=tty1 root=/dev/sda1 rootfstype=ext4 elevator=deadline rootwait rootdelay=5Save it and then we need to edit fstab with:sudo nano /etc/fstabThe following entry needs to be added:/dev/sda1 / ext4 defaults,noatime 0 1And the line referring to the sd card needs to be commented out, mine looks like this now

proc /proc proc defaults 0 0

/dev/mmcblk0p1 /boot vfat defaults 0 2

# /dev/mmcblk0p2 / ext4 defaults,noatime 0 1

/dev/sda1 / ext4 defaults,noatime 0 1

Save it and then it's time to reboot and it should all now be running off the USB stick with a bit more memory.

It's now running quite well with those big drives plugged in, every hour the data drive is backed up to the backup drive with a cron job and data is also sent to a remote location once a week, it really is a good little machine.