Rootless
From GoboLinux Knowledge Base
|
Concepts Installing
Managing software Configuring Other topics |
GoboLinux Rootless (usually called just Rootless) is a way to use the Gobo package management tools on top of another host system. Rootless does not require root access to the host system. The host system can be a non-Gobo Linux distribution. It is a long term, low priority goal to support non-Linux host systems such as the BSDs, OS X, and even MS Windows, but at present support for these systems should be considered experimental at best.
Contents |
[edit] Reasons to use Rootless
- You want to easily and cleanly compile and install programs from source, and...
- You do not have root access to the host system, or...
- You do not want to risk breaking the host system, or...
- You want to install multiple versions of the same program at the same time, or...
- You happen to want to use Gobo's tools for some other reason.
Root based packages managers can and do break systems. As Rootless does not require root access, it is therefore powerless to affect the host system as a whole and cannot break it.
[edit] Requirements
All platforms require:
- GNU Bash
- GNU Coreutil
- GNU Sed
- GNU Wget
- bzip2
- Python
-
- including Python's bz2 module
Non-i686 platforms also require:
- GNU GCC
(Non-i686 users: See platform specific notes below.)
[edit] Installation
$ cd $HOME $ wget http://svn.gobolinux.org/tools/trunk/Scripts/bin/CreateRootlessEnvironment $ chmod u+x CreateRootlessEnvironment $ ./CreateRootlessEnvironment $ ./Programs/Rootless/Current/bin/StartRootless $ InstallPackage Compile $ Compile MTail
Note that nothing other than Scripts and Compile should be installed using InstallPackage: packages will not be binary-compatible. If you're asked to fulfill dependencies when installing a package, you should choose to skip them all, and install them using Compile.
[edit] Tricks and traps
InstallPackage should not be used for anything but Scripts and Compile. Packages are not binary-compatible.
Glibc and other operating system-level programs should not be installed in Rootless.
Header files and libraries from the host system can and do confuse Rootless. Rootless tries to tell all the tools in the GNU toolchain to ignore these host files, but this does not always work in practice. This can cause nasty and frustrating problems.
For example, consider Compiling emacs (or any program that uses ncurses) in Rootless on Debian. Emacs' ./configure script will find the debian version of the ncurses libraries and use them. Installing a second copy of Ncurses inside of Rootless will not help, because ./configure will find Debian's ncurses first and always use it, ignoring the Rootless installed files. Additionally, it is not practical to remove the Debian version of ncurses, as many core parts of the system depend on the Debian provided version of ncurses.
There are two solutions to this problem, and both potentially require root access on the host system. The two solutions are discussed in the following two sections.
[edit] Rootless on specific platforms
The first solution is to always use the host systems versions of any libraries that are present, and to refrain from installing redundant copies inside of Rootless. This may or may not be practical. Refer to the platform specific pages listed below for details on specific platforms.
[edit] Rootless in a chroot jail
The second solution is to bootstrap Rootless into a "chroot" jail. This will completely isolate Rootless (at the filesystem level) from the host system's filesystem. Setting up "chroot" jails is complicated, and bootstrapping into them is even more complicated. This solution is only mentioned here too let advanced and adventuresome users know that it is possible, and that doing it is fairly straightforward if you already have a fairly thorough understanding all the fairly advanced concepts involved, such as: chroot, suid bits, GCC spec files, /proc filesystems, etc. (Perhaps someday a more complete Howto guide will be written.)
[edit] Files
The rootless system creates the following directories.
Programs/
.Settings/
Files/
System/
| Rootless | |
| Platforms | |


