Add regserver run function.
Fix logging statements.