TugaCS
Gostaria de reagir a esta mensagem? Crie uma conta em poucos cliques ou inicie sessão para continuar.
Ir em baixo
almighty
almighty
Mensagens : 1
Data de inscrição : 15/01/2020

multics verificacao minuto a minuto e arranque automatico Empty multics verificacao minuto a minuto e arranque automatico

Sex 8 Jan 2021 - 21:15
como crear cronjob para verificar se o multics esta a trabalhar todos os minutos

1- open putty

2- apt-get update

3- apt-get install nano

4- cd /etc

5- touch multics.sh

6- chmod 777 multics.sh

7- nano multics.sh

8- Next copy all that code bellow inside the multics.sh ( note ) write the wright path where your multics versison is located and the right name.

ex: in my case i have in usr, local, bin, multics so i will copy and paste the codes bellow

#!/bin/bash
if ! ps -C multics > /dev/null
then
    /usr/local/bin/multics
fi

9- Next hit from your keyboard ctrl+o and enter to save then to exit ctrl+x

10- Now we need make a cron job what executes the script every 1 minute, or from you desire minutes. Please give next commands to make a cron job

11- cd /etc

11- export EDITOR="nano"

12- crontab -e

13- There add new line to the cronjob like this bellow

14- */1 * * * * /etc/multics.sh

15- Hit ctrl+o enter to save and ctrl+x to exit 

16- reboot your server

17- login over putty kill your multics then you will see that in 1 minute will restart multics by it self

18- i will leave a few examples how to kill multics

19- killall multics -9 ### killall multics.x32 -9 ### killall multics.x64 -9  

                                                                           Tested and working by me enjoy ...

altair70 e nortsat gostam desta mensagem

Voltar ao Topo
Permissão deste fórum:
Você não pode responder aos tópicos neste fórum