Yenya's World

Sat, 14 Apr 2012

My New Bike

Several months ago, I have written about choosing a new bicycle. Here is the outcome:

AZUB Apus 2011

Introducing my new AZUB Apus. I have rented and extensively tested several recumbents from AZUB (20" Eco with above-seat steering, 24" Max with under-seat steering, and 26/20" Apus with above-seat steering), and I have decided to go for Apus with under-seat steering.

The next thing to decide was gearing. After testing 24" Max with 48-38-26 chainrings and 11-34 sprocket (about 570% ratio) I've got the feeling that I could occasionally use even slower gear (and with 26" rear wheel of Apus the 26/34 gear would be a bit faster than on a 24" wheel), and I can definitely use more faster gears. Recumbents are fast, especially going downhill, because of lower aerodynamic drag. So I wanted gearing with ratio larger than 570% and with the slowest gear slower than 26/34. This is hard to achieve with current components, so I went for triple gearing: I have got SRAM DualDrive in-hub planetary gearbox (three speed gearbox and 8-speed derailleur), combined with tree chainrings, giving me 3x3x8=72 gear combinations and over 920% ratio. One of the biggest advantages is that the gearbox gears can be changed even without pedaling, for example after having to stop unexpectedly.

After five months with Apus, I am still excited with it. I really enjoy being faster on flat surface and on downhills, being able to pedal even while turning, having excellent view with zero neck, wrists and backbone pain, being able to brake without the danger of falling ahead, sitting lower in case of fall, and so on.

The drawbacks are worse view when entering street crossings, being slower uphill, and not being able to jump over obstacles higher than about 10 cm). And the front suspension of the SASO carbon fork is not as good as I expected. I plan to try softer coil spring.

If I had to choose again, I would buy the same bike, possibly with not-so-steep sprocket (11-28 instead of 11-32). Also, having used really narrow tyres on my previous (road) bike, I did not pay much attention to the brakes - I have got V-brakes on my Apus, and I am not able to make the front wheel slip even when braking really hard (on asphalt roads). So probably next time I would get disc brakes instead (at least on the front wheel). Anyway, watch this guy's commute riding Apus on forest paths:

Section: /personal (RSS feed) | Permanent link | 0 writebacks

Fri, 18 Nov 2011

Google Authenticator

For some time, I have been considering adding two-factor authentication to my systems in order to prevent break-ins in case somebody's workstation is compromised (which is a common attack vector these days). One of the systems for one-time passwords is Google Authenticator.

G-A has an application for many smart-phone platforms (Android, iOS, Blackberry), and has a PAM module, which is even packaged in Fedora. It stores users' secrets in a file in the home directory, and uses 6-digit time-based passwords and 8-digit emergency scratch passwords. The configuration in Fedora is pretty straightforward:

There are several problems with SSH-daemon, though:

Especially the second problem is pretty serious, as I wanted to allow also public key + one-time password authentication there.

So, my dear lazyweb, what kind of two-factor authentication do you use?

Section: /computers (RSS feed) | Permanent link | 2 writebacks

Mon, 03 Oct 2011

Dear Customer,

[...] we would also like to inform you about the following change in your network: a new address has been assigned to you: 2001:4cc8:...::/64.

Netbox apparently supports IPv6 now. Yay!

Section: /computers (RSS feed) | Permanent link | 2 writebacks

Mon, 18 Jul 2011

Which Bike?

The 30 years old frame of my bike broke several weeks ago, so I will need a new bike. We have already decided to buy a new bike for my wife, so I have took the frame of her present bike, and remounted some components of my former bike to it. So I don't need a new bike right now, and I have more time to decide what I want.

My previous bicycle was road bike with drop handlebars. I ride on paved roads mostly (altough many roads in Brno resemble off-road riding :-), and we occasionally do touring as well. I am considering the following options:

So, my dear lazyweb, do you have anything to recommend?

Section: /personal (RSS feed) | Permanent link | 7 writebacks

Wed, 15 Jun 2011

High-Performance HTTP Servers

Yesterday I have read about Apache Traffic Server. My dear lazyweb, do you use something like that (or Nginx)? What is your main reason for using it? I wonder why use user-space solution, when IPVS works pretty well for load balancing.

Section: /computers (RSS feed) | Permanent link | 1 writebacks

Fri, 03 Jun 2011

Citroën Xsara

It has been seven years since I have bought my Citroën Xsara. At that time, I have considered several models, looking for an estate car for my family. Having used several Škoda Felicia cars in my previous job, I have definitely wanted a car from some other manufacturer. My opinion was "the car can have its problems, but at least let it be different problems than Škoda have".

Citroën Xsara

That said, I have never considered Citroën, and in fact I did not know much about Citroëns. When I have been offered a 4.5 years old imported Xsara, however, I have found it "good enough" for me to buy.

Subsequently, I have been pleased to find out how comfortable my Xsara was, and how well equipped compared to the cars of similar age and class it was. It provides enough leg room in back seats (especially when compared to Octavia), and the 82 kW engine provided enough power for most of my needs. During almost 100,000 km in seven years I had only few malfuncions, the most serious one was a broken exhaust pipe because of corrosion.

Even though I did not originally considered buying Citroën at all, the next car which I have bought and which I use these days is also Citroën. So, my dear lazyweb, is anybody in your social network interested in buying a cheap, well-equipped, used car? If so, look here.

Section: /personal (RSS feed) | Permanent link | 0 writebacks

Tue, 24 May 2011

Mysterious Source Code

About a month ago, I have spotted a two-page listing of source code in our printer room/kitchenette. I have glanced over it briefly, and during subsequent visits to the room, I became more and more fascinated by it. Finally, about a week ago, I have grabbed it for myself, because nobody seemed to care about it anymore. So here it is, in all its glory:

source code page 1 source code page 2

Click the thumbnails for full-size images. Sorry for not providing a plain text version, and sorry for the Czech language in the comments. I have two reasons for which I find it really fascinating:

  1. There are two pages of source code, which does literally nothing. It only wraps an existing class with a new one with marginally different API (two exceptions joined into one exception, and retrying in case of failure). Nobody sane would write these two pages by hand, so I expect the code has been at least partially generated by some IDE. Obviously nobody can expect the code to be read by a human (actually, not read, but carefully examined for traces of some non-trivial application logic, should there be any). So I wonder what the present meaning of "the source code" phrase is, when it is no longer written nor readable by humans.
  2. The only real "application logic" is the for-cycle near the end of the second page. And even this has been totally destroyed by the "every block should have only one exit point" mantra of the programming theoreticians. Adding a simple return statement when the message sending finally succeeds would save them the following:
    • a boolean variable
    • a complicated condition in the for-cycle
    • an if statement when the maximum number of tries is reached

I can only hope this is some kind of a silly example and not a real assignment given to the students of the Programming in Java course. I think the students have to be taught that mid-layers are root of all evil, and not some highly theoretical (read: impractical) rules like "goto is evil" or "a single exit point only".

Section: /computers (RSS feed) | Permanent link | 4 writebacks

Mon, 23 May 2011

Lost GUI features

Contemporary GUI applications have several problems which, if I remember correctly, previous systems did not have. I wonder whether somebody else also considers it being a problem:

Creating a new file
Almost every TUI text editor (like vim) happily accepts a non-existent file as a command-line argument, and the straightforward interpretation is "user wants to start working with a new file". On the other hand, most GUI applications simply complain that the file does not exist, and some‒like OO.org‒exit after that message. Other GUI apps, like Gnumeric, present a warning, but then open a new work with the default file name (Book1.gnumeric in the case of Gnumeric) instead.
Working directory
The file open/save dialog of contemporary GUI apps does not offer by default the working directory from which the application has been started, and uses some silly default (such as ~/Documents in case of OpenOffice.org). Even gThumb needs to be explicitly told that the user wants to browse the current directory with the "gthumb ." command line.
Iconified applications
Once upon a time, in a stone age of GUI computing, there was a twm window manager. When the application window was not needed on the screen, twm could be used to iconify the application. All applications, and all instances of them, could be iconified and then restored back the same way. Then Windows 95 happened, and it started to minimize the applications to the bottom panel instead of iconifying them to any place in the desktop. It also reused the desktop icons as application shortcuts instead of representing the minimized running applications. Unfortunately, the panel was too small for so many running minimized applications. Users stopped expecting to be able to restore the application after minimizing it. The applications which required to be minimized and restored back frequently (music players etc), developed their own means of minimizing, the notification icon area. So we have the iconification back, only not usable from all applications, and with each application implementing it in its own crappy way.

So what other important features of the "desktop of the past" do you consider missing from the present GUI systems?

Update - Mon, 23 May 2011: Iconified Apps

I have just discovered that XFCE4 in Fedora 15 allows the desktop icons to be switched between the Application launchers/shortcuts and Minimzed applications modes. Yay!

Section: /computers/desktops (RSS feed) | Permanent link | 8 writebacks

Fri, 20 May 2011

GNOME 3

After installing Fedora 15 in a virtual machine, I have decided to give GNOME 3 a try. Firstly, it is really slow over VNC. While GNOME 2 has been pretty usable for testing various new applications in a virtual machine, under GNOME 3 it is almost impossible. Here is a screenshot on which I will demonstrate my problems with GNOME 3:

GNOME 3 on Fedora 15

Firstly about the file manager. I use mostly command line for managing my files, but using a file manager is sometimes handy nevertheless. One of the features I often use is the "Places" list. In GNOME 3, it is presented differently in the Places menu and in the file manager itself, which is a clear usability bug. When I wanted to add another directory there (I often use ~/tmp as my sandbox), it took me at least 10 minutes to discover that "Bookmarks" is what I probably want. And even then, the newly added bookmark is added to a submenu instead of the main Places menu. Also, I did not found any way how to remove those useless predefined directories like Videos, Music, etc. from the left sidebar. Even when I have deleted them from my home directory, they still remain in the sidebar.

Another ugliness is that the new window manager does not decorate the windows properly, and instead relies on the applications themselves to provide things like resizing handle in the lower right corner (see the gnome-terminal window). Not only it looks ugly as hell, it also obscures the space the application expects to be visible. I will probably file this as a bug report when F15 is officially released, but I expect in a truly GNOME-ish fasion it to be solved by removing the "scrollbar on the left side" option :-/.

Anyway, it seems that XFCE+Sawfish combo works as expected, so I am definitely leaving GNOME when I install F15 on my workstations.

Section: /computers/desktops (RSS feed) | Permanent link | 6 writebacks

Tue, 03 May 2011

Rethinking Cron

cron(8) is one of the oldest tools in UNIX. Despite of that, I think cron is not something to be proud of. In my opinion, it falls to the unfixable designs category. The recent attempts to fix it (factoring out atd(8), a dirty hack that is anacron(8), etc.) show some of the problems of cron. My recent experience confirms it:

Cronserver load average

This is the load average graph from our server, which runs periodical jobs of IS MU. Around 2 pm, I have rewritten the main crontab joining several similar tasks to one line, and adding several seconds delay between their startup. The groups of tasks are now started by a simple Perl script which handles redirecting STDOUT and STDERR, and handling the return code. The Perl script is started using exec in the crontab line, saving one more process.

This way, I have managed to get the number of jobs which are simultaneously started in the peak minutes of an hour from 155 to 13. The system does exactly the same amount of work as before, but most of the work is evenly distributed across the whole timeframe, not started in parallel the first second of a minute. This is one of the big weaknesses of cron. I think the future cron will need to support the following use cases:

What periodical and semi-periodical tasks scheduler do you use? Will systemd be the answer to these problems?

Section: /computers (RSS feed) | Permanent link | 2 writebacks

Fri, 01 Apr 2011

git-diff(1) Dark Color Scheme

The default colored output of git-diff(1) and other commands is a bit ugly in my terminal with dark (green-on-black) color scheme. Here is how to fix it:

git config --global color.branch.current 'yellow bold'
git config --global color.branch.remote 'cyan bold'
git config --global color.diff.new 'yellow bold'
git config --global color.diff.old 'red bold'
git config --global color.diff.meta 'cyan bold'
git config --global color.diff.frag 'white bold'
git config --global color.diff.commit 'white bold'
git config --global color.status.added 'yellow bold'
git config --global color.status.changed 'cyan bold'
git config --global color.status.untracked 'red bold'

Hope this helps - I had to read the source code to find out where the color of the commit ID in git-log(1) is set. The above can at least serve as an example (after all, I don't expect you to have the same taste for colours), and for my future reference.

Section: /computers (RSS feed) | Permanent link | 0 writebacks

Fri, 25 Mar 2011

man(1) Surprise

Hello, this is your editor speaking, welcome to the "lesser known Linux feature of the day" series. Today we will cover an interesting feature of man(1) that your editor has just ran into. Try running the following command:

$ man git log

The manual page of git-log(1) is displayed on my Fedora 14 system. How does man know that git provides a "log" sub-command in addition to the equivalent git-log standalone command?

The man page says:

By default, man will try to interpret pairs of manual page names given on the command line as equivalent to a single manual page name containing a hyphen. This supports the common pattern of programs that implement a number of subcommands, allowing them to provide manual pages for each that can be accessed using similar syntax as would be used to invoke the subcommands themselves.

And it even goes into an example using - guess what - git. That's all for today, see you next time!

Section: /computers (RSS feed) | Permanent link | 2 writebacks

Wed, 23 Mar 2011

XFCE

The first alternative to GNOME I have decided to try is XFCE. In the LWN discussion, Jon Masters presented it as a viable replacement to GNOME. Also, it uses GTK+ like GNOME, so many applications can be the same (including, I have hoped, my window manager of choice, Sawfish. XFCE is definitely usable and configurable for power-user. Most (but not all) properties can also be set using their Settings manager, and thus XFCE should also be mostly usable for ordinary users. So far the problems include:

XFCE is tightly related to both GTK+ and GNOME, and can incorporate various parts of GNOME (some notification area applets, keyring manager, etc). So I guess I would be able to use it as a replacement, if not for the whole GNOME, then at least for the central parts like GNOME Shell.

Section: /computers/desktops (RSS feed) | Permanent link | 1 writebacks

Tue, 22 Mar 2011

GNOME in the Shell

Yesterday, after reading The Grumpy Editor's GNOME 3 experience article at LWN, I have decided it is time to at least make an attempt to move away from GNOME, which (much like KDE 4) decided to use revolutionary instead of evolutionary development, and apparently continues in their feature removal crusade in the name of so called usability. Also, this might be a good chance to move away from Galeon after so many years.

I wonder what makes the GNOME developers think the existing users would welcome a completely new desktop with very limited means of customization. GNOME 2 has only recently reached a moderate level of usability (except gdm, which is still not usable for many purposes since the last rewrite).

It would be very sad to move away from GNOME, because I think I am not a typical conservative user, and I welcome occasional new features, provided they do not hurt productivity and power-user usability. However, apparently GNOME Shell provides neither, and the so called fallback mode is not complete enough (virtual desktops in a single row, seriously?). Also I would rather use the same desktop envionment as some non-computer-savvy users to which I occasionally provide technical support.

So I have decided to experiment a bit on my laptop, but keep GNOME and Galeon both on my home and work workstations for now. More on it in a few days.

Note: I am sorry, the above mentioned LWN article is subscribers-only for now. It will become freely available in several days. Alternatively, you can ask me for a link in a private e-mail.

Section: /computers/desktops (RSS feed) | Permanent link | 2 writebacks

Wed, 09 Mar 2011

New Odysseus

We have got a new hardware for our FTP server to replace our seven years old server. It is amazing how the old hardware is still in many aspects on par with state-of-the-art "average workstations". The old system had 12 GB of RAM, 8 TB of disks, and dual GbE. It was one of the first 64-bit x86 systems here at Faculty of Informatics. So, which principal improvements in server hardware the last seven years brought (apart from speed, of course)?

Anyway, both the original and new configurations are described on the Odysseus statistics page (in Czech). Let me thank CZLUG and CSTUG for sponsoring some of the disks for the new server. We will see whether the new hardware can also keep running for at least seven years.

Section: /computers (RSS feed) | Permanent link | 1 writebacks

About:

Yenya's World: Linux and beyond - Yenya's blog.

Links:

RSS feed

Jan "Yenya" Kasprzak

The main page of this blog

Categories:

Archive:

Blog roll:

alphabetically :-)