altered style a bit and added stylesheets to all the other html files
[spider.git] / html / connect.html
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html>
3   <head>
4     <title>Connecting to other Clusters</title>
5         <meta name="Keywords" content="DX Cluster, DXSpider, Spider, Packet Cluster, DXCluster, Pavillion Software, AK1A, AX25, AX.25, WWV, Packet Radio, Amateur Radio, Propagation, DX, DXing, G1TLH, GB7TLH, Dirk Koopman, Mailing list, Linux, RedHat, PERL">
6         <meta name="Description" content="Software and systems for realtime digital communications between amateur radio stations for the provision of information on propagation conditions and stations operating">
7         <meta name="Author" content="Dirk Koopman G1TLH">
8     <link rel=stylesheet href="style.css" type="text/css" title="default stylesheet">
9   </head>
10
11   <body TEXT="#000000" LINK="#0000ff" VLINK="#800080" BGCOLOR="#FFFFFF">
12         <FONT COLOR="#606060"> 
13           <hr>
14           <h2>Connecting to other Clusters</h2>
15           <hr>
16         </font>
17         
18         
19         <address><a href="mailto:djk@tobit.co.uk">Dirk Koopman G1TLH</a></address>
20         <p>
21           <!-- Created: Sun Dec 13 20:25:14 GMT 1998 -->
22           <!-- hhmts start -->
23 Last modified: Fri Jan 19 14:25:13 GMT 2001
24 <!-- hhmts end -->
25         <p>At the moment, anybody can connect inwards at any time from outside, either by ax25 or by
26           telnet (assuming you have followed the instructions in <a href="install.html">installation</a>
27           instructions. However, in order to connect outwards, you will need to create <em>connect</em> scripts.
28           
29         <p><em>Connect</em> scripts live in the <tt>/spider/connect</tt> directory and are simple ascii scripts
30           that are written using a normal editor. There are a couple of examples in the issue directory.
31           
32         <p>Here are a few of basic types, first a telnet connection where the 
33            client is set up in the passwd file thus:-
34         <pre>
35     gb7djk:x:1372:1291::/home/gb7djk:/usr/bin/perl /spider/perl/client.pl gb7djk telnet
36         </pre>
37         and the connect script would be:-
38         <pre>
39     timeout 15
40     # this is a comment
41     connect telnet dirkl.tobit.co.uk
42     'login' 'gb7djk'
43     'word' 'gb7djk'
44     client gb7djk telnet
45         </pre>
46         <p>For a connect that requires a login and execution of the programs
47           from a normal shell, do:-
48
49         <pre>
50     timeout 15
51     connect telnet dirkl.tobit.co.uk
52     'login' 'gb7djk'
53     'word' 'gb7djk'
54     '\$' 'cd /spider/perl'
55     # set the line to prevent echoing, leaving this out will
56     # confuse whole networks for hours!
57     '\$' 'stty -echo raw'
58     # tell GB7DJK that you are GB7DJK-1
59     '\$' 'client.pl gb7djk-1 telnet'
60     # tell GB7DJK-1 that it is connected to GB7DJK
61     # you can leave this out if you call this script 'gb7djk'
62     client gb7djk telnet
63         </pre>
64
65         <p>and finally an ax25 example:-
66         <pre>
67     timeout 60
68     abort (Busy|Sorry|Fail)
69     # don't forget to chmod 4775 netrom_call!
70     connect ax25 /usr/sbin/netrom_call bbs gb7djk g1tlh
71     'Connect' ''
72     'Connect' 'c np7'
73     'Connect' 'c gb7dxm'
74     'Connect' ''
75     # you can leave this out if you call the script 'gb7dxm'
76     client gb7dxm ax25
77         </pre>
78         
79         <p>A connection is started manually by typing in <tt>connect &lt;scriptname&gt;</tt> on a sysop enabled
80           <tt>client.pl</tt> session. For example:-
81         <pre>
82     G1TLH de GB7DJK 13-Dec-1998 2041Z > connect gb7djk-1
83     connection to GB7DJK-1 started
84     G1TLH de GB7DJK 13-Dec-1998 2043Z > 
85         </pre>
86         
87     <p>You can watch the progress of the connection (if you have the standard debugging enabled) on the
88           <tt>cluster.pl</tt> screen and you should see something like this:-
89         <pre>
90     &lt;- D G1TLH connect gb7djk-1
91     -> D G1TLH connection to GB7DJK-1 started
92     -> D G1TLH G1TLH de GB7DJK 13-Dec-1998 2046Z >
93     timeout set to 15
94     CONNECT sort: telnet command: dirkl.tobit.co.uk
95     CHAT "login" -> "gb7djk"
96     received "
97     Red Hat Linux release 5.1 (Manhattan)
98     Kernel 2.0.35 on an i586
99     "
100     received "login: "
101     sent "gb7djk"
102     CHAT "word" -> "gb7djk"
103     received "gb7djk
104  
105     "
106     received "Password: "
107     sent "gb7djk"
108     Connected to GB7DJK-1, starting normal protocol
109     &lt;- O GB7DJK-1 telnet
110     -> B GB7DJK-1 0
111     GB7DJK-1 channel func  state 0 -> init
112     &lt;- D GB7DJK-1 
113     &lt;- D GB7DJK-1 Last login: Sun Dec 13 17:59:56 from dirk1
114     &lt;- D GB7DJK-1 PC38^GB7DJK-1^~
115     &lt;- D GB7DJK-1 PC18^ 1 nodes, 0 local / 1 total users  Max users 0  Uptime 0 00:00^5447^~
116     etc
117         </pre>
118         
119         <p>The connect scripts consist of lines which start with the
120         following keywords or symbols:-
121
122         <ul>
123
124                 <p><li><b>#</b> All lines starting with a <b>#</b> are
125                 ignored, as are wholly blank lines.
126
127                 <p><li><b>timeout</b> followed by a number is the number of
128                 seconds to wait for a command to complete. If there is no
129                 <b>timeout</b> specified in the script then the default is 60
130                 seconds.
131
132                 <P><li><b>abort</b> is a regular expression containing one or
133                 more strings to look for to abort a connection. This is a perl
134                 regular expression and is executed ignoring case.
135
136                 <p><li><b>connect</b> followed by <b>ax25</b> or <b>telnet</b>
137                 and some type dependent information. In the case of a
138                 <b>telnet</b> connection, there can be up to two parameters,
139                 the first is the ip address or hostname of the computer you
140                 wish to connect to and the second is the port number you want
141                 to use (this can be left out if it is a normal telnet
142                 session).
143
144                 <p>In the case of an <b>ax25</b> session then this would
145                 normally be a call to <tt>ax25_call</tt> or
146                 <tt>netrom_call</tt> as in the example above. It is your
147                 responsibility to get your node and other ax25 parameters to
148                 work before going down this route!
149
150                 <p><li><b>'</b> is the delimiting character for a word or
151                 phrase of an expect/send line in a <tt>chat</tt> type
152                 script. The words/phrases normally come in pairs, either can
153                 be empty. Each line reads input from the connection until it
154                 sees the string (or perl regular expression) contained in the
155                 left hand string. If the left hand string is empty then it
156                 doesn't read or wait for anything. The comparison is done
157                 ignoring case.
158
159                 <p>When the left hand string has found what it is looking (if
160                 it is) then the right hand string is sent to the connection.
161
162                 <p>This process is repeated for every line of <tt>chat</tt> script. 
163
164                 <p><li><b>client</b> starts the connection, put the arguments
165                 you would want here if you were starting the client program
166                 manually. You only need this if the script has a different
167                 name to the callsign you are trying to connect to (i.e. you
168                 have a script called <tt>other</tt> which actually connects to
169                 <tt>GB7DJK-1</tt> [instead of a script called
170                 <tt>gb7djk-1</tt>]).
171
172         </ul>
173
174 <!-- Standard Footer!! -->
175         <p>&nbsp;</p>
176         <p>
177           <FONT COLOR="#606060"><hr></font>
178         <font color="#FF0000" size=-2>
179           Copyright &copy; 1998 by Dirk Koopman G1TLH. All Rights Reserved<br>
180         </font>
181         <font color="#000000" size=-2>$Id$</font>
182   </body>
183 </html>