Web OS 10.0 Application Guide226 n Chapter 10: Health Checking 212777-A, February 2002Script FormatThe general format for health-check scripts is shown below:N OTE – If you are doing HTTP 1.1 pipelining, you need to individually open and close eachresponse in the script. Each script should start with the command open port <protocol port number>. Thenext line can be either a send or expect. The first word is the method. This is usually get; however, HTTP supports several othercommands, including put and head. The second word indicates the content desired, orrequest-URI, and the third word represents the version of the protocol used by the client.If you supplied HTTP/1.1 for the protocol version, you would also have to add in the fol-lowing line: Host: www.hostname.comExample: GET /index.html HTTP/1.1 (press Enter key)Host: www.hostname.com (press Enter key twice)This is known as a host header. It is important to include because most Web sites nowrequire it for proper processing. Host headers were optional in HTTP/1.0 but are requiredwhen you use HTTP/1.1+. In order to tell the Web server you have finished entering header information, a blank lineof input is needed after all headers. At this point, the URL will be processed and theresults returned to you.N OTE – If you make an error, enter rem to remove the last typed script line entered. If youneed to remove more than one line, enter rem for each line that needs to be removed. The switch provides the “\” prompt, which is one enter key stroke. When using the sendcommand, note what happens when you type the send command with the commandstring. When you type send, press enter and allow the switch to format the commandstring (that is, \ versus \\).open application_port (e.g., 80 for HTTP, 23 for Telnet, etc.)send request1expect response1send request2expect response2send request3expect response3close