move management console functions into library