Changes between Version 31 and Version 32 of startstop


Ignore:
Timestamp:
11/16/11 15:57:25 (10 years ago)
Author:
branden
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • startstop

    v31 v32  
    1212For startstop to work, it must know about the Earthworm environment. This is typically done by setting the environment variables within the environment/ew_* file specific to your platform, and then sourcing that file, or executing the cmd if you're on Windows. Startstop typically reads its configuration file from the EW_PARAMS directory (as defined in your environment) and creates the specified rings. It then starts each module as a child process, passing its configuration file name, and any other parameters as its command line paramters (argv, argc). Each module (child process) is started with the priority indicated in startstop*.d. Note that each module and each ring specified must be definined within earthworm.d or earthworm_global.d, which should be in the EW_PARAMS directory. The system continues to run until "quit<cr>" is typed in startstop's command window. Startstop then sets a terminate flag in each transport ring. Each well-behaved module (child process) should periodically check for the terminate flag, and exit gracefully if is set. 
    1313 
    14 Note that two copies of startstop pointing at the same startstop *d file are not allowed to run simultaneously. The second one started will fail and quit. (If you really want to do this for some reason, you'd need to make sure that you use all different rings in the second version, different ports for the modules, and a different startstop*d file, specified as a parameter when starting startstop.) 
     14Note that two copies of startstop pointing at the same startstop*.d file are not allowed to run simultaneously. The second one started will fail and quit. (If you really want to do this for some reason, you'd need to make sure that you use all different rings in the second version, different ports for the modules, and a different startstop*.d file, specified as a parameter when starting startstop.) 
    1515 
    1616If the user presses the "Enter" key while the startstop command window is Selected, or enters the command "status", startstop will print a status table showing various statistics for each module, including whether it is dead or alive. If a module is dead because it could not be started (for example, the executable's name were mistyped so the executable could not be found), it will be reported as !NoExec. 
     
    7474}}} 
    7575 
    76  * The reconfigure program sends an Earthworm TYPE_RECONFIGURE message. Startstop will then re-read the startstop_nt.d, starstop_unix.d or startstop_sol.d, and allocate any new rings and start up any new modules it finds in the new .d file. In the process it rereads the earthworm.d and earthworm_global.d, in the event that there have been new module IDs or new ring IDs added there. 
     76 * The reconfigure program sends an Earthworm TYPE_RECONFIGURE message. Startstop will then re-read the [wiki:startstop_nt startstop_nt].d, [wiki:starstop_unix starstop_unix].d or [wiki:startstop_sol startstop_sol].d, and allocate any new rings and start up any new modules it finds in the new .d file. In the process it rereads the earthworm.d and earthworm_global.d, in the event that there have been new module IDs or new ring IDs added there. 
    7777 * As the final reconfigure step, [wiki:startmgr statmgr] is restarted as well so it re-reads it's config file. Any modules that were added to startstop*.d should be added to the statmgr.d config file as well. 
    7878 * Reconfigure is a command you can run from within startstop, and it also is a standalone command-line tool. The standalone tool will show you a 'status' before and after the reconfigure.rererec 
     
    133133== Solaris, Linux, Mac OS X versions == 
    134134 
    135  * Solaris startstop reads a configuration file named 'startstop_sol.d' 
    136  * Mac OS X and Linux startstop reads a configuration file named 'startstop_unix.d' 
     135 * Solaris startstop reads a configuration file named [wiki:startstop_sol startstop_sol].d' 
     136 * Mac OS X and Linux startstop reads a configuration file named [wiki:startstop_unix startstop_unix].d' 
    137137 * If a child process does not exit within a user specified time after the user types "quit<cr>" (or "stopmodule" or "restart"), startstop terminates the child process. Startstop will resort to a more draconian but reliable approach to quiting a module if the standard approach fails, but only if a command to do so is included in the configuration file. 
    138138 * The amount of CPU time used by each child process is listed in the process status table. 
     
    151151== Windows Service version == 
    152152 
    153  * Windows startstop and Windows startstop service read a configuration file named 'startstop_nt.d' 
     153 * Windows startstop and Windows startstop service read a configuration file named [wiki:startstop_nt startstop_nt].d' 
    154154 * If Windows starts up, and, for example, the binary executables for certain modules are missing or are misnamed, startstop will start up anyway. These processes will be shown with a nonexistent negative process ID, and "!NoExec" as their status. If this process is restarted once the problem that caused the error has been fixed, the process ID will return to a normal ID, and the status will change to "Alive". 
    155155 * Startstop can be set to start automatically when Windows boots up (see below: 'Earthworm NT Autostart'), but probably better than doing that is to set startstop as a Windows service (see below: Earthworm Windows Service). Note if you set Startstop as a Windows service you'll need to use other command line utilities like 'status' and 'restart' to monitor and control earthworm modules since there's no interface to the Startstop service. You can run !StartstopConsole in order to be able to connect to the session running earthworm, if you're not logged in as administrator (see above: !StartstopConsole). You'll be able to start and stop Earthworm with the Windows Services Control Panel.