first "working version of the script" needs manual db dump of hostid's in orter to work