<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Void And Any &#187; boot</title>
	<atom:link href="http://voidandany.free.fr/index.php/tag/boot/feed/" rel="self" type="application/rss+xml" />
	<link>http://voidandany.free.fr</link>
	<description>mon bazar...</description>
	<lastBuildDate>Sat, 09 Dec 2017 09:24:06 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1</generator>
		<item>
		<title>Démarrer le serveur X avec un utilisateur non connecté</title>
		<link>http://voidandany.free.fr/index.php/demarrer-le-serveur-x-avec-un-utilisateur-non-connecte/</link>
		<comments>http://voidandany.free.fr/index.php/demarrer-le-serveur-x-avec-un-utilisateur-non-connecte/#comments</comments>
		<pubDate>Fri, 11 Sep 2009 12:08:21 +0000</pubDate>
		<dc:creator>voidAndAny</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[boot]]></category>
		<category><![CDATA[user]]></category>
		<category><![CDATA[xorg]]></category>

		<guid isPermaLink="false">http://voidandany.free.fr/?p=1048</guid>
		<description><![CDATA[Pour rappel le serveur X, est le serveur gérant l&#8217;affichage graphique (par opposition à l&#8217;affichage console = des lignes sur fond noir) de fenêtre. X est le nom générique, 2 projets principaux peuvent être nommé ainsi XFree86 tombé en désuétude &#8230; <a href="http://voidandany.free.fr/index.php/demarrer-le-serveur-x-avec-un-utilisateur-non-connecte/">Continuer la lecture <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><br class="spacer_" /></p>
<p>Pour rappel le serveur X, est le serveur gérant l&#8217;affichage graphique (par opposition à l&#8217;affichage console = des lignes sur fond noir) de fenêtre.</p>
<p>X est le nom générique, 2 projets principaux peuvent être nommé ainsi XFree86 tombé en désuétude et Xorg utilisé sur la plupart des distributions.</p>
<p><br class="spacer_" /></p>
<p>Par défaut xorg peut être lancé par n&#8217;importe quelle utilisateur étant loggué sur une console, mais il se peut que l&#8217;on veuille lancer X dans un script d&#8217;init par exemple ou personne n&#8217;est loggué.</p>
<p>Typiquement mon <a href="http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-3/" target="_blank">script d&#8217;init freevo</a> lance la commande &laquo;&nbsp;freevo -fs&nbsp;&raquo; qui elle même se charge de lancer X, cette commande étant lancée par l&#8217;utilisateur freevo (pas admin/root), le lancement échoue avec le message suivant :</p>
<pre>X: user not authorized to run the X server, aborting.</pre>
<p><br class="spacer_" /></p>
<p>Pour y remédier 2 solutions :</p>
<p><br class="spacer_" /></p>
<h3>En éditant le fchier de configuration</h3>
<p><br class="spacer_" /></p>
<p>Editer le fichier <strong>/etc/X11/Xwrapper.conf</strong> éditer la ligne suivante pour autoriser n&#8217;importe qui (anybody) à lancer X :</p>
<pre>allowed_users=anybody</pre>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<h3>En reconfigurant le package</h3>
<p><br class="spacer_" /></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span>  dpkg-reconfigure x11-common</pre></div></div>

<p><br class="spacer_" /></p>
<p>Dans le bel écran ncurse qui apparait :</p>
<div id="attachment_1054" class="wp-caption aligncenter" style="width: 310px"><a href="http://voidandany.free.fr/wp-content/uploads/2009-09-10_140742.png"><img class="size-medium wp-image-1054" title="dpkg-reconfigure x11-common" src="http://voidandany.free.fr/wp-content/uploads/2009-09-10_140742-300x166.png" alt="dpkg-reconfigure x11-common" width="300" height="166" /></a><p class="wp-caption-text">dpkg-reconfigure x11-common</p></div>
<p><br class="spacer_" /></p>
<p>Choisir :</p>
<p>&laquo;&nbsp;N&#8217;importe qui&nbsp;&raquo;</p>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
]]></content:encoded>
			<wfw:commentRss>http://voidandany.free.fr/index.php/demarrer-le-serveur-x-avec-un-utilisateur-non-connecte/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Démarrer un PC via le réseau : Wake on LAN</title>
		<link>http://voidandany.free.fr/index.php/demarrer-un-pc-via-le-reseau-wake-on-lan/</link>
		<comments>http://voidandany.free.fr/index.php/demarrer-un-pc-via-le-reseau-wake-on-lan/#comments</comments>
		<pubDate>Wed, 02 Sep 2009 11:56:43 +0000</pubDate>
		<dc:creator>voidAndAny</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[boot]]></category>
		<category><![CDATA[réseau]]></category>
		<category><![CDATA[WOL]]></category>

		<guid isPermaLink="false">http://voidandany.free.fr/?p=906</guid>
		<description><![CDATA[Il peut être utile (par exemple dans le cadre d&#8217;un script de sauvegarde) de pouvoir démarrer une machine distante via le réseau. Cette pratique s&#8217;appelle le Wake On Lan (WOL). En pré-requis il faut que la machine à reveiller soit &#8230; <a href="http://voidandany.free.fr/index.php/demarrer-un-pc-via-le-reseau-wake-on-lan/">Continuer la lecture <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Il peut être utile (par exemple dans le cadre d&#8217;un script de sauvegarde) de pouvoir <strong>démarrer une machine distante</strong> via le réseau.</p>
<p>Cette pratique s&#8217;appelle le <strong>Wake On Lan</strong> (WOL).</p>
<p>En pré-requis il faut que la machine à reveiller soit sur un réseau local et qu&#8217;elle soit connecté via RJ45 ou  CPL (<strong>pas de WiFi</strong>)</p>
<p>Pour réveiller un PC on doit connaître <strong>l&#8217;adresse MAC</strong> de sa carte réseau, pour cela :</p>
<ul>
<li>Sous Linux : </li>
</ul>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">ifconfig</span></pre></div></div>

<p>L&#8217;adresse MAC se trouve sur la première ligne, zone HWaddr</p>
<ul>
<li>Sous Windows : </li>
</ul>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">ipconfig <span style="color: #000000; font-weight: bold;">/</span>all</pre></div></div>

<p>L&#8217;adresse MAC est désignée par &laquo;&nbsp;Adresse Physique&nbsp;&raquo;, la noter en remplaçant les &#8211; par des :</p>
<p><br class="spacer_" /></p>
<p>Éteindre le PC à réveiller.</p>
<p>Sur le PC Linux devant effectuer le réveil il faut ensuite installer le paquet wakeonlan :</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">aptitude</span> wakeonlan</pre></div></div>

<p><br class="spacer_" /></p>
<p>Il suffira ensuite pour réveiller le PC voulu de saisir la commande suivante :</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;">wakeonlan <span style="color: #7a0874; font-weight: bold;">&#91;</span>Adresse MAC<span style="color: #7a0874; font-weight: bold;">&#93;</span></pre></div></div>

<p>&nbsp;</p>
<p><strong>Edit 264/06/2011 :</strong> Voir aussi mon article <a title="Lien permanent vers Allumer / éteindre un PC sous Linux à distance (scripts)" rel="bookmark" href="../index.php/allumer-eteindre-un-pc-sous-linux-a-distance-scripts/">Allumer / éteindre un PC sous Linux à distance (scripts)</a></p>
<p>&nbsp;</p>
<p><strong><em><span style="text-decoration: underline;">Remarque :</span></em></strong></p>
<p>Si cela ne fonctionne pas, il se peut que la fonctionnalité de WOL soit désactivé sur votre carte réseau.</p>
<p>Pour s&#8217;en assurer sur un PC Linux :</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> ethtool eth0</pre></div></div>

<p>Qui doit renvoyer :</p>
<pre>Supports Wake-on: g</pre>
<p>Si ce n&#8217;est pas le cas lancer la commande, je vous conseille la lecture de l&#8217;article indiqué dans les source de ce post (chez moi cela à toujours fonctionné du premier coup&#8230;)</p>
<p><br class="spacer_" /></p>
<p><strong><em><span style="text-decoration: underline;">Sources :</span></em></strong></p>
<p><a href="http://doc.ubuntu-fr.org/wakeonlan">http://doc.ubuntu-fr.org/wakeonlan</a></p>
<p><a href="http://doc.ubuntu-fr.org/wake-on-lan"></a></p>
]]></content:encoded>
			<wfw:commentRss>http://voidandany.free.fr/index.php/demarrer-un-pc-via-le-reseau-wake-on-lan/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Démarrer automatiquement Freevo (méthode 3)</title>
		<link>http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-3/</link>
		<comments>http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-3/#comments</comments>
		<pubDate>Fri, 03 Jul 2009 08:01:58 +0000</pubDate>
		<dc:creator>voidAndAny</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[boot]]></category>
		<category><![CDATA[freevo]]></category>
		<category><![CDATA[mediacenter]]></category>

		<guid isPermaLink="false">http://voidandany.free.fr/?p=746</guid>
		<description><![CDATA[Dernier article listant les possibilités pour démarrer freevo automatiquement au démarrage de votre HTPC. Dans le premier article le démarrage se faisait via l’auto-login d’un utilisateur et l’utilisation du fichier bash_profil. Enfin dans cet article, j&#8217;expliquai la mise en œuvre d&#8217;un script d&#8217;init, &#8230; <a href="http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-3/">Continuer la lecture <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Dernier article listant les possibilités pour démarrer freevo automatiquement au démarrage de votre HTPC.</p>
<p>Dans le premier <a href="http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-1/" target="_blank">article</a> le démarrage se faisait via l’auto-login d’un utilisateur et l’utilisation du fichier bash_profil.</p>
<p>Enfin dans cet <a href="http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-2/" target="_blank">article</a>, j&#8217;expliquai la mise en œuvre d&#8217;un script d&#8217;init, par contre freevo était lancé avec le user root et je concluais l&#8217;article en indiquant que j&#8217;expliqerai comment utiliser start-stop-deamon pour changer cet utilisateur.</p>
<p><br class="spacer_" /></p>
<p>Après pas mal d&#8217;essai je peux conclure que l&#8217;utilisation start-stop-deamon est un echec.</p>
<p>Pour des raisons qui m&#8217;échappent (surement des histoire de PID), on peut démarrer Freevo (et ses composants) avec start-stop-deamon mais pas l&#8217;arrêter.</p>
<p><br class="spacer_" /></p>
<p>Donc dans le script suivant j&#8217;ai contourné le problème à coup de su.</p>
<p><br class="spacer_" /></p>
<h3>Création du fichier de configuration</h3>
<p>Ce fichier permet de déterminer les processus freevo à lancer (recordserver, werserver, etc), le user réalisant ces lancements, et les option des différents composant.</p>
<p>Pour le différencier du précédent je l&#8217;ai nommé boot_freevo.conf et il est localisé dans /etc/freevo.</p>
<p><br class="spacer_" /></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">##############################################################################</span>
<span style="color: #666666; font-style: italic;"># Component to start</span>
<span style="color: #666666; font-style: italic;">##############################################################################</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Mode to start Freevo itself. Possible values are</span>
<span style="color: #666666; font-style: italic;">#</span>
<span style="color: #666666; font-style: italic;"># no:     don't start Freevo</span>
<span style="color: #666666; font-style: italic;"># yes:    start Freevo on startup. You should only use this when the</span>
<span style="color: #666666; font-style: italic;">#         computer is for Freevo only or you use Freevo with a DXR3</span>
<span style="color: #666666; font-style: italic;"># daemon: start Freevo in daemon mode. The daemon will wait for you to</span>
<span style="color: #666666; font-style: italic;">#         press QUIT or POWER on your remote and will than start</span>
<span style="color: #666666; font-style: italic;">#         Freevo. After Freevo shut down, the daemon will wait again.</span>
<span style="color: #666666; font-style: italic;">#</span>
<span style="color: #666666; font-style: italic;"># You don't need a X server running to start Freevo from init. If</span>
<span style="color: #666666; font-style: italic;"># needed, Freevo will start a X server on its own. Make sure your X</span>
<span style="color: #666666; font-style: italic;"># server can handle the resolution defined in /etc/freevo/freevo.conf</span>
<span style="color: #007800;">FREEVO</span>=<span style="color: #ff0000;">&quot;yes&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Mode the start the webserver. Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #666666; font-style: italic;"># If you start the webserver with Freevo itself, you should say &quot;no&quot; here.</span>
<span style="color: #007800;">WEBSERVER</span>=<span style="color: #ff0000;">&quot;no&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Mode the start the recordserver. Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #007800;">RECORDSERVER</span>=<span style="color: #ff0000;">&quot;yes&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Mode the start the encodingserver. Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #007800;">ENCODESERVER</span>=<span style="color: #ff0000;">&quot;no&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">##############################################################################</span>
<span style="color: #666666; font-style: italic;"># Options</span>
&nbsp;
<span style="color: #666666; font-style: italic;">##############################################################################</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># User that freevo should be run as</span>
<span style="color: #666666; font-style: italic;"># useless if ROOTUSERINFO=yes</span>
<span style="color: #007800;">FREEVO_USER</span>=<span style="color: #ff0000;">&quot;freevo&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Set the root USER and HOME variables. Some distros need this to work.</span>
<span style="color: #666666; font-style: italic;"># Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #007800;">ROOTUSERINFO</span>=<span style="color: #ff0000;">&quot;no&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Do we have a mouse and/or keyboard attached to this pc.</span>
<span style="color: #666666; font-style: italic;"># this sets SDL variables for smooth operation if no keyboard or mouse.</span>
<span style="color: #666666; font-style: italic;"># Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #007800;">HAVEMOUSE</span>=<span style="color: #ff0000;">&quot;yes&quot;</span>
<span style="color: #007800;">HAVEKEYBOARD</span>=<span style="color: #ff0000;">&quot;yes&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Use setleds to set numlock before starting freevo. THis is necessary</span>
<span style="color: #666666; font-style: italic;"># for some SDL fbcon setups.</span>
<span style="color: #666666; font-style: italic;"># Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #007800;">SETNUMLOCK</span>=<span style="color: #ff0000;">&quot;no&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">##############################################################################</span>
<span style="color: #666666; font-style: italic;"># Internals Options</span>
<span style="color: #666666; font-style: italic;">##############################################################################</span>
<span style="color: #666666; font-style: italic;"># change this if you know what you are doing</span>
&nbsp;
<span style="color: #666666; font-style: italic;">## where freevo shell script lives. used to call freevo</span>
<span style="color: #007800;">FREEVO_HOME</span>=<span style="color: #ff0000;">&quot;/usr/local/bin&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">## Options for freevo daemon</span>
<span style="color: #007800;">F_DAEMON_OP</span>=<span style="color: #ff0000;">&quot;daemon&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">## Options for freevo not as daemon</span>
<span style="color: #007800;">F_OP</span>=<span style="color: #ff0000;">&quot;-fs&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">## Options for freevo record server</span>
<span style="color: #007800;">F_RECORD_OP</span>=<span style="color: #ff0000;">&quot;recordserver&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">## Options for freevo encoding server</span>
<span style="color: #007800;">F_ENCODE_OP</span>=<span style="color: #ff0000;">&quot;encodingserver&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">## Options for freevo webserver</span>
<span style="color: #007800;">F_WEBSERVER_OP</span>=<span style="color: #ff0000;">&quot;webserver&quot;</span></pre></div></div>

<p><br class="spacer_" /></p>
<h3>Création du scripts d’init</h3>
<p>Comme dans  l&#8217;<a href="http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-2/" target="_blank">article</a> précédent créer ce fichier dans /etc/init.d et le nommer freevo</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">#! /bin/bash</span>
&nbsp;
<span style="color: #666666; font-style: italic;">### BEGIN INIT INFO</span>
<span style="color: #666666; font-style: italic;"># Provides:          freevo</span>
<span style="color: #666666; font-style: italic;"># Required-Start:    $all</span>
<span style="color: #666666; font-style: italic;"># Required-Stop:     $all</span>
<span style="color: #666666; font-style: italic;"># Default-Start:     2 3 4</span>
<span style="color: #666666; font-style: italic;"># Default-Stop:      0 1 6</span>
<span style="color: #666666; font-style: italic;"># Short-Description: starts Freevo</span>
<span style="color: #666666; font-style: italic;"># Description:       starts the open source HTPC media centre software Freevo</span>
<span style="color: #666666; font-style: italic;">### END INIT INFO</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Get startup config file</span>
<span style="color: #7a0874; font-weight: bold;">test</span> <span style="color: #660033;">-f</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>freevo<span style="color: #000000; font-weight: bold;">/</span>boot_freevo.conf <span style="color: #000000; font-weight: bold;">||</span> <span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span>
. <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>freevo<span style="color: #000000; font-weight: bold;">/</span>boot_freevo.conf
&nbsp;
<span style="color: #007800;">PATH</span>=<span style="color: #000000; font-weight: bold;">/</span>sbin:<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>sbin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>games
<span style="color: #007800;">DAEMON</span>=<span style="color: #007800;">$FREEVO_HOME</span><span style="color: #000000; font-weight: bold;">/</span>freevo
<span style="color: #007800;">NAME</span>=freevo
<span style="color: #007800;">DESC</span>=freevo
&nbsp;
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$ROOTUSERINFO</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
    <span style="color: #007800;">USER</span>=root
    <span style="color: #007800;">HOME</span>=<span style="color: #000000; font-weight: bold;">/</span>root<span style="color: #000000; font-weight: bold;">/</span>
    <span style="color: #7a0874; font-weight: bold;">export</span> USER HOME
<span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
<span style="color: #7a0874; font-weight: bold;">test</span> <span style="color: #660033;">-f</span> <span style="color: #007800;">$DAEMON</span> <span style="color: #000000; font-weight: bold;">||</span> <span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">case</span> <span style="color: #ff0000;">&quot;$1&quot;</span> <span style="color: #000000; font-weight: bold;">in</span>
  start<span style="color: #7a0874; font-weight: bold;">&#41;</span>
 <span style="color: #666666; font-style: italic;"># Let configure environment</span>
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$SETNUMLOCK</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Setting NUMLock on&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">setleds</span> +num
 <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$HAVEKEYBOARD</span>&quot;</span> == <span style="color: #ff0000;">&quot;no&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Setting no keyboard&quot;</span>
  <span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">SDL_NOKEYBOARD</span>=<span style="color: #c20cb9; font-weight: bold;">true</span>
 <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$HAVEMOUSE</span>&quot;</span> == <span style="color: #ff0000;">&quot;no&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Setting no mouse&quot;</span>
  <span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">SDL_NOMOUSE</span>=<span style="color: #c20cb9; font-weight: bold;">true</span>
 <span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
 <span style="color: #666666; font-style: italic;"># Let start freevo and components</span>
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$FREEVO</span>&quot;</span> == <span style="color: #ff0000;">&quot;daemon&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Freevo start as a deamon...&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">su</span> <span style="color: #660033;">-l</span> <span style="color: #800000;">${FREEVO_USER}</span> <span style="color: #660033;">-c</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$DAEMON</span> <span style="color: #007800;">$F_DEAMON_OP</span> &amp;&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
 <span style="color: #000000; font-weight: bold;">elif</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$FREEVO</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Freevo start...&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">su</span> <span style="color: #660033;">-l</span> <span style="color: #800000;">${FREEVO_USER}</span> <span style="color: #660033;">-c</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$DAEMON</span> <span style="color: #007800;">$F_OP</span> &amp;&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
 <span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$RECORDSERVER</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Record server start...&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">su</span> <span style="color: #660033;">-l</span> <span style="color: #800000;">${FREEVO_USER}</span> <span style="color: #660033;">-c</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$DAEMON</span> <span style="color: #007800;">$F_RECORD_OP</span> --start &amp;&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
 <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$WEBSERVER</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Web server start...&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">su</span> <span style="color: #660033;">-l</span> <span style="color: #800000;">${FREEVO_USER}</span> <span style="color: #660033;">-c</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$DAEMON</span> <span style="color: #007800;">$F_WEBSERVER_OP</span> --start &amp;&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
 <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$ENCODESERVER</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Encode server start...&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">su</span> <span style="color: #660033;">-l</span> <span style="color: #800000;">${FREEVO_USER}</span> <span style="color: #660033;">-c</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$DAEMON</span> <span style="color: #007800;">$F_ENCODE_OP</span> --start &amp;&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
 <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #000000; font-weight: bold;">;;</span>
  stop<span style="color: #7a0874; font-weight: bold;">&#41;</span>
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$FREEVO</span>&quot;</span> <span style="color: #000000; font-weight: bold;">!</span>= <span style="color: #ff0000;">&quot;no&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Freevo stop...&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">su</span> <span style="color: #660033;">-l</span> <span style="color: #800000;">${FREEVO_USER}</span> <span style="color: #660033;">-c</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$DAEMON</span> --stop&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
  <span style="color: #c20cb9; font-weight: bold;">sleep</span> <span style="color: #000000;">3</span>
 <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$RECORDSERVER</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Record server stop...&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">su</span> <span style="color: #660033;">-l</span> <span style="color: #800000;">${FREEVO_USER}</span> <span style="color: #660033;">-c</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$DAEMON</span> <span style="color: #007800;">$F_RECORD_OP</span> --stop&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
  <span style="color: #c20cb9; font-weight: bold;">sleep</span> <span style="color: #000000;">3</span>
 <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$WEBSERVER</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Web server stop...&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">su</span> <span style="color: #660033;">-l</span> <span style="color: #800000;">${FREEVO_USER}</span> <span style="color: #660033;">-c</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$DAEMON</span> <span style="color: #007800;">$F_WEBSERVER_OP</span> --stop&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
 <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$ENCODESERVER</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Encode server stop...&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">su</span> <span style="color: #660033;">-l</span> <span style="color: #800000;">${FREEVO_USER}</span> <span style="color: #660033;">-c</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$DAEMON</span> <span style="color: #007800;">$F_ENCODE_OP</span> --stop&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
 <span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
 <span style="color: #000000; font-weight: bold;">if</span> pgrep <span style="color: #660033;">-f</span> <span style="color: #ff0000;">&quot;python.*freevo&quot;</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null ; <span style="color: #000000; font-weight: bold;">then</span>
  <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;At least one Freevo component still running, kill 'em all...&quot;</span>
  <span style="color: #c20cb9; font-weight: bold;">kill</span> <span style="color: #000000; font-weight: bold;">`</span>pgrep <span style="color: #660033;">-f</span> <span style="color: #ff0000;">&quot;python.*freevo&quot;</span> <span style="color: #660033;">-d</span><span style="color: #ff0000;">&quot; &quot;</span><span style="color: #000000; font-weight: bold;">`</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
 <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #000000; font-weight: bold;">;;</span>
  restart<span style="color: #000000; font-weight: bold;">|</span>force-reload<span style="color: #7a0874; font-weight: bold;">&#41;</span>
 <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Restarting...&quot;</span>
 <span style="color: #007800;">$0</span> stop
 <span style="color: #c20cb9; font-weight: bold;">sleep</span> <span style="color: #000000;">1</span>
 <span style="color: #007800;">$0</span> start
 <span style="color: #000000; font-weight: bold;">;;</span>
  <span style="color: #000000; font-weight: bold;">*</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
 <span style="color: #007800;">N</span>=<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span><span style="color: #007800;">$NAME</span>
 <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Usage: <span style="color: #007800;">$N</span> {start|stop|restart|force-reload}&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;&amp;</span><span style="color: #000000;">2</span>
 <span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">1</span>
 <span style="color: #000000; font-weight: bold;">;;</span>
<span style="color: #000000; font-weight: bold;">esac</span>
&nbsp;
<span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span></pre></div></div>

<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<h3>Installation du script</h3>
<p>Comme précedemment, on installera ce script avec  :</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> update-rc.d freevo defaults <span style="color: #000000;">99</span></pre></div></div>

<p><br class="spacer_" /></p>
<p>Puis on pourra démarrer freevo en faisant :</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>freevo start</pre></div></div>

<p><br class="spacer_" /></p>
<h3>Conclusion :</h3>
<p>Cette méthode est à mon avis la méthode ultime puisqu&#8217;elle cumule les avantages des 2 précédentes plus quelques une supplémentaire :</p>
<ul>
<li>Il n’y pas d’utilisateur de loggué</li>
<li>Les “différents” processus freevo à lancer sont paramétrés dans un fichier de configuration</li>
<li>Les process sont exécutées avec le user paramétré dans le fichier de configuration</li>
<li>Le paramétrage des lignes de commandes à lancer est faite dans le fichier de configuration</li>
<li>Le kill des process résiduel est plus propre</li>
</ul>
<p><br class="spacer_" /></p>
<p>Enfin pour finir quelques mots de précaution :</p>
<ul>
<li>Ce script à été testé avec Freevo 1.9.0 sous Jaunty</li>
<li>Seul les composants recordserver et freevo lui-même ont été testé (pas l&#8217;encodingserver ni le webserver)</li>
<li>La configuration clavier/souris repris du script précédent, lui même repris des sources Freevo n&#8217;a pas été testé</li>
</ul>
<p><br class="spacer_" /></p>
<p>Bref ce script est fournis &laquo;&nbsp;<a href="http://en.wikipedia.org/wiki/As_is" target="_blank">as is</a>&nbsp;&raquo; je ne garantis pas qu&#8217;il fonctionnera sur toutes les plateformes&#8230;.</p>
<p><br class="spacer_" /></p>
]]></content:encoded>
			<wfw:commentRss>http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-3/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Bug de l&#8217;autologin GDM avec un dossier home crypté</title>
		<link>http://voidandany.free.fr/index.php/bug-de-lautologin-gdm-avec-un-dossier-home-crypte/</link>
		<comments>http://voidandany.free.fr/index.php/bug-de-lautologin-gdm-avec-un-dossier-home-crypte/#comments</comments>
		<pubDate>Sat, 20 Jun 2009 10:18:42 +0000</pubDate>
		<dc:creator>voidAndAny</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[boot]]></category>
		<category><![CDATA[erreur]]></category>
		<category><![CDATA[GDM]]></category>
		<category><![CDATA[window manager]]></category>

		<guid isPermaLink="false">http://voidandany.free.fr/?p=702</guid>
		<description><![CDATA[Il y a peu j&#8217;ai travaillé sur sweetHome en vue de me passer définitivement de Windows XP, après avoir installé les logiciels qu&#8217;il me fallait, fait un peu de paramétrage et de cosmétique (thème Wild-shine), j&#8217;ai mis l&#8217;autologin GDM et &#8230; <a href="http://voidandany.free.fr/index.php/bug-de-lautologin-gdm-avec-un-dossier-home-crypte/">Continuer la lecture <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p><br class="spacer_" /></p>
<p>Il y a peu j&#8217;ai travaillé sur <a href="http://voidandany.free.fr/index.php/architecture-domestique/" target="_blank">sweetHome</a> en vue de me passer définitivement de Windows XP, après avoir installé les logiciels qu&#8217;il me fallait, fait un peu de paramétrage et de cosmétique (thème <a href="http://francois.vogelweith.com/index.php?option=com_content&amp;view=article&amp;id=20:theme-wild-shine&amp;catid=3:themes&amp;Itemid=14" target="_blank">Wild-shine</a>), j&#8217;ai mis l&#8217;<a href="http://voidandany.free.fr/index.php/ubuntu-auto-login/" target="_blank">autologin GDM</a> et fait un reboot final.</p>
<p>Et là surprise un bel écran noir&#8230;</p>
<p><br class="spacer_" /></p>
<p>Après quelque recherche il s&#8217;agit d&#8217;un bug <a href="https://bugs.launchpad.net/ubuntu/+source/ecryptfs-utils/+bug/353446" target="_blank">référencé</a> qui intervient quand on met en oeuvre l&#8217;autologin GDM avec un utilisateur dont le home est crypté (option par défaut sous Jaunty).</p>
<p><br class="spacer_" /></p>
<p>Tout d&#8217;abord voici comment reproduire aisément le bug puis ensuite comment s&#8217;en sortir.</p>
<p><br class="spacer_" /></p>
<p><span id="more-702"></span></p>
<h3>Reproduction du bug<a href="https://bugs.launchpad.net/ubuntu/+source/ecryptfs-utils/+bug/353446"></a></h3>
<p>Sur une machine ayant Jaunty d&#8217;installé, creation d&#8217;un user avec son home crypté</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> adduser <span style="color: #660033;">--encrypt-home</span> mon_user</pre></div></div>

<p>
<br class="spacer_" /></p>
<p>Mise en place de l&#8217;<a href="http://voidandany.free.fr/index.php/ubuntu-auto-login/" target="_blank">autologin GDM</a> pour mon_user et reboot.</p>
<p>Et voila un un bel ecran noir.</p>
<p><br class="spacer_" /></p>
<p>Maintenant comment s&#8217;en sortir ?</p>
<p>2 solutions :</p>
<ul>
<li>Enlever l&#8217;autologin</li>
<li>Decrypter la partition home de l&#8217;utilisateur</li>
</ul>
<p><br class="spacer_" /></p>
<p>Je vais décrire ici la première solution, la deuxième fera l&#8217;objet d&#8217;un autre article.</p>
<p><br class="spacer_" /></p>
<h3>Supprimer l&#8217;autologin GDM</h3>
<p>La question est ici de supprimer l&#8217;autologin GDM en ligne de commande puisque le serveur X nous donne un écran noir.</p>
<p><br class="spacer_" /></p>
<p>Pour avoir accès à la ligne de commande :</p>
<ul>
<li>soit rebooter en mode sans echec (faire apparaitre le menu Grub en pressant escape, sélectionner le mode sans echec puis choisir root dans la liste des option disponibles)</li>
<li>soit passer sur un autre terminal CTRL+ALT+1</li>
</ul>
<p><br class="spacer_" /></p>
<p>Personnellement j&#8217;ai choisi la solution 1.</p>
<p><br class="spacer_" /></p>
<p>Editer le fichier gdm.conf-custom :</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">vim</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>gdm<span style="color: #000000; font-weight: bold;">/</span>gdm.conf-custom</pre></div></div>

<p><br class="spacer_" /></p>
<p>Chercher les lignes suivantes :</p>
<pre>AutomaticLogin= mon_user</pre>
<pre>AutomaticLoginEnable = true</pre>
<p><br class="spacer_" /></p>
<p>Et les remplacer par :</p>
<pre>AutomaticLogin= </pre>
<pre>AutomaticLoginEnable = false</pre>
<p><br class="spacer_" /></p>
<p>Rebooter et la mire de connexion GDM devrait apparaitre.</p>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
]]></content:encoded>
			<wfw:commentRss>http://voidandany.free.fr/index.php/bug-de-lautologin-gdm-avec-un-dossier-home-crypte/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Démarrer automatiquement Freevo (méthode 2)</title>
		<link>http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-2/</link>
		<comments>http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-2/#comments</comments>
		<pubDate>Sun, 07 Jun 2009 08:11:05 +0000</pubDate>
		<dc:creator>voidAndAny</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[boot]]></category>
		<category><![CDATA[freevo]]></category>
		<category><![CDATA[mediacenter]]></category>

		<guid isPermaLink="false">http://voidandany.free.fr/?p=623</guid>
		<description><![CDATA[Dans un article précédent nous avons vu comment démarrer freevo de façon automatique via l&#8217;auto-login d&#8217;un utilisateur et l&#8217;utilisation du fichier bash_profil. Dans cet article nous allons parvenir au même résultat mais sans loguer d&#8217;utilisateur. Pour cela on va créer un &#8230; <a href="http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-2/">Continuer la lecture <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Dans un <a href="http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-1/" target="_blank">article</a> précédent nous avons vu comment démarrer freevo de façon automatique via l&#8217;auto-login d&#8217;un utilisateur et l&#8217;utilisation du fichier bash_profil.</p>
<p><br class="spacer_" /></p>
<p>Dans cet article nous allons parvenir au même résultat mais sans loguer d&#8217;utilisateur.</p>
<p>Pour cela on va créer un script d&#8217;init (init.d) qui va lancer freevo au démarrage comme un service.</p>
<p><br class="spacer_" /></p>
<p>Les scripts présentés ici sont ceux qui tournent actuellement sur ma version de prod (freevo 1.8.3 / Gutsy) de freevo sur sweetBox.</p>
<p>Ces scripts sont issus des sources de freevo (répertoire contrib/debian)</p>
<p><br class="spacer_" /></p>
<h3>Création du fichier de configuration</h3>
<p>Ce fichier permet de déterminer les processus freevo à lancer (recordserver, werserver, etc).</p>
<p>Créer ce fichier dans /etc/freevo et le nommer boot_config.</p>
<p><br class="spacer_" /></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;"># $Id: boot_config 5071 2004-01-29 15:48:31Z mikeruelle $</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># where freevo shell script lives. used to call freevo</span>
<span style="color: #007800;">FREEVO_HOME</span>=<span style="color: #ff0000;">&quot;/usr/bin&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># a log used to catch errors when freevo startsup</span>
<span style="color: #007800;">FREEVO_LOG</span>=<span style="color: #ff0000;">&quot;/var/log/freevo/main.log&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Mode to start Freevo itself. Possible values are</span>
<span style="color: #666666; font-style: italic;">#</span>
<span style="color: #666666; font-style: italic;"># no:     don't start Freevo</span>
<span style="color: #666666; font-style: italic;"># yes:    start Freevo on startup. You should only use this when the</span>
<span style="color: #666666; font-style: italic;">#         computer is for Freevo only or you use Freevo with a DXR3</span>
<span style="color: #666666; font-style: italic;"># daemon: start Freevo in daemon mode. The daemon will wait for you to</span>
<span style="color: #666666; font-style: italic;">#         press QUIT or POWER on your remote and will than start</span>
<span style="color: #666666; font-style: italic;">#         Freevo. After Freevo shut down, the daemon will wait again.</span>
<span style="color: #666666; font-style: italic;">#</span>
<span style="color: #666666; font-style: italic;"># You don't need a X server running to start Freevo from init. If</span>
<span style="color: #666666; font-style: italic;"># needed, Freevo will start a X server on its own. Make sure your X</span>
<span style="color: #666666; font-style: italic;"># server can handle the resolution defined in /etc/freevo/freevo.conf</span>
<span style="color: #007800;">FREEVO</span>=<span style="color: #ff0000;">&quot;yes&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Mode the start the webserver. Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #666666; font-style: italic;"># If you start the webserver with Freevo itself, you should say &quot;no&quot; here.</span>
<span style="color: #007800;">WEBSERVER</span>=<span style="color: #ff0000;">&quot;no&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Mode the start the recordserver. Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #007800;">RECORDSERVER</span>=<span style="color: #ff0000;">&quot;yes&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Do we have a mouse and/or keyboard attached to this pc.</span>
<span style="color: #666666; font-style: italic;"># this sets SDL variables for smooth operation if no keyboard or mouse.</span>
<span style="color: #666666; font-style: italic;"># Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #007800;">HAVEMOUSE</span>=<span style="color: #ff0000;">&quot;yes&quot;</span>
<span style="color: #007800;">HAVEKEYBOARD</span>=<span style="color: #ff0000;">&quot;yes&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># The SDL video driver to use. common values are x11 or fbcon.</span>
<span style="color: #666666; font-style: italic;"># for a full list see:</span>
<span style="color: #666666; font-style: italic;"># http://www.libsdl.org/faq.php?action=listentries&amp;category=9#9</span>
<span style="color: #007800;">SDL_VIDEODRIVER</span>=<span style="color: #ff0000;">&quot;x11&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Set the root USER and HOME variables. Some distros need this to work.</span>
<span style="color: #666666; font-style: italic;"># Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #007800;">ROOTUSERINFO</span>=<span style="color: #ff0000;">&quot;no&quot;</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Use setleds to set numlock before starting freevo. THis is necessary</span>
<span style="color: #666666; font-style: italic;"># for some SDL fbcon setups.</span>
<span style="color: #666666; font-style: italic;"># Possible values are &quot;no&quot; and &quot;yes&quot;.</span>
<span style="color: #007800;">SETNUMLOCK</span>=<span style="color: #ff0000;">&quot;no&quot;</span></pre></div></div>

<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<h3>Création du scripts d&#8217;init</h3>
<p>Ce script est celui qui sera lancé au démarrage, il reprend la structure des scripts d&#8217;init comme défini <a href="http://refspecs.freestandards.org/LSB_3.1.0/LSB-Core-generic/LSB-Core-generic/iniscrptact.html" target="_blank">ici</a>.</p>
<p>Il va lire le fichier de configuration et lance les processus demandés.</p>
<p>Créer ce fichier dans /etc/init.d et le nommer freevo</p>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">#! /bin/bash</span>
<span style="color: #666666; font-style: italic;"># chkconfig: 234 99 00</span>
<span style="color: #666666; font-style: italic;"># description: A boot script for the Freevo package</span>
<span style="color: #666666; font-style: italic;">#</span>
<span style="color: #666666; font-style: italic;"># Enhanced boot script for freevo</span>
<span style="color: #666666; font-style: italic;">#</span>
<span style="color: #666666; font-style: italic;"># $Id: freevo 5489 2004-03-13 15:13:36Z mikeruelle $</span>
&nbsp;
<span style="color: #666666; font-style: italic;"># Get startup config file</span>
<span style="color: #7a0874; font-weight: bold;">test</span> <span style="color: #660033;">-f</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>freevo<span style="color: #000000; font-weight: bold;">/</span>boot_config <span style="color: #000000; font-weight: bold;">||</span> <span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span>
. <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>freevo<span style="color: #000000; font-weight: bold;">/</span>boot_config
&nbsp;
<span style="color: #007800;">PATH</span>=<span style="color: #000000; font-weight: bold;">/</span>sbin:<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>sbin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>local<span style="color: #000000; font-weight: bold;">/</span>bin:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>games
<span style="color: #007800;">DAEMON</span>=<span style="color: #007800;">$FREEVO_HOME</span><span style="color: #000000; font-weight: bold;">/</span>freevo
<span style="color: #007800;">NAME</span>=freevo
<span style="color: #007800;">DESC</span>=freevo
&nbsp;
<span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$ROOTUSERINFO</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
    <span style="color: #007800;">USER</span>=root
    <span style="color: #007800;">HOME</span>=<span style="color: #000000; font-weight: bold;">/</span>root<span style="color: #000000; font-weight: bold;">/</span>
    <span style="color: #7a0874; font-weight: bold;">export</span> USER HOME
<span style="color: #000000; font-weight: bold;">fi</span>
&nbsp;
<span style="color: #7a0874; font-weight: bold;">test</span> <span style="color: #660033;">-f</span> <span style="color: #007800;">$DAEMON</span> <span style="color: #000000; font-weight: bold;">||</span> <span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span>
&nbsp;
freevoserver<span style="color: #7a0874; font-weight: bold;">&#40;</span><span style="color: #7a0874; font-weight: bold;">&#41;</span> <span style="color: #7a0874; font-weight: bold;">&#123;</span>
    <span style="color: #666666; font-style: italic;"># $1 is the server</span>
    <span style="color: #666666; font-style: italic;"># $2 is the action</span>
    <span style="color: #007800;">$DAEMON</span> <span style="color: #007800;">$1</span> <span style="color: #007800;">$2</span> <span style="color: #000000;">2</span><span style="color: #000000; font-weight: bold;">&gt;&amp;</span><span style="color: #000000;">1</span> <span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
<span style="color: #7a0874; font-weight: bold;">&#125;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">case</span> <span style="color: #ff0000;">&quot;$1&quot;</span> <span style="color: #000000; font-weight: bold;">in</span>
  start<span style="color: #7a0874; font-weight: bold;">&#41;</span>
        <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">&quot;Setting up RTC: &quot;</span>
        sysctl <span style="color: #660033;">-w</span> dev.rtc.max-user-freq=<span style="color: #000000;">1024</span> <span style="color: #000000; font-weight: bold;">&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
        <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;sysctl.&quot;</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$RECORDSERVER</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
            <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">&quot;Starting Freevo Recordserver: &quot;</span>
            freevoserver <span style="color: #ff0000;">&quot;recordserver&quot;</span> <span style="color: #ff0000;">&quot;start&quot;</span>
            <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Recordserver.&quot;</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$WEBSERVER</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
            <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">&quot;Starting Freevo Webserver: &quot;</span>
            freevoserver <span style="color: #ff0000;">&quot;webserver&quot;</span> <span style="color: #ff0000;">&quot;start&quot;</span>
            <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Webserver.&quot;</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$SETNUMLOCK</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
            <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">&quot;Setting NUMLock on: &quot;</span>
            <span style="color: #c20cb9; font-weight: bold;">setleds</span> +num
            <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;setleds.&quot;</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$HAVEKEYBOARD</span>&quot;</span> == <span style="color: #ff0000;">&quot;no&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
       <span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">SDL_NOKEYBOARD</span>=<span style="color: #c20cb9; font-weight: bold;">true</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$HAVEMOUSE</span>&quot;</span> == <span style="color: #ff0000;">&quot;no&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
            <span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">SDL_NOMOUSE</span>=<span style="color: #c20cb9; font-weight: bold;">true</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">SDL_VIDEODRIVER</span>=<span style="color: #007800;">$SDL_VIDEODRIVER</span>
 <span style="color: #7a0874; font-weight: bold;">export</span> <span style="color: #007800;">LANG</span>=fr_FR.UTF-<span style="color: #000000;">8</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$FREEVO</span>&quot;</span> == <span style="color: #ff0000;">&quot;daemon&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
     <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">&quot;Starting deamon  <span style="color: #007800;">$DESC</span>: &quot;</span>
            freevoserver <span style="color: #ff0000;">&quot;daemon&quot;</span> <span style="color: #ff0000;">&quot;start&quot;</span>
     <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$NAME</span>.&quot;</span>
        <span style="color: #000000; font-weight: bold;">elif</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$FREEVO</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
     <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">&quot;Starting <span style="color: #007800;">$DESC</span>: &quot;</span>
            <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #c20cb9; font-weight: bold;">egrep</span> <span style="color: #660033;">-q</span> <span style="color: #ff0000;">'^display.*(x11|dga)'</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>freevo<span style="color: #000000; font-weight: bold;">/</span>freevo.conf ; <span style="color: #000000; font-weight: bold;">then</span>
                <span style="color: #007800;">PATH</span>=<span style="color: #007800;">$PATH</span>:<span style="color: #000000; font-weight: bold;">/</span>usr<span style="color: #000000; font-weight: bold;">/</span>X11R6<span style="color: #000000; font-weight: bold;">/</span>bin
           <span style="color: #007800;">$DAEMON</span> <span style="color: #660033;">-fs</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #007800;">$FREEVO_LOG</span> <span style="color: #000000;">2</span><span style="color: #000000; font-weight: bold;">&gt;&amp;</span><span style="color: #000000;">1</span> <span style="color: #000000; font-weight: bold;">&amp;</span>
            <span style="color: #000000; font-weight: bold;">else</span>
           <span style="color: #007800;">$DAEMON</span> <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #007800;">$FREEVO_LOG</span> <span style="color: #000000;">2</span><span style="color: #000000; font-weight: bold;">&gt;&amp;</span><span style="color: #000000;">1</span> <span style="color: #000000; font-weight: bold;">&amp;</span>
            <span style="color: #000000; font-weight: bold;">fi</span>
     <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$NAME</span>.&quot;</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
 <span style="color: #000000; font-weight: bold;">;;</span>
  stop<span style="color: #7a0874; font-weight: bold;">&#41;</span>
 <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">&quot;Stopping <span style="color: #007800;">$DESC</span>: &quot;</span>
        <span style="color: #007800;">$DAEMON</span> stop <span style="color: #000000; font-weight: bold;">&gt;&gt;</span> <span style="color: #007800;">$FREEVO_LOG</span> <span style="color: #000000;">2</span><span style="color: #000000; font-weight: bold;">&gt;&amp;</span><span style="color: #000000;">1</span> <span style="color: #000000; font-weight: bold;">&amp;</span>
        <span style="color: #c20cb9; font-weight: bold;">sleep</span> <span style="color: #000000;">5</span>
        <span style="color: #c20cb9; font-weight: bold;">kill</span> <span style="color: #000000; font-weight: bold;">`</span>pgrep <span style="color: #660033;">-f</span> <span style="color: #ff0000;">&quot;python src/main.py&quot;</span> <span style="color: #660033;">-d</span><span style="color: #ff0000;">&quot; &quot;</span><span style="color: #000000; font-weight: bold;">`</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
 <span style="color: #c20cb9; font-weight: bold;">kill</span> <span style="color: #000000; font-weight: bold;">`</span>pgrep <span style="color: #660033;">-f</span> <span style="color: #ff0000;">&quot;python main.py&quot;</span> <span style="color: #660033;">-d</span><span style="color: #ff0000;">&quot; &quot;</span><span style="color: #000000; font-weight: bold;">`</span> <span style="color: #000000; font-weight: bold;">&amp;&gt;</span> <span style="color: #000000; font-weight: bold;">/</span>dev<span style="color: #000000; font-weight: bold;">/</span>null
 <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$NAME</span>.&quot;</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$RECORDSERVER</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
            <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">&quot;Starting Freevo Recordserver: &quot;</span>
            freevoserver <span style="color: #ff0000;">&quot;recordserver&quot;</span> <span style="color: #ff0000;">&quot;stop&quot;</span>
            <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Recordserver.&quot;</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
        <span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> <span style="color: #ff0000;">&quot;<span style="color: #007800;">$WEBSERVER</span>&quot;</span> == <span style="color: #ff0000;">&quot;yes&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span>; <span style="color: #000000; font-weight: bold;">then</span>
            <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">&quot;Starting Freevo Webserver &quot;</span>
            freevoserver <span style="color: #ff0000;">&quot;webserver&quot;</span> <span style="color: #ff0000;">&quot;stop&quot;</span>
            <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Webserver.&quot;</span>
        <span style="color: #000000; font-weight: bold;">fi</span>
        <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #660033;">-n</span> <span style="color: #ff0000;">&quot;Hard kill to be sure: &quot;</span>
        <span style="color: #c20cb9; font-weight: bold;">ps</span> aux <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> python <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">grep</span> main.py <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">awk</span> <span style="color: #ff0000;">'{ print &quot;kill -9 &quot; $2 }'</span> <span style="color: #000000; font-weight: bold;">|</span> <span style="color: #c20cb9; font-weight: bold;">sh</span>
        <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;kill.&quot;</span>
 <span style="color: #000000; font-weight: bold;">;;</span>
  restart<span style="color: #000000; font-weight: bold;">|</span>force-reload<span style="color: #7a0874; font-weight: bold;">&#41;</span>
 <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Restarting...&quot;</span>
 <span style="color: #007800;">$0</span> stop
 <span style="color: #c20cb9; font-weight: bold;">sleep</span> <span style="color: #000000;">1</span>
 <span style="color: #007800;">$0</span> start
 <span style="color: #000000; font-weight: bold;">;;</span>
  <span style="color: #000000; font-weight: bold;">*</span><span style="color: #7a0874; font-weight: bold;">&#41;</span>
 <span style="color: #007800;">N</span>=<span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span><span style="color: #007800;">$NAME</span>
 <span style="color: #7a0874; font-weight: bold;">echo</span> <span style="color: #ff0000;">&quot;Usage: <span style="color: #007800;">$N</span> {start|stop|restart|force-reload}&quot;</span> <span style="color: #000000; font-weight: bold;">&gt;&amp;</span><span style="color: #000000;">2</span>
 <span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">1</span>
 <span style="color: #000000; font-weight: bold;">;;</span>
<span style="color: #000000; font-weight: bold;">esac</span>
&nbsp;
<span style="color: #7a0874; font-weight: bold;">exit</span> <span style="color: #000000;">0</span></pre></div></div>

<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<h3>Installation du script</h3>
<p>on installera ce script avec  :</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> update-rc.d deluge-daemon defaults <span style="color: #000000;">99</span></pre></div></div>

<p><br class="spacer_" /></p>
<p>Puis on pourra démarrer freevo en faisant :</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>init.d<span style="color: #000000; font-weight: bold;">/</span>freevo start</pre></div></div>

<p><br class="spacer_" /> </p>
<h3>Conclusion :</h3>
<p>Cette méthode est à mon avis mieux que la précédente puisque :</p>
<ul>
<li>Il n&#8217;y pas d&#8217;utilisateur de loggué</li>
<li>Les &laquo;&nbsp;différents&nbsp;&raquo; processus freevo à lancer sont paramétrés dans un fichier de configuration</li>
</ul>
<p>Mais avec ce mécanisme les processus sont lancés en root&#8230;</p>
<p><br class="spacer_" /></p>
<p>On verra dans un autre article comment remédier à ce problème en utilisant la commande <span style="text-decoration: line-through;">start-stop-deamon</span> su.</p>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
]]></content:encoded>
			<wfw:commentRss>http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-2/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Démarrer automatiquement Freevo (méthode 1)</title>
		<link>http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-1/</link>
		<comments>http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-1/#comments</comments>
		<pubDate>Tue, 02 Jun 2009 13:34:15 +0000</pubDate>
		<dc:creator>voidAndAny</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[boot]]></category>
		<category><![CDATA[freevo]]></category>
		<category><![CDATA[mediacenter]]></category>

		<guid isPermaLink="false">http://voidandany.free.fr/?p=294</guid>
		<description><![CDATA[Quand on a Freevo d&#8217;installé sur un PC médiacenter relié à la télé, que ce dernier est configurée correctement (objet d&#8217;un autre post), on peut souhaiter qu&#8217;au démarrage du PC, Freevo se lance automatiquement. Ainsi pour regarder un film, on &#8230; <a href="http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-1/">Continuer la lecture <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Quand on a Freevo d&#8217;installé sur un PC médiacenter relié à la télé, que ce dernier est configurée correctement (objet d&#8217;un autre post), on peut souhaiter qu&#8217;au démarrage du PC, Freevo se lance automatiquement.</p>
<p>Ainsi pour regarder un film, on allume la TV et le PC, 45 secondes plus tard (boot), on pilote Freevo à la télécommande et on démarre le film.</p>
<p><br class="spacer_" /></p>
<p>Cet article décrit une 1ère façon de répondre au besoin via l&#8217;autologin d&#8217;un utilisateur.</p>
<p><br class="spacer_" /></p>
<p>Il faut tout d&#8217;abord qu&#8217;un utilisateur se loggue de façon automatique sur la console, cela peut être fait avec <a href="http://sourceforge.net/projects/mingetty" target="_blank">mingetty</a>.</p>
<p><br class="spacer_" /></p>
<p><strong>Installation de mingetty</strong></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">aptitude</span> <span style="color: #c20cb9; font-weight: bold;">install</span> mingetty</pre></div></div>

<p>(1 paquet &#8211; 10 Ko)</p>
<p><br class="spacer_" /></p>
<p><strong>Login automatique</strong></p>
<p>Attention ce qui suit est spécifique à Ubuntu ou tout du moins aux distributions qui utilisent upstart (pas de inittab)</p>
<p>Editer le fichier /etc/event.d/tty1</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">vim</span> <span style="color: #000000; font-weight: bold;">/</span>etc<span style="color: #000000; font-weight: bold;">/</span>event.d<span style="color: #000000; font-weight: bold;">/</span>tty1</pre></div></div>

<p><br class="spacer_" /></p>
<p>Puis rechercher la ligne (fin de fichier) :  </p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">exec</span> <span style="color: #000000; font-weight: bold;">/</span>sbin<span style="color: #000000; font-weight: bold;">/</span>getty <span style="color: #000000;">38400</span> tty1</pre></div></div>

<p><br id="u:r446" /> </p>
<p>Et la remplacer par :</p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #7a0874; font-weight: bold;">exec</span> <span style="color: #000000; font-weight: bold;">/</span>sbin<span style="color: #000000; font-weight: bold;">/</span>mingetty <span style="color: #660033;">--noclear</span> --autologin mon_user tty1</pre></div></div>

<p><br id="u:r451" /> </p>
<p><br class="spacer_" /></p>
<h3>Exécution automatique de Freevo</h3>
<p>Une fois l&#8217;utilisateur loggué il faut ensuite lancer Freevo, pour cela créer/éditer le fichier bash_profil :  </p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #c20cb9; font-weight: bold;">sudo</span> <span style="color: #c20cb9; font-weight: bold;">vim</span> <span style="color: #000000; font-weight: bold;">/</span>home<span style="color: #000000; font-weight: bold;">/</span>mon_user<span style="color: #000000; font-weight: bold;">/</span>bash_profile</pre></div></div>

<p><br class="spacer_" /></p>
<p>Et coller les lignes suivantes :</p>
<p><br class="spacer_" /></p>

<div class="wp_syntax"><div class="code"><pre class="bash" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">if</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span>-z <span style="color: #ff0000;">&quot;<span style="color: #007800;">$DISPLAY</span>&quot;</span><span style="color: #7a0874; font-weight: bold;">&#93;</span>  <span style="color: #000000; font-weight: bold;">&amp;&amp;</span> <span style="color: #7a0874; font-weight: bold;">&#91;</span> $<span style="color: #7a0874; font-weight: bold;">&#40;</span>tty<span style="color: #7a0874; font-weight: bold;">&#41;</span> == <span style="color: #ff0000;">&quot;/dev/tty1&quot;</span> <span style="color: #7a0874; font-weight: bold;">&#93;</span> <span style="color: #000000; font-weight: bold;">then</span>
&nbsp;
       freevo <span style="color: #660033;">-fs</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">fi</span></pre></div></div>

<p><br class="spacer_" />Redémarer et admirer le résultat.</p>
<p><br class="spacer_" /></p>
<p>Dans un prochain post on verra comment faire encore mieux&#8230;</p>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
]]></content:encoded>
			<wfw:commentRss>http://voidandany.free.fr/index.php/demarrer-automatiquement-freevo-methode-1/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Activer la connexion automatique sous Ubuntu</title>
		<link>http://voidandany.free.fr/index.php/ubuntu-auto-login/</link>
		<comments>http://voidandany.free.fr/index.php/ubuntu-auto-login/#comments</comments>
		<pubDate>Mon, 01 Jun 2009 06:21:50 +0000</pubDate>
		<dc:creator>voidAndAny</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[software]]></category>
		<category><![CDATA[boot]]></category>
		<category><![CDATA[desktop]]></category>
		<category><![CDATA[GDM]]></category>
		<category><![CDATA[window manager]]></category>

		<guid isPermaLink="false">http://voidandany.free.fr/?p=546</guid>
		<description><![CDATA[Étant le seul utilisateur de mes PC  j&#8217;ai mis en place l&#8217;auto-login en place, voici comment procéder. Aller dans Système  &#62; Administration &#62; Fenêtre de connexion : Et dans l&#8217;onglet Sécurité, côcher la case activer la connexion automatique et saisir &#8230; <a href="http://voidandany.free.fr/index.php/ubuntu-auto-login/">Continuer la lecture <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Étant le seul utilisateur de mes PC  j&#8217;ai mis en place l&#8217;auto-login en place, voici comment procéder.<br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<p>Aller dans Système  &gt; Administration &gt; Fenêtre de connexion : <br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<div id="attachment_547" class="wp-caption aligncenter" style="width: 292px"><a href="http://voidandany.free.fr/wp-content/uploads/2009-05-27_142030.png"><img class="size-medium wp-image-547" title="Fenetre de connexion" src="http://voidandany.free.fr/wp-content/uploads/2009-05-27_142030-282x300.png" alt="Accéder au paramétrage de la fenêtre de connexion (GDM)" width="282" height="300" /></a><p class="wp-caption-text">Accéder au paramétrage de la fenêtre de connexion (GDM)</p></div>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<p>Et dans l&#8217;onglet Sécurité, côcher la case activer la connexion automatique et saisir le nom de votre utilisateur dans la zone &laquo;&nbsp;Utilisateur&nbsp;&raquo;.<br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<div id="attachment_548" class="wp-caption aligncenter" style="width: 310px"><a href="http://voidandany.free.fr/wp-content/uploads/2009-05-27_142100.png"><img class="size-medium wp-image-548" title="Autologin" src="http://voidandany.free.fr/wp-content/uploads/2009-05-27_142100-300x273.png" alt="Activer l'autologin" width="300" height="273" /></a><p class="wp-caption-text">Activer l&#39;autologin</p></div>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<p><span style="font-weight: bold; font-style: italic; text-decoration: underline;">Edit 29/09/2010</span> : La boite de dialogue a changée (au moins sous Lucid Lynx 10.04) :</p>
<p><a href="http://voidandany.free.fr/wp-content/uploads/2010-09-27_170520.png"><img class="aligncenter size-large wp-image-2747" title="connexion auto" src="http://voidandany.free.fr/wp-content/uploads/2010-09-27_170520-650x202.png" alt="" width="650" height="202" /></a></p>
<p>Il faut tout d&#8217;abord cliquer sur le bouton Déverrouiller et saisir son mot de passe.</p>
<p>On peut ensuite activer l&#8217;option de connection automatique, en sélectionnant l&#8217;utilisateur à logguer et le gestionnaire de fenêtre à utiliser :</p>
<p><a href="http://voidandany.free.fr/wp-content/uploads/2010-09-27_170551.png"><img class="aligncenter size-large wp-image-2748" title="connection automatique" src="http://voidandany.free.fr/wp-content/uploads/2010-09-27_170551-650x202.png" alt="" width="650" height="202" /></a></p>
]]></content:encoded>
			<wfw:commentRss>http://voidandany.free.fr/index.php/ubuntu-auto-login/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Ubuntu &#8211; Jaunty Jackalope plus rapide à démarrer qu&#8217;Intrepid Ibex ?</title>
		<link>http://voidandany.free.fr/index.php/ubuntu-jaunty-jackalope-plus-rapide-a-demarrer-quintrepid-ibex/</link>
		<comments>http://voidandany.free.fr/index.php/ubuntu-jaunty-jackalope-plus-rapide-a-demarrer-quintrepid-ibex/#comments</comments>
		<pubDate>Thu, 28 May 2009 10:41:24 +0000</pubDate>
		<dc:creator>voidAndAny</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[boot]]></category>
		<category><![CDATA[jaunty]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://voidandany.free.fr/?p=531</guid>
		<description><![CDATA[Une des améliorations annoncée par Canonical concernant Jaunty Jackalope (Ubuntu 9.04) concerne le temps de boot qui à été réduit. A l&#8217;occasion de ma migration de sweetLap d&#8217;Intrepid Ibex vers Jaunty Jackalope, j&#8217;ai fais quelques mesures de temps de boot. &#8230; <a href="http://voidandany.free.fr/index.php/ubuntu-jaunty-jackalope-plus-rapide-a-demarrer-quintrepid-ibex/">Continuer la lecture <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Une des améliorations annoncée par Canonical concernant Jaunty Jackalope (Ubuntu 9.04) concerne le temps de boot qui à été réduit.</p>
<p><br class="spacer_" /></p>
<p>A l&#8217;occasion de ma migration de <a href="http://voidandany.free.fr/index.php/architecture-domestique/" target="_blank">sweetLap</a> d&#8217;Intrepid Ibex vers Jaunty Jackalope, j&#8217;ai fais quelques mesures de temps de boot.</p>
<p><span id="more-531"></span></p>
<p><br class="spacer_" /></p>
<p>Pour avoir une <strong>mesure</strong> représentant un cas d&#8217;utilisation réelle j&#8217;ai démarré le chrono à l&#8217;appuie sur le bouton on/off et arrêté lors de l&#8217;affichage de la page <strong>Google</strong> dans Firefox (usage principal de sweetLap).</p>
<p><br class="spacer_" /></p>
<p>Evidemment, cette mesure présente des risques d&#8217;erreurs non négligeables selon ma dexterité à lancer Firefox et à démarrer/stoper le chrono, mais les temps annoncés ici n&#8217;ont pas vocation à être des références, juste une indication&#8230;</p>
<p>Enfin les mesures ont été réalisé au moins 3 fois pour chaque OS.</p>
<p><br class="spacer_" /></p>
<p>Voici les temps :</p>
<ul>
<li><strong>Intrepid Ibex</strong> : 1 minute 27 secondes</li>
<li><strong>Jaunty Jackalope</strong> : 1 minute 14 secondes</li>
</ul>
<p><br class="spacer_" /></p>
<p>Soit une amélioration de 15%, bien mais pas top&#8230;</p>
<p><br class="spacer_" /></p>
<p>Pour info, la migration Interpid &#8211;&gt; Jaunty à été réalisé via l&#8217;update manager (pas de réinstalle complète de Jaunty), cela à durée environ 55 minutes et les partitions sont resté en ext3.</p>
<p>Pour info (bis) booter sur secteur ou sur batterie ne semble pas avoir d&#8217;impact sur la durée de ce dernier.</p>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<p>Il sera intéressant de refaire le test après migration des partitions en ext4 (sujet d&#8217;un prochain article).</p>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
]]></content:encoded>
			<wfw:commentRss>http://voidandany.free.fr/index.php/ubuntu-jaunty-jackalope-plus-rapide-a-demarrer-quintrepid-ibex/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Installation minimale de Jaunty Jackalope en dual boot avec Gutsy Gibbon</title>
		<link>http://voidandany.free.fr/index.php/installation-minimale-de-jaunty-jackalope-en-dual-boot-avec-gutsy-gibbon/</link>
		<comments>http://voidandany.free.fr/index.php/installation-minimale-de-jaunty-jackalope-en-dual-boot-avec-gutsy-gibbon/#comments</comments>
		<pubDate>Fri, 08 May 2009 11:46:13 +0000</pubDate>
		<dc:creator>voidAndAny</dc:creator>
				<category><![CDATA[linux]]></category>
		<category><![CDATA[boot]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://voidandany.free.fr/?p=304</guid>
		<description><![CDATA[Suite à cet article rédigé en utilisant une machine virtuelle, j&#8217;ai réalisé l&#8217;installation de Jaunty sur ma machine physique sweetBox. N&#8217;ayant pas le temps de tout réinstaller (Ubuntu + XFCE + Freevo + Deluge + Podracer + Flexget + scripts) &#8230; <a href="http://voidandany.free.fr/index.php/installation-minimale-de-jaunty-jackalope-en-dual-boot-avec-gutsy-gibbon/">Continuer la lecture <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Suite à cet <a href="http://voidandany.free.fr/index.php/jaunty-jackalope-installation-minimale/" target="_blank">article</a> rédigé en utilisant une machine virtuelle, j&#8217;ai réalisé l&#8217;installation de Jaunty sur ma machine physique sweetBox.</p>
<p><br class="spacer_" /></p>
<p>N&#8217;ayant pas le temps de tout réinstaller (Ubuntu + XFCE + Freevo + Deluge + Podracer + Flexget + scripts) j&#8217;ai décidé de garder le Gutsy qui est présent et fonctionnel et d&#8217;installer Jaunty en dual-boot. Cela me permet d&#8217;installer progressivement le Jaunty en ayant le Gutsy qui continu de fonctionner.</p>
<p><br class="spacer_" /></p>
<p>C&#8217;est dans cette situation que je suis content d&#8217;avoir gardé de l&#8217;espace non patitionné sur mon disque dur, sinon le dual boot, n&#8217;aurait pas été si facile à mettre en oeuvre.</p>
<p><br class="spacer_" /></p>
<p>Cet article ne présentera pas beaucoup de nouveauté par rapport à <a href="http://voidandany.free.fr/index.php/jaunty-jackalope-installation-minimale/" target="_blank">celui-ci</a>, mais il a le mérite de présenter l&#8217;installation dans la vraie vie.</p>
<p><br class="spacer_" /></p>
<p><br class="spacer_" /></p>
<h3>Installation Jaunty minimal</h3>
<p>Une fois sweetBox démenagé du salon dans le bureau (donc branché à un vrai écran, un clavier et du réseau en CPL), on boot sur le CD Ubuntu 9.04 alternate.</p>
<p><br class="spacer_" /></p>
<p>Vient ensuite le <strong>paramétrage</strong> comme décrit <a href="http://voidandany.free.fr/index.php/jaunty-jackalope-installation-minimale/" target="_blank">ici</a>.</p>
<p>Seule différence le partionnement :</p>
<p>Pour <a href="http://voidandany.free.fr/index.php/architecture-domestique/" target="_blank">rappel</a> le disque dur de sweetBox est partitionné ainsi :</p>
<p class="MsoNormal" style="margin: 0cm 0cm 0pt; line-height: normal; mso-yfti-cnfc: 128;"><span style="font-size: 10pt; mso-ascii-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-hansi-font-family: Calibri; mso-bidi-font-family: 'Times New Roman'; mso-fareast-language: FR;"><span style="font-family: Calibri;">700 Mo pour le Swap</span></span></p>
<p class="MsoNormal" style="margin: 0cm 0cm 0pt; line-height: normal; mso-yfti-cnfc: 128;"><span style="font-size: 10pt; mso-ascii-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-hansi-font-family: Calibri; mso-bidi-font-family: 'Times New Roman'; mso-fareast-language: FR;"><span style="font-family: Calibri;">14.3 Go pour la racine (/)</span></span></p>
<p class="MsoNormal" style="margin: 0cm 0cm 0pt; line-height: normal; mso-yfti-cnfc: 128;"><span style="font-size: 10pt; mso-ascii-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-hansi-font-family: Calibri; mso-bidi-font-family: 'Times New Roman'; mso-fareast-language: FR;"><span style="font-family: Calibri;">15 Go pour le /home</span></span></p>
<p class="MsoNormal" style="margin: 0cm 0cm 0pt; line-height: normal; mso-yfti-cnfc: 128;"><span style="font-size: 10pt; mso-ascii-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-hansi-font-family: Calibri; mso-bidi-font-family: 'Times New Roman'; mso-fareast-language: FR;"><span style="font-family: Calibri;">50 Go non alloués</span></span></p>
<p>J&#8217;ai donc créé une partition primaire de 10Go en ext4 en début de disque avec l&#8217;indicateur d&#8217;amorçage et le point de montage /, ce qui donne pour mon disque :</p>
<p class="MsoNormal" style="margin: 0cm 0cm 0pt; line-height: normal; mso-yfti-cnfc: 128;"><span style="font-size: 10pt; mso-ascii-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-hansi-font-family: Calibri; mso-bidi-font-family: 'Times New Roman'; mso-fareast-language: FR;"><span style="font-family: Calibri;">700 Mo pour le Swap</span></span></p>
<p class="MsoNormal" style="margin: 0cm 0cm 0pt; line-height: normal; mso-yfti-cnfc: 128;"><span style="font-size: 10pt; mso-ascii-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-hansi-font-family: Calibri; mso-bidi-font-family: 'Times New Roman'; mso-fareast-language: FR;"><span style="font-family: Calibri;">14.3 Go pour la racine (/) Gutsy</span></span></p>
<p class="MsoNormal" style="margin: 0cm 0cm 0pt; line-height: normal; mso-yfti-cnfc: 128;"><span style="font-size: 10pt; mso-ascii-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-hansi-font-family: Calibri; mso-bidi-font-family: 'Times New Roman'; mso-fareast-language: FR;"><span style="font-family: Calibri;"><span style="font-size: 10pt; mso-ascii-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-hansi-font-family: Calibri; mso-bidi-font-family: 'Times New Roman'; mso-fareast-language: FR;"><span style="font-family: Calibri;">10 Go pour la racine (/) Jaunty</span></span></span></span></p>
<p class="MsoNormal" style="margin: 0cm 0cm 0pt; line-height: normal; mso-yfti-cnfc: 128;"><span style="font-size: 10pt; mso-ascii-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-hansi-font-family: Calibri; mso-bidi-font-family: 'Times New Roman'; mso-fareast-language: FR;"><span style="font-family: Calibri;">15 Go pour le /home Gutsy</span></span></p>
<p class="MsoNormal" style="margin: 0cm 0cm 0pt; line-height: normal; mso-yfti-cnfc: 128;"><span style="font-size: 10pt; mso-ascii-font-family: Calibri; mso-fareast-font-family: 'Times New Roman'; mso-hansi-font-family: Calibri; mso-bidi-font-family: 'Times New Roman'; mso-fareast-language: FR;"><span style="font-family: Calibri;">40 Go non alloués</span></span></p>
<p><br class="spacer_" /></p>
<p>Puis l&#8217;installation se déroule jusqu&#8217;à une phase de paramétrage supplémentaire par rapport à la maquette sur virtualBox, le message dit en gros :</p>
<pre>Les systèmes d'exploitation suivant ont été détectés :</pre>
<pre>...</pre>
<pre>Installer le programme de démarrage GRUB sur le secteur d'amorçage ?</pre>
<p><br class="spacer_" /></p>
<p>Ce qui nous va tout a fait.</p>
<p>Jaunty à détecté son petit frère Gutsy et demande si il doit faire du multi-boot.</p>
<p>On répondra donc Oui.</p>
<p><br class="spacer_" /></p>
<p>L&#8217;installation se termine, on enlève le CD et on reboot.</p>
<p><br class="spacer_" /></p>
<p>Lors de la phase de <strong>boot</strong> un menu <strong>GRUB</strong> permet de choisir le système sur lequel on désir booter.</p>
<p>Ce menu est positionné par défaut sur Jaunty et au bout de 10 secondes sans intervention Jaunty boot automatiquement et sans problème.</p>
<p>Pour me rassurer j&#8217;ai aussitôt effectué un test de boot sous Gutsy, tout fonctionne parfaitement aussi je n&#8217;ai rien cassé.</p>
<p><br class="spacer_" /></p>
<h3>Modification ordre de boot</h3>
<p>Pour changer le système de boot par défaut (Gutsy au lieu de Jaunty), il faut éditer le fichier menu.lst :</p>
<pre>sudo vi /boot/grub/menu.lst</pre>
<p><br class="spacer_" /></p>
<p>Et on changera la ligne</p>
<pre>Default 0</pre>
<p>par</p>
<pre>Default 4</pre>
<p><br class="spacer_" /></p>
<p>Où 4 est une valeur à adapter qui représente le numéro de ligne du menu Grub représentant le système sur lequel on souhaite démarrer par défaut (faire des essais)</p>
<p><br class="spacer_" /></p>
<p>On changera aussi la ligne :</p>
<pre>timeout 10</pre>
<p>par</p>
<pre>timeout 5</pre>
<p><br class="spacer_" /></p>
<p>Ne laissant que 5 secondes pour modifier le système à booter (permet de réduire le temps d&#8217;autant)</p>
<p><br class="spacer_" /></p>
<h3>Autres paramétrages</h3>
<p>Afin de remettre sweetBox dans le salon et de continuer à le paramètrer tranquillement du bureau, j&#8217;ai appliqué les configurations indiqué <a href="http://voidandany.free.fr/index.php/parametrage-de-jaunty-minimal-pour-acces-a-distance/" target="_blank">ici</a></p>
<p> Et pour avoir un jolie écran de démarrage j&#8217;ai installé USplash comme <a href="http://voidandany.free.fr/index.php/ubuntu-minimal-installation-de-usplash/" target="_blank">ici</a>.</p>
<p><br class="spacer_" /></p>
<h3>Reste à faire</h3>
<p>Pour que sweetBox puisse tourner sous Jaunty il reste à faire l&#8217;installation de :</p>
<ul>
<li>XFCE</li>
<li>Freevo</li>
<li>Divers outils</li>
</ul>
<p><br class="spacer_" /></p>
<p>Il faudra aussi récupérer la partition /home de Gutsy et remettre en place tous mes scripts (téléchargement, sauvegarde, etc.)</p>
<p><br class="spacer_" /></p>
<p>Bref encore du boulot&#8230;.</p>
]]></content:encoded>
			<wfw:commentRss>http://voidandany.free.fr/index.php/installation-minimale-de-jaunty-jackalope-en-dual-boot-avec-gutsy-gibbon/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
