DDD #3: Advanced Live-CD/DVD creation

In post 19 (Creating an Arch Live-CD) I blogged about building a simple Live-CD on Arch Linux. It was the summary of my first attempts relating to that topic. In the meantime I created another ISO and published it as a first preview of my “Desktop Demo DVD” project in post 21 (The Desktop Demo DVD).

This new entry will describe how my “DDD” was built (and thus how you add things like a graphical login manager and add users to a live medium).

Preparations

First I create a new virtual machine to keep things clean and tidy and then build and install the archiso tool. Next is building AUR packages edelib and ede as well as creating a custom repo for them. (I won’t repeat it in detail here. You can look up both things in post #19 if you wish).

Configuring archiso

Just like in my previous building attempt, it’s necessary to create a new directory and copy over the “releng” dir from archiso. After that the various steps at configuring the iso can be taken.

Packages

The first thing to do is adding the right packages to the file packages.i686. Since we want a graphical environment, it’s a good idea to have xorg-server installed (we’re going to use a graphical login manager this time, so we can do without xorg-xinit).

Since the system is meant to run on about every hardware, X11 needs the proper graphic drivers. You may want to look for all xf86-video-* packages and add them. The only issue with that was that the openchrome and unichrome drivers were conflicting, but later (and older) one has been removed from the “extra” repository recently. Whatever you do, be sure to leave xf86-video-vesa in there – that’s the fallback driver that will work on most machines even if none of the others does (which is pretty rare however). Also it might be a good idea to add xf86-input-evdev just to make sure, you can use e.g. your keyboard in X. Adding virtualbox-guest-modules, too, will let X.org use the appropriate driver if running inside a VirtualBox VM.

Next I added the desktop environments that I wanted to be available. I chose mate (remember to add the additional repos for it and ede!), xfce4, lxde and e-svn as well as libxpm (needed by ede) and the packages edelib and ede. Finally the display manager lxdm is added as well.

Display manager

Thanks to systemd, much of the wiki page about archiso is outdated and no longer of any use. This is the case e.g. when it comes to starting the display manager automatically after booting. It suggests using an inittab and we could actually do so and use a sysVinit compatibility package as well. However it was already announced that this would be dropped in the forseeable future so it’s best to do things the proper way right from the beginning.

LXDM comes with its own service file for usage with systemd. So the default command to configure the system for starting it after booting is systemctl enable lxdm.service. However this will of course not work in our case: First we don’t even have LXDM installed on building system and second – even if we had – enabling it there would not affect the live system. However for that reason there’s a folder called root image where we can make changes that will affect it!

So what does the above command really do? No more actually than creating a softlink! Of course we can do that by hand, too. Let’s change our PWD (present working directory) to /root/archlive/releng/root-image/etc/systemd/system. Now let’s create the proper link, shall we? The command for that is ln -s /usr/lib/systemd/system/lxdm.service display-manager.service.

Next step is creating a new directory (that is normally created when LXDM is installed): mkdir ../../lxdm and then I change into that dir. Afterwards I install lxdm on my build system and copy its configuration file into the new dir: cp /etc/lxdm/lxdm.conf . (if you’ve got LXDM installed on any other system, you can of course also copy it from there). Now it’s time to edit lxdm.conf: I simply add user “arch” to the blacklist (right at the end of the default configuration file). It’s a user automatically created by the install scripts and I have not yet looked into how to prevent its creation. For that reason I decided to just block it there so that it’s not offered by LXDM.

Adding a user

This step is important since we disabled the user “arch” and cannot log in as “root”. The solution suggested for this on the Arch wiki is simply copying over the files passwd, shadow and group (all located in /etc) from a system set up the way we want it. This is actually a fine way and since we’re using virtual machines anyway, it does not hurt to simply clone one, adding the desired user (“desktopdemodvd” in my case) there and copying said files over to root-img/etc on our building VM (using a USB device is probably the most confortable way).

That was the easy part. Many DEs will however not work if there’s no proper /home/$username directory present. We could of course create one in root-image/home, but that would be owned by root on our live system so that’s not quite what we want. Again the wiki is outdated (while I’m at it anyway, I should dedicate some love to it when I’m done here, I guess). We want to do things the systemd way! So how to do it in this case? Let’s write a new service for it (woah)!

Luckily things are easier than it might look first. Ok, I admit that it took me a few attempts before things finally worked right. But you can save yourself some time and simply copy what I did. Change into the dir root-img/etc/systemd/system again. Now create a new service file – I called mine “autostart.service”. The content of my file is like this:

[Unit]
Description=Autostart

[Service]
Type=oneshot
ExecStart=/bin/mkdir /home/desktopdemodvd
ExecStart=/bin/chown desktopdemodvd /home/desktopdemodvd

[Install]
WantedBy=multi-user.target

Note: “ExecStart=/bin/chown desktopdemodvd /home/desktopdemodvd” is one line!

Done configuring

Yes, if I remember correctly, that was all. You should be able to build the iso now.

I don’t know if I did any changes beside these, but this blog entry at least shows two important things: Adding users and using a graphical login manager.

There are of course a lot of things you could customize as well and perhaps I’m going to explore some of these in the future, too. But right now I’m going to wait and see what happens with the “DDD”.

What’s next?

My next post will deal with what should be considered essential graphical applications – and afterwards we’re getting back into the world of toolkits.

DDD #2: The “Desktop Demo DVD”!

In the last entry I discussed the situation of Linux desktop environments in general and how it encourages taking various less-known DEs into account for your system, too. Now it’s time to talk about the first alpha version of the actual DDD!

If you just want to download it, have a look here.

The idea behind the DDD

There are four reasons why I decided to create the “DDD”:

  1. Because I found out that there are many Linux users today who would like to know more about alternative DEs
  2. Because I think the less known DEs deserve some publicity
  3. Not every DE can be installed easily on each distro and thus it can take a lot of time and effort to try them out
  4. Because I’m interested in different DEs and building “DDD” is another informative thing

The version I release today is just a little preview. But before I describe what 0.1 includes right now, I’d like to share my vision of what DDD 1.0 should be.

Vision

  • A perfect Desktop Demo DVD should come with all available desktop environments the Linux world has to offer.
  • If possible it should also showcase some default applications of the particular DE which are not in the menus of the other ones so things don’t get confusing.
    (I think that this can be done with the desktop files or probably by other means.)
  • Localization at least for the most common languages.
    (Better: As much languages supported as possible.)
  • Only list the real DEs in the display manager (and not probably confusing variants with different WMs).
  • A short html tutorial which helps the users to discover the most important features of the various DEs could be very beneficial.
  • Some nice artwork would be great, too.
  • A few other “cosmetics”.

Desktop Demo DVD

This project is to provide an ISO file that can be downloaded and used in either a virtual machine or burned to a disk and then used with real hardware. It is meant to showcase the various DEs that work with Linux and thus give anybody interested the oportunity to quickly take a look at them without all the hassle (i.e. finding out that they even exist, often building them yourself, getting them to run on your distro, etc.).

You can download version 0.1 of it from Bitshare.

If you want to check the integrity of the downloaded file, you can just put this into a new file and use md5sum:

f9d57debb8d83cba46f4dada042133a5 desktop_demo_dvd_0.1.iso

As you would guess when you read the version number, this release is mearly a first attempt. Right now it fits on a CD but that’s going to change. I’ll try to improve DDD if I find time for it and then release a second version.

Currently it provides a graphical login (using lxdm) and comes with as much as 5 DEs:

  • MATE
  • Xfce
  • LXDE
  • Enlightenment 17
  • Equinox DE

Using the DDD

If all goes well you should be greeted by the graphical login manager LXDM after startup. First open the list of available desktop environments (if you don’t change anything, LXDE will be started as default). To do so, click on the list to open it.

Graphical login: First step

Now select which one to start and then click on the user “desktopdemodvd”.

Graphical login: Second step

The password for the primary user desktopdemodvd is simply ddd. Enter it and then press the return key.

Graphical login: Last step

That’s it! The DE you selected from the list should be starting.

Issues with version 0.1

There are a few issues I didn’t find a solution for yet, but I didn’t want to postpone things again for an even longer delay. Probably the worst thing is performance: Even when using the ISO in a virtual machine on a fast PC it takes quite a while until the DEs finish loading. Please be patient. Because of that I can’t recommend burning it and using a disk. Also for some reason loging out of E-17 does not work.

Please report other problems, make suggestions and give feedback of any kind. I’d very much appreciate it!

What’s next?

I can’t promise when (or if!) a new DDD version will be released. The next post will be about the technical side of it and describe how to build an extended Arch live-cd including users other than root and with a graphical login (display manager).

DDD #1: Situation of the Linux Desktop

It took me a bit longer to write this post (and when I finally did, I forgot to post it to the public). Sorry for that. But now it’s here – and like I promised, it’s introducing a new EERIE subproject!

Situation of the Linux Desktop

No, I don’t want to predict when the “final breakthrough” will happen nor do I care much for current market shares. And no, I’m also not going to repeat what Linus said about this topic – we all know it and if somebody really doesn’t, it’s easy to find out.

To be precise: I don’t mean the situation of the Linux Desktop at all but rather that of the Linux desktop. So – what’s noteworthy here? Well, I can’t put it better than a headline I read in a German magazine quite a while ago: “the desktop is fragmenting / splintering”!

Major desktop environments

Over the years many people have complained that Linux is not “successful” because there’s no standard desktop. There may or may not be something to this claim. The important thing is that it was raised in a time when there were essentially two big DEs which had such a high user base that other desktop environments were only playing underparts. Those two were KDE and GNOME.

Things have changed since then and ironically not in the direction that one of them established itself as the clear “winner”. What happened in fact is more like the contrary…

Forks

First KDE Plasma was released and left a lot of people perplexed. Some didn’t like the new style. Others found the system requirements to be ridiculously high (at that time). People who had used KDE for years were not happy with the direction Plasma was taking and were looking for alternatives. Some changed their default DE, some wanted to go on with KDE 3. Efforts of the later resulted in a new project: Trinity DE!

The other big desktop environment followed the same path; the idea was to modernize things. Some people liked the new GNOME 3, many others hated it (that word is not an exaggeration). The results? Same thing: Some former GNOME users were unhappy and switched their default DE and a few others decided to go on with GNOME 2’s codebase – and thus MATE was born.

Upward climbers

Of course this way DEs that were previously more or less underdogs were getting more and more popular. This is especially the case with Xfce which has been around for quite some time but has attracted many former GNOME 2 users since the release of GNOME 3. Another winner is surely the rather young LXDE: Anybody interested in Linux has at least heard of this light-weight DE today.

Other than that there are more noteworthy players now. First, there’s Unity. It’s one more modern DE that benefits greatly from nowadays being the standard desktop of the extremely popular distro Ubuntu. Another one is Enlightenment which already has a formidable user-base.

Outsiders

Apart from the DEs previously mentioned, new readers of my blog may be surprised just how many other desktop environments there are out there (I’ve blogged about them). Are those inferior to the more popular ones? Hell no!

The biggest problem with them is just that they are not well-known! However there are other problems as well. Many distros (especially the smaller ones) do not offer packages for these. Getting them to run on your distribution can be rather tricky and take some time and effort. In case of novice users it can also prove to be a barrier hard to cross.

The solution

Luckily many DEs offer Live-CDs so that you can easily take a look at them. But having to download multiple ISOs for that reason is also an unnecessary inconvenience. What about a single DVD image that comes with all Linux desktop environments?

This way each of them can be tested easily! It also has the advantages that you won’t miss some less-known DE and that you can compare them directly.

For those reasons I’d like to introduce project “DDD” which stands for “Desktop Demo DVD“!

What’s next?

I’ve already prepared the ISO for the DDD version 0.1. Expect it to be available during the next days!