Sunday, July 22, 2012

Ebooks vs paper books

I was reading ebooks long before they were popular and long before there were any ebook readers on the market. My first reader was Sony Clie with various reading applications. My favorite app was Plucker. Reading ebooks is much more convenient for following reasons:
  • You can read anywhere, given that your reader is compact. Bored standing in line at the store? Pull out your device and start reading.
  • You can read just a few pages at the time when you got a spare moment. The reader remembers where you are and ready as soon as you power it on.
  • You never run out of books to read. Even the old Clie with 16MB of memory could easy hold 10s of books.
  • It is easy to make notes with the right application or even without it if you get a little creative.
  • You don't need to have light while reading in bed if your device has a backlight.
There are of course some downsides:
  • You can't read on the plane during take off and landing.
  • Your device battery can run out if you forget to charge it.
Of course Clie is no longer practical and there are much better devices available. I currently read on iPod touch 2G which I received as a gift. iDevices have very poor ebook reader applications especially after demise of Stanza. Notable exception is MegaReader but it is still missing a lot of features and the font rendering is not accurate. If you have apple device this is the one I would recommend. iBooks is slow and huge. Most of the main stream readers are not configurable to be pleasant to use on the small screen.
Android platform has much better selection. All of the applications that I have tried were very good. FBreader was my favorite but they all very good. My next device is going to be Android powered, most likely one of the Samsung media players or possibly 7" tablet. I have tried 8" Visio but it is too heavy and too big to be useful on the go.
If you are avid reader and not sure if you want to read ebooks, give it a try and you will not regret it.
For managing your ebooks and converting them for your device Calibre is a perfect application. It is actively developed and getting better every day.

Monday, July 9, 2012

Checking root filesystem on ArchLinux

My shiny new ArchLinux on the Pogoplug was complaining about root filesystem not being clean. I tried usual approach of placing /forcefsck file in the root folder and rebooting. Although the file was removed at the next boot the filesystem check still complained.

I went to the IRC to the #arch-linux-arm channel which is recommended on the website, but no one appears to know how to do this on the running system. The only recommendation that I got, was to take out the drive and put it in to another Linux box. Well, this being a USB flash drive makes it possible to do so. But imagine an internal disk and this quickly becomes less than practical solution.

So I went to the "Internets" and did a search. As expected someone already asked this question and got a multitude of answers which helped me to put together a procedure. So here it goes:
  • Execute following command:
    fuser -v -m /
    This will give you a list of all processes having files open on the filesystem. Look for the processes that have F or f flags set. For example:
    root        182 .rce. dhcpcd
    root        197 frce. crond
    root        219 .rce. sshd
    ntp         226 Frce. ntpd
    So it looks like the crond and the ntpd have files open.
  • Shutdown these processes by using following command:
    rc.d stop ntpd
    Shutdown all of the processes that have files open on the filesystem.
  • Now you can remount filesystem using following command:
    mount -r -o remount  / 
    If you correctly shutdown all of the processes remount should complete without any error.
  • At this point you should be able to do a filesystem check:
    e2fsck /dev/sda1 or e2fsck -y /dev/sda1 
I hope that you found this post helpful and it saved you some time.

Saturday, July 7, 2012

Pogoplug after a few days

I had this device for several days and so far it works well. I replaced the original Pogoplug software with ArchLinuxArm. The box is much snappier than my original Cobalt Qube 2 with NetBSD 5.2. Of course it is much faster machine and with double the memory. The size of the device is also small and the case while funky looking is OK. I only wish it would open more easily so I could take a look inside.

ArchLinux appears to be well made distribution with the package manager that tracks dependencies. Startup scripts are easy to understand, unlike the latest Ubuntu. I am not sure why they keep changing startup scripts every year. I installed Python and Samba to run MyMedia server and to backup my data from the Windows PC. MyMedia server runs very well on this hardware. The menus come up fast and the videos and images served quickly enough. Over all it is very good box for the purpose.

I am getting another enclosure and will install Linux on the hard drive instead of the USB stick it is on now. I want to try to compile some software and to see how well this box would work for unix development. It probably would not be a speed daemon but it could work.

At this point I would recommend this device to anyone capable of installing Linux himself.

Wednesday, July 4, 2012

Linux on Pogoplug

I was tempted by the Pogoplug Family deal and got myself a Pogoplug  classic for $29.95. They advertise it as a "free device" with Pogoplug Family but in reality you are buying the device for the above sum. Don't forget to cancel the service after receiving the device. Otherwise it would be more expensive than actually buying the same device outright.
After getting the device I evaluated it for about a day. I got the grey version of the Pogoplug Classic with Marvel Chip, 256MB of ram and 128MB of flash. The device itself is snappy and works reasonably well. It recognized my USB hard drive and went to work on it, apparently indexing the content. I measured transfer speed and using my old router with 100Mbit Ethernet, the transfer speed is around 9MB/s which is not bad. The device is silent and consumes very little power.
The companion software on the other hand is terrible. It is very much useless for backup as one can not control what is being backed up. You can only specify the top directory and everything under that directory is backed up. I thought about using the drive feature to backup with Microsoft Sync Toy but somehow it makes for a very slow backups. This device appears to be made for a completely computer illiterate person who never used any NAS devices. It also requires connection to the Pogoplug servers and I would imagine opens files on your "cloud" to snooping by the company. Over all I found the "Pogoplug Cloud" concept is sorely lacking in the implementation department. It does not hold a candle to the simplicity of Dropbox or Google Drive.

I actually got this device to replace my very old Cobalt Qube microserver which is showing its age. In that role Pogoplug Classic performs really well.
Most people appear to have good luck with the Arch Linux Arm and that is what I decided to try. I used a Centon 4GB flash drive as my root drive and WD drive in USB enclosure as my data drive. Installation of Arch Linux Arm is very simple and described on the web page. The Pogoplug Classic model number is POGO-E02 which is one of the supported devices.
The installation went smoothly and the box appeared operational but it would not acquire  IP address. Due to the bug in the Ethernet driver and my old router the device kept disconnecting and reconnecting to the network. After some search I found the solution. If your Pogoplug appears to boot but fails to acquire IP address add following line to the dhcpcd.conf file : nolink. Linux, samba and python occupy around 740MB on the flash drive. I did not install git but instead use my custom copy of the MyMedia server.

Now my Pogoplug is booting Linux and can act as NAS device with up to 4 USB drives and can run MyMedia server for Roku. It is much snappier than my old MIPS box but obviously not as fast as my desktop. It is worth $30 in my opinion if you can install your own Linux on the device. Similar devices would easy cost north of $50.

If I decide later to change my mind and use the "Pogoplug Cloud", reverting back is as simple as removing the USB flash drive and rebooting the device. The original system is preserved in the flash along with the original uBoot bootloader.