Tag Archives: Raspberry Pi

Reinstalling another hosts packages on a new host with pkg

A while back I had to reinstall my Raspberry Pi 2 due to a faulty SD card. I decided to try something with pkg and it worked well so I wanted to share it here.

I copied my pkg database from the old SD card and then ran pkg upgrade -f which worked exactly how I hoped, and installed all the packages that I had previously had installed.

I did have to change the url in my /usr/local/etc/pkg/repos/FreeBSD.conf to url: "pkg+http://pkg.FreeBSD.org/${ABI}/latest", from quarterly as FreeBSD:11:armv6/quarterly/ was not populated at the time. (it is now, just making a note of it)

This was all done on FreeBSD 11.0-RC1 #0 r303979: Fri Aug 12 17:12:13 UTC 2016 root@releng2.nyi.freebsd.org:/usr/obj/arm.armv6/usr/src/sys/RPI2 arm.

Share
Nagios

Nagios on the Raspberry Pi

I have been playing around a bit with running Nagios on the Raspberry Pi for a while now and it works pretty well.

Even though I did the simplest kind of install of Nagios 3 with apt-get there was a couple of things that needed poking at to get external commands running.

Firs make sure that your webserver user is a member of the nagios group, and secondly change the group permissions lite below.

construct:/usr/lib/nagios/plugins# chmod g+w /var/lib/nagios3/rw

The above should be pretty self explanatory. I have no memory of actually adding the www-data user to the nagios group, but make sure that is done or the external commands wont work.

I’m currently monitoring 16 hosts – with a total of just about 30 checks which has to be seen as very little – and so far there has been no issues due to the Pies limitations.

Nagios circular map

Though it’s mostly just to test it still gives me some situational awareness which is always nice.

Share

Google authenticator on Raspberry Pi

Google authenticator logoAfter adding ssh keys as I try to always do on my systems I went on to installing the Google authenticator module.

Install and setup
construct:~# apt-cache search google-authenticator
libpam-google-authenticator - Two-step verification
construct:~#
construct:~# apt-get install libpam-google-authenticator

then as my user I just run google-authenticator to set it up:
henrik@construct ~ $ google-authenticator
Continue reading

Share
Raspberry Pi close

The Raspberry Pi is here!

Today it reached me at work thanks to a DHL delivery guy willing to make a couple of phone calls and an extra run.
I didn’t think it would arrive just yet so I had no prepared SD card, and due to my card reader in the mbp not working the process of flashing a card is a bit slower since I might have to use my GoPro camera as a reader..

Edit 20120620
I just wanted to note that my cheap Class 10 8GB Zap Glider card seems to work well.
End Edit

Edit 20120621
My A4 tech USB keyboard (KB-28GUSB) doesn’t work but a HP OEM (swedish) does.
End Edit

Here are a couple of unboxing pics to kill time with, taken with my new Galaxy S3 (so not cropped or altered just to test the camera).

Raspberry Pi box

Raspberry Pi box

Raspberry Pi ESD

Raspberry Pi ESD

Raspberry Pi top

Raspberry Pi top

Raspberry Pi bottom

Raspberry Pi bottom

Raspberry Pi close

Raspberry Pi close

Click to embiggen etc..
The pics are a bit noisy but I attribute that to being taken inside in pretty crappy lighting and having a monkey behing the steering wheel.

Share