Title photo
frugal technology, simple living and guerrilla large-appliance repair
Sun, 23 Aug 2015

Bash script that mounts drive, backs up with rsync

I already use Bash scripts to run my rsync backups automatically, more to avoid mistakes in the rsync syntax (copying the wrong directory) than anything else.

I've been wanting to improve the script both to enhance portability by setting the target and destination directories with variables and to auto-mount the destination drive if it is not mounted already.

I decided to start with a Google search, and this entry from Frustrated Tech does exactly what I need:

Sat, 25 Jul 2015

Still using Linux, just not talking/reading/obsessing about it

I'm probably using more Linux than ever. My laptop runs Fedora. I'm the admin on a server running CentOS.

I will keep doing those things.

But today I unsubscribed from most of the mailing lists that have been flowing through my Gmail account over the past few years.

The Debian, Fedora, Xubuntu and Lubuntu users list? All gone. So are the development lists for Debian, Fedora and Xubuntu, and most of the others. I'm keeping a few low-volume lists. For now anyway.

I was always more of a lurker than active participant on all of those mailing lists.

Lately, and probably before that, I didn't find much of value in most of that mail. Even though the quality of the Fedora lists is a bit higher than average, I wasn't getting a whole lot out of them. I'd scan the mail, maybe read one or two posts every few days, then delete the whole lot.

At this point, I see my operating system as a tool. To get things done.

I'm not interested in Linux evangelism. If you want to use it, that's great. I still do and will do.

If not, that's cool. Do what makes you happy.

I'm still a satisfied user of Linux. It's pretty much all I've run on my laptops since maybe 2009, and I messed around a whole lot with it before that, starting in late 2006 if I remember correctly.

There's more to life.

There's my family. I sure as hell want to do better where they're concerned.

Putting together coherent sentences? I'm still very much interested.

I've threatened to write about more than Linux for years. I'd like to write about things that aren't technology. It's been in the sidebar of this particular blog for as long as I've been writing it.

I see the "tech guy" on the morning news, and I wince. Is that me? Other than the fact that I'm very obviously not on TV, I worry that it is.

There's more to life than gadgets and apps.

That being said (there's always a that being said) ...

It sounds like I'm just on the other end of the same pool, but lately programming has dominated what little free time I have. I read a whole lot about it. And occasionally do it. Maybe I'll be able to tip the scales toward more doing in the near future.

I've been playing with Go, Perl, Python and Ruby. I need to focus.

Coding is what interests me at the moment.

What I'm not playing with are Linux distributions. I don't burn ISOs of anything, don't install just to see what something's like.

New releases of obscure distributions, or even not-so-obscure ones? I'm just not into it.

The ins, outs, politics and boiling pots of the Linux world? Not interested.

Give me my working Fedora system (or maybe Debian if the hardware is willing) and let me do my work, write my code, live my life.

If that sounds melodramatic, so be it.

I reserve the right to change my mind. But for now, I'm 50 other things first and a Linux user after that.

Tue, 26 May 2015

Trying to remove LXDE from Fedora 21 breaks Xfce, and why Fedora makes for a sturdy Citrix platform

I installed the LXDE desktop environment a while back. Part of me just wanted to check it out because it has been awhile. But I also was "auditioning" it as a potential working environment in Fedora because I'm now doing a lot more of my work via Citrix Receiver in Linux instead of Windows.

As a current Xfce user, moving to LXDE isn't quite the culture shock as it would be going from, say GNOME or KDE to the LXDE environment.

Things I liked in LXDE included that it picked up on the Adiwata Dark theme I'm using in GNOME and had a lot more "darkness" to it than Xfce picks up when I choose Adiwata on that side and Adiwata Dark in GNOME. Doing the latter makes GTK3 apps show up with a dark theme, though all GTK2 apps are as white as the Xfce Adiwata theme makes them.

Things I didn't like included a lack of screen animation when clicking an application button in a panel (I never knew if I really clicked it or not) and (more crucially) no way to manage touchpad tap-to-click in a GUI.

Yeah, it came down to touchpad management. Xfce is good at it. LXDE is not.

So I stopped using LXDE, barely used GNOME 3 (too many issues with Citrix and too hard to configure the way I want/need it to be) and focused on Xfce as my go-to desktop environment.

I recently removed the desktop pager from my upper panel to keep myself from accidentally clicking into a second desktop and causing my Citrix apps to lose their connection to the server. It's barbaric. But I can accept it.

And now LXDE has been hanging around unused on my Fedora system for more than a little time.

I figured, why not remove it?

So I went into my favorite Fedora package manager, searched for LXDE and removed everything that came up.

Bad move.

There were things in that mass package removal that Xfce needs.

After that ill-fated software removal, Xfce lost its wallpaper. And its ability to pretty much work at all. Applications would launch, but they would no longer refresh on the screen. And I couldn't do much of anything.

How did I set things right?

I went into Yumex again -- yes, it did work -- and added back all of the LXDE items.

Now Xfce works once again. And I still have LXDE.

Thu, 02 Apr 2015

Printing in Linux with the HP LaserJet 1020: The 2015 edition

Printing in Linux with the HP LaserJet 1020 has been a battle since forever. It used to be easier.

Back in Fedora 19, it really did just work. Same with older versions of Debian. (Can you tell I've had this printer a long, long time? It was cheap. It is small. It still works.)

But since Fedora 20 (and into Fedora 21, and other Linux distributions, as a trip around the web will confirm), it's been hell to get this printer to work.

That's because HP cheaped out with the LaserJet 1020 and didn't put the necessary firmware on board. You have to load that firmware with every print.

Linux should be able to handle this. Hell, HP's own HPLIP utility should be able to handle it.

No and no.

The printer shows up as a USB device, but neither CUPS nor HPLIP acknowledges its existence.

Every few months or so, I try again. I re-Google and look for clues. I go back and try things again.

Today I came upon Mark911's How to install printer drivers for HP Laserjet 1020 in Ubuntu 14.04 LTS 64-bit without needing access to openprinting.org website and without using buggy hplip drivers. (That title is even longer than my titles ...)

It basically says, "Get rid of HPLIP, don't use the foo2zjs driver with your distro, and instead go to the source, compile it yourself, add the firmware and go to town.

So I did just that. I went to http://foo2zjs.rkkda.com/. First I used my favorite Fedora package manager, Yumex, to get rid of HPLIP and foo2zjs (the latter from RPM Fusion, if I'm correct).

During the process, I also had to get rid of system-config-printer-udev to get hot-plugging set up.

I downloaded the foo2zjs source from http://foo2zjs.rkkda.com/, followed the instructions for compiling it, getting the HP LaserJet 1020 firmware, configuring hotplugging and restarting the CUPS spooler.

Then I started Fedora's system-config-printer GUI (which you can start from the menu as Administration - Print Settings or at the console with system-config-printer, sent out a test page, which worked (!!!), and the proceeded to print a document out of gedit, which also worked.

The question now is, will this loveliness survive a reboot?

Later: This configuration does survive a reboot. And a suspend/resume.

SELinux trouble?: If SELinux throws an error when you plug in your USB printer, follow the utility's instructions for allowing an exception for your printer.

Wed, 01 Apr 2015

Reddit: Why do developers choose OS X over Linux?

If you're wondering why real-life developers (and I suppose primarily web developers) who happen to hang out on Reddit often choose OS X over Linux for their laptop/desktop operating system, read this lengthy Reddit thread, which Jim Lynch brought to my attention.

Especially due to the large number of comments, it provides a very interesting snapshot of why a given developer chooses one platform or another.

Since you can now embed Reddit comments in your HTML, I'll provide a few samples:

There are 500+ more comments over at Reddit, and the thread is well worth reading.

My $.02

  • I neither need nor can afford the Adobe Creative Suite. I use GIMP, Inkscape, Gthumb, Irfanview under Wine, OpenShot (and I hope to pick up KDEnlive).
  • If I needed Microsoft Office, I could run it under Wine or in a VM. (Now I do most things in Google Docs/Spreadsheets or LibreOffice, if not in a local text editor)
  • I am a Linux hobbyist, and meeting the little challenges required to set up a computer with Linux is something that I enjoy. Yes, I'm probably a glutton for punishment. And things are never as smooth as billed in the "other" OSes (Windows and OS X).
  • There will always be Linux distributions that will work on my hardware and have timely security and bug-fix support. Windows is OK at this, but Apple sucks hard by orphaning hardware with no regrets (on their part, anyway).
  • I love coherent, systemwide package management and vast software repositories.

But

  • If my work required an Adobe-type proprietary application or three, I'd have to run them on OS X or Windows. I would do that if I had to.
  • Even though, as I mention above, I'm a self-proclaimed Linux hobbyist, going months and months on hardware without checking off all of my "it works" boxes can be disheartening.

That said, my laptop price point is ~ , and that's well below anything Apple offers.

Wed, 14 Jan 2015

Answers from a Fedora Xfce developer

Fedora developer (and Red Hat employee) Kevin Fenzi answers questions that users have about the project's Xfce spin in a new blog post.

As a longtime user of Fedora's Xfce spin, naturally I'm interested.

He covers:

  • The reasons why Xfce 4.11 is not in Fedora Rawhide (because there is no 4.12 release imminent, and 4.11 in "stable" Fedora would be bad, but there is a COPR repo for those who want it)

  • Rumors that Xfce, the project, is dead (It's not -- fixes and small changes continue to be committed; there's just no timetable for a 4.12 release)

  • The Xfce spin leaving its 700MB CD size behind and now aiming at 1 GB USB flash drive size in Fedora 22

  • Xfce continuing to be available for RHEL/CentOS users in EPEL

  • Ways of making Xfce work better on HIDPI displays (but don't expect miracles until Xfce adopts gtk3)

Read the original post. It's well worth it.

I've been running the Fedora Xfce Spin since F18, and I think it's one of the best-kept secrets in the Xfce-running distro world. It comes well-configured out of the box, looks great, is as cutting-edge as you'd want and really does just work most of the time.

Fri, 19 Dec 2014

I'm running Fedora 21 with Wayland, and so far (almost) everything is working just fine

After saying I wouldn't jump into a Fedora 21 upgrade, I rather quickly had a change of heart and mind, ran a Fedup upgrade and am now running Fedora 21 on my go-to HP Pavilion g6 laptop.

With Wayland.

Yep, one of the new features of the GNOME 3.14-running Fedora 21 is a preview of the next-generation, post-X Window Wayland display manager, and you can choose "GNOME with Wayland" in the login/session manager.

I'm running Wayland right now. I've heard the caveat many times: Not all applications will work in Wayland. But so far, every application I've tried (Firefox, Gedit, Transmission, FileZilla, VLC, Files/Nautilus, Liferea, Yumex, Google Chrome, Geany, even apps in Wine) has run in Wayland with no trouble.

I've been running Fedora 21 for a few days now, spending most of my time in the non-Wayland world of Xfce and GNOME with X, and the system is as solid as ever. And by that I mean pretty damn solid.

The only glitch I've had with Wayland has been in suspend/resume, which is pretty touchy anyway with my hardware. (I've probably written 50 posts about it since I got this laptop.) When running Wayland, the laptop will suspend and then resume, but I'm seemingly "detached" from my session and have to log in again. At this point I'm logged in twice. This doesn't happen in X. If this is the only thing I can find wrong with Wayland, I'll still consider it pretty remarkable.

Just from a "look and feel" perspective, GNOME 3.14 is working better and faster than version 3.10 did in Fedora 20. I'm not saying I'm going to throw Xfce over for it, but the environment is more usable than ever. I moved to the Adiwata Dark theme while still in F20, and everything looks that much better in F21.

As I've said since I began running Fedora 18 on this laptop and upgrading via Fedup to each subsequent release, a system as forward-looking as Fedora shouldn't be anywhere near as stable as it is. It's a tribute to the developers for Fedora and the many upstream projects that go into the distribution.

Today marks only nine days since Fedora 21 went stable, and my system is running like a well-maintained watch.

So if you think of yourself as the adventurous type, someone who likes everything to be pretty new all the time but doesn't really want to deal with a lot of breakage and is curious about Wayland in the real world, give Fedora 21 a try.

Later: You know what got fixed in Fedora 21 that was broken in F20? Mounting of Apple iOS 8 devices.

Fri, 12 Dec 2014

Fedora 20 confession: Now that F21 is out, I'm enjoying the quiet

So I haven't upgraded my daily-drive Fedora 20 system to Fedora 21, which was released two short days ago.

From what I can see, the RPM Fusion repositories are ready for F21. Google Chrome might break, but a quick removal and reinstall should fix that.

In F21, there will be many changes in the GNOME desktop environment and applications.

But for my go-to desktop environment, Xfce, it's going to be pretty much the same. (Yes, Xfce is moving glacially slow, and I've heard talk of people turning to the GNOME 2-inspired Mate desktop because it's under heavy development.)

My web browsers (Firefox and Chrome) won't fall behind. I get the latest versions from Fedora and Google, respectively.

I'm dabbling in Ruby, and F20 has version 2.0. F21 has 2.1, but at the level I'm at, it doesn't matter.

And now that all the heat is on F21, it's been relatively quiet, update-wise for F20. It's a bit closer to running Debian Stable. After awhile you get a few security patches here and there, but updates are quiet and quick.

Even an old (but still supported) Fedora release gets more updates than a current Debian Stable, but for the moment, I'm enjoying the ritual of staring Yumex and seeing either only a few or, better yet, no updates waiting to be installed.

Sure I'll move to F21. It could be tomorrow (probably not) or next month (you're getting warm). But what's the hurry?

Wed, 03 Dec 2014

So I did a Fedora 21 install, and the Anaconda installer was efficient and super quick

I needed to do a bare-metal install of Fedora 21 today, and I used the beta image for the live Xfce Spin.

I didn’t do anything special. The whole disk was devoted to Fedora. I encrypted everything.

It was probably the quickest Linux install I’ve ever done — even quicker than OpenBSD’s excellent text-based installer, where if you go with the defaults you have a working system within minutes.

Sure Ananconda isn’t “linear” like other installers, but once you get used to its “hub and spoke” logic, you can bring up a Fedora system very, very quickly.

As much as I love Debian, whenever I try to do anything complicated with disk partitioning, I run into trouble. Ubuntu’s Ubiquity installer is pretty good, too. But considering the bad press that Fedora/RHEL’s Anaconda installer has gotten over the past few years, once you get to know it, you can do installs very quickly and efficiently.

Thu, 27 Nov 2014

The secret to successful suspend/resume in Linux on the HP Pavilion g6-2210us

After a year and half, I've finally cracked suspend/resume in Linux on the HP Pavilion g6-2210us laptop (AMD A4-4300M APU with AMD Radeon HD 7420G graphics) with the open-source Radeon driver.

I've been able to successfully suspend/resume for some time on this laptop with the closed-source AMD Catalyst driver, but two things have prompted me to give that driver up for the open Radeon driver:

1) AMD Catalyst hasn't been packaged for Fedora since Fedora 19, and we're about to see Fedora 21 released with no indication that things will change. There are at least a couple of workarounds that will get Catalyst/fglrx on your Fedora 20 system, both of which I've written about at length, but I'm tired of doing them. While the Catalyst/fglrx experience is somewhat smoother on distributions that are serious about packaging the driver (Debian and Ubuntu come to mind), breakage is inevitable on fast-moving distros like Fedora that get new Linux kernels all the time.

2) While AMD Catalyst allows the laptop to run cooler at idle (I'm pretty sure it runs at a similar temperature under load), the quality of video -- actual videos in applications like VLC, that is -- is better with the latest Radeon driver than with Catalyst. Briefly, when I'm watching something and the image is "moving," it breaks up horizontally in Catalyst, not at all in Radeon.

But suspend/resume trumps all. Having it with Catalyst kept me ... running Catalyst.

Now that I've cracked the code for successful suspend/resume without Catalyst, the infrequently updated, not-packaged-for-Fedora, closed-source driver is fading in my virtual rear-view mirror.

So how do you get suspend/resume working on this particular HP Pavilion g6 (or similarly equipped) laptop?

There are two changes you need to make in GRUB.

Read the rest of this post