How to make a script in init.d run later

Solution 1:

When your computer starts up, it doesn't run the init.d scripts directly. Instead, depending on what's called the "runlevel", it runs the scripts in /etc/rcN.d (where N is the runlevel). You can determine the current runlevel with the runlevel command; mine returns 2 in normal operation. That means that when the computer started up, it ran the scripts in /etc/rc2.d. The contents of rc2.d are just symlinks to scripts in /etc/init.d, named according to whether they should be started or stopped, and the order they should be run.

Use the runlevel command to find out what runlevel your computer is at (probably 2), then look in /etc/rc2.d for a link named SNNccpd, which will be a symlink to /etc/init.d/ccpd, and rename it to S99zzzccpd - or whatever it takes to get it to sort after the other entries - that will cause it to run last.

There's more information about init.d scripts and runlevels at https://www.linux.com/news/enterprise/systems-management/8116-an-introduction-to-services-runlevels-and-rcd-scripts