Added -hostname and -attempts support

Added code to the command line parameters -hostname and -attempts. Did
not perform any operational testing on this code yet.