Script for detecting and logging ip address changes to database