Renamed savip to save_ip and refactored setting the hostname into a one-liner.