improved initdb error handling