FOR TIPS, gUIDES & TUTORIALS

subscribe to our Youtube

GO TO YOUTUBE

14210 questions

16856 answers

27737 comments

54319 members

0 votes
205 views 2 comments
by
Hello,

i would love to automatically turn off wifi during the night. Or if not possible then manually.

Is there any solution to that ?

Kind regards,

Woga

1 Answer

0 votes
by

Hi,

For this, you would need to set a crontab.

How to do it you will find here: https://openwrt.org/docs/guide-user/base-system/cron

The command you need to run with a crontab is wifi down in the evening and wifi up in the mornings.

EB.

by
i´m trying to switch it of but doesnt work

[email protected]:~# 25 6 * * 0-6 /sbin/wifi up

-ash: 25: not found

whats the problem?

by

I did not check, if the crontab is written correctly, but if you want to periodically turn WiFi on and of, you need to place the command you have written in the /etc/crontabs/root file with the following command:

echo "25 6 * * 0-6 /sbin/wifi up" >> /etc/crontabs/root

To check if the command is in the crontabs list, execute the following:

crontab -l