RPi resurrection – Pt. II – NFS

The second good use you could put your Pi, more so if you have unused external HDDs lying around, is to make an NFS out of it! I’ll spare mirroring the details here, there are many good references on how to go about creating a Samba server. For example, this one.

Since my laptop’s storage is limited, oftentimes it started complaining, as soon as any space-consuming operation started. At that point, I often had to make some hard life choices! :), you know, of the “shall I keep the big file or zap it!” kinds.

On top of that, I am not sure about others, I have realised that OSX has made working with an external HDD as painful as possible! A FAT32 formatted HDD takes forever to be recognised! To top it all, there’s that eternal irk of having to “safely removing the drive”. I mean c’mon. Windows has done it — how long will OSX take??

Anyway, so those were the reasons. But, I guess, the basic reason was: because I wanted to. ūüėÄ

Once, your NFS is in the network, on Mac, it’s just a few more steps to make your new storage available, and ready to use!

The HDD did need to be formatted, as the original format of FAT32 did not go too well with the Raspberry Pi OS (erstwhile called Raspbian Buster) — in that the auto-mount used to fail. I formatted it as FAT to keep it OS-neutral, even though there are trade-offs but the benefits outweighed!

So, yes, that it.

RPi resurrection – Pt. I – Pi-hole

Couple months ago, got to know about the Pi-hole project. It’s an ad-block server that can you can configure at the network level. That is, it can be configured as the DNS in your home router.

Of course, the benefit of network-wide ad-blocking is that it does its job in all of your home devices. If however, your router does not allow configuring a DNS — then you’d have to configure the DNS on a per-device level. While it may sound painful, but trust me, it’s worth it!

Thanks to online advertising — reading even a simple news article has become painful. While a lot of people use ad-block plugins, these plugins are, limited to browsers. How do you deal with ads on devices where one does not use the browser — e.g. while playing games, etc? That’s where a network-level ad-blocking gets an upper hand!

Okay, I just realised that I haven’t talked about why is “RPi” there in this post’s title. The thing is, I came across a post on Pi-hole as I was looking for a better (read: any) use for a legacy Pi2 — which was lying about mostly unused — thanks to it being trumped by newer Pis that I got later.

Seems being a Pi-hole server is one of the best uses that I could’ve put it to! The admin console is a rich and responsive UI, which allows your to further tweak the Pi-hole server as per your needs, for example: for explicitly allowing/denying any ad server, blocking specific keywords, etc.

Pi-hole Admin Console

Depending upon your privacy requirements, there’re also options to not log, or enable data masking/anonymise the data that is logged.

Anyway, as Apache Indian would have put it: ‘nuff said! Do go ahead and try it out this amazing project and may you bask in the glory of an ad-free world! And oh, btw, one doesn’t really need a RaspberryPi for Pi-hole — you can potentially install it on anythingandd…there’s a Docker image as well!

The glorious 'threat/reward' model

We have witnessed this since our childhood. Right from our homes, to our schools, colleges, and finally in our jobs. The glorious ‘threat/reward’ model! As the name suggests, it’s an approach where a certain set of actions lead (or are known to lead) to a certain reward (candy, toys, perks, H1B, and of course “that-irresistible-promotion”). On the flipside, non-compliance to a given, pre-defined set of laid-out steps, leads to ‘threats’, or a consequence of those threats (read: no candy, no perks, …and..well, you get the point.)

Continue reading The glorious 'threat/reward' model

Alexa + Raspberry Pi = Fun!

So, after a week a of grappling, trying to make Alexa AVS¬†work on a humble Raspberry Pi 2 Model B, I finally had success! Yayyy!¬†Now, thus far, the responses I have received on declaring this little victory of mine have been more or less like “meh!”, but still, I write about it because for me the experience was far more satiating.

So here goes.

I was fascinated by Amazon Echo, and the fact that Amazon has thrown open¬†the doors to the developer community to build its (what is known as) skills. Since Echo is not widely available in this part of the world yet, plus, getting an Echo and getting it to work doesn’t sound like ‘fun’; I decided to look for Alexa (soft-) implementations for other platforms.

Continue reading Alexa + Raspberry Pi = Fun!

Think.

One of the best mails I received was from a CEO (or to put it mildly — from the head of a startup I was working for) that he had sent to all the ’employees’. It was about a seemingly small fact which I had unconsciously felt on several occasions, but never actively thought about.

It went something like this:
Between the time when you’re given a problem, say an issue to troubleshoot, or a feature to implement, and the time that you actually start implementing or troubleshooting it: there is a something called “THINKING” required. I see a lot of you nodding when I tell you about an issue, or the next set of features to implement — but then when I see the approach or the implemented feature — the “THINKING” part seems to be lacking, or in some cases, absent. ‘Thinking’ is something that cannot be done on the fly but deserves a conscious time and effort!

The actual mail tone would have been more euphemistic that I can ever get, but the point I’m trying to highlight in this post is: I see it happening on so many occasions. That too in very senior developers, managers, etc.
There is almost negligible time devoted to understanding the need or cause of a feature or issue — and there is a restlessness to pounce to a solution. I think it might be driven by the assumption that one would be sort of ‘one-up’ or the ‘apple of customers’ eyes’ or that one-true-deserving ‘pat on the back’ awardee. But such myopic approaches tend to bite back in the long run.

Not guilty!

We have been recruiting a lot lately. I try to stick to the basics, and sometimes get surprised by the responses I receive. A lot of¬†seemingly successful candidates — who can take¬†any J2EE question you throw at them — fumble when the convenience of their favourite data structures are taken away from them. For example, a simple¬†Map implementation seems to give them a tough time.

I am surprised by one of the answers I receive quite a lot when asked about¬†data structures. That, “I don’t remember — it was a long time ago” (that they¬†were ‘taught’ about it). In other words: they plead “not guilty!”. Now, even though¬†we are not recruiting for a¬†programmer¬†position, so to speak — such an answer does spark a bit of outrage within me. And then I ponder: what are we doing in our colleges? Are we getting too driven by the shiny-white things like¬†BigData, BigAnalysis and IoT and what not — that we don’t really worry much about the basics of computer science. First of all: is the essence of computer science even put forth to the students? That it’s a¬†science…that one has to develop a scientific mindset! I believe, that’s something above¬†all the big college tag/big technology/big offer/big robot that one develops.

Even after college, do they ever go back and revisit the basics they had been ‘taught’? Or at least¬†think about them?

One of the candidate we came across recently could not proceed on a small programming problem because we took away the luxury of being able to use HashMap from him. When I asked why couldn’t he create a¬†Map of his own, the response was: “I am not sure what language are Java¬†Maps written in.”

Terminal within Eclipse

Every now and then I had this urge to have a tool which would save me from switching over to Terminal from Eclipse and vice-versa. A nifty little Eclipse plugin called elt came to the rescue!

elt

elt gives me the flexibility to execute frequently used console commands — thus saving me a lot of finger twitches. ūüėČ

A good introduction is provided here.

Ubuntu 12.04 missing 'Open In Terminal'

So I gave in to the whims and fancies of Ubuntu 12.04, after spending nearly 4 months with CentOS 6.3. And then my project changed, and over this period of 4 months I realized that I have spent a significant time on getting a few basic things to work on CentOS. It wasn’t worth it.

A real irk for me was getting Eclipse (Juno) to work with any of the SVN plugins (Subversive or Subclipse) on CentOS. Even when somehow it did work — it was pretty messy. Every check-in/check-out was a pain.

Anyway, so what more opportune a moment, than doing it when the project got changed. Ubuntu, as always, was a delight. Although its tough to ignore how several features of OS X have found their way into Ubuntu. But it’s mostly good features, so, who cares!

I’m still trying to get used to the departure from the traditional Ubuntu that I was used to — my last encounter with it was maybe more than an year ago. While I loved how the interface has been revamped to allow for better usage of screen real estate — I already started missing a few features of the¬†old Ubuntu.

One of them was ‘Open In Terminal’ from context menu which was very handy. However, I took care of it today, thanks to a post on askubuntu. So, no more qualms (at least as of now).

N900

My love for my phone resurfaced, when I had to flash it today (due to a reason outside of the context of this post). Anyway, in my quest for restoring whatever I had lost — applications mostly¬† — came across ‘Humanity theme’ (of Ubuntu fame) and decided to give it a go. The result is what you see in this image. I loved it instantly!

Screenshot-20120626-224448.png by pugmarx

n900_home, a photo by pugmarx on Flickr.

¬†Yes, in this age of Ice-cream Sandwiches, Honeycombs and iOSx’s — I am still fond of my phone. (This is in spite of the fact that Nokia abandoned Maemo.)

Books!

Two books I want to get my hands on:

  1. The Pragmatic Programmer
  2. Object Oriented Software Construction

Unfortunately, both of them do the second one does not have Eastern Economy Editions for some inexplicable reason; and the non-economy version — is, well — not exorbitant, but still on the higher side. Nevertheless, I consider both of them a must-have for anyone even remotely connected to software development.