Tag Archives: Linux

Linux Future

Some time ago I came across yet another angry discussion[1] about systemd, and have been reading and thinking a great deal about the design of Systemd, and what it says about Linux. I’ve come to realize that the strife in the Linux community is because an active and well-funded group of developers who have been driving the direction of various core components are not building UNIX. They are building some other philosophically divergent system on top of the Linux kernel, with roughly the same relationship to UNIX as Plan9[2]. For convenience I’m going to call the non-UNIX environment they’re building FLOS for the remainder of this post (F since the FreeDesktop.org folks, and their backers in the Fedora project, are driving this, L for the Linux kernel, OS should be self-explanatory). I intend this term to be value-neutral[3].

To me, the core of a UNIX system is a philosophical matter. To quote Mike Gancarz’s The UNIX Philosophy from 1994, UNIX has 9 paramount precepts:

  1. Small is beautiful.
  2. Make each program do one thing well.
  3. Build a prototype as soon as possible.
  4. Choose portability over efficiency.
  5. Store data in flat text files.
  6. Use software leverage to your advantage.
  7. Use shell scripts to increase leverage and portability.
  8. Avoid captive user interfaces.
  9. Make every program a filter.

FLOS is a nearly diametrically opposed design, with design concepts like the following:

  • FLOS avoids scripts, and prefers to split tasks into compiled logic interacting with logic-less configuration files.
  • FLOS prioritizes ease of machine manipulablity over human manipulablity.
  • The components of FLOS communicate over D-Bus rather than sockets and pipes.
  • FLOS is built on a core of monolithic programs which attempt to synergisticly manage multiple complex components.
  • FLOS leverages features specific to Linux and ignores portability.
  • FLOS prefers tightly integrated components to generic solutions.

I’m not sure that this is a bad design, but it is most definitely not UNIX or anything like it. I’ve seen some fairly convincing arguments that the FLOS design philosophy has serious benefits, and there are decades of convincing arguments that abandoning the UNIX way is the path to ruin. Systemd is the big realization of the FLOS design, but many projects, especially FreeDesktop projects, have been working this way for some time. I’m going to pick out a couple examples and talk about them under the fold.

Continue reading

Posted in Computers, DIY, General | Tagged , , | 114 Comments

Udisks2 and UNIX Philosophy

Apparently the udisks devs took it upon themselves to violate the FHS and moved the path for automounted media from /media/$DEVICE_NAME to /run/media/$USER/$DEVICE_NAME.

This is a user-facing change that I can’t find primary documentation for with google, which means the developers are automatically in the wrong, even if it is a good change.

Now, let’s talk about some things this change does (The first three are the developer’s claimed features):

  • Mount paths now belong to users – Why would a device plugged in to a computer belong to a particular user? It’s just as likely to be a backup drive or some other shared resource, and the interactions with hotplugging filesystems that support proper permissions are kind of bizarre. Older auto-mounters having to work around the “priviliged mount as a user” issue was a feature.
  • Avoids name clashes – Seriously? If we make the assumption that all relevant systems are single-user interactive machines, as the FreeDesktop folks have been making, every disc will belong to the same user, so the namespace is exactly the same. Also, is this a real problem? How common are device name conflicts? Can’t we just append “-(n+1)” or something straightforward like that?
  • Works with a ro / – OK, fair enough, it’s a neat idea. Now who run anything other than a statically configured embedded system with a ro /? Bueller? Bueller?
  • Where do discs plugged in before a user logs in go? How about if you have multiple interactive users logged in? This Fedora mailing list discussion seems to indicate they didn’t even think about it before pushing the change, and the suggestions mean your disc will mount in different places depending on when you plug it in. Broken.
  • The FHS is a standard, all manner of programs and scripts follow the standard. Everyone who was following the rules just got burnt.

    It wouldn’t be so aggravating if it weren’t part of a stream of douchey autocratic decisions the the gnome and RedHat contingent among the FreeDesktop folks have been making during the transition off of HAL, that harm everyone but the narrow use case they envision while making the decision. This is the same crew that has been forcing the *Kits on us (PolicyKit, ConsoleKit, DeviceKit, etc.), which have all made things less transparent, and power users’s lives more difficult. Most of these changes seem to be dedicated to breaking features accessible from the command line or other simple interfaces and instead integrating them into one of the bloated libraries attached to Gnome and QT, just to make things easier for the big desktop environments, which I find philosophically objectionable … in the words of Doug McIlroy himself, “This is the Unix philosophy: Write programs that do one thing and do it well. Write programs to work together.”

    There is a ragier condemation of it here that fails to bring in the UNIX philosophy argument, and an obnoxious but partly correct rebuttal from someone involved here if you would like to peruse the politics.

  • Posted in Computers, DIY, General | Tagged , | 4 Comments

    Another quick Linux aside/breadcrumb, I had some hand-written Udev rules start causing errors on my Arch boxes a while back, and just got around to fixing them. The basic problem is that the Udev rule syntax has changed, and statements … Continue reading

    Posted on by pappp | Leave a comment

    The previous post ended with “I have no idea why the nodes won’t boot.” Now we know. The problem is that, in terms of the mkchroot-rh script that Warewulf3 comes with, Fedora 16 is not a Redhat derivative. This makes … Continue reading

    Posted on by pappp | Leave a comment

    Warewulf, and the Kernel Documentation

    Earlier, while trying to instrument a failing boot from some peculiar nodes we were trying to provision, I came across the following gem in the Linux kernel documentation, from Documentation/filesystems/ramfs-rootfs-initramfs.txt:

    Note: The cpio man page contains some bad advice that will break your initramfs archive if you follow it. It says “A typical way to generate the list of filenames is with the find command; you should give find the -depth option to minimize problems with permissions on directories that are unwritable or not searchable.” Don’t do this when creating initramfs.cpio.gz images, it won’t work. The Linux kernel cpio extractor won’t create files in a directory that doesn’t exist, so the directory entries must go before the files that go in those directories. The above script gets them in the right order.

    Yup. If you follow the documentation for the tool, it renders your system unbootable. The linked documentation is actually pretty cool – it explains the rationale for the current state of the boot process, including that charming behavior, and links to the original discussions. But the particular behavior is still kind of psychotic.

    Upside: After today’s digging I know all kinds of neat things about the current Linux boot process, which I hadn’t relearned after it changed at the the 2.4/2.6 transition. Similarly, the last couple times we had problems with Warewulf 3 (or, actually, Redhat-isims interfering with Warewulf) brought me back up to speed on interpreting raw packet logs from Wireshark, so this has all been thoroughly educational.
    Downside: I have even less idea why the nodes won’t finish booting – the check I was adding was to test our theory that they were running out of memory, and they don’t seem to be.

    Posted in Computers, DIY, General, School | Tagged , | 1 Comment

    Linux 3!


    I just ran my first major-version-number Linux kernel upgrade, and nothing caught fire. The “no fire” is mostly thanks to the Arch maintainers, who held it until a clean upgrade path and driver compatibility was established, so props to them.

    Posted in Computers, General | Tagged , | Leave a comment

    Window Manager Musings

    A while ago I installed KDE 4.6 on one of my machines, just to see what the bulky extreme of desktops looked like these days. Mostly, it was obscenely bulky (KDE alone is, seriously, larger than the sum of the software I have on my workstation on campus) and cluttered (what is the deal with that fucking cashew). However, there are a lot of improvements over the last time I fiddled with KDE, and a few features I really, really like.

    Some of the little nice things: The control panels are all integrated and aware of each other. The GUI wrappers around randr are genuinely nice (display attachment behavior as good as Windows 7’s – which is frankly the best I’ve ever seen), and the fact that it customizes nicely to CDE-style right-click-the-desktop menus (sans this bug when I first tried) is promising.

    The most important (The nomenclature alone for this behavior is nonstandard) is “Desktop Gluing” – Permanently fixing particular windows (or applications, or whatever) to particular virtual desktops. In KDE, a huge array of window behaviors can be set from “Advanced Window Settings” or “Advanced Application Settings” panels obtained by right-clicking the title bar of a window. It’s a good design – unobtrusive until you go looking for it, and obvious once you do. I always keep my “Communication and Identity” stuff (Email, Chat clients, a browser with whatever social things I feel like tending to, etc.) on my second workspace, and this makes it much easier to respond to message alerts without pulling those windows to other workspaces.
    Any EWMH compliant environment SHOULD be able to do this, (and apparently E17 has behavior similar to KDE, but E17 has improved from “Broken” to “Useless” over the last few times I’ve played with it, so that isn’t terribly helpful). I can’t find a way to replicate this behavior with XFCE. The native settings don’t have anything, and Devil’s Pie and wmctrl can both cause windows to OPEN on a specified desktop, but they are both extra, somewhat fussy, programs that need to run in the background, and neither can force a window to STAY on a particular desktop.

    When looking into the feature, I did make the excellent discovery that XFCE has had a setting for the last several releases that takes care of one of the problems window gluing solves. Based on this Bug Report, one can switch the obnoxious “Pull window to active workspace when activated” behavior to either move focus to the workspace the window is on (My desired behavior), or just alert in the task bar.

    Always nice to find little ways to improve the workflow, and see what the other desktop environments are doing, especially with so much of the UI “Innovation” of late being disappointing (see iOS, and Unity).

    Posted in Computers, General | Tagged , , | Leave a comment

    Humble Indie Bundle #3

    There is another Humble Indie Bundle name-your-own price/donate to charity sale going on. Like last time, the average Linux user is paying about twice what the average Mac user does, which is in turn about 1.5x what the average Windows user offers. Who says we’re cheap?
    I put $15 into the last one, and even though I didn’t end up liking half the games in the set, it was totally a good deal. Did it again this time even though I won’t have time to play them in the near future.

    Posted in Computers, Entertainment, General, Objects | Tagged | Leave a comment

    Cluster GPU Thermal Monitoring

    The research group has been writing some simple monitoring scripts for handling the clusters. The focus is mostly on montitoring NAK (page in serious need of update), which has always had thermal irregularities with it’s GPUs. Some of the (poorly designed) GPU coolers have recently finished cooking their fans, and the “repair” has been to remove the cowling and mount an 80mm fan in the case to blow across the heatsink — this produces comparable temperatures to the vendor solution, whch is pathetic. This thermal instability requires that the system temperatures be periodically checked, and we have written variety of colorful scripts both for users and for the displays in the front of the machine room. The one I wrote for my own use is a simple combination of bash and AWK, which produces nice colorized one-line summaires for each machine when run with something like “mpirun –hostfile ~/nakhosts ./pstatc.sh | sort” where nakhosts is a standard MPI-friedly list of hosts, and ~/bin/ has nvidia-smi (a little tool for handling nivida GPUs from the command line) exported to the nodes. Script attached here for perusal (and so I can find it later). Possibly the best part is that it made me referesh my memory on using ANSI Color Escapes, which has been on my list of skills to touch up for a while – That foray also lead to souping up the script Hank was working on to use background colored spaces for ghetto bargraphs to keep the displays in the windows of the machine room interesting until we are set up to drive them with something else. One of these days I really should learn to use ncurses, or at least get better with one of the GUI libraries…

    Posted in Computers, DIY, General, School | Tagged , , | Leave a comment

    RIP N810

    My N810 finally bit it yesterday – The touchscreen gave out earlier in the week, and after re-seating the ribbon connector (again), it rebooted with serious video artifacts/flicker/discoloration. When I opened it back up to try again, the connector literally fell off the end of the ribbon, taking out the display as well as touch. Ribbons are not solderable, and replacement screen modules are not available, so it has been rendered pretty much useless.

    I was looking at replacement options as soon as the touchscreen went out again, and the field is grim. What I want is a modern handheld-size *nix (preferably Linux) box with a qwerty keyboard, a “reasonable” (800×480 or better) screen of around 4″, an audio out compatible with normal 3.5mm connections, WiFi, and enough battery to make it through the day. Apparently I am alone in this desire. Searching kept bringing me to the list at pocketables, which has the majority of potentially suitable devices.
    Continue reading

    Posted in Computers, General, Objects | Tagged , | 2 Comments