kb:testing_and_debugging:installing_a_test_version_of_a_single_program_on_a_lantime_device

Installing a Test Version of a Single Program on a LANTIME Device

Sometimes it is helpful to temporarily install a test or debug version of a specific program on a LANTIME device.

It has to be noted that all the changes described below are undone when the device is rebooted. This is because the whole firmware is unpacked from an archive when the device reboots, and thus temporary changes like those described here get lost.

This example shows how to do this with a test version of the NTP daemon, ntpd.

If the executable program shall work properly together with the other firmware components, it must have been specifically compiled for the particular version of the LANTIME firmware. So let's assume a specific test version of the NTP daemon, ntpd-test has been made available by the Meinberg support.

The test version of the program should be copied to some directory on the LANTIME, e.g. the root directory. Copy the executable file to the LANTIME using scp:

scp ntpd-test root@lantime:/

where of course lantime has to be replaced by the real name or IP address of the LANTIME device.


Then login to the device using ssh:

ssh root@lantime


Now let's see where the original ntpd is located:

lantime ~ # ls -l `which ntpd`
lrwxrwxrwx 1 root root 34 Apr 21 10:01 /sbin/ntpd → /packages/ntp/files/link/sbin/ntpd

So there's a symbolic link in /sbin/ which points to the real executable file.


We can simply change the symbolic link and let it point to our specific version. First we remove the original link, then we create a new one pointing to the new executable we want to use for testing:

lantime ~ # rm /sbin/ntpd
lantime ~ # ln -s /ntpd-test /sbin/ntpd


Just to be sure, we can verify that the link now points to our testing program:

lantime ~ # ls -l `which ntpd`
lrwxrwxrwx 1 root root 36 Apr 21 10:19 /sbin/ntpd → /ntpd-test


Finally we restart the NTP service to activate the test version:

lantime ~ # restart ntp


As mentioned above, all these changes are undone when the device is rebooted.


Martin Burnicki martin.burnicki@meinberg.de, last updated 2020-04-21

  • kb/testing_and_debugging/installing_a_test_version_of_a_single_program_on_a_lantime_device.txt
  • Last modified: 2020-09-21 12:44
  • by 127.0.0.1