View this PageEdit this PageUploads to this PageVersions of this PageHomeRecent ChangesSearchHelp Guide

Hacer que un ordenador Linux autoarranque en las X


  1. Primero instalas el rungetty con un:
     # apt-get install rungetty
  2. editas el /etc/inittabcomentando la línea de "1:2345:respawn:/sbin/getty 38400 tty1" y poniendo al final "x:23:respawn:/sbin/rungetty -w root -u root -g root --autologin root tty1 -- /bin/login -f metro RUNGETTY=YES", (cambiendo lode metro por el usuario que vayas a usar), quedando:
     #1:2345:respawn:/sbin/getty 38400 tty1
     2:23:respawn:/sbin/getty 38400 tty2
     3:23:respawn:/sbin/getty 38400 tty3
     4:23:respawn:/sbin/getty 38400 tty4
     5:23:respawn:/sbin/getty 38400 tty5
     6:23:respawn:/sbin/getty 38400 tty6
    
     [...]
    
     x:23:respawn:/sbin/rungetty -w root -u root -g root --autologin \
    root tty1 -- /bin/login -f metro RUNGETTY=YES
    

  3. Añades en el /home/metro/.bash_profile lo siguiente:
    if [ "m$RUNGETTY" = "mYES" ]; then
            export RUNGETTY=NO
            # Aqui van las cosas especificas de arranque automatico
            # Con un startx pasamos el control a $HOME/.Xsession
            startx
            logout
    fi
    

  4. Por último, añades en el /home/metro/.Xsession que arranque los programas que quieras y por último el gestor de ventanas, como en:
     #!/bin/sh
     xclock &
     xeyes &
     xterm &
     mwm
    




Y ya está, con eso tienes el arranque automático terminado