Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The instructions differ between production and development due to permission restrictions in production.

                                       Table 1

FacilityAccountServer
LCLSlacilcls-daemon0, lcls-daemon1, lcls-deamon2,cryo-daemon1
FACET-IIflacifacet-daemon1
TestFacacctftestfac-daemon1
Devlacilcls-dev3 (rhel6), dev-rhel7 (rhel7)


Production:   lcls, facet, testfac

  1. Send email to Ken Brobeck requesting:
    1. create controls infrastructure:
      • for a new IOC  that boots from a production Linux daemon server (see Table1) or a camera server.
        1.  Add boot directory: $EPICS_DATA/<ioc>IOCS<ioc>
        2.  Add data directories: $IOC_DATA/<ioc>/<autosave,autosave-req,restore,iocInfo,archive,yaml>  directories 
        3.  Add automatic boot scripts: 
        4. Add boot directory: $EPICS_DATA/<cpu>
        5. Add data directory: $IOC_DATA/<cpu>      - includes iocInfo
          • (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>
        for new CPU that will perform a diskless boot of rhel7 (centos7).   
  2. Proceed to Step #3 under Development

                                     Table 1

...

  1. #2c under Development

                                         

...

              

Development:    dev   dev

  1. Create the $IOC_DATA directory f as follows:
    1. For your IOC
      cd $IOC_DATA for your IOC
    2. mkdir sioc-<area>-<subsystem-prefix><2-digit#>
    3. cd  <sioc>
    4. mkdir archive autosave-req autosave iocInfo restore yaml
      For your CPU (in needed)
    5. $IOC_DATA
    6. mkdir cpu-<area>-<subsystem-prefix><2-digit#>
    7. cd <cpu>
    8. mkdir iocInfo
  2.  Create the $EPICS_IOCS  IOC boot directory with boot links as follows:

    1. cd $EPICS_IOCS
    2. For your IOC: mkdir  sioc-<area>-<subsystem-prefix><2-digit#>
    3. for your CPU: mkdir  cpu-<arae>-<subsystem-prefix><2-digit#>
    Setup boot directory files
    1. For your IOC: cd $EPICS_IOCS/ <ioc>
      1.  for Linux running iocsh:    cp  cp ../template/startup.cmd.soft         soft  startup.cmd
      2.  for Linux running cexp:     cp ../template/startup.cmd.soft.cexp  startup.cmd
      3. Edit startup.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, rhel7-x86_64    (ref. your application bin directory).
        3. replace <exe> with your IOC Application executable
        this ioc should load

        1. if your IOC Application uses a non-standard location for the st.cmd file,  change path of  EPICS_IOC_APP
      4. create symbolic:   ln -s   ../../iocTop/<app>/<ver>  iocSpecificRelease
    2. For you CPU (if needed)
      1. cd $EPCS_IOCS/<cpu>
      2. cp ../template/startup.cmd.soft.cpu.<facility> startup.cmd    where facility is dev,lcls,facet,testfac
      3. Edit startup.cmd
        1. replace <cpu> with cpu name
        2. if your IOC Application uses a non-standard locaiton for hte st.cmd file, change the path of EPICS_CPU_APP
      4. create symbolic:   ln -s   ../../iocTop/<app>/<ver>  iocSpecificRelease
      5. Add ipxe file in $TFTPBOOT/boot/ipxe/<cpu>.ipxe   Note: for a FACET cpu you must create this file from laci@lcls-srv01
  3. Modify $EPICS_IOCS/screeniocs    Please note that this is a symbolic link to a CVS file.
    1. Go to your home sandbox:
      1. cd <work>
        cvs co epics/iocCommon/All/<facility>   , where facility is Dev,Prod,facet,acctest
        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
        4. cd epics/iocCommon/All/<facility>/screeniocs
        5. edit screeniocs
    2. verify that the file in production have not been modified without being committed.
      1. cd $EPICS_IOCS/All/<facility>      , where facility is Dev,Prod,facet,acctest
      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.
    3. check out screeniocs from CVS into your work area
    4. commit your changes of screeniocs to CVS  as follows:
      1.  cvs commit  -m "added cpu and ioc blah" screeniocs
    5. update the screeniocs file in use
      1. cd $EPICS_IOCS/All/<facility>
      2.  rm -f screeniocs
      3. cvs update screeniocs
         
  1. Add your IOC to$EPICS_IOCS/facility/screeniocs and commit change to CVS 

How-to boot an IOC from the Linux (daemon) host with diskserver specified in screeniocs:

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

  1. Log onto server listed in table 1 above Table 1 from the account this same table,  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. siocRestart <ioc>
  4. Boot ioc IOC from the facility home display network display panel 


How - to boot an IOC from the Linux host w/o a disk:

The following scripts are located under the directory $IOC/common and should be in PATH on the CPU.

    1. siocStart <ioc>   - starts a specific ioc. However, if the ioc is up nothing will be done
    2. siocStart    -  starts all iocs not already running
    3. iocConsole.sh <ioc> -d   (starts the specified ioc, but does not attache to the screen session)
    4. iocConsole.sh <ioc> -R  (graceful reset)
    5. iocConsole.sh <ioc> -r  (fast restart)
    6. iocConsole.sh --help

How to connect to Linux CPU IOC from a Linux host with a disk:

Use either iocConsole or ssh to CPU as follows:

  1. iocConsole  <cpu>
  2. Using ssh
    • from  lcls or dev: ssh laci@<cpu>  
    • from facet: ssh flaci@<cpu

How to check if IOC is running on the linuxRT CPU:

...

server:

  1. iocConsole  <ioc>

How-to use screen program:

...