Central

From University of Washington - Ubicomp Research Page
Jump to: navigation, search

central

central is the server for the IPC (Inter Process Communications) package developed by Reid Simmons. IPC provides a simple means of communicating between applications on the same computer and other machines via TCP/IP. Central is used by the msb-server and several other applications to share information. More information about IPC can be found at the projects homepage.

usage

    Typical Usage

      Spawn central and send it to the background
      central -u &
      

      Note, that only 1 copy of central can be run at one time. If you want to run multiple central's (see the -p argument below) or access central running on another machine you will need to export the CENTRALHOST variable: <bash># If you want to use another port export CENTRALHOST=localhost:1234

      1. If you want to connect to another machine

      export CENTRALHOST=othermachine </bash>

    Available Commands

      Various debugging/logging capabilities are also available if necessary. Remember to have a process cat the .log file that central creates.
      The following are central commands:
       help: print this message
       display: display the active and pending messages
       status: display the known modules and their status
       memory: display total memory usage
       close <module>: close a connection to a module
       unlock <resource>: unlock a locked resource
      
      The following command line options can also be used as commands:
      -v: display server version information
      -l<option>: logging onto terminal. Options are:
         m (message traffic)
         s (status of IPC)
         t (time messages are received by central)
         d (data associated with messages)
         i (ignore logging certain internal messages)
         h (handle time summary of incoming messages)
         r (log the reference ID as well as the message name)
         p (log the reference ID of the message’s parent)
         x (no logging)
      
      -l (no options) is equivalent to -lmstdh; the default is –lmsi
      
      -L<option>: logging into file.
        Options are the same as above, with the addition of
         F (don’t flush file after each line)
         n (don’t prompt user for comments)
        The default is –Lx
      
      -f<filename>: filename to use for logging; If not specified, name is automatically generated.
      
      -p<port>: connect to central server on this port number.
      -c: Use direct (not via central) connections when possible
      -I<msgName>: Ignore logging this message (can occur multiple times).
      -I<filename>: File with names of messages to ignore logging
      -s: silent running; don’t print anything to terminal.
      -u: don’t run the user (tty) interface.
      -r: try resending non-completed messages when modules crash and then reconnect.
      

    example output

      central typically does not output anything to the console unless an error occurs.