13
cdsDaemonStarter Configuration
cdsDaemonStarter configuration enables you to launch a program without inheriting the control group of its parent. The following programs are started in Virtuoso using an optional cdsDaemonStarter script:
-
clsbd -
oaFSLockD -
cdsXvnc -
cdsNameServer
ThecdsNameServerprogram is used to establish communications between Cadence programs. It relies upon the TCP port number, 7325. In addition, whenever needed, thecdsNameServerprogram starts automatically and exits itself after being idle.
Control Groups
When the Linux control group functionality is enabled, a job is considered to be running until all the processes in the control group exit. This causes a problem because some processes are intended to daemonize themselves and continue to run after the parent job has finished.
To solve this problem, a support for an optional wrapper script has been introduced, which is automatically invoked by the Cadence software to start daemonizing processes. The arguments to the wrapper script indicates which daemon program (and its arguments) should start.
This is illustrated by the following pass-through example:
#!/bin/ksh
exec "$@"
The korn shell uses "$@" to denote the arguments provided to the wrapper script.
You can use the following wrapper script to launch the program in a specific control group:
#!/bin/ksh
cgexec -g someControlGroupInfo --sticky "$@"
If Load Sharing Facility (LSF, version 9) control group functionality is enabled, you can use the following wrapper script to launch the program:
#!/bin/ksh # If it looks like an LSF environment, look for job-specific control group if [ -n "${LSF_CGROUP_TOPDIR_KEY}" -a -n "${LSB_JOBID}" -a \ -n "${LSF_BINDIR}" -a -r /proc/self/cgroup ]; then if grep ":/lsf/${LSF_CGROUP_TOPDIR_KEY}/job\.${LSB_JOBID}\." \ /proc/self/cgroup >/dev/null; then
exec ${LSF_BINDIR}/lsgrun -m $(uname -n) "$@" < /dev/null
# only reached if above exec failed
fi
fi exec "$@"
As illustrated above, the lsgrun command starts the daemon in a different control group than the parent.
<cdsInstallDir>/cdssetup/daemon/starter.lsf.sample
If clsbd or other daemons are not exiting and preventing LSF jobs to get completed then use this script to start daemons in the LSF environment.
<cdsInstallDir>/cdssetup/daemon/starter.olv.sample
Wrapper Installation
Normally, the wrapper is installed as ${CDS_SITE}/cdssetup/daemon/starter, where the default value for ${CDS_SITE} is <cdsInstallDir>/share/local/. You can also install the wrapper as cdssetup/daemon/starter into a directory that is searched by the Cadence Setup File (csf) package.
~/cdssetup/daemon/starter. You must also ensure that you have appropriate execute permissions.
After installing the wrapper, you can use the following command to confirm that it is found by csf:
% cdswhich cdssetup/daemon/starter
Related Topics
Search Mechanism in Cadence Setup Search File
Return to top