Fixed signal handling and logging
Fixed logging
Fixed logging