home *** CD-ROM | disk | FTP | other *** search
/ Troubleshooting Netware Systems / CSTRIAL0196.BIN / attach / pcc / v08n03 / netwrk.exe / NETSCAN1.ZIP / NET_SCAN.TXT < prev   
Text File  |  1993-11-03  |  12KB  |  269 lines

  1.  
  2.              NET_SCAN : Network integrity checking package
  3.              ---------------------------------------------
  4.  
  5.                Copyright (c) Jean-Albert FERREZ  (11.93)
  6.  
  7.           ╔══════════════════════════════════════════════════╗
  8.           ║             This package is shareware.           ║
  9.           ║                                                  ║
  10.           ║ This package is provided "as is". There is no    ║
  11.           ║ warranty of any kind associated with the package ║
  12.           ║                                                  ║
  13.           ║ You are free to distribute the whole unmodified  ║
  14.           ║ package as long as you don't charge more than    ║
  15.           ║ the usual small fee for handling and shipping.   ║
  16.           ║                                                  ║
  17.           ║ You are free to test it for one month, but if    ║
  18.           ║ you want to use it or include it in any product, ║
  19.           ║ you have to register. Price and address follow.  ║
  20.           ╚══════════════════════════════════════════════════╝
  21.  
  22. The package includes the following files :
  23.         NET_SCAN.TXT  :  This text
  24.         NET_SCAN.EXE  :  Scanning TSR
  25.         NET_LOCK.COM  :  Lock-that-file TSR
  26.  
  27. The purpose of this package is to have a permanent scanning of a 
  28. network in order to be informed as early as possible of problems such 
  29. as :
  30.        - Terminal having been switched off
  31.        - Network cable having been pulled out
  32.  
  33. It is especially useful for terminals with no human activity.
  34.  
  35. Let's take the example given by the following network :
  36.  
  37.             Front office                               Back office
  38.  
  39.    ╔════════════╗
  40.    ║ terminal 1 ╟───────┐
  41.    ╚════════════╝       │
  42.                      ╔══╧═══════╗                     ╔════════════╗
  43.                      ║  server  ╟─────────────────────╢ terminal S ║
  44.                      ╚══╤═══════╝                     ╚════════════╝
  45.    ╔════════════╗       │
  46.    ║ terminal 2 ╟───────┘
  47.    ╚════════════╝
  48.  
  49. On terminal S runs a background program without any user intervention. 
  50. At least one person is always present at either terminal 1 or 2.
  51.  
  52. We need a way to warn these people if terminal S looses connection 
  53. with the server, either because  the cable has been pulled out or the 
  54. terminal has broken down or any other problem that the terminal can 
  55. neither detect nor take care of itself.
  56.  
  57. One possible solution is a permanent exchange of data between the 
  58. server and terminal S, detecting any unexpected end of communication. 
  59. The major drawback of this solution is that it requires a non-
  60. negligible amount of network resources, both in terms of bandwidth and 
  61. server performance. (Other solutions might be offered by specific 
  62. network functions, but we wanted to have something that would run on 
  63. just anything, see Requirements below).
  64.  
  65.  
  66. The idea
  67. ========
  68.  
  69. The idea behind NET_SCAN is to have terminal S open-and-lock a file on 
  70. the server and keep it open as long as it is running properly. Any 
  71. problem including abnormal program termination, terminal switching off 
  72. or cable cutting will cause the file to be unlocked by the server 
  73. after a few seconds. Therefore, all that is needed is to regularly 
  74. check from any other terminal if that file is accessible or not. If it 
  75. is not, everything is running properly, but if the file is accessible, 
  76. it is very likely that something has gone wrong. In the latter case, 
  77. just pop up a box with the hotline phone number or whatever. This 
  78. solution saves server performance and reduces network activity to a 
  79. minimum. The frequency for the check depends on how critical the 
  80. application on terminal S is, but this can usually be set to a couple 
  81. of minutes or even more.
  82.  
  83. All that is fairly easy to hardcode in your application, especially on 
  84. terminal S but a much smarter approach is to leave the job to a 
  85. background TSR-based routine that you just load at start-up and forget 
  86. about. This is highly preferable when front office people are likely 
  87. to use several applications. This is what the two programs NET_SCAN 
  88. and NET_LOCK have been written for.
  89.  
  90.  
  91. NET_LOCK
  92. ========
  93.  
  94. NET_LOCK runs on terminal S. At start up, it takes from the command 
  95. line the full path of a file to open and lock. If the file does not
  96. exist, it tries creates one with a zero-length. It then has to become
  97. resident, because DOS automatically closes (and unlocks) any open file 
  98. when a program terminates, but stays inactive. The memory required by 
  99. that TSR is about 500 bytes. In addition, it can be loaded in high 
  100. memory.
  101.  
  102. For example, if a server's drive is locally available as drive S:
  103. and the NET_SCAN package is in the C:\NET_SCAN\ directory,
  104. you can include the following line in terminal S's AUTOEXEC.BAT :
  105.  
  106.   C:\NET_SCAN\NET_LOCK.COM S:\NET_SCAN.SCN
  107.  
  108. As stated before, network-based application developers are very likely 
  109. to dismiss that TSR and include the open-and-lock process at the 
  110. beginning of their program, allowing them an extra possibility : just 
  111. unlock the file if you want the people to be aware of a difficult 
  112. situation although the terminal is physically OK. Examples of these 
  113. situations are buffer overflows or lost of serial connection with 
  114. whatever-you-want-including-coffee-machine...
  115.  
  116.  
  117. NET_SCAN
  118. ========
  119.  
  120. NET_SCAN runs on any user-accessed terminal. This includes the server, 
  121. although it is neither required nor advised. (The server should 
  122. actually never run user application). It works on any station
  123. independently from other stations. You have two strategies : install 
  124. it everywhere, increasing the chances for at least one person to be 
  125. warned, or install it only on the supervisor's terminal who is anyhow 
  126. the only person able to deal with the problem so why disturb other 
  127. people ? Once again the answer to that relies on how critical terminal 
  128. S is. However, NET_SCAN will keep popping up the warning message as 
  129. long as the situation has not been normalised (read: as long as the 
  130. file remains unlocked) so it doesn't really matter if the first 
  131. warning comes up while the whole office is having coffee. 
  132.  
  133. To install NET_SCAN either from the command line or from AUTOEXEC.BAT 
  134. or from NETSTART.BAT or whatever, you have to give the full path of 
  135. the file which has to be checked. You will be warned if that file 
  136. either is not locked (it is likely that terminal S is already in 
  137. trouble) or does not exist (some mistake in the path name ?). You may 
  138. also specify as second parameter the frequency of the check in 
  139. seconds, which is otherwise set to 600 (i.e. 10 minutes). If you do 
  140. this, you may then give as third parameter the time during which the 
  141. warning box will be displayed. The terminal is locked while that box 
  142. is on screen but you can also remove it by pressing CTRL-ENTER. The 
  143. default is here 20 seconds.
  144.  
  145. Once NET_SCAN has been successfully installed, no sign of its presence 
  146. is visible as long as the file is locked. If during one check the file 
  147. happens to be unlocked, then a red box with a configurable message
  148. pops up and locks the terminal until either the user presses CTRL-
  149. ENTER, acknowledging the message, or 20 seconds (or whatever time you 
  150. have specified) have passed. That time limit is here to avoid long-
  151. time lock-up in case of a lengthy user-less process such as background 
  152. printing or automatic file backup. It is however possible for the user 
  153. to make sure that NET_SCAN is installed and that terminal S is running 
  154. properly by pressing CTRL-ALT-T. If the file is not locked, you get 
  155. the same red box as usual, but if the file is locked you get a 
  156. reassuring green box with another configurable message telling you 
  157. everything is OK.
  158.  
  159. To go on with the example, provided the server's drive is still S:
  160. the following line goes in AUTOEXEC.BAT on any terminal :
  161.  
  162.   C:\NET_SCAN\NET_SCAN.EXE S:\NET_SCAN.SCN 600 10
  163.  
  164. This will scan every ten minutes on drive S: (ie on the server) for
  165. the file NET_SCAN.SCN in the root directory. If any box is to be
  166. displayed, it will remain at most ten seconds on the screen.
  167.  
  168.  
  169. The Messages
  170. ============
  171.  
  172. The messages in the two boxes are hard-coded in the NET_SCAN.EXE file 
  173. avoiding the need for a configuration file which give - as you know - 
  174. a good opportunity for an end-user to smash the beautiful environment 
  175. you had set up for him. You can still modify these messages with Norton
  176. or other similar HEX editors BUT MAKE A BACKUP OF THE ORIGINAL FILE !!
  177. If you prefer a safer approach, we have a nice INSTALL program to do
  178. the job. Please contact us.
  179.  
  180.  
  181. Requirements
  182. ============
  183.  
  184. These programs will work on any PC with DOS 3.0 or above and SHARE.EXE 
  185. loaded. They do run on a single PC but only make sense on a network. 
  186. The nice detail about them is that they don't require any specific 
  187. network but just some way to read and write to a remote machine's hard 
  188. disk.
  189.  
  190.  
  191. History and future developments
  192. ===============================
  193.  
  194. NET_SCAN was designed for the needs of the telephone logging program 
  195. we wrote as part of the Hotel Management System being developed here 
  196. at HotSoft in the marvellous resort of Verbier. Then we thought that 
  197. other people out there in the fog might have been facing the same 
  198. problem and decided to release it.
  199.  
  200. Although the programs might be improved for our own needs, it is not 
  201. likely that future versions will be publicly available. To get them, 
  202. you'll have to register. We may even consider writing a special 
  203. version for your needs. Contact us and we'll see if you can afford 
  204. it... 
  205.  
  206.  
  207. Disclaimer
  208. ==========
  209.  
  210. These programs have been tested and are currently being used by our 
  211. customers. That said, since TSR are by definition a possible cause of 
  212. trouble on a twelve years old OS and since you paid so little to have 
  213. them, we don't assume any responsibility for any problem due to the 
  214. use of these programs. 
  215.  
  216. The name of HotSoft only appears here as an example of application 
  217. using NET_SCAN. 
  218.  
  219.  
  220. Known bugs
  221. ==========
  222.  
  223. With Lantastic (tm), after having run (and exited) Windows 3.1, the
  224. box may not appear, eventually hanging up the computer. [Any technical
  225. information about how Lantastic and Win deal with int 8h & 28h and the
  226. indos flag would help.]
  227.  
  228.  
  229. Registration
  230. ============
  231.  
  232. NET_SCAN is shareware. Anyone is granted the right to TEST NET_SCAN 
  233. for a period of one month. Anyone interested in USING NET_SCAN on a 
  234. network must first register. Anyone interested in INCLUDING NET_SCAN 
  235. as part of any product also has to register. Source code is also 
  236. available, feel free to ask.
  237.  
  238. Registration fee is US$ 20 (or 30 Swiss Francs), to be sent at the 
  239. following address :
  240.  
  241.                   Jean-Albert FERREZ
  242.                   Route de Patier
  243.                   CH-1936 VERBIER
  244.  
  245. (When registering please give E-mail address if any.)
  246.  
  247. Since we use NET_SCAN for our own needs, it will improve and by 
  248. registering you will receive the latest version. In particular,
  249. NET_SCAN.EXE is being rewritten in assembler in order to cut its
  250. memory requirements from 21K down to 2-3K
  251.  
  252. Should you have further questions about the package or related topics 
  253. please write at the same address or E-mail at ferrez@dma.epfl.ch
  254.  
  255.  
  256. Addresses
  257. =========
  258.  
  259.              Jean-Albert FERREZ           ferrez@dma.epfl.ch
  260.              Route de Patier                on the InterNet
  261.              CH-1936 VERBIER
  262.  
  263.  
  264.              HotSoft Development          [71540.2311]
  265.              Residence du Parc              on CompuServe
  266.              CH-1936 VERBIER
  267.  
  268.  
  269.