Gearman Disconnects Client or Worker Before Doing Anything Useful

If the log shows that the client connects, but then gets disconnected after sending a few REQ packets (or at another part of the exchange), the cause is probably that there is an incompability between the version of the server and the version of the client or worker. If the client or worker sends a request that the server can’t understand (if the client/worker uses a part of the protocol that wasn’t defined when the server was compiled), the server will disconnect the client or worker.

Building Gearman: cannot find the flags to link with boost thread

While running ./configure things may bail out with the message “cannot find the flags to link with boost thread”. This is cause by configure not being able to find the development version of the libboost-thread libraries on the current library path. If you’ve not built libboost from source, you probably need to install the -dev version of the libboost-thread package for your distribution.

For ubuntu this package is named libboost-thread-dev (you’ll find specific versions under names such as “libboost-thread1.46-dev”. Do apt-cache search libboost-thread to see which packages are available).

For Gentoo the package is named dev-libs/boost, so just emerge that one (thanks to J/#gearman).

Building Gearman under Red Hat Enterprise 4 (RHEL4) or older CentOS-versions

While building gearman on our older RHEL4 servers, there was two issues that surfaced:

  • The version of boost included in RHEL4 is too old (1.32) for gearman. I decided to download the new boost version (1.48.0 at the time of writing) and install it. Be sure to remove the old version with rpm -e boost-devel, so that you don’t get strange conflicts while attempting to build the benchmark tools:
    benchmark/ undefined reference to 
    benchmark/ undefined reference to 
  • Issues while trying to build the tests/ directory:

    tests/ In function `test_return_t worker_ramp_TEST(void*)':
    tests/ error: `pthread_timedjoin_np' was not declared in this scope
    tests/ warning: unused variable 'pthread_timedjoin_np'
    make: *** [tests/stress_worker.o] Error 1

    This can be solved by removing the whole section enclosed in the #ifdef _GNU_SOURCE
    section. Let the content in the #else-part in place. Removing this will not affect the usual (and any important parts of it) gearman distribution in any way.

The configure / make process of gearman needs a way to exclude the benchmark/ and tests/ parts of the project from being built.

Missing Content in the Awesomebar or History in Firefox

One of the workstations at work had suddenly decided to not record any history of new sites visited .. and not to show any traces of old visits. After a bit of searching I found the recipe for How to fix a corrupt localstore which mentions a few of the same symptoms, in particular that the bookmark dialog won’t show up. Stopping Firefox and then renaming localstore.rdf did however not solve anything. Luckily I had remember that somewhere someone mentioned the places.sqlite database as containing information for the location field, so after stopping Firefox again, deleting the places.sqlite file and then restarting Firefox, everything went back to normal. Yet again Firefox knows where it has been!