Roll Out a Fedora Remix

3
11652

Learn how to remix Fedora with your choice of apps, and roll out an ISO for others to enjoy!

Background

To understand the idea of the Fedora Remix, use the Fedora time machine and take a peek into the past. From Fedora Core 1 to 6, Fedora had two repositories: Fedora Core, managed by Red Hat engineers and Fedora
Extras, an add-on community repository managed by volunteers.

Fedora Core was built internally by Red Hat, and packages would end up in the classic Fedora CD set or DVD. Fedora Extras was built using a public build system, and the packages were only available as part of the repository and not on the installation media.

Over a period of time, the Fedora Project realised that this structure was creating artificial walls in the project, preventing everyone from working together as a single community. The project broke that wall down and from Fedora 7 onwards, there was just one giant repository in a public build system growing faster, with more and more packages.

This success created a problem, however— one could not put every single package into the media because it would grow to more than a DVD could hold, and so the Fedora release engineering team still had to play favourites. This had the potential to ignite the classic Emacs vs Vim or GNOME vs KDE wars.

Picking the ‘right’ defaults in a community project is a tricky job, since everyone has their own strong ideas on what they like. To solve this in an elegant way, Fedora provided the tools to create Fedora variants called Fedora Spins, and gave the choice to participants in the community. Anyone interested could do their own Fedora release, and gather a community around their idea to use it and champion it. You could then think of Fedora releases as merely samples of what was possible.

Think of the Fedora Electronics Lab for instance. It has provided several different upstream projects a platform to work together, define a workflow, do integration testing, and it has also brought many people into Fedora and the free software world. This small but growing community of contributors with an interest in electronics now has an opportunity to use its expertise in a way that benefits a lot of people.

Spins and remixes

Fedora Spins are official Fedora releases targeted towards specific audiences. They are composed of pure packages from the official Fedora repository with no modifications. The Fedora Spins idea was widely popular, and over the last few releases after Fedora 7, Fedora has more than half a dozen spins at http://spins.fedoraproject.org that you can download and try. This includes Fedora Electronics Lab, Fedora Games Spin, Fedora LXDE, and many others. This was a grand success but there is more to it.

There were a lot of people interested in mixing third-party components or modifying existing Fedora packages in a way that met their needs, and to accommodate such interests, the project started discussing a secondary brand and I suggested the name, ‘Fedora Remix’, which was accepted by the project. A Fedora Remix is a combination of Fedora software, with or without third-party software that any community member can create at any time. You can use a Fedora Remix to:

*Target a specific hardware platform like a netbook, router, or other device.
*Provide an appropriate combination of software for a specific interest group, like artists, musicians, software developers,educators, craftsmen, et al.
*Demonstrate a layered product using the Fedora platform as the underlying operating system.
*Build a portable, bootable environment for a classroom.
*Offer promotional material to customers inside a fully customisable OS.
*Or any one of countless other applications…

You can read more at https://fedoraproject.org/wiki/Remix

The next step: Omega

Omega (http://omega.dgplug.org) is my own project to create a Fedora Remix that integrates Fedora and a few popular and compatible third-party repositories for Fedora, including RPM Fusion, Livna and Adobe, and all the initial Fedora updates. The goal is to provide a better out-of-the-box experience by integrating multimedia functionality from these popular third-party repositories and save bandwidth for users while providing a solid release. And all this, while being 100 per cent compatible with Fedora.

So not only do you get MP3, commercial DVDs, etc, working outof- the-box, you also get the bug fixes and features introduced by Fedora post-release. The Omega (Boxer) release is a Fedora Remix derived from Fedora 12 and all the recent updates, and is included in the LFY DVD as an ISO image this month! It is a Live DVD and I encourage you to try it out.

One very common question I’m asked is, “How did you do this and how do I go about creating my own Fedora Remix?”

The process is very simple and this article is a quick introduction to it. Let me start with a basic introduction to the tools of the trade.

*Anaconda: This is the Fedora installer and during interactive mode, it asks a few questions. Anaconda creates a file by default called anaconda-ks.cfg in the /root/ of every Fedora installation saving the input from the user and has a record of details such as the language, time zone, packages selected, etc, that enables the user to create a perfect replica of the same set-up across as many systems as the user wants. This is called a kickstart file. It basically provides the answers to the questions that Anaconda asks, and it is very powerful and flexible. Fedora provides the tools to create a Fedora Spin or Fedora Remix and with these tools, you can create images based on your preferences using the same kickstart files.

*Pungi: As part of the Fedora 7 release, Fedora’s primary release engineer, Jesse Keating, wrote Pungi to create the official Fedora installation images (CD set and DVD). Pungi is available in the Fedora repository itself, including the kickstart files used to generate the images.

*livecd-creator: Part of the livecd-tools package, this is a tool to create a Live CD or DVD. You can also use the cross-platform Fedora Live USB creator or livecd-iso-to-disk, which is part of the same package in Fedora, to create a Live USB key as well. In Fedora 12 or any Fedora Remix derived from Fedora 12, you can simply use dd to do things quickly!

*Revisor: It is a powerful graphical tool that encompasses the functionality of both Pungi and livecd-creator. It provides a simple point-and-click interface.

*fedora-kickstarts: This is a package that includes a collection of kickstart files used by the Fedora Project’s official releases, including the Fedora Spins available for download at http://spins.fedoraproject.org.

*generic-logos: This package provides non-branded equivalents to the fedora-logos package to enable anyone to rebrand the Fedora distribution and release it under any name they want!

Omega

Omega is a Live DVD that is derived from the official Fedora Desktop Live CD. To recreate something similar to it in Fedora 12, use the following code in your home directory:

[rahul@localhost ~]$ mkdir remix
[rahul@localhost remix]$ cd remix

Now, download the kickstart files for the Fedora Spins:

[rahul@localhost remix]$ su -c ‘yum install fedora-kickstarts’

Set SELinux in permissive mode:

[rahul@localhost remix]$ su -c ‘setenforce 0’

Copy two kickstart files to the current directory:

[rahul@localhost remix]$ cp /usr/share/spin-kickstarts/fedora-live-base.ks 
/usr/share/spin-kickstarts/fedora-livecd-desktop.ks .

Open fedora-livecd-desktop.ks file in your favourite text editor and add any packages under the %packages section. @ in front of the package name denotes a package group. To list all groups, you can use the command given below:

[rahul@localhost remix]$ yum -v grouplist

A – (minus) in front of a package indicates that it should be removed from the image unless it is a dependency of another package. Once you have the packages and package groups you wanted added, you must also rebrand the distribution. This is trivial. Just add the following to the kickstart file you have opened.

# rebranding
-fedora-logos
-fedora-release
-fedora-release-notes
generic-release
generic-logos
generic-release-notes

In the %post section of the kickstart file, add the following as the first line:

sed -i -e ‘s/Generic release/LFY Fedora Remix/g’ /etc/fedora-release /etc/issue

Save the kickstart file as lfy-fedora-remix.ks. You have now successfully rebranded the distribution! Just run the following command as the root user:

[root@localhost remix]# livecd-creator --config=lfy-fedora-remix.ks 
--cache=cache --fslabel=lfy-remix

The cache option indicates the download directory of the RPM packages needed to compose the Live image, and fslabel indicates the filesystem label/name of the remix. That’s it!

You can download the Omega kickstart file from http://omega.dgplug.org if you would like to explore more. That should be sufficient for you to create your own distribution! Hope you enjoy the world of Fedora Remixes.

3 COMMENTS

  1. I don’t understand the rebranding part. Using those lines, I won’t use the fedora naming and logo, that’s alright. But instead, how can I embed my logo, splashscreen, login screen naming etc.?

  2. Thanks Rahul for this howto that helped me to do my remix of Fedora 23 and 25.
    Please find some additional info below :
    – When using sed to update /etc/fedora-release, the word “release” must be kept because the release name of the remix is everything before this word; and the release version is the last number preceeded with a space (this is what I can see by having a look to the code installed by anaconda-core).
    If not following that, liveinst fails to install the live image to disk when using the default LVM partitioning (unexpected error popup); however it works with custom standard partitions instead of LVM.
    Seen with Fedora 23 and Fedora 25 with latest anaconda update.
    Example of a working /etc/fedora-release content ; “LFY release 1234 (Fedora-25 Remix)”; release name is “LFY” and release version is “1234” (not 25 because there’s a “-” before 25, not a space)
    – The /etc/issue.net should also be updated
    – Also to have “LFY” and “1234” in the name of GRUB entries after install, the /etc/os-release should also be updated, for example :
    NAME=LFY
    VERSION=”1234 (Fedora-25 Remix)”
    ID=lfy
    VERSION_ID=1234
    PRETTY_NAME=”LFY 1234 (Fedora-25 Remix)”
    ANSI_COLOR=”0;34″
    CPE_NAME=”cpe:/o:mycompanyname:lfy:1234″
    – And to be coherent with the other files, the /etc/system-release-cpe should have :
    cpe:/o:mycompanyname:lfy:1234

    • For liveinst failing to install with LVM partitioning, it turns out that logical volumes are named using the release name followed by -root and -swap, so if not following the recommendations above the release name contains unsupported characters for a logical volume name (space, …) and then the install fails.

LEAVE A REPLY

Please enter your comment!
Please enter your name here