<?xml version="1.0" encoding="utf-8"?>
<!-- generator="FeedCreator 1.7.2-ppt DokuWiki" -->
<?xml-stylesheet href="http://awired.net/lib/exe/css.php?s=feed" type="text/css"?>
<rdf:RDF
    xmlns="http://purl.org/rss/1.0/"
    xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
    xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
    xmlns:dc="http://purl.org/dc/elements/1.1/">
    <channel rdf:about="http://awired.net/feed.php">
        <title>Awired wiki</title>
        <description></description>
        <link>http://awired.net/</link>
        <image rdf:resource="http://awired.net/lib/images/favicon.ico" />
       <dc:date>2009-01-05T17:24:37+01:00</dc:date>
        <items>
            <rdf:Seq>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox"/>
                <rdf:li rdf:resource="http://awired.net/news/2008/08/nouveau-serveur"/>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/gentoo/mdadm"/>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/gentoo/cryptsetup"/>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/gentoo/winbind"/>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/gentoo/how-to"/>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/gentoo/dns"/>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/creation-d-un-reseau-d-entreprise"/>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/gentoo/apache"/>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/gentoo/installation-de-gentoo"/>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/gentoo/postgresql"/>
                <rdf:li rdf:resource="http://awired.net/tuto/admin-sys/gentoo/vmware"/>
            </rdf:Seq>
        </items>
    </channel>
    <image rdf:about="http://awired.net/lib/images/favicon.ico">
        <title>Awired wiki</title>
        <link>http://awired.net/</link>
        <url>http://awired.net/lib/images/favicon.ico</url>
    </image>
    <item rdf:about="http://awired.net/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox">
        <dc:format>text/html</dc:format>
        <dc:date>2008-11-19T17:18:53+01:00</dc:date>
        <title>Attribution d’une adresse IP en fonction de l’adresse mac avec une Livebox</title>
        <link>http://awired.net/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox</link>
        <description>
&lt;/p&gt;

&lt;div class=&quot;level2&quot;&gt;

Bonjour à tous ceux qui auront le courage de me lire, Aujourd’hui nous nous attaquons à un must de l’administration réseau : l’attribution d’un IP à un poste en rapport a son adresse mac.
&lt;/p&gt;

&lt;/div&gt;
&lt;h3&gt;&lt;a name=&quot;histoire&quot; id=&quot;histoire&quot;&gt;Histoire&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

L’adresse IP est en fait un peu comme notre adresse postale, elle permet à un autre ordinateur de nous envoyer des données.
L’adresse mac, elle, est un identifiant UNIQUE apposé par le constructeur sur votre carte, elle se compose de 6 caractères Hexadécimaux. Les trois premiers sont les ID du constructeur et les trois suivant sont l’ID de votre carte.
&lt;/p&gt;

&lt;p&gt;
La livebox est le modem/Routeur ADSL de France Telecom (Orange), pour ce document la livebox utilisée est une livebox Sagem. Il semblerai que la manipulation ne sois pas accessible sous Inventel
&lt;/p&gt;

&lt;p&gt;
EDIT: Suite au nombreuse mise a jour des livebox et de la sortie des nouvelles mini, mon tuto est malheuresement devenu OBSOLETE, je remerci tout ceux qui l&amp;#039;aurons lu.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Histoire&quot; [294-1046] --&gt;
&lt;h3&gt;&lt;a name=&quot;go&quot; id=&quot;go&quot;&gt;Go ?!&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

Tout d’abord pour récupérer son adresse mac, le plus simple est de la lire sur la carte, si la carte est déjà installée il vous suffira juste de faire démarrer à exécuter à cmd à ipconfig /all
&lt;/p&gt;

&lt;p&gt;
&lt;a href=&quot;http://awired.net/_detail/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox/image1.jpg?id=tuto%3Aadmin-sys%3Awindows%3Aattribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox&amp;amp;cache=cache&quot; class=&quot;media&quot; title=&quot;tuto:admin-sys:windows:attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox:image1.jpg&quot;&gt;&lt;img src=&quot;http://awired.net/_media/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox/image1.jpg?w=&amp;amp;h=&amp;amp;cache=cache&quot; class=&quot;mediacenter&quot; title=&quot;image1.jpg&quot; alt=&quot;image1.jpg&quot; /&gt;&lt;/a&gt;
&lt;/p&gt;

&lt;p&gt;
L’adresse mac est ici appelée « Adresse Physique »
&lt;/p&gt;

&lt;p&gt;
Maintenant que vous avez trouvé votre adresse mac, recopiez-la de cette façon :
00 :07 :CA :05 :6C :D9 (il faut en fait remplacer les «-«  par des « : »)
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Go ?!&quot; [1047-1602] --&gt;
&lt;h3&gt;&lt;a name=&quot;i-m-a-geek&quot; id=&quot;i-m-a-geek&quot;&gt;I’m a Geek&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

Maintenant avec Telnet (démarrer à exécuter à cmd à Telnet) vous faites les manipulations suivantes :
&lt;/p&gt;

&lt;p&gt;
&lt;a href=&quot;http://awired.net/_detail/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox/image2.jpg?id=tuto%3Aadmin-sys%3Awindows%3Aattribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox&amp;amp;cache=cache&quot; class=&quot;media&quot; title=&quot;tuto:admin-sys:windows:attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox:image2.jpg&quot;&gt;&lt;img src=&quot;http://awired.net/_media/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox/image2.jpg?w=&amp;amp;h=&amp;amp;cache=cache&quot; class=&quot;mediacenter&quot; title=&quot;image2.jpg&quot; alt=&quot;image2.jpg&quot; /&gt;&lt;/a&gt;

&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Open&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level2&quot;&gt;&lt;div class=&quot;li&quot;&gt; 192.168.1.1&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level2&quot;&gt;&lt;div class=&quot;li&quot;&gt; Root&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level2&quot;&gt;&lt;div class=&quot;li&quot;&gt; 1234&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;

Après tout ça vous arrivez ici :

&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; [ root @ home ]&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;

&lt;a href=&quot;http://awired.net/_detail/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox/image3.jpg?id=tuto%3Aadmin-sys%3Awindows%3Aattribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox&amp;amp;cache=cache&quot; class=&quot;media&quot; title=&quot;tuto:admin-sys:windows:attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox:image3.jpg&quot;&gt;&lt;img src=&quot;http://awired.net/_media/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox/image3.jpg?w=&amp;amp;h=&amp;amp;cache=cache&quot; class=&quot;mediacenter&quot; title=&quot;image3.jpg&quot; alt=&quot;image3.jpg&quot; /&gt;&lt;/a&gt;
&lt;/p&gt;

&lt;p&gt;
Vous voici donc au cœur de votre livebox, si vous voulez naviguer un peu tapez LS.
&lt;/p&gt;

&lt;p&gt;
Ce qui nous importe à nous, c’est le serveur DHCP, pour arriver dessus taper :
&lt;/p&gt;

&lt;p&gt;
&lt;a href=&quot;http://awired.net/_detail/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox/image4.jpg?id=tuto%3Aadmin-sys%3Awindows%3Aattribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox&amp;amp;cache=cache&quot; class=&quot;media&quot; title=&quot;tuto:admin-sys:windows:attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox:image4.jpg&quot;&gt;&lt;img src=&quot;http://awired.net/_media/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox/image4.jpg?w=&amp;amp;h=&amp;amp;cache=cache&quot; class=&quot;mediacenter&quot; title=&quot;image4.jpg&quot; alt=&quot;image4.jpg&quot; /&gt;&lt;/a&gt;

&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; dhcserver&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level2&quot;&gt;&lt;div class=&quot;li&quot;&gt; stop (car pour modifier les infos dhcp il faut que le serveur soit stoppé. DONC J’ESPERE QUE VOUS ETES EN IP FIXE)&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;

&lt;a href=&quot;http://awired.net/_detail/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox/image5.jpg?id=tuto%3Aadmin-sys%3Awindows%3Aattribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox&amp;amp;cache=cache&quot; class=&quot;media&quot; title=&quot;tuto:admin-sys:windows:attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox:image5.jpg&quot;&gt;&lt;img src=&quot;http://awired.net/_media/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox/image5.jpg?w=&amp;amp;h=&amp;amp;cache=cache&quot; class=&quot;mediacenter&quot; title=&quot;image5.jpg&quot; alt=&quot;image5.jpg&quot; /&gt;&lt;/a&gt;

&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; host –add –o –macaddr « votre-mac » -ipaddr « votre-ip-souhaité » -broadcast 192.168.1.255 –dns 192.168.1.1 –gateway 192.168.1.1&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level2&quot;&gt;&lt;div class=&quot;li&quot;&gt; start&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;I’m a Geek&quot; [1603-2777] --&gt;
&lt;h3&gt;&lt;a name=&quot;yes-we-did-it&quot; id=&quot;yes-we-did-it&quot;&gt;Yes we did it !&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

Voila si aucun message d’erreur n’est apparu, alors votre configuration à été finalisée avec succès.
Désormais vous avez votre adresse ip attribué a votre carte, si jamais vous changer de carte réseau n’oubliez pas de rechanger la configuration de la livebox.
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Yes we did it !&quot; [2778-] --&gt;&lt;span class=&quot;plugin_feedmod_comments&quot;&gt;
  &lt;a href=&quot;http://awired.net/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox#discussion__section&quot; title=&quot;Read or add comments to this article&quot;&gt;Read or add comments to this article&lt;/a&gt;
&lt;/span&gt;
&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/windows/attribution-dune-adresse-ip-en-fonction-de-ladresse-mac-avec-une-livebox&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/news/2008/08/nouveau-serveur">
        <dc:format>text/html</dc:format>
        <dc:date>2008-08-03T12:47:42+01:00</dc:date>
        <dc:creator>n0rad</dc:creator>
        <title>Nouveau serveur</title>
        <link>http://awired.net/news/2008/08/nouveau-serveur</link>
        <description>
&lt;/p&gt;

&lt;div class=&quot;level1&quot;&gt;

Awired.net est de nouveau en ligne sur une nouvelle installation du serveur sous gentoo-2008 x64 raid1 avec cryptage des disques durs
&lt;/p&gt;

&lt;/div&gt;

&lt;h4&gt;&lt;a name=&quot;section&quot; id=&quot;section&quot;&gt;&lt;/a&gt;&lt;/h4&gt;
&lt;div class=&quot;level4&quot;&gt;


&lt;/p&gt;

&lt;/div&gt;
&lt;span class=&quot;plugin_feedmod_comments&quot;&gt;
  &lt;a href=&quot;http://awired.net/news/2008/08/nouveau-serveur#discussion__section&quot; title=&quot;Read or add comments to this article&quot;&gt;Read or add comments to this article&lt;/a&gt;
&lt;/span&gt;
&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/news/2008/08/nouveau-serveur&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/news/2008/08/nouveau-serveur&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/news/2008/08/nouveau-serveur&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/tuto/admin-sys/gentoo/mdadm">
        <dc:format>text/html</dc:format>
        <dc:date>2008-07-26T18:58:46+01:00</dc:date>
        <dc:creator>n0rad</dc:creator>
        <title></title>
        <link>http://awired.net/tuto/admin-sys/gentoo/mdadm</link>
        <description>&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/gentoo/mdadm&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/gentoo/mdadm&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/gentoo/mdadm&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/tuto/admin-sys/gentoo/cryptsetup">
        <dc:format>text/html</dc:format>
        <dc:date>2008-07-26T11:53:47+01:00</dc:date>
        <dc:creator>n0rad</dc:creator>
        <title></title>
        <link>http://awired.net/tuto/admin-sys/gentoo/cryptsetup</link>
        <description>&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/gentoo/cryptsetup&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/gentoo/cryptsetup&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/gentoo/cryptsetup&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/tuto/admin-sys/gentoo/winbind">
        <dc:format>text/html</dc:format>
        <dc:date>2008-07-13T21:58:47+01:00</dc:date>
        <dc:creator>n0rad</dc:creator>
        <title>WINBIND</title>
        <link>http://awired.net/tuto/admin-sys/gentoo/winbind</link>
        <description>
&lt;/p&gt;

&lt;div class=&quot;level1&quot;&gt;

&lt;/p&gt;

&lt;/div&gt;
&lt;h2&gt;&lt;a name=&quot;ntp&quot; id=&quot;ntp&quot;&gt;NTP&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

emerge net-misc/ntp
&lt;/p&gt;

&lt;p&gt;
/etc/conf.d/ntp-client

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
NTPCLIENT_CMD=&quot;ntpdate&quot;
NTPCLIENT_OPTS=&quot;-s -b -u ilona.awired.loc&quot;&lt;/pre&gt;
&lt;p&gt;

talya mnt # date
dim. juil. 13 20:16:52 CEST 2008
talya mnt # /etc/init.d/ntp-client start
 * Caching service dependencies …                                                       [ ok ]
 * Setting clock via the NTP client &amp;#039;ntpdate&amp;#039; …                                         [ ok ]
talya mnt # rc-update add ntp-client default
 * ntp-client added to runlevel default
talya mnt # date
dim. juil. 13 18:29:22 CEST 2008
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;NTP&quot; [25-590] --&gt;
&lt;h2&gt;&lt;a name=&quot;fqdn&quot; id=&quot;fqdn&quot;&gt;FQDN&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

talya mnt # hostname -f
talya.awired.loc
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;FQDN&quot; [591-650] --&gt;
&lt;h2&gt;&lt;a name=&quot;kerberos&quot; id=&quot;kerberos&quot;&gt;Kerberos&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

#emerge -av sys-auth/pam_krb5 app-crypt/mit-krb5
&lt;/p&gt;

&lt;p&gt;
 /etc/krb5.conf 

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
[logging]
default = FILE:/var/log/krb5.log

[libdefaults]
   ticket_lifetime = 24000
   clock_skew = 300
   default_realm = AWIRED.LOC

[realms]
   domain.LOCAL = {
       kdc = ilona.awired.loc:88
       admin_server = ilona.awired.loc:464
       default_domain = AWIRED.LOC
}

[domain_realm]
   .domain.local = AWIRED.LOC
   domain.local = AWIRED.LOC&lt;/pre&gt;
&lt;p&gt;

talya mnt # kinit administrateur@AWIRED.LOC
Password for administrateur@AWIRED.LOC:
talya mnt # klist
Ticket cache: FILE:/tmp/krb5cc_0
Default principal: administrateur@AWIRED.LOC
&lt;/p&gt;

&lt;p&gt;
Valid starting     Expires            Service principal
07/13/08 18:38:16  07/14/08 01:18:16  krbtgt/AWIRED.LOC@AWIRED.LOC
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Kerberos&quot; [651-1416] --&gt;
&lt;h2&gt;&lt;a name=&quot;rejoindre-le-domaine&quot; id=&quot;rejoindre-le-domaine&quot;&gt;Rejoindre le domaine&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

/etc/portage/package.use

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
net-fs/samba ldap ads winbind&lt;/pre&gt;
&lt;p&gt;
#emerge -v samba
&lt;/p&gt;

&lt;p&gt;
/etc/samba/smb.conf

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
[global]
   workgroup = domain
   server string = Samba Server %v
   load printers = no
   log file = /var/log/samba/log.%m
   max log size = 50
   interfaces = lo eth0
   bind interfaces only = yes
   hosts allow = 192.168.1. 127.
   hosts deny = 0.0.0.0/0
   encrypt passwords = yes
   socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
   dns proxy = no
   smb ports = 139
   security = ADS
   realm = domain.LOCAL
   password server = 192.168.1.250
   winbind separator = /
   idmap uid = 10000-20000
   idmap gid = 10000-20000
   winbind enum users = yes
   winbind enum groups = yes
   template homedir = /home/%D/%U
   template shell = /bin/zsh
   client use spnego = yes
   client ntlmv2 auth = yes
   winbind use default domain = yes
   restrict anonymous = 2
   domain master = no
   local master = no
   preferred master = no
   os level = 0
   disable netbios = no
   dos charset = ASCII
   unix charset = UTF8
   display charset = UTF8&lt;/pre&gt;
&lt;p&gt;

File: /etc/conf.d/samba
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
#add &quot;winbind&quot; to the daemon_list if you also want winbind to start
daemon_list=&quot;smbd nmbd winbind&quot;&lt;/pre&gt;
&lt;p&gt;

# kinit Administrator@domain.LOCAL
&lt;/p&gt;

&lt;p&gt;
# net ads join -U administrator
Using short domain name – domain
Joined &amp;#039;gentoobox&amp;#039; to realm &amp;#039;domain.LOCAL&amp;#039;
&lt;/p&gt;

&lt;p&gt;
#/etc/init.d/samba start
# rc-update add samba default
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Rejoindre le domaine&quot; [1417-] --&gt;&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/gentoo/winbind&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/gentoo/winbind&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/gentoo/winbind&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/tuto/admin-sys/gentoo/how-to">
        <dc:format>text/html</dc:format>
        <dc:date>2008-07-13T16:55:57+01:00</dc:date>
        <dc:creator>n0rad</dc:creator>
        <title>gestion de la configuration des disque durs</title>
        <link>http://awired.net/tuto/admin-sys/gentoo/how-to</link>
        <description>
&lt;/p&gt;

&lt;div class=&quot;level2&quot;&gt;

A value of zero means “timeouts are disabled”: the device will not automatically enter standby mode.
Values from 1 to 240 specify multiples of 5 seconds, yielding timeouts from 5 seconds to 20 minutes.
Values from 241 to 251 specify from 1 to 11 units of 30 minutes, yielding timeouts from 30 minutes to 5.5 hours.
A value of 252 signifies a  timeout  of  21  minutes.
A value of 253 sets a vendor-defined timeout period between 8 and 12 hours.
A value of 255 is interpreted as 21 minutes plus 15 seconds.
The value 254 is reserved.
Note that some older drives may have very different interpretations of these values.
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
hdparm -S12 /dev/hda&lt;/pre&gt;
&lt;p&gt;
Now the drive spins down after 1 minute. (12&amp;times;5=60s) To turn it off choose x=0. 
&lt;/p&gt;

&lt;p&gt;
&amp;lt;!– &lt;a href=&quot;http://gentoo-wiki.com/HOWTO_Use_hdparm_to_improve_IDE_device_performance#Spindown_-S&quot; class=&quot;urlextern&quot; title=&quot;http://gentoo-wiki.com/HOWTO_Use_hdparm_to_improve_IDE_device_performance#Spindown_-S&quot;  rel=&quot;nofollow&quot;&gt;http://gentoo-wiki.com/HOWTO_Use_hdparm_to_improve_IDE_device_performance#Spindown_-S&lt;/a&gt; –&amp;gt;
&lt;/p&gt;

&lt;p&gt;
File: /etc/conf.d/hdparm (default)
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
hda_args=&quot;-S241&quot;
hdb_args=&quot;-S241&quot;
hdc_args=&quot;-S241&quot;
hdd_args=&quot;-S241&quot;
hdg_args=&quot;-S241&quot;
hdh_args=&quot;-S241&quot;
hdi_args=&quot;-S241&quot;
hdj_args=&quot;-S241&quot;

sdb_args=&quot;-S241&quot;
sdc_args=&quot;-S241&quot;
sdd_args=&quot;-S241&quot;&lt;/pre&gt;
&lt;p&gt;

/etc/init.d/hdparm start
rc-update add hdparm default
watch -n1 &amp;#039;cat /proc/mdstat&amp;#039;

&lt;/p&gt;

&lt;/div&gt;
&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/gentoo/how-to&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/gentoo/how-to&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/gentoo/how-to&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/tuto/admin-sys/gentoo/dns">
        <dc:format>text/html</dc:format>
        <dc:date>2008-07-13T15:32:07+01:00</dc:date>
        <dc:creator>n0rad</dc:creator>
        <title>Serveur dns</title>
        <link>http://awired.net/tuto/admin-sys/gentoo/dns</link>
        <description>
&lt;/p&gt;

&lt;div class=&quot;level1&quot;&gt;

&lt;p&gt;&lt;div class=&quot;notetip&quot;&gt;&lt;b&gt;tip:&lt;/b&gt; 
&lt;strong&gt; pour vider le cache dns :&lt;/strong&gt;
/etc/init.d/nscd restart

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
installation de bind :
&lt;/p&gt;

&lt;p&gt;
emerge bind
&lt;/p&gt;

&lt;p&gt;
emerge –config &amp;#039;=net-dns/bind-9.4.1_p1&amp;#039;
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
$ttl 38400  ; 10 hours 40 minutes
awired.loc.     IN      SOA     talya.awired.loc. n0rad.awired.net. (
                        1185440860 ; serial
                        10800      ; refresh (3 hours)
                        3600       ; retry (1 hour)
                        604800     ; expire (1 week)
                        38400      ; minimum (10 hours 40 minutes)
                        )
                IN      NS      talya.awired.loc.
                IN      A       192.168.42.252
ilona           IN      A       192.168.42.252
talya           IN      A       192.168.42.253&lt;/pre&gt;
&lt;/div&gt;
&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/gentoo/dns&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/gentoo/dns&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/gentoo/dns&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/tuto/admin-sys/creation-d-un-reseau-d-entreprise">
        <dc:format>text/html</dc:format>
        <dc:date>2008-07-13T15:07:33+01:00</dc:date>
        <dc:creator>n0rad</dc:creator>
        <title>Création d'un réseau d'entreprise</title>
        <link>http://awired.net/tuto/admin-sys/creation-d-un-reseau-d-entreprise</link>
        <description>
&lt;/p&gt;

&lt;div class=&quot;level1&quot;&gt;

Le but de cet article est la création d&amp;#039;un réseau avancé de type entreprise avec de nombreuse fonctionnalité. Pour expliquer comment installer les machines, les systèmes d&amp;#039;exploitations et les application je vais prendre comme modèle mon réseau personnel qui comprend (à  peu près) tout ce qu&amp;#039;une entreprise utilise.
&lt;/p&gt;

&lt;p&gt;
Pour économiser l&amp;#039;électricité ainsi que le prix de la facture d&amp;#039;électricité les 3 serveurs tourne sur la même machine physique avec un systÃ¨me de virtualisation (vmware) pour faire tourné les 2 windows
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Création d'un réseau d'entreprise&quot; [1-595] --&gt;
&lt;h2&gt;&lt;a name=&quot;les-serveurs&quot; id=&quot;les-serveurs&quot;&gt;Les serveurs&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;


&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Les serveurs&quot; [596-621] --&gt;
&lt;h3&gt;&lt;a name=&quot;serveur-physique-gentoo&quot; id=&quot;serveur-physique-gentoo&quot;&gt;Serveur physique (gentoo)&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/hardware&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:hardware&quot;&gt;Cablage réseau et choix du matériel&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/installation-de-gentoo&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:gentoo:installation-de-gentoo&quot;&gt;Installation du système d&amp;#039;exploitation&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/installation-de-gentoo-part2&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:gentoo:installation-de-gentoo-part2&quot;&gt;configuration du système&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/controlleur-ide&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:gentoo:controlleur-ide&quot;&gt;Driver carte contrôleur IDE&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/dhcp&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:gentoo:dhcp&quot;&gt;serveur DHCP&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/screen&quot; class=&quot;wikilink2&quot; title=&quot;tuto:admin-sys:gentoo:screen&quot; rel=&quot;nofollow&quot;&gt;Screen&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/dns&quot; class=&quot;wikilink2&quot; title=&quot;tuto:admin-sys:dns&quot; rel=&quot;nofollow&quot;&gt;dns&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/vmware&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:gentoo:vmware&quot;&gt;Vmware&lt;/a&gt;&lt;/div&gt;
&lt;ul&gt;
&lt;li class=&quot;level2&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/ad&quot; class=&quot;wikilink2&quot; title=&quot;tuto:admin-sys:gentoo:ad&quot; rel=&quot;nofollow&quot;&gt;Installation d&amp;#039;Active Directory&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/acl&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:gentoo:acl&quot;&gt;ACL&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/samba&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:gentoo:samba&quot;&gt;Samba&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Configuration de la freebox&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Installation de Gentoo&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Mise en place des acls&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Mise en place du serveur de mail&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Installation de &lt;a href=&quot;http://awired.net/tuto/admin-sys/logmein&quot; class=&quot;wikilink2&quot; title=&quot;tuto:admin-sys:logmein&quot; rel=&quot;nofollow&quot;&gt;LogMeIn&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Serveur physique (gentoo)&quot; [622-] --&gt;&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/creation-d-un-reseau-d-entreprise&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/creation-d-un-reseau-d-entreprise&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/creation-d-un-reseau-d-entreprise&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/tuto/admin-sys/gentoo/apache">
        <dc:format>text/html</dc:format>
        <dc:date>2008-07-12T19:58:34+01:00</dc:date>
        <dc:creator>n0rad</dc:creator>
        <title></title>
        <link>http://awired.net/tuto/admin-sys/gentoo/apache</link>
        <description>media-libs/gd jpeg pg truetype&lt;/pre&gt;&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/gentoo/apache&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/gentoo/apache&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/gentoo/apache&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/tuto/admin-sys/gentoo/installation-de-gentoo">
        <dc:format>text/html</dc:format>
        <dc:date>2008-07-12T16:33:47+01:00</dc:date>
        <title>Installation de Gentoo</title>
        <link>http://awired.net/tuto/admin-sys/gentoo/installation-de-gentoo</link>
        <description>
&lt;/p&gt;

&lt;div class=&quot;level1&quot;&gt;


&lt;/p&gt;

&lt;/div&gt;
&lt;h2&gt;&lt;a name=&quot;pourquoi-gentoo&quot; id=&quot;pourquoi-gentoo&quot;&gt;Pourquoi Gentoo ?&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

Gentoo est une distribution de Linux. le choix de linux par rapport a un autre système d&amp;#039;exploitation est simple. L&amp;#039;installation d&amp;#039;un &lt;acronym title=&quot;Operating System&quot;&gt;OS&lt;/acronym&gt; grandement utiliser est important pour éviter de galérer lors de l&amp;#039;installer de certaine application qui ne sont pas prévu à la base pour cette &lt;acronym title=&quot;Operating System&quot;&gt;OS&lt;/acronym&gt;.
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteclassic&quot;&gt;&lt;b&gt;note:&lt;/b&gt; La toute première version de mon serveur était une &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/freebsd&quot; class=&quot;wikilink2&quot; title=&quot;tuto:admin-sys:gentoo:freebsd&quot; rel=&quot;nofollow&quot;&gt;FreeBSD&lt;/a&gt; mais cette distribution Unix a beau être très utilisée, j&amp;#039;ai eu des problèmes à installer certain application très utilisé mais non prévu pour du Unix
&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
Quand à Windows, l&amp;#039;os n&amp;#039;est pas totalement stable lorsqu&amp;#039;on l&amp;#039;utilise un minimum et gère assez mal les ressources. 
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteclassic&quot;&gt;&lt;b&gt;note:&lt;/b&gt; la 2eme version de mon serveur était un Windows et plantait environ tout les 30 jours
&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
le choix d&amp;#039;une distribution Linux est donc évident.
&lt;/p&gt;

&lt;p&gt;
La particularité de Gentoo est que cette distribution est à installer entièrement à la main ce qui la rend forcement plus longue a installer mais cela permet d&amp;#039;avoir un &lt;acronym title=&quot;Operating System&quot;&gt;OS&lt;/acronym&gt; comprenant uniquement les applications dont vous avez besoin et en plus cela vous permettra de maitriser votre système d&amp;#039;exploitation.
&lt;/p&gt;

&lt;p&gt;
L&amp;#039;autre avantage de cette distribution est la présence du meilleur gestionnaire de package existant : &lt;em&gt;portage&lt;/em&gt; . Portage contient un arbre des applications existantes pour Gentoo dont les avantage sont les suivant : 
&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; vous pouvez mettre a jour votre arbre très facilement&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; tres bonne gestion des dépendances et mise a jour des logiciels&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; installation des application entièrement via compilation ce qui permet de les optimiser pour votre machine&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; possibilité de créer des packages pour une installation rapide sur des machines clonées&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;

pour plus d&amp;#039;info : &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/portage&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:gentoo:portage&quot;&gt;Portage&lt;/a&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;notewarning&quot;&gt;&lt;b&gt;warning:&lt;/b&gt; dans ce tuto nous utiliserons :
&lt;/p&gt;
&lt;ol&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; un processeur supportant le 64bit (core2duo)&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; une version 64Bit de gentoo&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; du cryptage de partition avec une passphrase sur un volume raid1 avec 2 disques dur&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; une partition swap crypter&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; une installation à partir du stage1&lt;/div&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Pourquoi Gentoo ?&quot; [39-2066] --&gt;
&lt;h2&gt;&lt;a name=&quot;la-demarche&quot; id=&quot;la-demarche&quot;&gt;La démarche&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

&lt;/p&gt;
&lt;ol&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; demarrage sur un live cd&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; mise en place du reseau sur le liveCd&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; chargement des modules du kernel&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; preparation des disques dur pour l&amp;#039;installation&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; recuperation des images de / et de Portage sur le net&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; chroot du nouveau system&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; extraction du nouveau system&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; mise en place du kernel&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; mise en place du boot loader&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; reboot&lt;/div&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;La démarche&quot; [2067-2446] --&gt;
&lt;h2&gt;&lt;a name=&quot;preparation&quot; id=&quot;preparation&quot;&gt;Préparation&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

Télécharger la versions &lt;strong&gt;&lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/livecd&quot; class=&quot;wikilink2&quot; title=&quot;tuto:admin-sys:gentoo:livecd&quot; rel=&quot;nofollow&quot;&gt;LiveCD&lt;/a&gt;&lt;/strong&gt; (700Mo) de gentoo &lt;strong&gt;la plus récente&lt;/strong&gt; (2008 beta2 minimum) sur &lt;a href=&quot;http://www.gentoo.org&quot; class=&quot;urlextern&quot; title=&quot;http://www.gentoo.org&quot;  rel=&quot;nofollow&quot;&gt;www.gentoo.org&lt;/a&gt; dans sa version &lt;strong&gt;amd64&lt;/strong&gt; et gravé la sur un CD. 
&lt;/p&gt;

&lt;p&gt;
Démarrer la machine sur le CD, à la fin du démarrage vous devez arriver sur une partie graphique que nous n&amp;#039;allons pas utilisé puisque toute l&amp;#039;installation sera faite en ligne de commande (CMD).
&lt;/p&gt;

&lt;p&gt;
Pour aller sur la ligne de commande : &lt;kbd&gt;Ctrl&lt;/kbd&gt;+&lt;kbd&gt;Alt&lt;/kbd&gt;+&lt;kbd&gt;F1&lt;/kbd&gt; :
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; 
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
chargement du clavier en français : 
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; loadkeys fr
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;notewarning&quot;&gt;&lt;b&gt;warning:&lt;/b&gt; si vous n&amp;#039;arrivez pas la CMD et qu&amp;#039;il vous affiche des erreurs de montage filesystem, des erreurs de checksum ou même un kernel panic (diode du clavier qui clignote), votre CD doit être corrompu et je vous conseil de retélécharger l&amp;#039;&lt;acronym title=&quot;International Organization for Standardization&quot;&gt;ISO&lt;/acronym&gt; sur un autre mirror et de la graver sur un autre CD
&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteimportant&quot;&gt;&lt;b&gt;important:&lt;/b&gt; En cas de probleme de boot vous pouvez essayer les paramètres de boot suivant :
&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; boot: gentoo-nofb&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;
ou 
&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; boot: gentoo-nofb nodetect&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Préparation&quot; [2447-3525] --&gt;
&lt;h3&gt;&lt;a name=&quot;configration-du-reseau&quot; id=&quot;configration-du-reseau&quot;&gt;Configration du réseau&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

Première chose à configurer, le réseau. Juste au dessus de la CMD vous avez peut être une ligne ressemblant à ça :
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;&amp;nbsp;
&lt;span style=&quot;color: green&quot;&gt;*&lt;/span&gt; Network device eth0 detected, DHCP broadcasting for IP ...
&lt;span style=&quot;color: blue&quot;&gt;[&lt;/span&gt;
&lt;span style=&quot;color: green&quot;&gt;ok&lt;/span&gt;
&lt;span style=&quot;color: blue&quot;&gt;]&lt;/span&gt;
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
Si vous avez cette ligne c&amp;#039;est que votre carte réseau est détectée, sinon il vous faudra utiliser la commande :
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; lspci
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
pour identifier le driver nécessaire au fonctionnement de votre carte réseau ainsi qu&amp;#039;une commande de ce genre pour charger votre driver de carte reseau
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; modprobe r8169
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; modprobe 3w-9xxx
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
Vous pouvez configurer votre carte réseau grâce à la commande : 
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; net-setup eth0
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
pour moi le &lt;em&gt;net-setup&lt;/em&gt; a un problème et ne fonctionne pas j&amp;#039;ai donc &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/configuration-du-reseau&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:gentoo:configuration-du-reseau&quot;&gt;configuré le réseau à la main&lt;/a&gt;
&lt;/p&gt;

&lt;p&gt;
un petit ping google vous permettra de savoir si votre réseau fonctionne bien :) (&lt;kbd&gt;Ctrl&lt;/kbd&gt;+&lt;kbd&gt;C&lt;/kbd&gt;pour stopper ;))
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Configration du réseau&quot; [3526-4626] --&gt;
&lt;h3&gt;&lt;a name=&quot;serveur-ssh&quot; id=&quot;serveur-ssh&quot;&gt;serveur SSH&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

si vous voulez configurer votre pc à distance via une connexion ssh vous pouvez démarrer le serveur &lt;acronym title=&quot;Secure Shell&quot;&gt;SSH&lt;/acronym&gt; :
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; /etc/init.d/sshd start
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
Il vous faut aussi définir le mot de passe de l&amp;#039;utilisateur root :
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; passwd
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;!-- SECTION &quot;serveur SSH&quot; [4627-4953] --&gt;
&lt;h2&gt;&lt;a name=&quot;preparation-des-disques-durs&quot; id=&quot;preparation-des-disques-durs&quot;&gt;Préparation des disques durs&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

chargement des modules du kernel
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; modprobe dm-mod
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; modprobe raid1
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; modprobe dm-crypt
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; modprobe xts
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; modprobe aes
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; modprobe aes-x86_64
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; modprobe sha256
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
Si vos disques dur ont possédés des données sensible dans le passé il est conseillé de le remplir avec des données aléatoire avant de l&amp;#039;utiliser pour votre nouveau système.
&lt;/p&gt;

&lt;p&gt;
&lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/remplir-le-dur-avec-des-donnee-aleatoire&quot; class=&quot;wikilink2&quot; title=&quot;tuto:admin-sys:gentoo:remplir-le-dur-avec-des-donnee-aleatoire&quot; rel=&quot;nofollow&quot;&gt;remplir le dur avec des donnée aleatoire&lt;/a&gt;
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Préparation des disques durs&quot; [4954-5679] --&gt;
&lt;h3&gt;&lt;a name=&quot;partitionnement-du-disque-dur&quot; id=&quot;partitionnement-du-disque-dur&quot;&gt;Partitionnement du disque dur&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

configurer le disque dur

&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; fdisk /dev/sda
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
Pour voir le resultat :

&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; fdisk -l /dev/sda
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
plus d&amp;#039;info sur le partitionnement : &lt;a href=&quot;http://awired.net/tuto/admin-sys/gentoo/fdisk&quot; class=&quot;wikilink1&quot; title=&quot;tuto:admin-sys:gentoo:fdisk&quot;&gt;Utilisation de fdisk&lt;/a&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;notewarning&quot;&gt;&lt;b&gt;warning:&lt;/b&gt; puisque vos 2 disques dur monter en raid ne doivent pas être de la même marque l&amp;#039;un est surement légèrement plus gros que l&amp;#039;autre. &lt;strong&gt;il faut que les partitions soit exactement de la même taille sur les 2 disques dur et donc l&amp;#039;un des durs doit avoir de l&amp;#039;espace non utilisé&lt;/strong&gt;
&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;/div&gt;

&lt;h4&gt;&lt;a name=&quot;creation-des-volumes-raid&quot; id=&quot;creation-des-volumes-raid&quot;&gt;Création des volumes raid&lt;/a&gt;&lt;/h4&gt;
&lt;div class=&quot;level4&quot;&gt;

On commence par créer les nodes :
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; mknod /dev/md1 b 9 1
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; mknod /dev/md2 b 9 2
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; mknod /dev/md3 b 9 3
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; mknod /dev/md4 b 9 4
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteclassic&quot;&gt;&lt;b&gt;note:&lt;/b&gt; les 4 partitions : 
&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; md1 : partition raid1 de demarrage contenant le bootloader, le kernel et le initRamFS&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; md2 : partition raid1 de swap&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; md3 : partition raid1 contenant la racine du système&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; md4 : reste du disque du contenant vos fichiers&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteimportant&quot;&gt;&lt;b&gt;important:&lt;/b&gt; le tuto de gentoo.org sur l&amp;#039;installation sur du raid1 n&amp;#039;utilise pas la 2eme partition de chaque disque pour fait un swap en raid.
Il est pourtant important de l&amp;#039;utiliser en mode raid1 comme les autres car si un de vos disque dur lâche et que votre système utilise du swap sur le disque mort votre système deviendra instable et plantera.
Sachant que l&amp;#039;utilisation du raid1 sert a réaliser une tolérance de panne &lt;strong&gt;(et non un backup !!)&lt;/strong&gt;, si votre swap n&amp;#039;est pas en raid1, alors votre raid sur les autres partition ne sert à rien !! 

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
on crée les volumes raid : 
&lt;/p&gt;
&lt;pre class=&quot;console&quot;&gt;
livecd ~ # mdadm --create /dev/md1 --level=1 --raid-devices=2 /dev/sda1 /dev/sdb1
mdadm: array /dev/md1 started.
livecd ~ # mdadm --create /dev/md2 --level=1 --raid-devices=2 /dev/sda2 /dev/sdb2
mdadm: array /dev/md2 started.
livecd ~ # mdadm --create /dev/md3 --level=1 --raid-devices=2 /dev/sda3 /dev/sdb3
mdadm: array /dev/md3 started.
livecd ~ # mdadm --create /dev/md4 --level=1 --raid-devices=2 /dev/sda4 /dev/sdb4
mdadm: array /dev/md4 started.&lt;/pre&gt;
&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteclassic&quot;&gt;&lt;b&gt;note:&lt;/b&gt; je n&amp;#039;ai pas encore reçu mon 2eme disque dur j&amp;#039;ai donc crée les volumes raid avec un seul disque grâce a la commande : 

&lt;/p&gt;
&lt;pre class=&quot;code console&quot;&gt;livecd ~ # mdadm --create /dev/md1 --level=1 --force --raid-devices=1 /dev/sda1&lt;/pre&gt;
&lt;p&gt;

et j&amp;#039;ajouterai le 2eme disque au “array”

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
on attend la fin de la syncro :
&lt;/p&gt;
&lt;pre class=&quot;console&quot;&gt;
# cat /proc/mdstat
Personalities : [raid1]
md1 : active raid1 sdb1[1] sda1[0]
      195904 blocks [1/1] [UU]

md2 : active raid1 sdb2[1] sda2[0]
      195904 blocks [1/1] [UU]

md3 : active raid1 sdb3[1] sda3[0]
      19531392 blocks [1/1] [UU]

md4 : active raid1 sdb4[1] sda4[0]
      708940416 blocks [1/1] [UU]&lt;/pre&gt;
&lt;p&gt;
le boot ne peut être crypté puisque qu&amp;#039;il est nécessaire au démarrage de la machine
&lt;/p&gt;

&lt;p&gt;
par contre le / doit être crypté : 
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; cryptsetup -y --cipher aes-xts-plain:sha256 --key-size 256 luksFormat /dev/md3
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; cryptsetup -y --cipher aes-xts-plain:sha256 --key-size 256 luksFormat /dev/md4
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;notewarning&quot;&gt;&lt;b&gt;warning:&lt;/b&gt; si vous oubliez votre passphrase vos données sont perdu à tout jamais
&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;

on peut vérifier le cryptage du disque en lisant les premiers secteur de la partition :
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; hexdump -n 256 -C /dev/md3
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;

&lt;h4&gt;&lt;a name=&quot;montage-des-partitions&quot; id=&quot;montage-des-partitions&quot;&gt;Montage des partitions&lt;/a&gt;&lt;/h4&gt;
&lt;div class=&quot;level4&quot;&gt;

Ouverture du mapper permettant l&amp;#039;échange de donnée clair/crypté
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; cryptsetup luksOpen /dev/md3 root
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; cryptsetup luksOpen /dev/md4 raid
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
Cette commande va crée les nodes /dev/mapper/root et raid que vous allez pouvoir monter plus tard
&lt;/p&gt;

&lt;p&gt;

&lt;p&gt;&lt;div class=&quot;notewarning&quot;&gt;&lt;b&gt;warning:&lt;/b&gt; pour éviter de corrompre la partition crypté lors d&amp;#039;une coupure de courant il est vivement recommandé de désactiver le cache en écriture sur vos disque dur (inutile si vous possédez un onduleur)

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;#hdparm je c plus koi... :)&lt;/pre&gt;

&lt;p&gt;


&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
formatage des partitions :
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; mke2fs /dev/md1
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; mke2fs -j /dev/mapper/root
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; mke2fs -j /dev/mapper/raid
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;~ #&lt;/span&gt; mount /dev/mapper/root /mnt/gentoo
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;gentoo #&lt;/span&gt; cd /mnt/gentoo
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;gentoo #&lt;/span&gt; mkdir boot
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;gentoo #&lt;/span&gt; mount /dev/md1 /mnt/gentoo/boot
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;!-- SECTION &quot;Partitionnement du disque dur&quot; [5680-10340] --&gt;
&lt;h2&gt;&lt;a name=&quot;installation-du-stage&quot; id=&quot;installation-du-stage&quot;&gt;Installation du stage&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

le stage est la base de votre linux avec un bootstrap (processus de démarrage) + les programme de base

&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Stage1 : le bootstrap doit être créé et la base du système doit être compilée&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Stage2 : le bootstrap existe et la base du système doit être compilée&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; Stage3 : le bootstrap existe et la base du système est compilée&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;

Les système à base de stages 1 et 2 ne sont plus gérer par le support technique de Gentoo mais il peut être intéressant de savoir configurer son système depuis la toute première base ou meme d&amp;#039;avoir la base de son systeme optimiser pour la machine
&lt;/p&gt;

&lt;p&gt;
choisir le stage sur un mirror Gentoo
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;gentoo #&lt;/span&gt; links http://www.gentoo.org/main/en/mirrors.xml
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
on telecharge le stage :
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;gentoo #&lt;/span&gt; wget ftp://ftp.free.fr/mirrors/ftp.gentoo.org/releases/amd64/2007.0/stages/stage1-amd64-2007.0.tar.bz2
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
on l&amp;#039;extrait : 
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;gentoo #&lt;/span&gt; tar xjpf stage1-amd64-2007.0.tar.bz2
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;gentoo #&lt;/span&gt; cd /mnt/gentoo/usr
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
on telecharge la derniere version des packages portage :
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;usr #&lt;/span&gt; wget ftp://ftp.free.fr/mirrors/ftp.gentoo.org/snapshots/portage-latest.tar.bz2
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
on l&amp;#039;extrait : 
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;usr #&lt;/span&gt; tar xjf portage-latest.tar.bz2
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;!-- SECTION &quot;Installation du stage&quot; [10341-11740] --&gt;
&lt;h3&gt;&lt;a name=&quot;chroot-dans-le-nouveau-system&quot; id=&quot;chroot-dans-le-nouveau-system&quot;&gt;Chroot dans le nouveau system&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;


&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;usr #&lt;/span&gt; cd /
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;/ #&lt;/span&gt; mount -t proc proc /mnt/gentoo/proc
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;/ #&lt;/span&gt; cp -L /etc/resolv.conf /mnt/gentoo/etc/
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;/ #&lt;/span&gt; chroot /mnt/gentoo /bin/bash
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;/ #&lt;/span&gt; env-update &amp;&amp; source /etc/profile
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;&gt;&gt;&gt; Regenerating /etc/ld.so.cache...&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;/div&gt;
&lt;!-- SECTION &quot;Chroot dans le nouveau system&quot; [11741-12230] --&gt;
&lt;h2&gt;&lt;a name=&quot;installation-du-systeme&quot; id=&quot;installation-du-systeme&quot;&gt;Installation du système&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;


&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;/ #&lt;/span&gt; cd /usr/portage/scripts
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;scripts #&lt;/span&gt; ./bootstrap.sh
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;scripts #&lt;/span&gt; emerge -e system
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;notewarning&quot;&gt;&lt;b&gt;warning:&lt;/b&gt; pour moi emerge system echoue car &lt;em&gt;Locale_gettext&lt;/em&gt; est emerge avant perl
il faut donc
emerge perl
emerge Locale_gettext
emerge -e system

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;notewarning&quot;&gt;&lt;b&gt;warning:&lt;/b&gt; attr ne trouve pas la lib libexpat.so.0 car une nouvelle version est apparemment sortie et donc il n&amp;#039;existe plus que libexpat.so.1 il faut donc faire un lien symbolique de la nouvelle version vers l&amp;#039;ancienne : 
&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; #ln -s /lib64/libexpat.so.1 /lib64/libexpat.so.0&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;
ou
&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; un revdep-rebuilds…&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;/div&gt;

&lt;h4&gt;&lt;a name=&quot;passage-en-gcc-4.3.1&quot; id=&quot;passage-en-gcc-4.3.1&quot;&gt;passage en gcc 4.3.1&lt;/a&gt;&lt;/h4&gt;
&lt;div class=&quot;level4&quot;&gt;

nano /etc/portage/package.keywords

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
sys-devel/gcc ~amd64
sys-libs/glibc ~amd64&lt;/pre&gt;&lt;pre class=&quot;code console&quot;&gt;# emerge -vp =gcc-4.3.1&lt;/pre&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;scripts #&lt;/span&gt; gcc-config x86_64-pc-linux-gnu-4.3.1
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;scripts #&lt;/span&gt; source /etc/profile
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
Apres ça vous pouvez changer le &lt;em&gt;march&lt;/em&gt; de votre /etc/make.conf en core2 : 

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
CFLAGS=&quot;-O2 -march=core2 -pipe&quot;&lt;/pre&gt;
&lt;/div&gt;
&lt;!-- SECTION &quot;Installation du système&quot; [12231-13404] --&gt;
&lt;h3&gt;&lt;a name=&quot;mise-en-place-du-initramfs-busybox&quot; id=&quot;mise-en-place-du-initramfs-busybox&quot;&gt;mise en place du initramfs &amp;amp; busybox&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

/etc/portage/package.use

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
sys-fs/cryptsetup -dynamic static
sys-fs/mdadm -dynamic static&lt;/pre&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; emerge sys-fs/device-mapper
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; emerge sys-fs/cryptsetup
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; emerge mdadm
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
maintenant on emerge busybox dans un autre root

&lt;/p&gt;
&lt;pre class=&quot;console&quot;&gt;
# ROOT=&quot;/tmp/bb&quot; USE=&quot;static -readline savedconfig&quot; FEATURES=keepwork emerge busybox
&amp;#60;code&amp;#62;
{{template&amp;#62;tpl:cmd|host=livecd|path=root|cmd=cd /var/tmp/portage/busybox*/work}}

on configure les option de compilation de busybox pour le faire compiler en static :

{{template&amp;#62;tpl:cmd|host=livecd|path=root|cmd=make menuconfig}}

&amp;#60;code&amp;#62;
Busybox Settings ---&amp;#62; Build Options ---&amp;#62;
  [*] Build BusyBox as a static binary (no shared libs)&lt;/pre&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; make -j3
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;notewarning&quot;&gt;&lt;b&gt;warning:&lt;/b&gt; 
Ma compilation échoue sur un flag de pam qui est totalement inutile dans notre cas :
nano .config et recherchez la ligne comprenant &amp;#039;pam&amp;#039; et passer sa valeur a &amp;#039;n&amp;#039;

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; mkdir /root/myroot
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; cd /root/myroot
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; mkdir bin dev proc new sys
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; cp /bin/busybox bin/
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; cp /sbin/cryptsetup bin/
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; cp /sbin/mdadm bin/
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; cd /root/myroot/bin
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; for i in echo mkdir mknod mount sed sh switch_root test touch umount
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;&gt; do&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;&gt;     ln busybox $i&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;&gt; done&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; cd /root/myroot/dev
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; mknod -m600 console c 5 1
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; mknod -m660 null c 1 3
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; mknod -m660 ram0 b 1 0
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; mknod -m666 tty c 5 0
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; mkdir vc
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; ln -s console vc/0
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; mkdir /dev/vc
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; ln -s /dev/console /dev/vc/0
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; cd /root/myroot
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; ./bin/busybox dumpkmap &gt; fr-x86_64.bin
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; nano /root/myroot/init
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;pre class=&quot;code bash&quot;&gt;&lt;span class=&quot;co0&quot;&gt;#!/bin/sh&lt;/span&gt;
&lt;span class=&quot;co0&quot;&gt;# Awired.net init ram fs scrypt&lt;/span&gt;
&amp;nbsp;
&lt;span class=&quot;kw3&quot;&gt;export&lt;/span&gt; &lt;span class=&quot;re2&quot;&gt;PATH=&lt;/span&gt;&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin:&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;sbin
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;# mount proc&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;busybox &lt;span class=&quot;kw2&quot;&gt;mount&lt;/span&gt; -t proc proc &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;proc
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#mount sys&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;busybox &lt;span class=&quot;kw2&quot;&gt;mount&lt;/span&gt; -t sysfs sysfs &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;sys
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#detect raid&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;mdadm --auto-detect
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#detect devices&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;busybox mdev -s
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#create console node for keyboard&lt;/span&gt;
&lt;span class=&quot;kw2&quot;&gt;rm&lt;/span&gt; -f &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;vc&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nu0&quot;&gt;0&lt;/span&gt;
&lt;span class=&quot;kw2&quot;&gt;mkdir&lt;/span&gt; &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;vc
&lt;span class=&quot;kw2&quot;&gt;ln&lt;/span&gt; -s &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;console &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;vc&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;nu0&quot;&gt;0&lt;/span&gt;
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#load keyboard&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;busybox loadkmap &lt;span class=&quot;sy0&quot;&gt;&amp;lt;&lt;/span&gt; fr-x86_64.bin
&lt;span class=&quot;kw3&quot;&gt;echo&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&amp;quot;NOW KEYBOARD IS IN FRENCH !!&amp;quot;&lt;/span&gt;
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#decrypt root&lt;/span&gt;
&lt;span class=&quot;kw3&quot;&gt;echo&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&amp;quot;mount root :&amp;quot;&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;cryptsetup -y luksOpen &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;md3 root
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#decrypt raid&lt;/span&gt;
&lt;span class=&quot;kw3&quot;&gt;echo&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&amp;quot;mount raid :&amp;quot;&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;cryptsetup -y luksOpen &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;md4 raid
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#mount boot&lt;/span&gt;
&lt;span class=&quot;kw3&quot;&gt;echo&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&amp;quot;mount boot :&amp;quot;&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;busybox &lt;span class=&quot;kw2&quot;&gt;mount&lt;/span&gt; &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;md1 &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;boot
&lt;span class=&quot;kw3&quot;&gt;echo&lt;/span&gt; &lt;span class=&quot;st0&quot;&gt;&amp;quot;exec myinit :&amp;quot;&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;boot&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;myinit
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#mount root&lt;/span&gt;
&lt;span class=&quot;kw2&quot;&gt;mount&lt;/span&gt; -r &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;mapper&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;root &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;new
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#create swap&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;cryptsetup -c aes-xts-plain:sha256 --key-&lt;span class=&quot;kw2&quot;&gt;size&lt;/span&gt; &lt;span class=&quot;nu0&quot;&gt;256&lt;/span&gt; -d &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;urandom create swap &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;md2
mkswap &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;dev&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;mapper&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;swap
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#en cas de pb pour faire kke traitement a la main :)&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;&lt;span class=&quot;kw2&quot;&gt;sh&lt;/span&gt;
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#clean&lt;/span&gt;
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;busybox &lt;span class=&quot;kw2&quot;&gt;umount&lt;/span&gt; &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;boot
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;busybox &lt;span class=&quot;kw2&quot;&gt;umount&lt;/span&gt; &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;sys
&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;busybox &lt;span class=&quot;kw2&quot;&gt;umount&lt;/span&gt; &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;proc
&amp;nbsp;
&lt;span class=&quot;co0&quot;&gt;#start real root&lt;/span&gt;
&lt;span class=&quot;kw3&quot;&gt;exec&lt;/span&gt; &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;bin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;busybox switch_root &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;new &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;sbin&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;init `&lt;span class=&quot;kw2&quot;&gt;cat&lt;/span&gt; &lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;proc&lt;span class=&quot;sy0&quot;&gt;/&lt;/span&gt;cmdline`&lt;/pre&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; localhost myroot # chmod +x init
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; cd /tmp/myroot
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; find . -print
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; cp ../myiramfs /boot
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;notetip&quot;&gt;&lt;b&gt;tip:&lt;/b&gt; 
pour afficher le contenu du fichier

&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; zcat myiramfs
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;


&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;notetip&quot;&gt;&lt;b&gt;tip:&lt;/b&gt; 
pour tester le bon fonctionnement de votre initramfs :

&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; chroot /root/myroot/ /bin/sh
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;

si vous obtenez le shell sh alors votre ramfs devrai reussir a booter
&lt;/p&gt;

&lt;p&gt;

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;mise en place du initramfs &amp; busybox&quot; [13405-17838] --&gt;
&lt;h3&gt;&lt;a name=&quot;compilation-du-kernel&quot; id=&quot;compilation-du-kernel&quot;&gt;Compilation du kernel&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;


&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
sys-kernel/gentoo-sources ~amd64&lt;/pre&gt;
&lt;p&gt;

on install le kernel via portage :
&lt;/p&gt;

&lt;p&gt;
#emerge gentoo-sources
&lt;/p&gt;

&lt;p&gt;
livecd etc # cd /usr/src/linux
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteclassic&quot;&gt;&lt;b&gt;note:&lt;/b&gt; &amp;#039;/usr/src/&amp;#039; contient les différent kernel présent sur le système et &amp;#039;/usr/src/linux/&amp;#039; est un lien symbolique vers le kernel actuel
&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
on lance la configuration du kernel en graphique
&lt;/p&gt;

&lt;p&gt;
livecd linux # make menuconfig
&lt;/p&gt;

&lt;p&gt;
pour la première compilation le plus important est d&amp;#039;ajouter votre driver de carte réseau et d&amp;#039;ajouter le driver raid 

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
Processor type and features  ---&amp;#62;
Processor family (Generic-x86-64)  ---&amp;#62;
(X) Core 2/newer Xeon






Device Drivers  ---&amp;#62;
Multi-device support (RAID and LVM)  ---&amp;#62;
[*] Multiple devices driver support (RAID and LVM)
&amp;#60;*&amp;#62;   RAID support
&amp;#60;*&amp;#62;   RAID-1 (mirroring) mode
Network device support  ---&amp;#62;
Ethernet (10 or 100Mbit)  ---&amp;#62;
[*] 3COM cards
&amp;#60;*&amp;#62;   3c590/3c900 series (592/595/597) &quot;Vortex/Boomerang&quot; support
&amp;#60;*&amp;#62;   RealTek RTL-8129/8130/8139 PCI Fast Ethernet Adapter support




Device Drivers  ---&amp;#62;
  Block devices  ---&amp;#62;
    &amp;#60;*&amp;#62; Loopback device support
    &amp;#60; &amp;#62;   Cryptoloop Support
    (4096) Default RAM disk size (kbytes)
    [*]   Initial RAM disk (initrd) support
  Multi-device support (RAID and LVM)  ---&amp;#62;
    &amp;#60;*&amp;#62;   Device mapper support
    &amp;#60;*&amp;#62;     Crypt target support
Cryptographic options  ---&amp;#62;
    &amp;#60;*&amp;#62;   SHA256 digest algorithm
    &amp;#60;*&amp;#62;   AES cipher algorithms (i586)
&amp;#60;*&amp;#62;   XTS support (EXPERIMENTAL)&lt;/pre&gt;
&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteclassic&quot;&gt;&lt;b&gt;note:&lt;/b&gt; l&amp;#039;étoile signifie que le driver sera integrer directement dans le kernel et le &amp;#039;M&amp;#039; signifie qu&amp;#039;il sera installer en temps que module du kernel
&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteclassic&quot;&gt;&lt;b&gt;note:&lt;/b&gt; la configuration du kernel peut-être faite directement à la main dans le fichier ”.config” à la racine du kernel
&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
une fois la configuration achever on peut lancer la compilation du kernel :
&lt;/p&gt;

&lt;p&gt;
livecd linux # make -j3
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteclassic&quot;&gt;&lt;b&gt;note:&lt;/b&gt; l&amp;#039;option -j3 sert à définir le nombre de processus utilisé pour la compilation. Sa valeur est en général égal au nombre de processeur ou core de votre machine + 1 (pour un core2duo : -j3. pour un core2quad : -j5)
&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
on copie le kernel vers la partition de boot
&lt;/p&gt;

&lt;p&gt;
livecd linux # cp arch/i386/boot/bzImage /boot/kernel
&lt;/p&gt;

&lt;p&gt;
on installe les modules dans le système :
&lt;/p&gt;

&lt;p&gt;
livecd linux # make modules_install
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Compilation du kernel&quot; [17839-20100] --&gt;
&lt;h3&gt;&lt;a name=&quot;installation-du-bootloader-grub&quot; id=&quot;installation-du-bootloader-grub&quot;&gt;installation du bootloader grub&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

emerge grub
&lt;/p&gt;

&lt;p&gt;
&lt;p&gt;&lt;div class=&quot;noteclassic&quot;&gt;&lt;b&gt;note:&lt;/b&gt; 

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;emerge --config =grub-0.97-r5&lt;/pre&gt;

&lt;p&gt;

pour une installation sur le boot

&lt;/div&gt;&lt;/p&gt;
&lt;/p&gt;

&lt;p&gt;
livecd conf.d # nano -w /boot/grub/grub.conf
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
default 0
timeout 2

title Gentoo
root (hd0,0)
kernel /boot/kernel root=/dev/md3



title Gentoo
root (hd0,0)
kernel /boot/kernel root=/dev/ram0 rw init=/init
initrd /myiramfs&lt;/pre&gt;
&lt;p&gt;

livecd conf.d # grub
Probing devices to guess BIOS drives. This may take a long time.
&lt;/p&gt;

&lt;p&gt;
grub&amp;gt; root (hd0,0)
 Filesystem type is ext2fs, partition type 0xfd
&lt;/p&gt;

&lt;p&gt;
grub&amp;gt; setup (hd0)
 Checking if ”/boot/grub/stage1” exists… yes
 Checking if ”/boot/grub/stage2” exists… yes
 Checking if ”/boot/grub/e2fs_stage1_5” exists… yes
 Running “embed /boot/grub/e2fs_stage1_5 (hd0)”…  16 sectors are embedded.
succeeded
 Running “install /boot/grub/stage1 (hd0) (hd0)1+16 p (hd0,0)/boot/grub/stage2 /boot/
grub/menu.lst”… succeeded
Done.
&lt;/p&gt;

&lt;p&gt;
grub&amp;gt; root (hd1,0)
 Filesystem type is ext2fs, partition type 0xfd
&lt;/p&gt;

&lt;p&gt;
grub&amp;gt; setup (hd1)
&lt;/p&gt;

&lt;p&gt;
grub&amp;gt; quit
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;installation du bootloader grub&quot; [20101-21118] --&gt;
&lt;h2&gt;&lt;a name=&quot;configuration-du-systeme&quot; id=&quot;configuration-du-systeme&quot;&gt;configuration du système&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

livecd linux # cd /etc
livecd etc # nano -w fstab
/dev/md1          /boot                   ext2  noauto,noatime  1 2
/dev/md3          /                       ext3  noatime         0 1
/dev/md2          none                    swap  sw              0 0
&lt;/p&gt;

&lt;/div&gt;

&lt;h4&gt;&lt;a name=&quot;configurtation-du-mot-de-pass-root&quot; id=&quot;configurtation-du-mot-de-pass-root&quot;&gt;configurtation du mot de pass root&lt;/a&gt;&lt;/h4&gt;
&lt;div class=&quot;level4&quot;&gt;

mot de pass root :
&lt;/p&gt;

&lt;p&gt;

#passwd
&lt;/p&gt;

&lt;/div&gt;

&lt;h4&gt;&lt;a name=&quot;configuration-du-clavier&quot; id=&quot;configuration-du-clavier&quot;&gt;configuration du clavier&lt;/a&gt;&lt;/h4&gt;
&lt;div class=&quot;level4&quot;&gt;

pour éviter de se demander pourquoi le mot de passe qu&amp;#039;on vient juste de définir au dessus ne fonctionne pas après le premier démarrage on va définir la langue du clavier par défaut :
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
/etc/conf.d/keymaps
KEYMAP=&quot;fr&quot;&lt;/pre&gt;
&lt;/div&gt;

&lt;h4&gt;&lt;a name=&quot;configuration-du-reseau&quot; id=&quot;configuration-du-reseau&quot;&gt;Configuration du réseau&lt;/a&gt;&lt;/h4&gt;
&lt;div class=&quot;level4&quot;&gt;

livecd etc # cd conf.d
livecd conf.d # echo &amp;#039;config_eth0=( “192.168.1.10/24” )&amp;#039; » net
livecd conf.d # echo &amp;#039;routes_eth0=( “default via 192.168.1.1” )&amp;#039; » net
livecd conf.d # rc-update add net.eth0 default
&lt;/p&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;configuration du système&quot; [21119-22001] --&gt;
&lt;h3&gt;&lt;a name=&quot;autre-configuration&quot; id=&quot;autre-configuration&quot;&gt;Autre configuration&lt;/a&gt;&lt;/h3&gt;
&lt;div class=&quot;level3&quot;&gt;

(If you compiled your network card driver as a module,
add it to /etc/modules.autoload.d/kernel-2.6)
echo r8169 » /etc/modules.autoload.d/kernel-2.6

&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;livecd conf.d # rc-update add sshd default&lt;/pre&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;Autre configuration&quot; [22002-22241] --&gt;
&lt;h2&gt;&lt;a name=&quot;reboot&quot; id=&quot;reboot&quot;&gt;reboot&lt;/a&gt;&lt;/h2&gt;
&lt;div class=&quot;level2&quot;&gt;

&lt;/p&gt;
&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; exit
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; cd /
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; umount /mnt/gentoo/boot /mnt/gentoo
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;&lt;div class=&quot;templater&quot;&gt;
&lt;div style=&quot;background-color: black; color: #bbbbbb; font-family: courier new&quot;&gt;
&lt;span style=&quot;color: #ff5555&quot;&gt;livecd&lt;/span&gt; &lt;span style=&quot;color: #5555ff&quot;&gt;root #&lt;/span&gt; reboot
&lt;/div&gt;


&lt;/p&gt;
&lt;/div&gt;
&lt;p&gt;

source :
&lt;/p&gt;
&lt;ul&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://gentoo-wiki.com/SECURITY_Encrypting_Root_Filesystem_with_DM-Crypt_with_LUKS&quot; class=&quot;urlextern&quot; title=&quot;http://gentoo-wiki.com/SECURITY_Encrypting_Root_Filesystem_with_DM-Crypt_with_LUKS&quot;  rel=&quot;nofollow&quot;&gt;http://gentoo-wiki.com/SECURITY_Encrypting_Root_Filesystem_with_DM-Crypt_with_LUKS&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://gentoo-wiki.com/SECURITY_Encrypting_an_existing_root_partition_DM-Crypt_with_LUKS&quot; class=&quot;urlextern&quot; title=&quot;http://gentoo-wiki.com/SECURITY_Encrypting_an_existing_root_partition_DM-Crypt_with_LUKS&quot;  rel=&quot;nofollow&quot;&gt;http://gentoo-wiki.com/SECURITY_Encrypting_an_existing_root_partition_DM-Crypt_with_LUKS&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; &lt;a href=&quot;http://gentoo-wiki.com/SECURITY_System_Encryption_DM-Crypt_with_LUKS#Ciphers&quot; class=&quot;urlextern&quot; title=&quot;http://gentoo-wiki.com/SECURITY_System_Encryption_DM-Crypt_with_LUKS#Ciphers&quot;  rel=&quot;nofollow&quot;&gt;http://gentoo-wiki.com/SECURITY_System_Encryption_DM-Crypt_with_LUKS#Ciphers&lt;/a&gt;&lt;/div&gt;
&lt;/li&gt;
&lt;li class=&quot;level1&quot;&gt;&lt;div class=&quot;li&quot;&gt; google…&lt;/div&gt;
&lt;/li&gt;
&lt;/ul&gt;

&lt;/div&gt;
&lt;!-- SECTION &quot;reboot&quot; [22242-] --&gt;&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/gentoo/installation-de-gentoo&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/gentoo/installation-de-gentoo&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/gentoo/installation-de-gentoo&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/tuto/admin-sys/gentoo/postgresql">
        <dc:format>text/html</dc:format>
        <dc:date>2008-07-06T11:43:02+01:00</dc:date>
        <dc:creator>n0rad</dc:creator>
        <title></title>
        <link>http://awired.net/tuto/admin-sys/gentoo/postgresql</link>
        <description>&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/gentoo/postgresql&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/gentoo/postgresql&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/gentoo/postgresql&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
    <item rdf:about="http://awired.net/tuto/admin-sys/gentoo/vmware">
        <dc:format>text/html</dc:format>
        <dc:date>2008-07-05T14:13:30+01:00</dc:date>
        <dc:creator>n0rad</dc:creator>
        <title>vmware</title>
        <link>http://awired.net/tuto/admin-sys/gentoo/vmware</link>
        <description>
&lt;/p&gt;

&lt;div class=&quot;level2&quot;&gt;


&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
Enable loadable module support  ---&amp;#62;
 [*] Module unloading

&lt;p&gt;

&lt;/p&gt;

&lt;p&gt;
lisez la licence et quittez grâce a &amp;#039;q&amp;#039;
&lt;/p&gt;

&lt;p&gt;
configurer le réseau
&lt;/p&gt;

&lt;p&gt;

bridger sur eth0
&lt;/p&gt;

&lt;p&gt;
pas de nat
&lt;/p&gt;

&lt;p&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;/p&gt;

&lt;p&gt;
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
{
    disable         = no
    port            = 902
    socket_type     = stream
    protocol        = tcp
    wait            = no
    user            = root
    type            = unlisted
    only_from       = 192.168.42.0/24
}&lt;/pre&gt;
&lt;p&gt;
#nano /etc/group
&lt;/p&gt;
&lt;pre class=&quot;code&quot;&gt;
&lt;p&gt;
# /etc/init.d/xinetd restart
rc-update add xinetd default
&lt;/p&gt;

&lt;p&gt;
&lt;/p&gt;

&lt;/div&gt;
&lt;a href=&quot;http://digg.com/submit?phase=2&amp;url=http://awired.net/tuto/admin-sys/gentoo/vmware&quot; title=&quot;Digg this post&quot;&gt;Digg this post&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://www.stumbleupon.com/submit?url=http://awired.net/tuto/admin-sys/gentoo/vmware&quot; title=&quot;Digg this post&quot;&gt;Stumble it&lt;/a&gt; &amp;middot;
&lt;a href=&quot;http://del.icio.us/post/?url=http://awired.net/tuto/admin-sys/gentoo/vmware&quot; title=&quot;Save to del.icio.us&quot;&gt;Save to del.icio.us&lt;/a&gt;
</description>
    </item>
</rdf:RDF>
