# ERROR: Checkout failed: Could not resolve hostname github.com: Name or service not known

- **ID:** `cicd/jenkins-pipeline-checkout-failed`
- **Domain:** cicd
- **Category:** network_error
- **Verification:** ai_generated
- **Fix Rate:** 85%

## Root Cause

Jenkins pipeline failed to resolve the Git hostname due to DNS resolution failure, network misconfiguration, or proxy issues in the build environment.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| Jenkins 2.440 | active | — | — |
| Git plugin 5.2.0 | active | — | — |
| Alpine Linux 3.18 | active | — | — |

## Workarounds

1. **Configure DNS servers explicitly in the Jenkins agent's /etc/resolv.conf or set the DNS in Docker if using containers: echo 'nameserver 8.8.8.8' >> /etc/resolv.conf** (90% success)
   ```
   Configure DNS servers explicitly in the Jenkins agent's /etc/resolv.conf or set the DNS in Docker if using containers: echo 'nameserver 8.8.8.8' >> /etc/resolv.conf
   ```
2. **If behind a proxy, set the proxy environment variables in the Jenkins node configuration: export http_proxy=http://proxy:8080; export https_proxy=http://proxy:8080** (80% success)
   ```
   If behind a proxy, set the proxy environment variables in the Jenkins node configuration: export http_proxy=http://proxy:8080; export https_proxy=http://proxy:8080
   ```

## Dead Ends

- **** — Restarting Jenkins only restarts the master; it doesn't fix DNS resolution in build agents unless they are restarted separately. (50% fail)
- **** — Pinging github.com from the master doesn't guarantee the agent can resolve it; agents may have different DNS settings. (60% fail)
