Reorganized client/agent cfg + added some features