Difference between revisions of "HOWTO: Install from an existing Linux system"

From Sabayon Wiki
Jump to: navigation, search
 
(Codeblocks!)
(18 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{i18n| [[HOWTO: Install from an existing Linux system|en]] [[Tr:HOWTO: Install from an existing Linux system|tr]]}}
+
{{i18n| [[De:HOWTO: Install from an existing Linux system|de]] [[HOWTO: Install from an existing Linux system|en]] [[Tr:HOWTO: Install from an existing Linux system|tr]]}}
 
+
  
 
;Overview
 
;Overview
Line 6: Line 5:
 
This HOWTO brings the gentoo installation method (as in the Handbook) to Sabayon.
 
This HOWTO brings the gentoo installation method (as in the Handbook) to Sabayon.
  
Please note that "an existing Linux system" can be either an installed system (then you cannot use that partition for sabayon) or just a livecd.
+
Please note that "an existing Linux system" can be either an installed system (then you cannot use that partition for sabayon), or a live linux system.
 
+
I would recommend using the official Gentoo livecd if you're going that way.
+
    <Me>  | But then, why bother doing this instead of just burn a Sabayon install media?
+
    <You> | For the fun.
+
    <Me>  | Fair enough :)
+
 
+
The first part is about installing a very basic gentoo system in a chrooted partition; in the second part we will use <tt>portage</tt> to install <tt>entropy</tt> and <tt>equo</tt>. Finally we will use <tt>equo</tt> to install a full sabayon system in the third and last part.
+
  
 +
The first part is about installing a very basic gentoo system in a chrooted partition; in the second part we will use <tt>portage</tt> to install <tt>entropy</tt> and <tt>equo</tt>. We will then use <tt>equo</tt> to install a full sabayon system in the third and last part.
  
==Part 1: Gentoo install==
+
== Part 1: Gentoo install ==
  
 
;Please refer to http://www.gentoo.org/doc/en/gentoo-x86-quickinstall.xml and http://www.gentoo.org/doc/en/handbook/index.xml for more in-depth details about gentoo installation.
 
;Please refer to http://www.gentoo.org/doc/en/gentoo-x86-quickinstall.xml and http://www.gentoo.org/doc/en/handbook/index.xml for more in-depth details about gentoo installation.
  
===Partitioning===
+
=== Partitioning ===
  
 
Do your thing and partition your disk(s). You need at least a root partition (/).
 
Do your thing and partition your disk(s). You need at least a root partition (/).
Line 30: Line 23:
 
Also if you have a <tt>/var</tt>, <tt>/boot</tt>, <tt>/usr</tt>, <tt>/home</tt> ... filesystems, create the mountpoints relative to /mnt/sabayon and mount them now.
 
Also if you have a <tt>/var</tt>, <tt>/boot</tt>, <tt>/usr</tt>, <tt>/home</tt> ... filesystems, create the mountpoints relative to /mnt/sabayon and mount them now.
  
===Get Gentoo installation files===
+
=== Get Gentoo installation files ===
  
 
We will assume an x86_64 architecture here. If you're on x86 (32 bits), change "amd64" with "x86".
 
We will assume an x86_64 architecture here. If you're on x86 (32 bits), change "amd64" with "x86".
  
    export ARCH="amd64"
+
{{Console|<pre class="clear">export ARCH="amd64"</pre>}}
  
 
Pick up a mirror near you from this list: http://www.gentoo.org/main/en/mirrors.xml
 
Pick up a mirror near you from this list: http://www.gentoo.org/main/en/mirrors.xml
  
    export MIRROR="ftp://distfiles.gentoo.org/pub/gentoo"
+
{{Console|<pre class="clear">export MIRROR="ftp://distfiles.gentoo.org/pub/gentoo"</pre>}}
  
 
We will refer to your arch as <tt>$ARCH</tt> and to your chosen mirror as <tt>$MIRROR</tt> from now on.
 
We will refer to your arch as <tt>$ARCH</tt> and to your chosen mirror as <tt>$MIRROR</tt> from now on.
  
====Download and verify stage3 archive====
+
==== Download and verify stage3 archive ====
  
    wget -r $MIRROR/releases/$ARCH/current-stage3/
+
{{Console|<pre class="clear">
    cat stage3-$ARCH-*.tar.bz2.DIGESTS && md5sum stage3-$ARCH-*.tar.bz2 && sha1sum stage3-$ARCH-*.tar.bz2
+
wget -r $MIRROR/releases/$ARCH/current-stage3/
 +
cat stage3-$ARCH-*.tar.bz2.DIGESTS && md5sum stage3-$ARCH-*.tar.bz2 && sha1sum stage3-$ARCH-*.tar.bz2
 +
</pre>}}
  
====Download and verify portage snapshot====
+
==== Download and verify portage snapshot ====
  
    wget $MIRROR/snapshots/portage-latest.tar.bz2
+
{{Console|<pre class="clear">
    wget $MIRROR/snapshots/portage-latest.tar.bz2.md5sum
+
wget $MIRROR/snapshots/portage-latest.tar.bz2
    cat portage-latest.tar.bz2.DIGESTS && md5sum portage-latest.tar.bz2 && sha1sum portage-latest.tar.bz2
+
wget $MIRROR/snapshots/portage-latest.tar.bz2.md5sum
 +
cat portage-latest.tar.bz2.DIGESTS && md5sum portage-latest.tar.bz2 && sha1sum portage-latest.tar.bz2
 +
</pre>}}
  
===Unpack stage3 and portage===
+
=== Unpack stage3 and portage ===
  
    tar xfpj stage3-$ARCH-*.tar.bz2 -C /mnt/sabayon
+
{{Console|<pre class="clear">
    tar xfpj portage-latest.tar.bz2 -C /mnt/sabayon/usr
+
tar xfpj stage3-$ARCH-*.tar.bz2 -C /mnt/sabayon
 +
tar xfpj portage-latest.tar.bz2 -C /mnt/sabayon/usr
 +
</pre>}}
  
 
Note the <tt>p</tt> option: it's for preserving file permissions and it's very important!
 
Note the <tt>p</tt> option: it's for preserving file permissions and it's very important!
  
===Chroot into your new Gentoo===
+
=== Chroot into your new Gentoo ===
  
 
Everything that follows is done while in <tt>/mnt/sabayon</tt>:
 
Everything that follows is done while in <tt>/mnt/sabayon</tt>:
  
    cd /mnt/sabayon
+
{{Console|<pre class="clear">cd /mnt/sabayon</pre>}}
  
====Mounting filesystems====
+
==== Mounting filesystems ====
  
    mount -o bind /dev ./dev
+
{{Console|<pre class="clear">
    mount -t devpts none ./dev/pts
+
mount -o bind /dev ./dev
    mount -t tmpfs none ./dev/shm
+
mount -t devpts none ./dev/pts
    mount -t proc none ./proc
+
mount -t tmpfs none ./dev/shm
    mount -t sysfs none ./sys
+
mount -t proc none ./proc
 +
mount -t sysfs none ./sys
 +
</pre>}}
  
====Copying <tt>/etc/resolv.conf</tt>====
+
==== Copying <tt>/etc/resolv.conf</tt> ====
  
    cp /etc/resolv.conf ./etc
+
{{Console|<pre class="clear">cp /etc/resolv.conf ./etc</pre>}}
  
====Chroot!====
+
==== Chroot! ====
  
    chroot /mnt/sabayon /bin/bash
+
{{Console|<pre class="clear">chroot /mnt/sabayon /bin/bash</pre>}}
  
 
Now you are on your Gentoo chroot!
 
Now you are on your Gentoo chroot!
  
====Configure environnment====
+
==== Configure environnment ====
    export LANG=en_US
+
    export LANGUAGE=${LANG}
+
    export LC_ALL=${LANG}.UTF-8
+
    env-update
+
    eselect python set 1    #sets python 2.7 as default
+
    source /etc/profile
+
  
====Some early configuration====
+
{{Console|<pre class="clear">
 +
export LANG=en_US
 +
export LANGUAGE=${LANG}
 +
export LC_ALL=${LANG}.UTF-8
 +
env-update
 +
eselect python set 1    #sets python 2.7 as default
 +
source /etc/profile
 +
</pre>}}
  
=====Set up a root password=====
+
==== Some early configuration ====
 +
 
 +
===== Set up a root password =====
 
      
 
      
 
As I '''regulary''' forget to setup the root password, let's do that as first thing:
 
As I '''regulary''' forget to setup the root password, let's do that as first thing:
  
    passwd
+
{{Console|<pre class="clear">passwd</pre>}}
  
=====Timezone=====
+
===== Timezone =====
       
+
 
    cd /etc/
+
{{Console|<pre class="clear">       
    ln -sf ../usr/share/zoneinfo/<REGION>/<City> localtime
+
cd /etc/
 +
ln -sf ../usr/share/zoneinfo/<REGION>/<City> localtime
 +
</pre>}}
  
 
Where <REGION> is your region and <City> the nearest big city.
 
Where <REGION> is your region and <City> the nearest big city.
  
=====Hostname=====
+
===== Hostname =====
 
      
 
      
Don't be lame and change "localhost" to something else. Update <tt>/etc/hosts</tt> accordingly.
+
Be original and change "localhost" to something else. Update <tt>/etc/hosts</tt> accordingly.
  
    nano -w /etc/conf.d/hostname
+
{{Console|<pre class="clear">
    nano -w /etc/hosts
+
nano -w /etc/conf.d/hostname
 +
nano -w /etc/hosts
 +
</pre>}}
  
=====Mount points=====
+
===== Mount points =====
  
    nano -w /etc/fstab
+
{{Console|<pre class="clear">nano -w /etc/fstab</pre>}}
  
 +
== Part 2: Sabayon overlay setup and installation of <tt>entropy</tt>+<tt>equo</tt> ==
  
==Part 2: Sabayon overlay setup and installation of <tt>entropy</tt>+<tt>equo</tt>==
+
=== Layman ===
 
+
===Layman===
+
  
 
<tt>layman</tt> is a gentoo tool to manage portage overlays. We will use it to get our hands on the sabayon overlay.
 
<tt>layman</tt> is a gentoo tool to manage portage overlays. We will use it to get our hands on the sabayon overlay.
 +
Update: entropy and equo are in regular portage, so you can skip this step.
  
  emerge --sync     # make sure portage is fully up to date
+
{{Console|<pre class="clear">
  USE="git" emerge -avt layman
+
# emerge --sync               # make sure portage is fully up to date... or not. Up to you. portage snapshots are done daily, i see no need to sync.
  layman -S
+
# USE="git" emerge -avt layman # now equo is in regular portage!
  layman -a sabayon
+
# layman -a sabayon           # see above
 +
</pre>}}
  
===Entropy and Equo===
+
=== Entropy and Equo ===
  
  emerge -avt equo --autounmask-write
+
{{Console|<pre class="clear">
  etc-update
+
emerge -avt equo --autounmask-write
  emerge -avt equo
+
etc-update
 +
emerge -avt equo
 +
</pre>}}
  
Now we have <tt>entropy</tt> and <tt>equo</tt> installed. To make use of it, we should first generate the entropy database (only the very first time!):
+
Now we have <tt>entropy</tt> and <tt>equo</tt> installed. To make use of it, we should first generate the entropy database ('''only the very first time!'''):
  
    equo rescue generate
+
{{Console|<pre class="clear">equo rescue generate</pre>}}
  
 
Yes, you are sure about this. You should answer yes three times to make it happy.
 
Yes, you are sure about this. You should answer yes three times to make it happy.
  
Perfect. Now we need to setup sabayon repositories:
+
Perfect. Now we need to setup sabayon repositories. As an example, we use '''sabayonlinux.org''' (i.e. updated daily), but you can use '''sabayon-weekly''' instead if you want to upgrade less often. See [[En:Entropy#Package_Repositories]].
  
    cd /etc/entropy/repositories.conf.d
+
{{Console|<pre class="clear">
    cp entropy_sabayonlinux.org.example entropy_sabayonlinux.org
+
cd /etc/entropy/repositories.conf.d
    cd -
+
cp entropy_sabayonlinux.org.example entropy_sabayonlinux.org
 +
cd -
 +
</pre>}}
  
Let's use <tt>equo</tt> to populate the repo db:
+
Let's use <tt>equo</tt> to populate the repo db (if you used sabayon-weekly, substitute "sabayonlinux.org" with sabayon-weekly here):
   
+
 
    equo update
+
{{Console|<pre class="clear">   
    equo repo mirrorsort sabayonlinux.org
+
equo update
 +
equo repo mirrorsort sabayonlinux.org
 +
</pre>}}
  
 
We're set! <tt>equo</tt> is now in a working state!
 
We're set! <tt>equo</tt> is now in a working state!
  
===Entropy: the missing bits===
+
=== Optional: Entropy: the missing bits ===
  
When you install entropy you'll miss some vital portage bits, namely the /etc/make.conf and /etc/portage/* files used to build the sabayon packages.
+
'''Notice: if you are planning to exclusively use entropy, you can happily skip to [[HOWTO:_Install_from_an_existing_Linux_system#Part_3:_Finish_installation_using_equo|Part 3: Finish installation using equo]]'''.
 +
 
 +
----
 +
 
 +
So you will be using portage and/or want to have the same portage settings used to build your sabayon packages? Very well, here's how!
 +
 
 +
When you install entropy you'll miss some vital portage bits, namely the /etc/portage/* files used to build the sabayon packages.
  
 
Hopefully you can find those here: https://git.sabayon.org/build.git/
 
Hopefully you can find those here: https://git.sabayon.org/build.git/
Line 163: Line 184:
 
Let's make use of them!
 
Let's make use of them!
  
    # fetch the bits!
+
{{Console|<pre class="clear">
    cd /opt
+
# fetch the bits!
    git clone git://git.sabayon.org/projects/build.git sabayon-build
+
cd /opt
    cd /opt/sabayon-build/conf/intel/portage
+
git clone git://git.sabayon.org/projects/build.git sabayon-build
    # keep your specific stuff in "myconf" branch:
+
cd /opt/sabayon-build/conf/intel/portage
    git checkout -b myconf
+
# keep your specific stuff in "myconf" branch:
    # symlink to your <arch>:
+
git checkout -b myconf
    ln -sf make.conf.amd64 make.conf
+
# symlink to your <arch>:
    ln -sf package.env.amd64 package.env
+
ln -sf make.conf.amd64 make.conf
    # add & commit
+
ln -sf package.env.amd64 package.env
    git add make.conf package.env
+
# add & commit
    git config --global user.name "Your Name"
+
git add make.conf package.env
    git config --global user.email "your@email"
+
git config --global user.name "Your Name"
    git commit
+
git config --global user.email "your@email"
    # rename the gentoo /etc/make.conf and /etc/portage/:
+
git commit
    cd /etc/
+
# rename the gentoo /etc/make.conf and /etc/portage/:
    mv portage portage-gentoo
+
cd /etc/
    mv make.conf make.conf-gentoo
+
mv portage portage-gentoo
    # symlink to sabayon /etc/make.conf /etc/portage/:
+
mv make.conf make.conf-gentoo
    ln -sf /opt/sabayon-build/conf/intel/portage portage
+
# symlink to sabayon /etc/make.conf /etc/portage/:
    ln -sf portage/make.conf make.conf   
+
ln -sf /opt/sabayon-build/conf/intel/portage portage
 +
</pre>}}
 +
 
 
Of course, change <tt>make.conf.amd64</tt> and <tt>package.env.amd64</tt> to <tt>make.conf.x86</tt> and <tt>package.env.x86</tt> if you are not on x86_64.
 
Of course, change <tt>make.conf.amd64</tt> and <tt>package.env.amd64</tt> to <tt>make.conf.x86</tt> and <tt>package.env.x86</tt> if you are not on x86_64.
  
Line 194: Line 217:
 
i.e. you want ruby support for <tt>app-editors/vim</tt>:
 
i.e. you want ruby support for <tt>app-editors/vim</tt>:
  
    cd /etc/portage
+
{{Console|<pre class="clear">
    sed -i package.use -e "s,app-editors/vim vim-pager,app-editors/vim vim-pager ruby" # or just use VIM!
+
cd /etc/portage
    git add package.use
+
sed -i package.use -e "s,app-editors/vim vim-pager,app-editors/vim vim-pager ruby" # or just use VIM!
    git commit -m "app-editors/vim +ruby"
+
git add package.use
    cd /etc/entropy/packages
+
git commit -m "app-editors/vim +ruby"
    echo "app-editors/vim" >> package.mask
+
cd /etc/entropy/packages
 +
echo "app-editors/vim" >> package.mask
 +
</pre>}}
  
==Part 3: Finish installation using <tt>equo</tt>==
+
== Part 3: Finish installation using <tt>equo</tt> ==
  
===eix===
+
=== eix ===
  
 
To make your life easier, let's install <tt>eix</tt> (a tool for portage searching) and also the sabayon-distribution overlay (i.e. the <tt>entropy</tt> packages as a portage overlay):
 
To make your life easier, let's install <tt>eix</tt> (a tool for portage searching) and also the sabayon-distribution overlay (i.e. the <tt>entropy</tt> packages as a portage overlay):
  
    equo install eix
+
{{Console|<pre class="clear">
    layman -a sabayon-distro
+
equo install eix
    cd /etc/portage
+
layman -a sabayon-distro
    echo "source /var/lib/layman/make.conf" >> make.conf
+
cd /etc/portage
    git commit -m "source layman/make.conf in /etc/make.conf"
+
echo "source /var/lib/layman/make.conf" >> make.conf
    eix-sync
+
git commit -m "source layman/make.conf in /etc/make.conf"
 +
eix-sync
 +
</pre>}}
  
 
Now you can use <tt>eix</tt> to quickly search for installed/installable/upgradable packages and see their versions and use flags.
 
Now you can use <tt>eix</tt> to quickly search for installed/installable/upgradable packages and see their versions and use flags.
  
===Filesystem progs===
+
=== Filesystem progs ===
  
 
From gentoo quickinstall, code listing 2.27:
 
From gentoo quickinstall, code listing 2.27:
  
    equo install xfsprogs # (if you use the XFS file system)
+
{{Console|<pre class="clear">
    equo install jfsutils # (if you use the JFS file system)
+
equo install xfsprogs # (if you use the XFS file system)
 +
equo install jfsutils # (if you use the JFS file system)
 +
</pre>}}
  
===Network stuff===
+
=== Network stuff ===
  
    equo install dhcpcd        # (if you need a DHCP client)
+
{{Console|<pre class="clear">
    equo install ppp            # (if you need PPPoE ADSL connectivity)
+
equo install dhcpcd        # (if you need a DHCP client)
    equo install wireless-tools # (if you need wireless connectivity)
+
equo install ppp            # (if you need PPPoE ADSL connectivity)
    equo install wpa_supplicant # (if you need WPA/WPA2 authentication)
+
equo install wireless-tools # (if you need wireless connectivity)
    equo install wicd          # (if you do like wicd)
+
equo install wpa_supplicant # (if you need WPA/WPA2 authentication)
 +
equo install wicd          # (if you do like wicd)
 +
</pre>}}
  
===Kernel & bootloader===
+
=== Kernel & bootloader ===
  
    equo install linux-sabayon
+
{{Console|<pre class="clear">
    equo install grub
+
equo install linux-sabayon
    nano -w /boot/grub/menu.lst # setup grub
+
equo install grub
 +
nano -w /boot/grub/menu.lst # setup grub
 +
</pre>}}
  
===System logger and Cron daemon===
+
=== System logger and Cron daemon ===
  
    equo install syslog-ng vixie-cron
+
{{Console|<pre class="clear">
    rc-update add syslog-ng default
+
equo install syslog-ng vixie-cron
    rc-update add vixie-cron default
+
rc-update add syslog-ng default
 +
rc-update add vixie-cron default
 +
</pre>}}
  
 
This is just a suggestion: please go for the system logger and cron daemon of your choice!
 
This is just a suggestion: please go for the system logger and cron daemon of your choice!
  
===Everything else===
+
=== Everything else ===
  
 
Install any other packages you want using equo:
 
Install any other packages you want using equo:
  
    equo install <whatever>
+
{{Console|<pre class="clear">equo install <whatever></pre>}}
  
 
For example, if you want KDE, the base packages needed can be installed with <tt>equo install kdebase-meta</tt>
 
For example, if you want KDE, the base packages needed can be installed with <tt>equo install kdebase-meta</tt>
  
===Exit & cleanup===
+
=== Exit & cleanup ===
  
====Exit the chroot====
+
==== Exit the chroot ====
  
    exit
+
{{Console|<pre class="clear">exit</pre>}}
  
====Unmount filesystems====
+
==== Unmount filesystems ====
  
    cd /mnt/sabayon
+
{{Console|<pre class="clear">
    umount ./sys
+
cd /mnt/sabayon
    umount ./proc
+
umount ./sys
    umount ./dev/shm
+
umount ./proc
    umount ./dev/pts
+
umount ./dev/shm
    umount ./dev
+
umount ./dev/pts
 +
umount ./dev
 +
</pre>}}
  
 
Unmount any other filesystem inside /mnt/sabayon.
 
Unmount any other filesystem inside /mnt/sabayon.
Line 272: Line 309:
 
Then unmount the root filesystem of your new sabayon system:
 
Then unmount the root filesystem of your new sabayon system:
  
    umount /mnt/sabayon
+
{{Console|<pre class="clear">umount /mnt/sabayon</pre>}}
  
===Reboot===
+
=== Reboot ===
  
 
You are now ready to reboot (well, you were ready since the "setup grub" step, actually)
 
You are now ready to reboot (well, you were ready since the "setup grub" step, actually)
  
    reboot
+
{{Console|<pre class="clear">reboot</pre>}}
  
 
Enjoy your new shiny Sabayon system installed like it should be! (please forgive the troll in me)
 
Enjoy your new shiny Sabayon system installed like it should be! (please forgive the troll in me)

Revision as of 21:04, 4 April 2013

i18n: de en tr
Overview

This HOWTO brings the gentoo installation method (as in the Handbook) to Sabayon.

Please note that "an existing Linux system" can be either an installed system (then you cannot use that partition for sabayon), or a live linux system.

The first part is about installing a very basic gentoo system in a chrooted partition; in the second part we will use portage to install entropy and equo. We will then use equo to install a full sabayon system in the third and last part.

Part 1: Gentoo install

Please refer to http://www.gentoo.org/doc/en/gentoo-x86-quickinstall.xml and http://www.gentoo.org/doc/en/handbook/index.xml for more in-depth details about gentoo installation.

Partitioning

Do your thing and partition your disk(s). You need at least a root partition (/).

Create filesystems for your partitions according to your likings. Remember that you will need to install the *progs packages for your filesystem(s).

From now on we will assume that your root filesystem is mounted under /mnt/sabayon.

Also if you have a /var, /boot, /usr, /home ... filesystems, create the mountpoints relative to /mnt/sabayon and mount them now.

Get Gentoo installation files

We will assume an x86_64 architecture here. If you're on x86 (32 bits), change "amd64" with "x86".

export ARCH="amd64"

Pick up a mirror near you from this list: http://www.gentoo.org/main/en/mirrors.xml

export MIRROR="ftp://distfiles.gentoo.org/pub/gentoo"

We will refer to your arch as $ARCH and to your chosen mirror as $MIRROR from now on.

Download and verify stage3 archive

wget -r $MIRROR/releases/$ARCH/current-stage3/
cat stage3-$ARCH-*.tar.bz2.DIGESTS && md5sum stage3-$ARCH-*.tar.bz2 && sha1sum stage3-$ARCH-*.tar.bz2

Download and verify portage snapshot

wget $MIRROR/snapshots/portage-latest.tar.bz2
wget $MIRROR/snapshots/portage-latest.tar.bz2.md5sum
cat portage-latest.tar.bz2.DIGESTS && md5sum portage-latest.tar.bz2 && sha1sum portage-latest.tar.bz2

Unpack stage3 and portage

tar xfpj stage3-$ARCH-*.tar.bz2 -C /mnt/sabayon
tar xfpj portage-latest.tar.bz2 -C /mnt/sabayon/usr

Note the p option: it's for preserving file permissions and it's very important!

Chroot into your new Gentoo

Everything that follows is done while in /mnt/sabayon:

cd /mnt/sabayon

Mounting filesystems

mount -o bind /dev ./dev
mount -t devpts none ./dev/pts
mount -t tmpfs none ./dev/shm
mount -t proc none ./proc
mount -t sysfs none ./sys

Copying /etc/resolv.conf

cp /etc/resolv.conf ./etc

Chroot!

chroot /mnt/sabayon /bin/bash

Now you are on your Gentoo chroot!

Configure environnment

export LANG=en_US
export LANGUAGE=${LANG}
export LC_ALL=${LANG}.UTF-8
env-update
eselect python set 1    #sets python 2.7 as default
source /etc/profile

Some early configuration

Set up a root password

As I regulary forget to setup the root password, let's do that as first thing:

passwd
Timezone
        
cd /etc/
ln -sf ../usr/share/zoneinfo/<REGION>/<City> localtime

Where <REGION> is your region and <City> the nearest big city.

Hostname

Be original and change "localhost" to something else. Update /etc/hosts accordingly.

nano -w /etc/conf.d/hostname
nano -w /etc/hosts
Mount points
nano -w /etc/fstab

Part 2: Sabayon overlay setup and installation of entropy+equo

Layman

layman is a gentoo tool to manage portage overlays. We will use it to get our hands on the sabayon overlay. Update: entropy and equo are in regular portage, so you can skip this step.

# emerge --sync                # make sure portage is fully up to date... or not. Up to you. portage snapshots are done daily, i see no need to sync.
# USE="git" emerge -avt layman # now equo is in regular portage!
# layman -a sabayon            # see above

Entropy and Equo

emerge -avt equo --autounmask-write
etc-update
emerge -avt equo

Now we have entropy and equo installed. To make use of it, we should first generate the entropy database (only the very first time!):

equo rescue generate

Yes, you are sure about this. You should answer yes three times to make it happy.

Perfect. Now we need to setup sabayon repositories. As an example, we use sabayonlinux.org (i.e. updated daily), but you can use sabayon-weekly instead if you want to upgrade less often. See En:Entropy#Package_Repositories.

cd /etc/entropy/repositories.conf.d
cp entropy_sabayonlinux.org.example entropy_sabayonlinux.org
cd -

Let's use equo to populate the repo db (if you used sabayon-weekly, substitute "sabayonlinux.org" with sabayon-weekly here):

    
equo update
equo repo mirrorsort sabayonlinux.org

We're set! equo is now in a working state!

Optional: Entropy: the missing bits

Notice: if you are planning to exclusively use entropy, you can happily skip to Part 3: Finish installation using equo.


So you will be using portage and/or want to have the same portage settings used to build your sabayon packages? Very well, here's how!

When you install entropy you'll miss some vital portage bits, namely the /etc/portage/* files used to build the sabayon packages.

Hopefully you can find those here: https://git.sabayon.org/build.git/

Let's make use of them!

# fetch the bits!
cd /opt
git clone git://git.sabayon.org/projects/build.git sabayon-build
cd /opt/sabayon-build/conf/intel/portage
# keep your specific stuff in "myconf" branch:
git checkout -b myconf
# symlink to your <arch>:
ln -sf make.conf.amd64 make.conf
ln -sf package.env.amd64 package.env
# add & commit
git add make.conf package.env
git config --global user.name "Your Name"
git config --global user.email "your@email"
git commit
# rename the gentoo /etc/make.conf and /etc/portage/:
cd /etc/
mv portage portage-gentoo
mv make.conf make.conf-gentoo
# symlink to sabayon /etc/make.conf /etc/portage/:
ln -sf /opt/sabayon-build/conf/intel/portage portage

Of course, change make.conf.amd64 and package.env.amd64 to make.conf.x86 and package.env.x86 if you are not on x86_64.

If you want to change some USE flags on certain packages you should:

  • update your /etc/portage/package.use
  • mask the package in /etc/entropy/packages/package.mask

so that emerge will use your specified USE flags and entropy will not handle the specified package again.

i.e. you want ruby support for app-editors/vim:

cd /etc/portage
sed -i package.use -e "s,app-editors/vim vim-pager,app-editors/vim vim-pager ruby" # or just use VIM!
git add package.use
git commit -m "app-editors/vim +ruby"
cd /etc/entropy/packages
echo "app-editors/vim" >> package.mask

Part 3: Finish installation using equo

eix

To make your life easier, let's install eix (a tool for portage searching) and also the sabayon-distribution overlay (i.e. the entropy packages as a portage overlay):

equo install eix
layman -a sabayon-distro
cd /etc/portage
echo "source /var/lib/layman/make.conf" >> make.conf
git commit -m "source layman/make.conf in /etc/make.conf"
eix-sync

Now you can use eix to quickly search for installed/installable/upgradable packages and see their versions and use flags.

Filesystem progs

From gentoo quickinstall, code listing 2.27:

equo install xfsprogs # (if you use the XFS file system)
equo install jfsutils # (if you use the JFS file system)

Network stuff

equo install dhcpcd         # (if you need a DHCP client)
equo install ppp            # (if you need PPPoE ADSL connectivity)
equo install wireless-tools # (if you need wireless connectivity)
equo install wpa_supplicant # (if you need WPA/WPA2 authentication)
equo install wicd           # (if you do like wicd)

Kernel & bootloader

equo install linux-sabayon
equo install grub
nano -w /boot/grub/menu.lst # setup grub

System logger and Cron daemon

equo install syslog-ng vixie-cron
rc-update add syslog-ng default
rc-update add vixie-cron default

This is just a suggestion: please go for the system logger and cron daemon of your choice!

Everything else

Install any other packages you want using equo:

equo install <whatever>

For example, if you want KDE, the base packages needed can be installed with equo install kdebase-meta

Exit & cleanup

Exit the chroot

exit

Unmount filesystems

cd /mnt/sabayon
umount ./sys
umount ./proc
umount ./dev/shm
umount ./dev/pts
umount ./dev

Unmount any other filesystem inside /mnt/sabayon.

Then unmount the root filesystem of your new sabayon system:

umount /mnt/sabayon

Reboot

You are now ready to reboot (well, you were ready since the "setup grub" step, actually)

reboot

Enjoy your new shiny Sabayon system installed like it should be! (please forgive the troll in me)