Using the 3 arg form of open is not performance related. There are several reasons, but the key one is security. The 2 arg form is less secure because it opens the door for possible code injection. For example, in the 2 arg form if the filename is being supplied by the user instead of being hard coded, it's passed to and interpolated by the shell. In such a case, the user could add malicious code after the filename and it would/could be executed by the shell.
One advantage of the lexical var is that it's block scoped and perl will do an implicit close if needed and another advantage is that since it's a lexical var, it doesn't pollute the symbol table like the bareword filehandles do.
Since the hostnames aren't duplicated, then a simple hash will suffice instead of the hash of arrays. Before we make that change, I'd like to know the results of code I provided.