Tag Archives: Linux

Citrix Receiver on Linux

I’ve written about this issue before, in 2008. But as it turns out, the problem still exists with todays version of the Citrix client, version 12.0, now called Citrix Receiver. And people are still searching for an answer on how to solve this issue.

You have not chosen to trust [certificate] the issuer of the server’s security certificate (SSL error 61)

Both the problem and the solution is the same as before, only the name and the path is different. The path depends on whether you installed the client/receiver as a normal user, or root, also known as the superuser.

I’ve used Ubuntu 11.04 here, but I reckon it’ll work on any Linux distribution.

The problem is this; When you install the Citrix Receiver, it will only install a handful of certificate files, and we’ll have to provide the rest. Now, where can we find a reliable source of SSL certificates? Well, it turns out that we most likely have that already. The same source our browser is using.

 /usr/share/ca-certificates/mozilla/

Just copy those .crt files over to the Citrix keystore, and we should be done. If the client is installed under /opt/Citrix/ICAClient/, run this command in a terminal:

sudo cp /usr/share/ca-certificates/mozilla/* \
/opt/Citrix/ICAClient/keystore/cacerts/

If it’s installed in your home directory, this command should work:

cp /usr/share/ca-certificates/mozilla/* \
$HOME/ICAClient/linuxx86/keystore/cacerts/

If you are using a home made certificate, or for some reason this doesn’t work for you, you’ll have to track down the correct .crt files yourself. But at least now you’ll know where to place them.

Adobe Air – Open URLs in default browser

For the last few days I’ve been fighting TweetDeck on my laptop trying to get it to open web pages in Opera. A small, but fast browser, from the Norwegian company with the same name.

At first I thought that Opera wasn’t my default browser in Gnome. I’m currently using Linux Mint, a distribution based on Ubuntu. So I checked the “Preferences->Preferred Applications” and made sure Opera was the default application for browsing the web. I also checked with “gconf-editor” just to be safe that Opera was set as default browser.

Having checked all this. I did a few tests and found out that Opera was indeed the default application for surfing the web. So the problem had to be limited to TweetDeck or Adobe AIR.

Now. I checked all the xml-files regarding Adobe AIR and TweetDeck, I even installed SQLite3 to read the database file for TweetDeck in my home directory. No luck.

But the Internet is a collection of tubes amazing and brilliant people. So I searched and found Andrea Olivato, which in turned had found the solution to my (and many others) problem. He discovered that Adobe AIR has hard-coded firefox as default browser in libCore.so, which (usually) can be found in /opt/Adobe AIR/Versions/1.0.

The solution

His solution to the problem was to open libCore.so with vim, or any other editor for that matter, and search for the word “firefox”. Ok, he writes that he jumps directly to line 15500, but this might change. But then again, maybe Adobe will make it work in the future. Anyway. He replaced “firefox” with “browser”, which is the same length. Very important. And created a symlink from his favourite browser to, well, browser.

In my case:

ln -s /usr/bin/opera /usr/local/browser

I noticed that in libCore.so, Adobe has a reference to /desktop/gnome/url-handlers/http/command, which is the registry setting for Gnome when it comes to default browser. Why this isn’t used I don’t understand. Perhaps the hard-coded firefox is a backup solution in case AIR fails to retrieve the information from the registry.

Upgrading Ubuntu 6.06 LTS to 8.04 LTS

Today I upgraded from Ubuntu 6.06 to 8.04. The process was fairly painless thanks to a guide I found floating around on the Internet by Ronald Bruintjes. Thanks!

I thought about posting it here, but that wouldn’t be fair to the author. So, please visit his site for more information.

However, be prepared to answer some questions regarding different configuration files. More specifically if you want to keep the original, or overwrite with a new one. I myself have edited a quite a few configuration files over the last year, so I had to do a manual screening before I decided what to do.

Filesystem mounted as read-only during boot

Today I had a case where a server mounted the root filesystem as read-only during boot. To make a short story shorter, check /dev/null.

After doing some searching in the logs I found a few lines complaining about /dev/null also being read-only filesystem. So I checked the permission with ls -al /dev/null, and it turned out this had been changed into a regular file rather then the special file it’s supposed to be.

The fix is easy. Delete the file called /dev/null and re-create the special device with the command mknod -m 666 /dev/null c 1 3.

You can also read about how to create this special file by reading the man-pages. Command: man 4 null.

NimBUS and Regular Expressions

I recently had to configure NimBUS to send alarm upon detecting a specific log entry in /var/log/messages on a Linux system. Because this alarm was supposed to be sent by SMS , I didn’t want it to send more than one message. But since our log file has a timestamp, each entry were we found a match would be handled as a unique alarm, thus sending one message for each log entry where the mach was found.

If the string we were looking for first would appear, it would most likely show up somewhere between 5 to 50 times within an hour.It’s hard to guess, really. But we are looking for a problem that won’t solve itself, and the program checking for this problem will continue to write to the log file upon each encounter with the problem.

The way to solve this kind of problem, where we want to ignore the timestamp, is to understand how NimBUS handle incoming alarms. If it receives the same message two or more times, it would just upper the count, instead of creating a new entry in the alarm window.

Lets say our log file looks like this:

Mar 14 14:55:35 ErrorCheck: Oh noes, error detected in A51
Mar 14 14:57:32 ErrorCheck: Oh noes, error detected in A51

We only want to get one alarm, but with a count of two (actually one), not two alarms which is identical except for the timestamp. First, set up logmon to detect the correct line in the log file using regular expressions. The logmon probe supports both pattern recognition and regular expressions, so make sure to use the right one. Regex starts and end with a forward slash, otherwise it assumes pattern is used.

In this case we can use the following simple regex:

/.*ErrorCheck.*/

Of course my regex where more advanced since I had to detect other parameters as well, since the output of our program also had to be checked.

Now, with this regex in place, we are at the point where every entry will be treated uniquely. But logmon also give you the possibility to construct your own message, and to define variables. And that is what we have to do.

We can construct variables both by row or column number. Since this is a single line, we will use the column offset. So, let us create the variables:

prog = column number 4
error = column number 10

This is only a simplified view. The logmon probe has a user interface for this. Right click, add new variable (or something like that).

When this is done, add your own message text in the field saying so:

$prog: Error detected in $error

When this is set as the outbound message, NimBUS will count it instead of creating a new entry in the alarm view each time, since the message now is identical. If the error code changes, a new alarm will be sent.

Short version:

Create your own output message when using NimBUS logmon probe on a log file which has a timestamp.

(This short version was a lot better and could have saved me some time)