Wind River Support Network


LIN5-3518 : wrlinux 5.0.1 - /etc/init.d/ntpd errors

Created: Jul 4, 2013    Updated: Dec 19, 2017
Resolved Date: Jul 28, 2013
Found In Version: 5.0.1
Fix Version:
Severity: Severe
Applicable for: Wind River Linux 5
Component/s: Userspace


$PATH should be set in /etc/init.d/ntpd, because otherwise, if this script is being called by a non-root user using sudo, it will fail as follows:

/etc/init.d/ntpd restart
Stopping ntpd: /etc/init.d/ntpd: line 29: start-stop-daemon: command not found
Starting ntpd: /etc/init.d/ntpd: line 24: start-stop-daemon: command not found

root cause: the script /etc/init.d/ntpd calls start-stop-daemon which is in /sbin (not in the default path for non-root users)

Steps to Reproduce

configure a wrlinux 5.0.1. project (any rootfs type is ok as long as it has ntp included)

boot the target
create a new user
reboot & login with the new user

run /etc/init.d/ntpd restart

Other Downloads

Live chat