Since you seem to be starting to learn Sockets, you may be interested in looking at these nice self-documenting code examples, which don't use high-level modules, that show how sockets really work. UNO Golden Socket examples (Scroll down to Perl ) After a few socket scripts, you will come to appreciate the higher-level-socket modules, but it's also nice to see the real thing.