Wednesday, April 28, 2021

Chromebook Part Too: The LInux Apps

After my recent lengthy post on setting up Linux on my Chromebook, I thought it might be good to take a look at what Linux apps I have installed on my Chromebook and why. While I initially found the ready availability of Android apps on my new Chromebook to be welcome advancement and a huge step in the right direction, most are too limited in scope and functionality for my needs, as are most Web apps. For that reason, the availability of familiar Linux software titles makes my Chromebook seem much more usable. All of these titles are free and most are also available for Windows and Mac OS.

Gnome Software Center--Consider this the missing puzzle piece to make the experience of setting up Linux apps on your Chromebook much less painful. You have to install it from the Terminal's command line but once it's in place, most other titles you would want are available with point-n-click convenience, much like Google's Play Store or the Apple App Store. It should be noted that some titles in the store are outdated versions and depending upon your needs, you may be better off enduring the Terminal to install the latest version. The folks at Chrome OS would do well to include a dedicated software center with Crostini once the Linux experience graduates from Beta.

LibreOffice--This is the main reason I opened up a can of Linux on my Chromebook in the first place. The Web and Android versions of MS Office and their G-Suite (Google) equivalents are more than a little lacking for my tastes. I have used LibreOffice and its predecessor, OpenOffice, for about 20 years and find it contains all I need in an office productivity suite to do. LibreOffice comes preinstalled on most Linux distributions and is also available for Mac OS and Windows. It should be noted that the Gnome Software Center offers an obsolete version of LibreOffice (6.1.x), which reached its end-of-life two years ago (May 2019) so you'll definitely be better off downloading this one from the command line. Chrome Unboxed has an excellent how-to article to walk you through the process but the install scripts point to version 6.4.x so you'll need to modify them to point to the present version (7.1.2 as of this writing).

Thunderbird--This email client has long been my go-to outside of Mac OS, where I prefer Apple Mail. Having it in my Linux container means I can easily open attached files in LibreOffice or follow a Web Link in Firefox. Chrome cannot communicate with apps in the Linux container in the same way. Curiously, Thunderbird is not present in the Gnome Software Center's repository so it must be acquired via the Terminal with the command 'sudo apt install thunderbird'.

Firefox ESR--It may seem odd to want an alternative Web browser when Google Chrome is built into Chrome OS but as with Thunderbird, it's handy to have a Web browser residing inside the Linux container where it can interact with other Linux apps in a way that Chrome cannot. The 'ESR' designation stands for 'Extended Support Release'. Available from the Gnome Software Center, it is a slightly older but more stable version of the browser. It may not have all the latest features but you are spared having to restart every so often to install the latest version. 

GIMP (Gnu Image Manipulation Program)--It functions like Photoshop without the annual subscription and also has some limited page layout capabilities. There are also versions available for Windows and Mac OS as well. This one is easy to install either from the Gnome Software Center or from the Terminal (sudo apt install gimp)

Scribus--A page layout application similar to MS Publisher or Adobe InDesign, it is not quite as user friendly as its commercial counterparts but it's not bad and the price is right. The version included in Gnome Software Center is the latest stable release and finally includes an assortment of templates for common projects like Fliers, brochures, booklets and business cards but it lacks one for a CD jewel case insert. It's not hard to create one, though. Like GIMP, there are also versions available for Windows and Mac OS as well. The easiest way to install this one is from the Gnome Software Center

AisleRiot Solitaire and Gnu Mahjongg--While these don't exactly qualify as must-have titles, they're fun, simple games for when you feel like wasting a little time on the computer. AisleRiot includes a multitude of different solitaire card games and Mahjongg (I have no idea why it's misspelled with two g's) is a simple puzzle game in which the object is to clear the board by clicking matching tiles. Both are easily installed from the Gnome Software Center.

The above titles adequately flesh out my software needs on the Chromebook and mirror most of the titles I have installed on my ancient Linux laptop. Unlike Android apps and Web apps, which have individual icons in the Chrome OS Launcher, icons for Linux apps are housed together under a single 'Linux Apps' icon, appears to open a folder containing icons for each app. For a more seamless experience, you can 'pin' the icons of your most frequently used apps to the Shelf at the bottom of your screen, much like the Windows System Tray or the Dock in Mac OS. 

I realize some hard-core Chromebook fans may think installing Linux apps somehow runs counter to the whole idea of maximized simplicity, which is central to the Chrome OS ethos but it does provide much-needed functionality that Web- and Android apps cannot quite match, at least for this old-school user.

UPDATE (5/6/21)--Late last week, my Linux environment crashed as I was using it and none of the Linux apps would launch. I was very busy, so I just set the Chromebook aside and used my MacBook Pro for 'mission-critical' work until I had the time, energy and inclination to resurrect it. The only solution I could come up with was to delete the Linux environment and start over. Having been through this before, I decided I needed a shortcut so as I installed each component, I also copied the installation scripts to a Google Docs file (see appendix below) so I could readily access it in the future. Just knowing what to do made the process simpler and I had all of my Linux apps restored in about an hour, including creating the 'cheat sheet' on Google Docs. I then took another hour or two on the next evening to configure and personalize Firefox and Thunderbird. I hope I don't have to go through this process again anytime soon but at least I'm becoming adept at using the Terminal.

Looking back on what happened, the crash occurred when Chrome OS attempted to install a minor system update. I'm thinking that it might have included an update to the Linux environment that couldn't be properly installed since it was in use at the time. As evidence that the update affected the Linux environment, my Linux apps' icons are now out on the Launcher instead of under the "Linux Apps" icon, which now only contains icons for library files I wouldn't need to launch directly. Of course, the latest experience also points out that the Linux environment still has a way to go before it is ready for 'prime time'.  Nonetheless, I still believe the addition of Linux apps is an important growth path for Chrome OS as it continues to increase in mainstream acceptance as evidenced by its tripling of market share in the past year to surpass my beloved Mac OS as the number two computer platform behind Windows. Ironically, this trend also sets Chrome OS on the path to become a dominant player in the desktop Linux market.


APPENDIX

Crostini Rebuild Scripts

The scripts below, implemented one at a time  in the sequence below, will quickly set up basic Linux applications under Crostini on a Chromebook with Linux Development Environment implemented.

Update System

sudo apt update

sudo apt upgrade

Install CUPS (printer support)

sudo apt install cups

sudo apt install system-config-printer

xhost +

sudo system-config-printer

Install Thunderbird1

sudo apt install thunderbird

Install Latest LibreOffice2

sudo apt remove libreoffice (if an older LO is already Installed, then download latest LibreOffice from libreoffice.org)

sudo tar -xf LibreOffice_7.1.2_Linux_x86-64_deb.tar.gz
(update version number, if necessary)
cd LibreOffice_7.1.2.2_Linux_x86-64_deb
cd DEBS
sudo dpkg -i *.deb

Install Gnome Software Center (easy access to additional Linux apps)
sudo apt-get install gnome-software gnome-packagekit
sudo apt-get update
sudo apt-get dist-upgrade

1Thunderbird is not included in the Gnome Software Center.
2The version of LibreOffice included in the Gnome Software Center is grossly outdated.


Thursday, April 15, 2021

The Future of Chrome is Linux

 For some odd reason, the concept of a Chromebook has always intrigued me. It's sort of the ultimate expression of the power of a modern Web browser that it could essentially function as an operating system. The fact that Chrome OS has not only survived but thrived and grown in the decade since its introduction is proof that this concept is viable and that it is filling an important niche. Of course, it hasn't been without its growing pains.

If you look at online reviews of almost any Chromebook model, you will inevitably find negative reviews by people who purchased one and then were disappointed when they couldn't install Windows apps like MS Office on them. While those individuals arguably had unrealistic expectations because they did not fully understand what they were buying, the truth is they do function as advertised and are priced accordingly.

When I first acquired an outdated Samsung Chromebook a few years ago just to see what all the fuss was about, I at once marveled at its simplicity and chafed against its limitations. When I received a notification about a year ago that it had reached the end of its allotted period of updates--and as far as Google and Samsung were concerned, the end of its useful life--I figured my Chromebook journey was effectively at an end. But then, in a rather sizable impulse purchase, at least for me, I recently bought an HP Chromebook from Costco and was amazed to find how much had changed. 

For starters, the Chrome Web browser was now supplemented with Android apps, easily installed via the included Google Play store. I could have access to other apps in addition to Google Chrome, albeit stripped down versions, designed primarily for phones and tablets. Some are more optimized for laptop use than others, but it's a step in the right direction.

The greatest revelation came about a week after I acquired my Chromebook, when I came across an article the Web, describing how to install Linux apps on a Chromebook. Running Linux apps on a Chromebook is a logical extension of functionality, given that Chrome OS, like Android, is built upon the Linux kernel. I thought this was a brilliant idea as it would allow me to run LibreOffice on my Chromebook, which would be a huge step toward remedying what I considered to be one of Chromebooks' major limitations in functionality.

The Road to Linux.

Linux functionality turned out to be a bit of a hidden feature, clearly marked as a 'beta' under developer tools, but I've dabbled in Linux for more than a decade and had a passing familiarity with its command line terminal, which can be fundamental to installing and administering most things Linux. I also knew that once I had things set up and running, the terminal would not be part of my daily workflow on the Chromebook. The Linux apps would run pretty much just like one would expect them to in Windows or Mac OS. The pain, in other words, would be temporary.

With that, I decided to activate the Linux developer environment and install a modest collection of Linux apps--LibreOffice, Firefox, Thunderbird, Gimp and AisleRiot Solitaire. Activation was the easy part. The more challenging part was installing applications from the command line and configuring my printers. Fortunately, I had found a Website, chromeunboxed.com, which included a wealth of tutorials on how to do exactly what I needed to accomplish. In most cases, the tutorials included the exact lines of script I needed to put into the terminal, which I could do via copy and paste, which is almost as easy as point-and-click. Of course, sometimes I had to modify a script because the article in which it appeared was old enough that the current version number of the software had changed. 

Two lessons I had to learn the hard way were to start off by updating and upgrading (two separate functions) my Linux to the newest versions of the software I wanted to install as installing older versions can cause what is known in the Linux universe as dependency errors as an application being installed looks for newer versions of libraries than exist on the computer. I also found that it works better to install printer support (CUPS) prior to installing applications.

It only took me three tries over the course of five days to get everything up and running like it should. The first two tries ended in frustration with me invoking the 'nuclear' option of completely deleting my Linux environment and starting over. But now that it is all up and working, I am enjoying this Chromebook much more than my earlier one. I don't see it replacing my MacBook Pro, but it is certainly a viable alternative for many routine tasks. I actually set myself a challenge a few days ago to use the Chromebook exclusively for a day making note of the times when I felt I needed my MacBook Pro in order to complete a particular task. Thankfully, those moments were surprisingly few.

Installation options

While I chose to run my Linux apps from within Chrome OS, using a container environment called Crostini, there are other options that involve installing a complete Linux desktop operating system such as Ubuntu. There is even one designed especially for Chromebook hardware called Gallium.

One can choose to install and run Linux as a virtual machine, which allows both Linux and Chrome OS to run simultaneously and gives the user the option to toggle between them with a set of keystrokes. This puts greater demands on system resources but arguably achieves greater convenience.

Alternately, one can set up a dual-boot configuration where one chooses which operating system to use when starting up the computer. This is less resource intensive but is also less convenient in that switching from one operating system to the other involves restarting the computer.

The final option (figuratively as well as literally) is to completely erase Chrome OS and replace it with a Linux distribution. This is the most destructive option in that it removes the possibility of easily moving between Chrome OS and Linux but it does give Linux 100 percent of available system resources; thus it might be a viable alternative for extending the useful life of older hardware that has passed its allotted period for receiving Chrome OS updates. 

Hope for the Future

While the availability of Linux apps on a Chromebook is a major leap forward, its implementation is still in its infancy and definitely not ready for prime time for most users, as indicated by its 'beta' status. In the future, I would like to see Crostini or some successor active by default with something similar to the Google Play store installed to would allow users to easily install software in a more familiar manner with a few clicks of a mouse or track pad instead of typing commands in a terminal window. 

Most major desktop Linux distributions have such software libraries now and there are even a couple that purport to work with Crostini. As an experiment, I installed the KDE Discover library and was more than a little disappointed. Apps installed from it were often outdated versions and for the most part were not installed properly. Some apps would only launch from within Discover and others would not launch at all. 

The technology exists for making the installation and management of Linux apps on a Chromebook just as easy as it is for Android apps from the Play store. It's just up to Google to put the pieces together for a relatively seamless user experience, which should also include making CUPS an active component of Crostini by default. 

Final Thoughts

 Chrome OS, like Mac OS, was conceived largely as a closed system with Google controlling most aspects of the user experience but it has matured to the point that adding access to third party Linux apps is the logical direction for it to grow as not everyone is going to be content with a Web browser as a sole application. 

There is already speculation that Google is in the process of separating the Chrome browser from Chrome OS so that the browser would pick up updates on the same schedule as the Chrome browser does in other operating systems. Doing so would also allow Chrome OS to evolve into one of the most user friendly Desktop Linux distributions by virtue of tighter integration with purpose-built Chromebook and Chromebox hardware. 

All in all, I would say the future is filled with possibilities...

 

UPDATE: 26 April 2021:

The need for an easy-to-use Linux software store for Chromebooks has continued to tickle at my consciousness since I published the above post. Last night, I thought to give the KDE Plasma-Discover store a second look but then came across the GNOME Software Center and decided to give it a try instead. I am happy to report that instead of the previous days-long debacle, installing this software store took only about 20 minutes and after restarting of my Chromebook a couple of times, everything is copacetic--with me and with the computer. And just because I could, I installed a couple more Linux apps, including Scribus, a page layout application similar to Adobe InDesign or M$ Publisher and a Mahjong solitaire game, just to make sure things were working okay. Unlike Discover, everything installed flawlessly and with just a few mouse clicks. 

One annoyance is that both installers pull from the same Debian repositories so some of the apps I looked at were the same outdated versions. LibreOffice 6.1? Seriously? According to the LibreOffice Release Plan Web page, that version reached 'End of Life' on 29 May 2019! The newest version on the LibreOffice Web site is 7.1, which I had already installed from the command line. It wasn't the easiest task ever but it was definitely a worthwhile exercise.

An application I found inexplicably absent from the list was the Thunderbird email client. Fortunately, that one was easy to grab via the command line: Type in 'sudo apt install thunderbird' and follow the prompts.

This entire exercise with Linux apps on a Chromebook points out one inescapable fact. If Google wants the Linux apps to be a viable part of the Chromebook experience, Crostini absolutely must include a dedicated point-n-click software center by the time it graduates from Beta. The average user will not be as obsessed as I was and will follow the paths of least resistance to settle for Android apps at the first sign of difficulty.

I have read suggestions that such a function should be integrated with the existing Google Web Store but whether that happens or Google adopts or even re-brands a third-party store such as the Gnome Software Center, it needs to be present by default and pointed to repository of up-to-date apps. Anything less would be less than viable, in my opinion. Not that that counts for anything at Google, but still...