...
- BOLD: refers to files that need to be modified or generated by IOC developer
- Italics: symbolic link
How-To setup the IOC boot directories
The instructions differ between production and development due to permission restrictions in production.
Table 1
Facility | Account | Server |
---|
LCLS | laci | lcls-daemon0, lcls-daemon1, lcls-deamon2,cryo-daemon1 |
FACET-II | flaci | facet-daemon1 |
TestFac | acctf | testfac-daemon1 |
Dev | laci | lcls-dev3 (rhel6), dev-rhel7 (rhel7) |
Production: lcls, lcls2, facet, testfac
- Send email to Ken Brobeck requesting:
create controls infrastructure for a new IOC on facility production server, which includes the following:- create controls infrastructure:
- for a new IOC that boots from a production Linux daemon server (see Table1) or a camera server.
- Add boot directory:
$IOC_DATA/<ioc> directory- $EPICS_IOCS<ioc>
- Add data directories: $IOC_DATA/<ioc>/<autosave,autosave-req,restore,iocInfo,
archive> - archive,yaml> directories
- Add automatic boot scripts:
- (rhel6 only)
- add boot script on server defined in table 1: /etc/inti.d/st.<ioc>
- add symbolic link on server defined in table 1: /etc/rc3.d/SS98st.<ioc> ----> /etc/init.d/st.<ioc>
- Proceed to Step #2c under Development
...
...
Development: dev
- Create the $IOC_DATA directory
Facility | Server |
---|
LCLS | laci@lcls-daemon1 |
LCLS-II | laci@lcls-daemon1 |
FACET-II | flaci@facet-daemon1 |
TestFac | acctf@testfac-daemon1 |
...
Development: dev
- Create the $IOC_DATA directory for your iocs as follows:
- cd $IOC_DATA for your IOC
- mkdir sioc-<area>-<subsystem-prefix><2-digit#>
- cd <sioc>
- mkdir archive autosave-req autosave iocInfo restore yaml
- Create the $EPICS_IOCS ioc boot directory
- mkdir sioc-<area>-<subsystem-prefix><2-digit#>
Setup ioc boot directory filesCreate the IOC boot directory with boot links as follows:
- cd $EPICS_IOCS
- mkdir / sioc-<area>-<subsystem-prefix><2-digit#>
copy the ioc startup.cmd script from $EPICS_IOCS/template- cd <ioc>
- cp
for Linux running iocsh: cp - ../template/startup.cmd.
soft st.cmd Create symbolic link: ln -s st.cmd - soft startup.cmd
- Edit
st- startup.cmd
- replace <ioc> with your ioc name
- replace <t_a> with the target, such as linux-x86 or linux-x86_64 or rhel6-x86_64, rhel7-x86_64 (ref. your application bin directory).
- replace <exe> with your IOC Application executable
this ioc should load
- if your IOC Application uses a non-standard location for the st.cmd file, change path
of the EPICS- of EPICS_IOC_APP
Setup a relative symbolic link that points to the EPICS IOC Applicaiton TOP as follows- create symbolic:
- ln -
s - s ../../iocTop/<app>/
<version>- <ver> iocSpecificRelease
Modify - Add your IOC to$EPICS_IOCS/
screeniocs – Please note that this is a symbolic link to a CVS file.
verify that the file in use has not been modified without being committed.cd $EPICS_IOCS/All/<facility> , where - facility
is Dev,Prod,facet,acctest- cvs diff -r HEAD screeniocs
- if there are issues, then send email to whoever made the change or to controls-software that you are about to update this file and uncommitted edits will be lost, so please commit your changes to CVS. If you don't get a response, you can either add the changes to CVS in addition to yours or just add yours.
- check out screeniocs from CVS into your work area
- cd
cd <work>
cvs co epics/iocCommon/All- /
<facility> , where facility is Dev,Prod,facet,acctestcd epics/iocCommon/All/<facility>/- screeniocs
- edit screeniocs
- add line for <ioc>. For server refer to table 1 above.
format: sioc-<area>-<subsystem prefix><2-digit #> <executable w/full absoluete path> sioc <server> [#comment}
The "comment" field in screeeniocs is optional - and
must be preceded by a "#".- add comment in the "Mod:" section of the header
- commit your changes of screeniocs to CVS as follows:
- cvs commit -m "added cpu and ioc blah" screeniocs
- update the screeniocs file in use
- cd $EPICS_IOCS/All/<facility>
- rm -f screeniocs
- cvs update screeniocs
- commit change to CVS
How-to boot an IOC from the Linux host(daemon) server specified in screeniocs:
There are multiple ways to boot a soft ioc which are listed below:
- Log onto server listed in table 1 above Table 1 from the account this same table, and perform the following commands:
- cd /etc/init.d
- ./st.<ioc> <restart,start,stop>
- Use iocConsole to start an ioc, which uses the screen program
- iocConsole <ioc> --stayup
- siocRestart <ioc>
- Boot ioc IOC from the facility home network display
...
- display network panel
How to connect to Linux IOC from a Linux server:
- iocConsole <ioc>
How-to use screen program:
...