Provided by: vzctl_4.9.4-6_amd64 bug

NAME

       vznnc - run a program connected to a socket

SYNOPSIS

       vznnc { -l | -c } -p port [-f fd] [--] program [arg ...]

DESCRIPTION

       This "nano-netcat" utility can be used to either listen on or connect to a TCP port at
       localhost, and run a specified program with its stdin and stdout (or a specified file
       descriptor) connected to the socket.

OPTIONS

       -l     Listen on a specified TCP port at localhost.

       -c     Connect to a specified TCP port at localhost.

       -p port
              Port number.

       -f fd  File descriptor ID. If this option is not set, stdin and stdout are closed and are
              connected to the socket, otherwise they are left intact, and the specified fd is
              used.

       --     This is a separator between vznnc own arguments and program arguments, so that
              latter won't be processed by vznnc.  It is required in case there are any arguments
              to program that start with the dash (-) character, and is optional otherwise.

       program [ arg ... ]
              Program to run, with optional arguments.

EXIT STATUS

       Returns program exit status upon success, or one of the following codes in case of an
       error:

       1      Invalid usage

       127    Error executing program.

       220    Network-related error.

EXAMPLES

       To run receiving side of ploop copy command on a remote server, using openssh port
       forwarding:

        PORT=2345
        ssh -L localhost:$PORT:localhost:$PORT $REMOTE_SERVER \
            vznnc -l -p $PORT -- ploop copy -d $FILE -i0 -o1

       To do the same, but with stdin and stdout intact, using file descriptor 5 for
       communication:

        ssh -L localhost:$PORT:localhost:$PORT $REMOTE_SERVER \
            vznnc -l -p $PORT -f 5 -- ploop copy -d $FILE -i5 -o5

SEE ALSO

       nc(3), netcat(3), socat(2).

LICENSE

       Copyright (C) 2014, Parallels, Inc. Licensed under GNU GPL v2.