You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »


Definitions

  • 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.

Production:   lcls, lcls2, facet, testfac

  1. Send email to Ken Brobeck requesting:
    1. create controls infrastructure for a new IOC on facility production server, which includes the following:
      1.  Add boot directory: $IOC_DATA/<ioc>  directory
      2.  Add data directories: $IOC_DATA/<ioc>/<autosave,autosave-req,restore,iocInfo,archive>  directories 
      3.  Add automatic boot scripts:
        1. add boot script on server defined in table 1:       /etc/inti.d/st.<ioc>
        2. add symbolic link on server defined in table 1:   /etc/rc3.d/SS98st.<ioc> ---->   /etc/init.d/st.<ioc>

                               Table 1
           
          FacilityServer
          LCLSlaci@lcls-daemon1
          LCLS-IIlaci@lcls-daemon1
          FACET-IIflaci@facet-daemon1
          TestFacacctf@testfac-daemon1

           

  2. Proceed to Development Step #3

Development:    dev

  1. Create the $IOC_DATA directory for your iocs as follows:
      1. cd $IOC_DATA
      2. mkdir sioc-<area>-<subsystem-prefix><2-digit#>
      3. cd  <sioc>
      4. mkdir archive autosave-req autosave iocInfo restore
  2.  Create the $EPICS_IOCS  ioc boot directory
    1. mkdir  sioc-<area>-<subsystem-prefix><2-digit#>
  3. Setup ioc boot directory files
    1. cd $EPICS_IOCS/sioc-<area>-<subsystem-prefix><2-digit#>
    1. copy the ioc startup.cmd script from  $EPICS_IOCS/template
      1.  for Linux running iocsh:    cp ../template/startup.cmd.soft         st.cmd
      2.  Create symbolic link:         ln -s st.cmd startup.cmd
  4. Edit st.cmd
    1. replace <ioc>  with your ioc name
    2. replace <t_a> with the target, such as  linux-x86  or linux-x86_64 or rhel6-x86_64 (ref. your application bin directory).
    3. replace <exe> with your IOC Application executable this ioc should load
    4. if your IOC Application uses a non-standard location for the st.cmd file,  change path of the EPICS_IOC_APP
    5. Setup a relative symbolic link that points to the EPICS IOC Applicaiton TOP as follows:  
               ln -s ../../iocTop/<app>/<version> iocSpecificRelease
  1. Modify $EPICS_IOCS/screeniocs    Please note that this is a symbolic link to a CVS file.
    1. verify that the file in use has not been modified without being committed.
      1. cd $EPICS_IOCS/facility
      2. cvs diff -r HEAD screeniocs
      3. 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.
    2. check out screeniocs from CVS into your work area
      1. cd
      2. cd <work>
        cvs co epics/iocCommon/<facility>   , where facility is Dev,Prod,facet,acctest
        1. cd epics/iocCommon/<facility>/screeniocs
        2. edit screeniocs
          1. 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}
          2. The "comment" field in  screeeniocs  is optional and must be preceded by a  "#".
          3. add comment in the "Mod:" section of the header
    3. commit your changes of screeniocs to CVS  as follows:
      1.  cvs commit  -m "added cpu and ioc blah" screeniocs
    4. update the screeniocs file in use
      1. cd $EPICS_IOCS/<facility>
      2.  rm -f screeniocs
      3. cvs update screeniocs
         

How-to boot an IOC from the Linux host:

There are multiple ways to boot a soft ioc which are listed below: 

  1. Log onto server listed in table 1 above and perform the following commands:
    1. cd /etc/init.d
    2. ./st.<ioc>  <restart,start,stop>
  2. Use iocConsole to start an ioc, which uses the screen program
    1. iocConsole <ioc>  --stayup
  3. Boot ioc from the facility home network display 

 

How-to use screen program:

  • ctrl a d : detach from the screen session
  • ctrl a [ : scroll up through the start-up messages.

  • No labels