I have a file on my server that has HL7 messages spread out by a space. Example below. I am wanting to send one of these messages at a time in a continual loop until stopping the script with ctrl+c. I am pretty new to
netcat but when I try to netcat directly using
nc -l 10004 I get:
ncat: bind to :::10004: Address already in use. QUITTING.
There is a Mirth application on the appliance listening on this port already. I have no problem running the command on another appliance altogether sending it to this one if that is the only way but I need assistance sending to the IP using
netcat and sending one message at a time with a timed gap between them.
MSH.... ....... ....... MSH.... ....... MSH.... ....... ....... .......
The file I am pulling from has multiple messages with more than one line but they are separated by a line break. (space)