Advertisement
Guest User

Untitled

a guest
Mar 19th, 2019
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. ##DESCARGA NTP
  2. sudo apt install ntp
  3. sudo apt install ntpstat
  4.  
  5. ##LEVANTA EL SERVICIO
  6. service ntp start -x
  7. /etc/init.d/ntp start
  8.  
  9. ##CHEQUEA RESULTADO DE CONEXION
  10. result=$(ntpstat);
  11. conected=$( echo $result | awk '{print $1}')
  12. if [ $conected = "synchronised" ]
  13. then
  14. echo "Conectado correctamente"
  15. else
  16. echo "Fallo la conexión"
  17. fi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement