Neater logging

Fixed double log output from generateUdn(), tidied up some other log
levels and messages.