Is gawk available?  I've used the '|&' operator, but not on Linux-390.

http://www.gnu.org/software/gawk/manual/gawkinet/html_node/Gawk-Special-Files.html#Gawk-Special-Files

2.1 gawk's Networking Mechanisms

The ‘|&’ operator introduced in gawk 3.1 for use in communicating with a
coprocess is described in Two-way Communications With Another
Process<http://www.gnu.org/software/gawk/manual/gawkinet/gawk/Two_002dway-I_002fO.html#Two_002dway-I_002fO>.
It shows how to do two-way I/O to a separate process, sending it data with
print or printf and reading data with getline. If you haven't read it
already, you should detour there to do so.

gawk transparently extends the two-way I/O mechanism to simple networking
through the use of special file names. When a “coprocess” that matches the
special files we are about to describe is started, gawk creates the
appropriate network connection, and then two-way I/O proceeds as usual.

At the C, C++, and Perl level, networking is accomplished via sockets, an
Application Programming Interface (API) originally developed at the
University of California at Berkeley that is now used almost universally for
TCP/IP networking. Socket level programming, while fairly straightforward,
requires paying attention to a number of details, as well as using binary
data. It is not well-suited for use from a high-level language likeawk. The
special files provided in gawk hide the details from the programmer, making
things much simpler and easier to use.

The special file name for network access is made up of several fields, all
of which are mandatory:

     /inet/protocol/localport/hostname/remoteport

The /inet/ field is, of course, constant when accessing the network. The
localport and remoteport fields do not have a meaning when used with
/inet/raw because “ports” only apply to TCP and UDP. So, when using
/inet/raw, the port fields always have to be ‘0’.

   - Special File
Fields<http://www.gnu.org/software/gawk/manual/gawkinet/html_node/Special-File-Fields.html#Special-File-Fields>:
   The fields in the special file name.
   - Comparing 
Protocols<http://www.gnu.org/software/gawk/manual/gawkinet/html_node/Comparing-Protocols.html#Comparing-Protocols>:
   Differences between the protocols.

----------------------------------------------------------------------
For LINUX-390 subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO LINUX-390 or visit
http://www.marist.edu/htbin/wlvindex?LINUX-390

Reply via email to