Monthly Archives: July 2009

SSHmenu

This application I use almost as much as my terminal application. Also this application means that I now hardly ever type SSH any more. No more remembering my username on each host, remembering the options that host accepts and no more configuring each and every environment to update the xterm title to include the hostname.

At work  I have 109 hosts setup in my SSHmenu, this seems overwhelming but using menus and submenus i can hide away most of the clutter. I don’t ever have to remember the username I have on that host, any other hosts I have to go via on the way or even whether I can X forward from that machine. All that is abstracted away by a simple menu. SSHmenu will also set the title, size and colours of the terminal so you can ever have different colours for different hosts. Production hosts red, development blue and testing servers green for example.

The innate beauty of SSHmenu is that it is so easily hackable. On the SSHmenu website there is even a hacking guide. Normally it does SSH but there are instructions on how to add telnet support, and if you were savvy enough it would only be a small step to add rdesktop or dsh support.

If you manage or use more than 30 servers I’d highly recommend you check out SSHmenu. On Fedora its a simple ‘yum install gnome-applet-sshmenu‘.

See Also

http://embraceubuntu.com/2007/08/17/ssh-menu-save-and-open-ssh-connections-from-the-panel/

http://blog.flexion.org/index.php/2008/02/26/sshmenu-ssh-connection-management/

Random Thought: Why does my software that says Windows XP or better not work on Linux?

A Look forward to Fedora 12 (Constantine)

So, they’ve named Fedora 12 Constantine. Both Constantine and Leonidas are towns in Township in St. Joseph County, Michigan. There is going to be much more to the new Fedora than just a fancy pants new name, so lets look at the accepted features. It needs to be noted that since Fedora has hit the feature freeze stage new features will not be added (except in an exception :P ) but may be dropped.

Better Webcam Support

If you’re like me and have a webcam that sends a jpeg (or even worse, a proprietary compression) stream from the sensor through USB then you’ll like this one. The kernel guys have been adamant that JPEG decompression should not be in the kernel. This makes it hard to present a common interface to userspace, as the stream could come in several different formats. To fix this problem drivers are having their decompression code moved out of the kernel and into a new library, called libv4l.  libv4l presents a common interface for all the webcams it supports to applications, this includes v4l1 and v4l2 webcams. This feature also involves porting applications (like cheese, ekiga and amsn) to this new library.

DebugInfo Filesystem

Currently should you want to debug a package in Fedora you have to install the often large -debuginfo packages. For example the kernel-debuginfo package is usually around 300Mb compressed. When installed this figure can inflate to up to 400Mb. With enough debug packages installed this can quickly fill your system. Even if you install a debuginfo package often the whole package isn’t required, for example installing the kernel debug information just to write SystemTap scripts or to debug a single module. This feature allows debug information to be installed when required and only what is required. This is most useful when users are reporting bugs, as their machines can resolve the addresses in the backtraces on the fly as bugs are reported. This means we get better bug reports, which leads to easier fixes, which leads to more time, which leads to more features and who doesn’t want more features?

DisplayPort Support

DisplayPort is a new type of connector that was designed to replace DVI and VGA. Designed by the people at the Video Electronics Standards Association (VESA), like its predecessors it is royalty royalty free. It is going to be extremely important for laptops, which will most likely switch to it because it uses less power and DVI and LVDS. Adding support for DisplayPort will be more complicated than others but most of the work will be able to be shared (by putting in Xorg or the kernel).

Dracut

Currently when a Red Hat system boots, it loads the initrd, and starts nash. Nash isn’t really a shell its just enough to get load the correct drivers and to finally load init. To rebuild your initrd (to include an extra drive for example) you use a tool called mkinird. These tools are maintained by Red Hat and they have done the bulk of the development work. A better approach would be to have a common set of tools to build Linux ramdisk images that can be used across many distributions. That is basically what Dracut is, and this feature is about moving Fedora to these new tools.

Empathy

GNOME dropped Pidgin and now heralds Empathy as the official instant messenger application. Empathy includes not only instant messaging, but also voice and video chat. It can connect and voice/video chat to Google Talk and other XMPP/Jabber users. Another awesome advantage with Empathy is that it includes an API to allow other applications to check your status online. Empathy will enhance the Linux Desktop experience and provide an instant messaging experience that Pidgin simply can’t.

LibLVM

Should you currently want to write a program that creates, removes or alters in any way the LVM setup of the machine your only option is to exec the command line tools, and parse the output. While this approach does work (anaconda and system-config-lvm currently work this way) it isn’t perfect. What is really needed is somebody to come along and write a library to directly interface with LVM that works in an object oriented fashion. This library is currently being written for Fedora 12 and according to the project pages it is 25% complete.

Multiseat

With the current economy saving money is as important as ever. Multiseat will allow you to plug two keyboards, mice and monitors into the same computer and allow each to work independently. This effectively allows two (or more) users per computer, saving you from buying two PCs. The last time this support was available was Fedora 8 but it was dropped in order to use the new GDM, ConsoleKit and X.

NetworkManager Improvements

When I first used NetworkManager I hated it, and I immediately disabled it and rolled back to the network service. The second time I used it things went a little better, but I still ended up disabling it. In Fedora 10 NetworkManager worked flawlessly for me and I discovered that NetworkManager was previously working as well as it could with a poorly written wireless driver. Yes, NetworkManager has copped a lot of flak recently but its constantly improving and some of its problems are caused by dodgy drivers. This feature (actually two on the Fedora 12 features page) focuses on getting system connections working (the ones in /etc/sysconfig) and IPV6 support.

NFS Client IPV6

At the moment IPV6 roll outs across enterprises are happening, but not at a fast rate. There is a lack of support for many applications and the nfs client is included, yet Solaris has had support for NFS over IPV6 for years. This adds one more application to the slowly growing list of applications that support pure IPV6.

PolicyKit 1.0

PolicyKit is a tool kit designed to allow applications to request escalated privileges, for example the time/date control panel can request access to set the system time or the shutdown dialog can request permissions to log out other users prior to shutdown. Unfortunately the current PolicyKit design is not flexible enough. Fortunately it’s been redesigned and now the new improved PolicyKit is ready to take over. It now includes a plugin API and you can change exactly what admin authentication means.

Systemtap static probes

So if you haven’t heard of SystemTap you soon will, I’ve got a post on it coming up shortly, but for the moment just think Dtrace for Linux. Anyway, SystemTap lets you monitor the performance of your machine and your applications in ways that you define. For example I can monitor how many reads Firefox makes while sitting idle on my system (quite a lot actually) but at the moment I can’t monitor how many hits firefox gets in its cache, or how fast queries to its built in SQLlite database are. If static probes were inserted into Firefox at these particular points then I could, and this feature focuses on getting static probes into postgresql, xorg-x11-server, openjdk, tcl and finally firefox.

XZ RPM Payloads

XZ is the new version of LZMA which offeres better compression at faster rates. This means that RPMs in Fedora will be smaller and will be able to be downloaded quicker. This feature will mean that more RPMS can fit on each DVD (or CD) allowing a bigger distribution on the same media. This feature will also help users on slower connections who are currently using deltarpms as now the deltarpms will be even smaller.

x86 Improvements

The Processor world is constantly moving forward, making new processors and dropping old ones on the floor. Fedora is also moving forward, and its come time to drop support for some older processors so we can optimise for the newer ones. So the proposal is that for Fedora 12 i586 support be dropped and packages be optimised for the i686 architecture. For me personally this means that my extremely old HP Desktop will no longer run Fedora, but at 800MHz and with 256Mb of RAM I should probably be retiring it soon anyway.

Random Thought: Which distro has the highest version number? RHEL is at 5.4, Ubuntu is at 9.04, Fedora is at 11, Gentoo is 2009.0 and Mandriva is at 2009.1. So I guess Mandriva wins :D

Edit (20/7/2009): According to the Fedora 12 Features pages many many new features have been added. A repost will follow in a few weeks.

Edit (6/8/2009): You’ll find the current feature list in my new post titled Fedora 12 (Constantine) Features.

The Obligatory Post on Google Chrome OS

I’m not excited by Google Chrome OS. And the majority of the reason for that stems from the following paragraph posted on the Official Google Blog:

Speed, simplicity and security are the key aspects of Google Chrome OS. We’re designing the OS to be fast and lightweight, to start up and get you onto the web in a few seconds. The user interface is minimal to stay out of your way, and most of the user experience takes place on the web. And as we did for the Google Chrome browser, we are going back to the basics and completely redesigning the underlying security architecture of the OS so that users don’t have to deal with viruses, malware and security updates. It should just work.

They keep mentioning simplicity, lightweight and ‘back to the basics’. have you ever used an OS designed to be extremely simple? Have you ever tried SplashTop, HyperSpace, Latitude ON or even gOS? They may be fast to start up, but you’ll curse just as much when the one thing you want to do is only possible on the actual OS you have installed, requiring a reboot. My opinion is that these lightweight OSes actually make my life harder. Lets see one use case.

I’m at home and I need to check my email. This can be done in ExpressGate so I boot it up (really fast) open up a browser and browse to my Gmail. So far the experience is relatively smooth, until I discover that somebody has sent me an attachment that I need to see. Of course this requires an application installed in my OS so I have to close my browser and any other sites I had open and wait for a reboot into my OS. This is the inherent problem, if I need to use something that isn’t part of my lightweight distribution then I have to stop everything and wait.

Now I understand Google Chrome OS is going to be the actual OS, except most of the applications will be based in the cloud. This presents another problem, especially on netbooks. Netbooks are portable, and designed to be used in places where there is no internet connection. See the problem? Sure you could use a 3G modem but then you have to fork out a fortune for data (especially excess usage).

Unless Google can find a creative way to solve these problems I don’t think that Chrome OS will be anything exciting. It should be noted though that if I were to pick a company that would be able to take on this challenge I would pick Google. I suppose in the end there is only one way to find out, and that would be to wait until the end product is released.

Random thought: If you use a Live CD of another distribution, but don’t install it, is it still cheating?

Linux ‘top’ Commands

As a sysadmin working with Linux PCs I often need real time data on the status of the systems I manage. For example I might need to know what is using up all the bandwidth on an interface, whats taking up  all the memory or why my X displays are running sluggish. The impromptu
standard for naming these commands is to add the ‘top’ suffix. Here is a list of my favorite 8 ‘top’ commands.

top

Top, the grandaddy of all the Linux top commands, is most useful for  monitoring tasks running on your system. On my Fedora system its contained in package procps which on Fedora 11 was 3.2.7. Top has many keybindings to change its behaviour, for example ‘f’ is used to add and remove fields, ‘o’ will help you reorder those fields and the lesser-than and greater-than keys move the search field. You can type ‘h’ for a bigger list.

tload

You caught me! This one doesn’t end with top, but I put it here because on Fedora it comes as part of the procps packages with top, slabtop and others. tload is a good application to have in a small terminal in the background.  It comes packaged along with top. It displays a histogram of the current load for the system. I like to have it running in a transparent terminal that I leave open on my laptop.

htop

An improved, menu driven and colourised version of normal top. Htop allows you to get information on each thread of a program or combine all thread like normal top does. Some would argue that its more powerful, but others simply say its bloated. Whatever you believe, it has some nice features that any sysadmin will appreciate and you’ll soon be wishing htop was avaliable
everywhere.

iftop

top is to cputime what iftop is to your network interfaces. It displays a list of the top servers that are exchanging data over the selected interface. Because of the way it captures packets from the interface it needs root privleges to run.

iotop

iotop displays live system IO statistics. Like top it lists the top applications that are using IO. It can be toggled with the ‘o’ key to only
display programs currently performing IO, which is useful on large servers. You can read more about its keybindings on its manpage.

slabtop

slabtop is especially useful for kernel developers and pedantic system tuners. It displays a summary of all the slab objects allocated in the kernel. I can take options to tell it how to display its information, but only has two keybindings, spacebar is to refresh the screen and ‘q’ is to quit. You can see its options on its manpage.

xrestop

For X developers there is a utility called xrestop. xrestop displays a list of X server resources allocated. It can be useful to see if your application, or your X server is leaking resources. While it only accepts the ‘q’ key to exit it does accept a few options.

powertop

Built by Intel to help tune laptops to get the best performance out of your battery. It shows the percentage time spent in each CPU state and lists the programs and devices that caused the most wake ups from idle mode. Its most useful feature though is that it will analyse your system and give a suggestion on action to be taken to save just that little bit more power.