Skip to content
Snippets Groups Projects
  • Adam Wujek's avatar
    rootfs/etc/init.d/system_clock_monitor: fix killing ntpd with pgid · fee88de0
    Adam Wujek authored
    
    -Get process group ID (pgid) instead of process ID. It didn't work when
     it was called from cron.
    -pgrep should accept full path. Without "-f" pgrep accepts "ntpd", but
     not "/usr/sbin/ntpd"
    
    Because of the two reasons above the system_clock_monitor script was not
    killing ntpd correctly.
    
    In practice, the ntp will be killed after 10s, instead of default
    timeout from ntpd 50s.
    
    Signed-off-by: default avatarAdam Wujek <dev_public@wujek.eu>
    fee88de0