This MR tries to make the admin backend work again after #515 (closed) and also to prevent socket leaks.