• # Re: Script de démarrage

    Posté par (site web personnel) . En réponse au journal Script de démarrage. Évalué à 1.

    Je suis complètement reparti de zéro, en réécrivant le contenu de /etc/rc.d et /etc/inittab:

    ===== /etc/inittab =====

    id:3:initdefault:
    si:S:sysinit:/etc/rc.d/sysinit
    ca::ctrlaltdel:/sbin/shutdown -r now
    l0:0:wait:/etc/rc.d/halt halt
    l6:6:wait:/etc/rc.d/halt reboot

    c1:1235:respawn:/sbin/agetty 38400 tty1 linux
    c2:1235:respawn:/sbin/agetty 38400 tty2 linux
    c3:1235:respawn:/sbin/agetty 38400 tty3 linux
    c4:1235:respawn:/sbin/agetty 38400 tty4 linux
    c5:1235:respawn:/sbin/agetty 38400 tty5 linux
    c6:12345:respawn:/sbin/agetty 38400 tty6 linux

    ===== /etc/rc.d/sysinit ======

    #!/bin/sh

    export PATH="/bin:/usr/bin:/usr/local/bin:/sbin:/usr/sbin:/usr/local/sbin";
    loadkeys fr
    swapon -a
    mount /proc
    fsck -A
    mount -a
    mount / -o remount,rw
    klogd && syslogd
    hwclock --utc --hctosys
    hostname plop
    ifconfig lo inet 127.0.0.1 up
    ifconfig eth0 inet 192.168.0.1 up
    startadsl &

    ====== /etc/rc.d/halt ======

    #!/bin/sh

    killall5 -9
    umount -a
    mount / -o remount,ro

    if [ "1ドル" = "halt" ]; then
    halt -f;
    else
    reboot -f;
    fi;


    Ok c'est pas très propre, mais ca marche Bien(r).