❓ Help Walang Kwentang Ideya | Nolowd

Status
Not open for further replies.
crontab setup for seconds

30 seconds : */30 * * * *
10 seconds : */10 * * * *
Screenshot_2020-11-19-11-30-12-93.webp
 
[XX='KoroSenpai, c: 507549, m: 1358296'][/XX]
Napapagana ko na autorecon every minute. Nirerestart yung squid. Pero yung dropbear ayaw mag autorecon kapag dropbear ang nirestart.
 
[XX='Stale, c: 507555, m: 520608'][/XX] gawin mo

screen -d -m -f systemctl restart squid dropbear openvpn privoxy

para sabay sabay.
isahang command lang.

debian/ubuntu command install : apt-get install screen -y
centos 6/7 command install : yum install screen -y
 
ito mas maganda Stale

create new file

restart.sh

then
add code below

Bash:
#!/bin/bash
while true
do
 systemctl restart dropbear
 sleep 5
 systemctl restart dropbear2
done

tapos command :
chmod +x restart.sh && bash restart.sh && crontab -l | { cat; echo "* * * * * screen -d -m -f bash restart.sh"; } | crontab -


every 1 minute dalawa ang ma re restart including sleep 5 seconds pwede mo gawing 10 seconds depende sayo. pwede mo rin gawin ito while naghihintay sa 1 minute by looping


Bash:
#!/bin/bash
while true
do
 systemctl restart dropbear
 sleep 10
 systemctl restart dropbear2
 sleep 15
 systemctl restart dropbear
 sleep 10
screen -d -m -f bash restart.sh
sleep 2
done
 
Status
Not open for further replies.

About this Thread

  • 62
    Replies
  • 2K
    Views
  • 19
    Participants
Last reply from:
PHC - plokplok

Trending Topics

Online now

Members online
263
Guests online
682
Total visitors
945

Forum statistics

Threads
2,276,504
Posts
28,970,462
Members
1,231,325
Latest member
Classvali
Back
Top