technology

Linux – tinyMediaManager on Kubuntu 18.04

I run a network attached storage (NAS) device at home to manage all my media (e.g., music, videos, photos, etc.). I have used various programs over the years to manage the naming and organizing of my music files but just recently discovered tinyMediaManager for managing video files. Since it’s written in Java, it works on any OS, including Linux.

Given my large collection of movies, I have been looking for software that would properly name and organize all of them. tinyMediaManager seemed like the perfect solution, but I immediately hit a snag once I tried to get it running on Kubuntu 18.04 (my current distribution of choice). I couldn’t get the GUI to launch. It took some doing, but I eventually figured out how to make this work on Kubuntu 18.04.

First, download the tar.gz file here. (Note: I couldn’t download it using Chrome, as the tinyMediaManager site only lets you download it using a browser that allows Java and, as of Chrome 45, Chrome doesn’t. I used Firefox, which worked fine.).

Untar that file and move the resulting folder wherever you want it to reside (obviously, somewhere you have access to it, but, otherwise, it doesn’t matter).

Now, the tricky part. According to the tinyMediaManager website, all you need to do to launch the program is use a terminal to navigate to the folder you just untarred and use the command:

cd /home/ryan/tinyMediaManager
./tinyMediaManager.sh

When I tried this, it didn’t work. It seemed like it was trying to do something, but then the GUI wouldn’t open and… nothing. Disappointed, I started looking for answers. I eventually found the “launcher.log” file in the tinyMediaManager folder and that gave me the clue I needed to solve the problem. As it was trying to launch, it was running into a problem with a specific thread and library in the version of Java I had installed by default. Here was the error:

Exception in thread "Getdown" java.awt.AWTError: Assistive Technology not found:

It turns out, tinyMediaManager has not been updated to work with newer versions of Java. So, here’s what you can do.

First, install the Open Java Development Kit version 8 which is the latest version it works with:

sudo apt-get install openjdk-8-jdk

It turns out, you can have multiple openjdk’s installed at the same time. I was running as my default openjdk 11. Now, in order to switch to the openjdk 8 environment, type in the following command at the terminal:

sudo update-alternatives --config java

You’ll then be given the chance to choose which openjdk you want to use, like in this screenshot:

Choose openjdk 8 as your default. Then try running tinyMediaManager again. If the software gods are smiling upon you, the GUI will launch:

technology

LibreOffice Calc – Comparing and Aligning Two Lists Using VLOOKUP

One of the tasks I have to do regularly as part of my job is to compare two lists to see which items are missing on one list but not the other. I have been doing this by hand but figured there had to be a way to do this in Excel. I finally figured it out but don’t want to forget how to do it. So, I’m documenting it here so I can draw on this whenever I need to do it again.

Here’s the scenario. I have a list of “items” but every month or so I receive an updated list of “items” from someone else. During that month, some of the items on my list have been taken off and some have been added to it. Likewise, the same has happened to the other list that this other person sends me (I’m being really vague here because I work at a university and there are laws that govern academic records).

My list and the other list have to be kept synchronized but we have two separate databases that are used for this because… (argh, yeah). Anyway, what that means is that I have to compare the two lists and quickly find the items on one list but not the other and vice versa. Here’s how to do it quickly in LibreOffice Calc.

Here are two lists:

(NOTE: You can actually do this in two separate Calc sheets or within the same one.)

LIST 1 is in Column A and List 2 is in Column C.

In Column B I am going to create a function that allows me to search all of Column C to see which of the items in LIST 1 show up in LIST 2. Click in Row 2 of Column B then click on the Function Wizard (or start typing):

In the Function Wizard dialogue box, you’ll see this:

Search for VLOOKUP then double-click it and you’ll see this:

You now need to build the function. This is where I got confused, so I’m going to try to explain this carefully.

The first box is the “Search criterion.” Basically, this is what you want to find. In our example, let’s say that we want to see which items in List 1 are in List 2 (Hint: It’s apples and grapes.). So, we are going to put in the Search criterion that we want the software to search the items in column A or LIST 1. We do this by simply selecting cell A2 (you can do this by typing it in or by selecting it by clicking the button to the right of the box and then selecting A2 like I did below):

Next is the “Array” box. This is the content through which you want the software to search to find the items in LIST 1. Again, you can type this in or select it using the button to the right. However, there is an important change that you need to make here. If you select the array with your mouse and leave it as is, the values will change as you drag this formula down in Column B as it will assume you want to adjust the array as well. Since we don’t want to adjust the array but rather want to search through the same items in LIST 2, we need to put dollar signs before the letters and numbers in the Array which will lock the boundaries of the array into place so they don’t change when we copy the formula to other cells, as shown below:

The next part is the part that threw me off for a long time in figuring this out. The “Index” is the column in the Array you want to compare to the Search Criterion. In this case, all you need to do is specify “1” since there is only one column. But, presumably, you could have an array made up of multiple columns and want to choose just the 4th column (so you would enter 4 in the Index). Here’s how this looks:

Finally, the last box that is part of our function is the “Sort order” box. This tells the software whether the lists are ordered alphabetically or not. If they are not, enter zero (“0”). If they are, enter “1.” If you leave this blank, LibreOffice Calc thinks the lists are ordered. So, make sure you fill this out.

Once you’ve got that all entered, your formula should look like what I have above. Hit “OK” and it will search the Array C2:C7 for “bananas.” If it finds it, it will return “bananas.” If it doesn’t, it will return “#N/A” as shown below:

You can then, of course, drag this formula down. When it finds the item from LIST 1 in LIST 2 it returns that item. When it doesn’t, you get #N/A.

And there you have it. A LibreOffice Calc function for searching a list for a target and returning an indicator.

(NOTE: What I typically do after I have run this function is sort by the column where the function is located so I know which items are missing from LIST 1 and which are missing from LIST 2.)

technology

Linux – Adding and Organizing Music with Clementine

In the almost 15 years I’ve been using Linux I have gone through a number of music playing apps. From Amarok to Banshee to Rhythmbox and at least a few more. My favorite at the moment is Clementine. I’ve grown to really like the basic interface of Clementine and it does a good job with pretty much everything I need.

The one issue I had with it over the years is that I didn’t think I could use it to add music to my music library and organize it at the same time. Turns out, I was wrong. Clementine does have the ability to add songs to your music library and organize them (into folders and renaming the files). It’s just not the most intuitive process. So, I figured I’d outline the process below.

First, you obviously need to install Clementine.

You’ll then need to set your music directory in Clementine which is where you want to store your music files. Go to Tools -> Preferences.

In the window that opens, click on “Music Library” and then add the folder where you want to store your music:

Next, to add music to your folder, go to the left side of Clementine and look for where it says “Files”:

Click on that and you’ll be able to browse to any folder on your computer.

I usually put the music I want to add to my collection on my desktop, so I navigate there, find the folder, and then right-click on it. In the context menu that comes up, click on “Copy to library.”

In the window that comes up next, you’ll have the option to change how the files are organized, both at the folder level and with the renaming of files.

You also have the option of changing the destination (which doesn’t make much sense since you want the music in your primary music folder). You also have a bunch of other options, like deleting the files after they are copied, changing the naming conventions, etc. Once you’re ready, hit “OK” and your music files will be copied into your music library named exactly how you want them to be named and organized how you want them to be organized.

technology

Linux – Fixing the Epson (V33 Perfection) Scanner Issue in Kubuntu 18.04

As of Kubuntu 17.10, my Epson V33 Perfection scanner stopped working with Linux. I bought this scanner specifically because it did work with Linux. That it stopped working was a serious disappointment as I have been using the same scanner for years and regularly need it for a variety of things.

I tried installing older versions of the software (I’ve kept the downloads from Epson for years) but that didn’t work. I tried it on a different computer with the same OS and that didn’t work. I tried a lot of troubleshooting and came up empty. After hours of trying various solutions, I gave up (that was a few months ago).

However, when my CPU died on my desktop computer forcing me to reformat it again about a month after I had previously tried, I figured it was time to try to solve this again. This time, however, I quickly came across the answer online (see here). It turns out, this is a bug in the latest version of the scanning software that ships with Linux, which confirmed that it wasn’t a problem with my scanner or with Epson’s software. Here’s what I did to fix the problem.

First, go ahead and install the latest version of Epson’s software from their website (start here – or just here – lots of clicks to get to where you need to go).

Untar the file you download and read the directions for how to install the software. (Basically, navigate to the directory you just untarred in a terminal then run ./install.sh).

Before this bug, that was all you needed to do and the scanner would work. Now, there are two more steps.

The second step, also at the terminal, is to type in:

sudo ln -sfr /usr/lib/sane/libsane-epkowa* /usr/lib/x86_64-linux-gnu/sane

I’m not exactly sure what this command does but the “ln” command creates symbolic links, so I’m guessing it’s linking two files or commands that help correct the bug in the latest iteration of the software.

Then, open a text editing program and create a new, blank file. In that file, you’re going to add the following content:

# chmod device EPSON group
ATTRS{manufacturer}=="EPSON", DRIVERS=="usb", SUBSYSTEMS=="usb", ATTRS{idVendor}=="04b8", ATTRS{idProduct}=="*", MODE="0777"

The first line of this file is just a comment. The second adds information about Epson scanners.

Save the file as “79-udev-epson.rules”.

Now, move that file from wherever you created it to the following directory:

“/etc/udev/rules.d/”

Like this:

Now, restart your computer. This worked for me. Hopefully, it will work for you too.

 

technology

Linux: How to Install Zotero Standalone (in KDE or Kubuntu)

I’ve used Zotero to manage my collection of books, articles, and other citations since Zotero was released. The software has become much more robust over time. As of the latest major milestone release (5.0), Zotero has moved to standalone software exclusively (they no longer piggyback on Firefox). With Mac and Windows, you can download executable files to install Zotero. With Linux, it’s a little trickier. Here’s my method for installing Zotero so I can launch it from the KDE application menu.

First, download the tar.gz file from Zotero.

Second, untar (i.e., unzip) the folder inside the tar.gz compressed file.

Move the resulting folder (Zotero_linux-x86_64) to a directory where you’ll want to run Zotero from. I use my /home/[user]/ folder but it can be any folder with read/write/execute access.

The Zotero website says that you should then run the bundled “set_launcher_icon.” I usually do that, but I still need to add Zotero to my application launcher. To do this, right-click on the KDE application launcher menu like this:

Select “Edit Applications.”

In the window that pops up, decide where you want to put Zotero (I went with Education) then select “New Item.” You’ll get this window:

Fill it in with the following information:

Name: Zotero
Description: (Whatever you want.)
Comment: (Again, whatever you want.)
Command: /home/[user]/Zotero_linux-x86_64/zotero

You can also add an icon for Zotero (I always do), like this one.

Obviously, replace [user] with your username. The line that really matters is the Command line as that is where the OS will know to look for the Zotero launcher. Make sure it is pointing to the file names “zotero” in the application folder (not “zotero.desktop” as that won’t launch the application).

Once you’ve done that, you should be able to launch Zotero for the quick launcher or from the application launcher: