SSSD LDAP / Active Directory Integration Debugging Prompt
Systematically debug SSSD-backed LDAP or Active Directory authentication and identity lookups — failed logins, missing groups, cache staleness, and GPO/access-control surprises — instead of randomly bumping debug_level.
- Target user
- Linux admins integrating hosts with central LDAP/AD directories
- Difficulty
- Intermediate
- Tools
- Claude, ChatGPT
The prompt
You are an identity-management engineer who has joined hundreds of Linux hosts to LDAP and Active Directory and can tell a Kerberos failure from a name-service failure by the symptom alone. I will provide: - `/etc/sssd/sssd.conf` (secrets redacted) and which provider (ad, ldap, ipa) - The exact failure: `id user` empty, `getent passwd` works but login fails, groups missing, or intermittent timeouts - `nsswitch.conf` and the relevant PAM stack - Realm/domain, DNS setup, and time-sync status Diagnose in this order — do not skip layers: 1. **Split identity vs auth** — `getent passwd user` and `id user` test the NSS/identity path; `su - user` or `kinit user` tests the auth path. Establish which is broken before touching config; the fixes are completely different. 2. **DNS + time first** — AD is brutally sensitive to both. Verify SRV records (`_ldap._tcp`, `_kerberos._tcp`), that the host resolves its own FQDN, and that clock skew is under five minutes (Kerberos will silently fail otherwise). 3. **Cache layer** — distinguish a config bug from a stale cache. Show `sssctl` commands to inspect/expire entries and when to stop the service and clear `/var/lib/sss/db/*` (and why doing that casually masks the real problem). 4. **Targeted logging** — set `debug_level` per-section (domain vs nss vs pam), reproduce once, then read the logs with `sssctl logs-fetch` / journal; point to the specific lines that show the bind, search base, or filter that failed. 5. **Search base & filters** — verify `ldap_search_base`, `ldap_user_object_class`, group resolution mode (RFC2307 vs RFC2307bis vs AD), and why a wrong objectClass yields empty `id` output. 6. **Access control** — `access_provider`, `ad_access_filter`, simple allow/deny lists; explain why a user can authenticate yet still be denied login. 7. **Verify the fix** — clear cache, restart, re-run the exact failing command, and confirm with a fresh login. For each step give the exact command, the healthy vs broken output, and the one config key most likely at fault. End with root cause, the minimal config diff, and a one-line verification. Bias toward: isolating identity-vs-auth early, never blindly wiping the cache, and provider-correct objectClass/filters.
Run this prompt with AI
Test it, get an AI-improved version, or compare models — live in the Prompt Workspace. No copy-paste.
Related prompts
-
nsswitch.conf Name Resolution Order Audit Prompt
Audit /etc/nsswitch.conf to explain why a user, group, hostname, or netgroup resolves (or fails to resolve) the way it does — across files, sss, ldap, systemd, and dns sources — and fix surprising precedence or NSS lookup hangs.
-
Linux PAM Authentication Debugging Prompt
Diagnose Linux login failures — PAM stack misconfiguration, lockouts (`faillock`/`pam_tally2`), sssd/LDAP join issues, missing modules, password policy rejection.
-
Linux bcache SSD Caching Setup Prompt
Design a bcache SSD-in-front-of-HDD caching tier with the right cache mode, write policy, and sequential-bypass tuning, and plan the attach/detach and failure behavior so a cache device loss never means data loss.
-
Linux fapolicyd Application Allowlisting Prompt
Design, test, and roll out fapolicyd application allowlisting so only trusted binaries and scripts execute, without locking yourself out or breaking legitimate app updates, package installs, and interpreters.
More Linux Admins prompts & error guides
Browse every Linux Admins prompt and troubleshooting guide in one place.
Reading prompts? Get all 500 in one free PDF
500 battle-tested, copy-paste AI prompts engineered by a senior systems engineer — every one with fill-in placeholders and safety/back-out notes. Drop your email and it's yours.
- 500 prompts: Linux · Kubernetes · Terraform · OpenStack · GitLab · Docker · Monitoring · Incident Response
- Instant PDF download — yours free, forever
- Plus one practical AI-workflow email a week (no spam)
Single opt-in · unsubscribe anytime · no spam.