önce dosyanın bir yedeğini alalım.
Ne olur Ne olmas.
cp -a /etc/rc.d/rc.local /etc/rc.d/rc.local.yedek
/etc/rc.d/rc.local dosyasındaki
#!/bin/bash
# If you compiled the speedtouch driver as a module you'll
# need to load it first, so uncomment the next line
# modprobe speedtch
count=0
while [[ $count -lt 40 ]]
do
sync=$(dmesg | grep 'ADSL line is up')
if [ ! -z "$sync" ]
then
pppd call speedtch
exit 0
fi
sleep 1
let "count += 1"
done
echo "The Speedtouch firmware didn't load"
bu kısımı
/etc/rc.d/rc.adsl adında bir dosya oluşturarak içine kaydet
/etc/rc.d/rc.adsl yi çalıştırılabilir hale getirelim.
chmod 755 /etc/rc.d/rc.adsl
rc.local dosyasından yukarıdaki kısımları sil
ve
bu kodu ekle
# Adsl yi Baslatir
if [ -x /etc/rc.d/rc.adsl ]; then
. /etc/rc.d/rc.adsl
echo "Adsl Baglantisi Acildi"
fi
ekle
rc.local in son hali buna benzemeli
#!/bin/sh
#
# /etc/rc.d/rc.local: Local system initialization script.
#
# Put any local startup commands in here. Also, if you have
# anything that needs to be run at shutdown time you can
# make an /etc/rc.d/rc.local_shutdown script and put those
# commands in there.
# Start the Wifi-radar daemon
if [ -x /etc/rc.d/rc.wifi-radar ]; then
/etc/rc.d/rc.wifi-radar start
fi
# Adsl yi Baslatir
if [ -x /etc/rc.d/rc.adsl ]; then
. /etc/rc.d/rc.adsl
echo "Adsl Baglantisi Acildi"
fi
# Web sunucuyu baslatır
if [ -x /opt/lampp/lampp ]; then
/opt/lampp/lampp start
echo "Web sunucu Baslatiliyor"
fi
Problem Çıkarsa Gene Buradayız