Themabewertung:
  • 0 Bewertung(en) - 0 im Durchschnitt
  • 1
  • 2
  • 3
  • 4
  • 5
Raspberry pi als AccessPoint (AP)
#2
Crontab einstellen für 2x in der Woche nen reboot
Quellen:
forum.smartapfel.de/forum
www.elektronik-kompendium.de

Grund: Um Stabilitätsprobleme zu beheben oder eventuellen langzeitlichen Stabilitätsproblemen aus dem Weg zu gehn, denn bei mir hat sich der AP nach ~6tagen abgeschossen und über ihn konnte nicht mehr aufs netzwerk/internet zugegriffen werden.

Hinweis: Wichtig ist, dass am Ende der Tabelle ein Kommentar oder eine Leerzeile steht. Ähnlich wie die fstab muss die crontab mit einer Leerzeile enden!

Code:
sudo crontab -e
Öffnet den crontab Editor

Code:
pi@raspberrypi:~ $ sudo su
root@raspberrypi:/home/pi# sudo crontab -e
no crontab for root - using an empty one

Select an editor. To change later, run 'select-editor'.
1. /bin/ed
2. /bin/nano <---- easiest
3. /usr/bin/vim.tiny

Choose 1-3 [2]:
Ich empfehle hier den nano-Editor, also Taste 2 und bestätigen mit der Entertaste.

Jetzt müste euch in der Console Folgendes angezeigt werden (is mehr aber ich habs kürzen müssen) :
Code:
Edit this file to introduce tasks to be run by cron.
#
# Each task to run has to be defined through a single line
# indicating with different fields when the task will be run
# and what command to run for the task
~~~~~
~~~~~
# For more information see the manual pages of crontab(5) and cron(8)
#
00 3 * * 4,7 sudo reboot
# m h  dom mon dow   command
Strg+x für beenden drücken und Abfrage zum Speicher mit j für ja beantworten.
Dann Enter drücken und nochmal Enter dann sollte crontab fertig sein.
Wie immer noch nen Neustart und schon sollte der Pi nun 2mal in der Woche am Donnerstag und Sonntag jeweil um 3 Uhr Nachts von alleine neustarten.

Dieser Abschnitt ist für 3x täglich nen Neustart alle 8h:
Code:
Edit this file to introduce tasks to be run by cron.
#
# Each task to run has to be defined through a single line
# indicating with different fields when the task will be run
# and what command to run for the task
~~~~~
~~~~~
# For more information see the manual pages of crontab(5) and cron(8)
#
00 7,15,23 * * * sudo reboot
# m h  dom mon dow   command
Neugestartet wird damit jeden Tag um 3Uhr 15Uhr sowie 23Uhr.

---------------------------

wenn man noch pi-hole drauf haben will
Code:
wget -O basic-install.sh https://install.pi-hole.net

!Wird noch weiter vervollständigt!
Inside Windows-Kernel: if(everything_is_ok==1) { crash(); }

[Bild: lpy4aa-2.png]

</>Congratulations, you've reached the end of the internet!
Zitieren


Nachrichten in diesem Thema
Raspberry pi als AccessPoint (AP) - von T!t@n - 27.02.2016, 03:53
[Kein Betreff] - von T!t@n - 06.05.2019, 03:21
[Kein Betreff] - von Jochen - 06.05.2019, 09:40
[Kein Betreff] - von T!t@n - 07.05.2019, 02:35
[Kein Betreff] - von Jochen - 07.05.2019, 07:43
[Kein Betreff] - von T!t@n - 07.05.2019, 16:34
[Kein Betreff] - von Jochen - 08.05.2019, 12:19
[Kein Betreff] - von T!t@n - 08.05.2019, 16:55
[Kein Betreff] - von CB1JCY - 08.05.2019, 18:01
[Kein Betreff] - von Holzroller - 08.05.2019, 22:37
[Kein Betreff] - von Jochen - 09.05.2019, 08:07
und der Umwelt zur Liebe - von CB1JCY - 09.05.2019, 11:43
[Kein Betreff] - von T!t@n - 09.05.2019, 17:22
[Kein Betreff] - von CB1JCY - 09.05.2019, 20:32
[Kein Betreff] - von Holzroller - 10.05.2019, 22:16
[Kein Betreff] - von T!t@n - 10.05.2019, 23:36
[Kein Betreff] - von maikt - 10.05.2019, 23:46
[Kein Betreff] - von T!t@n - 12.05.2019, 22:17
[Kein Betreff] - von T!t@n - 15.05.2019, 01:39
[Kein Betreff] - von T!t@n - 17.05.2019, 01:54

Gehe zu:


Benutzer, die gerade dieses Thema anschauen: 1 Gast/Gäste