Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Latest commit

 

History

History
28 lines (21 loc) · 604 Bytes

README.md

File metadata and controls

28 lines (21 loc) · 604 Bytes

NetReconnector

The script for linux to reconnect net. The wifi of raspberrypi lost connection frequently, so this is for it.

1.put the script into the home dir, like: /home/pi

2.edit the parameter in the script

vim NetReconnector.sh
# NetCard and PingTarget should be modified.

2.add x priority to the script

chmod +x NetReconnector.sh

3.add a task with crontab

crontab -e

4.add this line which means run the script every 5 minutes between 8:00 and 22:00.

*/5 8-22 * * * ~/NetReconnector.sh 

5.log file generated in home dir, like: /home/pi/NetReconnector.log