using.yo (4014B)
1 Crossroads is started from the commandline, and highly depends on 2 tt(/etc/crossroads.conf) (the default configuration file). It 3 supports a number of flags (e.g., to overrule the location of the 4 configuration file). The actual usage information is always obtained 5 by typing tt(crossroads) without any arguments. Crossroads then 6 displays the allowed arguments. 7 8 subsect(General Commandline Syntax) 9 10 This section shows the most basic usage. As said above, start 11 tt(crossroads) without arguments to view the full listing of options. 12 13 itemization( 14 it() tt(crossroads start) and tt(crossroads stop) are typical 15 actions that are run from system startup scripts. The 16 meaning is self-explanatory. 17 it() tt(crossroads restart) is a combination of the former 18 two. Beware that a restart may cause discontinuity in 19 service; it is just a shorthand for typing the 'stop' and 20 'start' actions after one another. 21 it() tt(crossroad status) reports on each running 22 service. Per service, the state of each back end is 23 reported. 24 it() tt(crossroads tell) em(service backend state) is a 25 command line way of telling crossroads that a given back 26 end, of a given service, is in a given state. Normally 27 crossroads maintains state information itself, but by 28 using tt(crossroads tell), a back end can be e.g. taken 29 'off line' for servicing. 30 it() tt(crossroads configtest) tells you whether the 31 configuration is syntactially correct. 32 it() tt(crossroads services) reports on the configured 33 services. In contrast to tt(crossroads status), this 34 option only shows what's configured -- not what's up and 35 running. Therefore, tt(crossroads services) doesn't 36 report on back end states. 37 it() tt(crossroads sampleconf) shows a sample configuration on 38 screen. A good way of quicky viewing the configuration 39 file syntax, or of getting a start for your own 40 configuration tt(/etc/crossroads.conf). 41 ) 42 43 subsect(Logging-related options) 44 45 Two 'flags' of Crossroads are specifically logging-related. This 46 section elaborates on these flags. 47 48 First, there's flag tt(-a). When present, the start and end of 49 activity is logged using statements like 50 51 center(em(YYYY-MM-DD HH/MM/SS starting http from 61.45.32.189 to 10.1.1.1)) 52 53 Similarly, there are 'ending' statements. Using this flag and 54 scanning your logs for these statements may be helpful in quickly 55 determining your system load. 56 57 Second, there's flag tt(-l). This flag selects the 'facility' of 58 logging and defaults to tt(LOG_DAEMON). You can supply a number 59 between 0 and 7 to flag tt(-l) to select tt(LOG_LOCAL0) to 60 tt(LOG_LOCAL7). This would separate the Crossroads-related logging 61 from other streams. Here's a very short guide; please read your Unix 62 manpages of tt(syslogd) for more information. 63 64 itemization( 65 it() First edit tt(/etc/syslog.conf) and add a line: 66 67 verb(local7.* /var/log/crossroads.log) 68 69 That instructs tt(syslogd) to send tt(LOG_LOCAL7) requests to the 70 logfile tt(/var/log/crossroads.log). 71 72 it() Next, restart tt(syslogd). On most Unices that's done by 73 issuing tt(killall -1 syslogd). (As a side-note, I tried this once 74 on an Bull/AIX system, and the box just shut down. The tt(killall) 75 command killed every process...) 76 77 it() Now start tt(crossroads) with the flag tt(-l7). 78 79 it() Finally, monitor tt(/var/log/crossroads.log) for Crossroads' 80 messages.) 81 82 83 subsect(Reloading Configurations) 84 85 Crossroads doesn't support the reloading of a configuration while 86 running (such as other programs, e.g. Apache do). There are various 87 technical reasons for this. 88 89 However, external lists of allowed or denied IP addresses can be 90 reloaded by sending a signal -1 (tt(SIGHUP)) to Crossroads. See 91 section ref(servicedef) for the details.