'makepipe' and 'readpipe'

makepipe and readpipe are a little-known pair of utilities that are useful when you want to verify a client's connectivity to SQL Server through named pipes. The utilities work in con-junction with one another. To use these utilities, you first run makepipe from a command line on the server. The basic syntax is as follows:

makepipe 
readpipe /Sserver_name

You can optionally pass it a pipe name, or it will create a default named pipe on the local SQL Server with a name of \\.\pipe\abc. Next, on the client computer, you can run readpipe /Sserver_name. You can supply some optional parameters, but at minimum, readpipe needs the server name. If the named pipes interface is working properly between the client and the server, the client will display a message indicating that it sent data successfully to the server, and the server will echo the data sent from the client.

The following is an example of what you would see on the client machine after a successful readpipe execution.

SvrName:\\win2000svr 
PIPE   :\\win2000svr\pipe\abc
DATA   :test
Data Sent: 1 : test
Data Read: 1 : test

The server also reacts to the readpipe call with the makepipe utility, showing something like this:

Waiting for client to send... 1 
Data Read:      test
Waiting for client to send... 2
Pipe closed
Waiting for Client to Connect...

You can press Ctrl+C to exit the utility on the server side. The -q option for the readpipe utility enables you to specify that it poll for incoming data. If not specified, the utility will wait for incoming data.

The makepipe and readpipe utilities are not installed as part of the SQL Server 2000 installation, but they can be copied from the installation disc.



    Part III: SQL Server Administration
    Part IV: Transact-SQL
    Part V: SQL Server Internals and Performance Tuning
    Part VI: Additional SQL Server Features