Added catch for long hostname