Back to Article List

CrowdSec troubleshooting: Common errors and fixes

CrowdSec troubleshooting: Common errors and fixes

Updated 22 October 2026

This is the reference I wish I'd had during my first year of running CrowdSec on client servers: every failure mode I keep meeting, with the exact error string and the shortest fix that works.

Please note it's written against Security Engine 1.7.x, and where a version matters I say so.

SymptomWhere it showsLikely causeFirst command
API error: access forbiddenbouncer logAPI key invalid or missingcscli bouncers list
connect: connection refusedbouncer logLAPI down or listening elsewherecscli lapi status
CrowdSec Access Forbidden pagebrowseractive decision on your IPcscli decisions list -i YOUR_IP
Nothing gets blockedattacks continueempty firewall set or dead registrationcscli metrics show bouncers
No alerts, evercscli alerts list emptyacquisition reads zero linescscli metrics show acquisition
Community blocklist missingonly local decisions existCAPI credentials or rate limitcscli capi status
IPv6 attackers not bannednftables or ip6tablesv6 set absent or disablednft list table ip6 crowdsec6
Console shows nothingapp.crowdsec.netengine not enrolledcscli console status

API error: Access forbidden

The bouncer logs level=error msg="API error: access forbidden" and enforcement silently stops while everything else looks healthy. The API key the Remediation Component (bouncer, in everyday speech) sends doesn't match any registered identity on LAPI, most often because a package upgrade replaced the config file. Fix by deleting the registration under the name cscli bouncers list shows (the packages use cs-firewall-bouncer- plus a timestamp) and regenerating under a fresh name:

sudo cscli bouncers list
sudo cscli bouncers delete cs-firewall-bouncer-1792659514
sudo cscli bouncers add firewall-bouncer-new

Paste the printed key into /etc/crowdsec/bouncers/crowdsec-firewall-bouncer.yaml and restart the service. There's a related string, API error: access forbidden from this IP (x.x.x.x), that hits cscli admin commands when LAPI is bound to a non-localhost address; that one is solved by api.server.trusted_ips in config.yaml rather than any key. Both variants, including the Docker and Kubernetes angles, get full treatment in my guide to the CrowdSec access forbidden 403.

Connection refused on 127.0.0.1:8080

The bouncer log shows Get "http://127.0.0.1:8080/v1/decisions/stream...": dial tcp 127.0.0.1:8080: connect: connection refused, as reported in crowdsec issue 3729. Nobody is listening where the bouncer is calling. Either the crowdsec service is down, listen_uri points somewhere else or, in containers, api_url targets the container's own loopback instead of the LAPI service name. Diagnose in two commands:

sudo systemctl status crowdsec
sudo ss -tlnp | grep 8080

Firewall bouncer log with dial tcp 127.0.0.1:8080 connect connection refused while the CrowdSec service is stopped

The bouncer keeps calling 127.0.0.1:8080 and nobody answers.

cscli lapi status fails with the same connection refused while the engine is down, so it works as a third check from the same terminal. A few of these lines right after a normal systemctl restart crowdsec are harmless: the bouncer polls every ten seconds and the engine needs a moment to bind the port again.

cscli lapi status failing to authenticate to the Local API with connect connection refused on 127.0.0.1:8080

cscli lapi status fails the same way while the engine is down.

If crowdsec is up and the port is bound to another address, align api_url in the bouncer config with reality. On Compose stacks the value should read http://crowdsec:8080 or whatever you named the container; my CrowdSec Docker Compose guide shows the working layout.

CrowdSec Access Forbidden page in the browser

A visitor sees "CrowdSec Access Forbidden. You are unable to visit the website." instead of your site. This is the opposite of a malfunction: a bouncer found an active decision against that IP and served the ban template. When the visitor is you, list what LAPI holds against your address and note the origin column, because a ban from a local scenario, the community blocklist or a subscribed list each needs a different cure:

sudo cscli decisions list -i YOUR_IP
sudo cscli decisions delete -i YOUR_IP

The full recovery path, including what to do when the firewall bouncer has taken SSH down with it, is in fixing the CrowdSec Access Forbidden page.

Bouncer runs but nothing gets blocked

The service is active, the log is quiet and attackers keep hammering. Check what the firewall actually holds:

sudo nft list table ip crowdsec | head -n 20
sudo cscli metrics show bouncers

That first line is for the nftables bouncer, which LumaDock's nginx + CrowdSec template ships; there ipset isn't installed at all. It keeps one set per decision origin, crowdsec-blacklists-CAPI, crowdsec-blacklists-crowdsec and crowdsec-blacklists-cscli. The iptables bouncer uses ipsets named crowdsec-blacklists-0, -1 and so on, and sudo ipset list -n shows which exist.

Empty sets (or zero active_decisions in the metrics) while the bouncer runs means the registration or the decision stream is broken, a case documented in a solved Discourse thread. Confirm with cscli bouncers list that the component is valid and pulled recently, and confirm with cscli decisions list that there's anything to enforce at all. One more trap for people testing from home: since 1.6.3 the crowdsecurity/whitelists parser ships by default and whitelists private RFC1918 ranges, so hammering your server from the LAN will never produce a ban. Test from a public address, or read my firewall bouncer guide for a proper verification routine.

ent: bouncer not found

The log pairs while fetching bouncer info: ent: bouncer not found with Http error 403 while talking to LAPI. The key is syntactically fine but the bouncer identity it belongs to no longer exists in the database, which shows up after someone runs cscli bouncers delete, after database restores and chronically in Kubernetes when replicas scale and share a deleted identity. Re-register with cscli bouncers add, give each replica its own name and the 403s end.

IPSET hash is full

The firewall bouncer logs IPSET Hash is full, cannot add more elements and new bans silently fail to land. Your decision count, usually inflated by blocklist subscriptions, has outgrown the set's capacity. Add ipset_size to the bouncer yaml and restart. The packaged file doesn't carry the key (bouncer 0.0.34 on Ubuntu 24.04 didn't), so there's nothing to edit until you add it; the default is 131072 entries since v0.0.28:

ipset_size: 262144

In ipset set-only mode the sets are yours, so recreate them with a bigger maxelem instead. The behavior and the fix are discussed in cs-firewall-bouncer issue 368.

Allowlist entries not applying to existing bans

You allowlisted an address and it stays banned. Allowlists drop new alerts and strip incoming blocklist IPs before database insertion; they don't purge decisions that already exist. So a decision created before your allowlist entry lives on until it expires or you remove it:

sudo cscli allowlists check 198.51.100.7
sudo cscli decisions delete -i 198.51.100.7

If check says the value isn't covered, remember that allowlists match IPs and ranges only, and an entry for a single address won't cover the /24 around it. The allowlist also guards the other direction: once an address is on it, cscli decisions add refuses to ban it unless you pass --bypass-allowlist.

No alerts from any scenario

Days of uptime, zero alerts, and you know the internet has been knocking. Detection starts at acquisition, so measure that first:

sudo cscli metrics show acquisition

cscli metrics show acquisition with lines read, parsed and unparsed per log file, auth.log at 462 read and 47 parsed

Acquisition first: lines read and parsed per source. Zero read means the engine is watching the wrong place.

Zero lines read means CrowdSec is watching the wrong places. The usual causes sort into four buckets: the log file path in /etc/crowdsec/acquis.yaml (or acquis.d/) doesn't exist on this distro, the service logs to journald while acquisition expects a file, the app runs in Docker so its logs live under the container runtime rather than /var/log or the file exists and lines are read but a missing parser leaves them all unparsed. For journald sources, point acquisition at the unit instead of a path:

source: journalctl
journalctl_filter:
  - _SYSTEMD_UNIT=ssh.service
labels:
  type: syslog

Lines read but nothing parsed points at a missing collection for that service. Distro defaults differ more than people expect (Debian in particular ships thinner logging than Ubuntu), which is why my CrowdSec on Debian install guide spends half its length on acquisition.

Community blocklist not pulling and CAPI rate limits

Local detection works while community bans never arrive. Start with:

sudo cscli capi status

Credential errors point at /etc/crowdsec/online_api_credentials.yaml, fixable by re-registering the engine with the Central API. If credentials check out and pulls still fail, you may be rate limited: CrowdSec introduced CAPI rate limiting in December 2025, and engines stuck in restart loops, retrying aggressively or sharing one set of credentials across machines can be temporarily banned from CAPI for several hours. Normal deployments never hit it. The tell is a healthy engine whose CAPI calls suddenly fail for hours while journalctl -u crowdsec shows a crash or restart pattern beforehand. Fix the loop, stop cloning credentials between servers and the ban lifts on its own.

IPv6 attackers not banned

IPv4 bans land while v6 attackers walk straight through. The firewall bouncer keeps IPv6 in a table and sets of its own, and they're the ones people forget to check. With the nftables bouncer, the IPv6 bans sit in the crowdsec6 table:

sudo nft list table ip6 crowdsec6

nft list table ip6 crowdsec6 showing the crowdsec6-blacklists-CAPI set and the input chain rule that drops it

With the nftables bouncer the IPv6 bans live in the crowdsec6 table, one set per origin.

With the iptables bouncer, look for the v6 ipsets and the jump rule. The rule's target is CROWDSEC_CHAIN in capitals, so a case-sensitive grep finds nothing:

sudo ipset list -n | grep crowdsec6
sudo ip6tables -L INPUT -n | grep -i crowdsec

An absent table, set or rule usually traces to disable_ipv6: true left in the bouncer config, or to set-only mode where nobody created the v6 set. Appliance users have their own variant of this; see CrowdSec troubleshooting on OPNsense if your engine lives on the firewall.

Machine not validated

A remote Log Processor registers against a central LAPI and then can't push alerts. Registration via cscli lapi register creates the machine in a pending state, and someone has to approve it on the LAPI side:

sudo cscli machines list
sudo cscli machines validate MACHINE_NAME

The validated column tells you instantly which machine is stuck. On single-server installs you'll rarely meet this, since the local machine validates during setup.

Hub errors and tainted collections after upgrade

After an engine upgrade, scenarios misbehave or cscli complains about hub items. Refresh and upgrade the hub in one line:

sudo cscli hub update && sudo cscli hub upgrade

Then run cscli hub list and look for items marked tainted, which means locally edited; the hub refuses to overwrite your changes, so those items stay frozen at old versions forever. The clean pattern is to copy the hub file into a local item under /etc/crowdsec/parsers/ or /etc/crowdsec/scenarios/, customize the copy and let the original upgrade normally. I've inherited servers where a parser tainted in 2023 was still parsing 2026 traffic, badly.

Metrics missing from the console

The engine works locally while app.crowdsec.net shows it offline or empty. Check enrollment state and the export flags:

sudo cscli console status
sudo cscli console enroll YOUR_ENROLL_KEY

Enrollment needs accepting in the console UI after the command runs, which is the step everyone misses. Also worth a glance: disable_usage_metrics_export in config.yaml, which does exactly what it says and occasionally survives from someone's old hardening template.

Your idea deserves better hosting

24/7 support 30-day money-back guaranteeRefund covers the VPS plan on your first order. Cancel anytime
Abonament

VPS.S1

$5.99 Save  17 %
$4.99 Lunar
  • 2 vCPU AMD EPYC
  • 2 GB RAMMEMORIE
  • 30 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse

VPS.S3

$14.99 Save  33 %
$9.99 Lunar
  • 4 vCPU AMD EPYC
  • 6 GB RAMMEMORIE
  • 70 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse

VPS.S4

$19.99 Save  20 %
$15.99 Lunar
  • 6 vCPU AMD EPYC
  • 8 GB RAMMEMORIE
  • 80 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse

EPYC VPS.P1

$8.99 Save  22 %
$6.99 Lunar
  • 2 vCPU AMD EPYC
  • 4 GB RAMMEMORIE
  • 40 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse
  • Backup automat gratuitInclude un spațiu de backup pe care îl poți configura pentru rulare zilnică, săptămânală sau lunară.

EPYC VPS.P2

$16.99 Save  24 %
$12.99 Lunar
  • 2 vCPU AMD EPYC
  • 8 GB RAMMEMORIE
  • 80 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse
  • Backup automat gratuitInclude un spațiu de backup pe care îl poți configura pentru rulare zilnică, săptămânală sau lunară.

EPYC VPS.P4

$29.99 Save  23 %
$22.99 Lunar
  • 4 vCPU AMD EPYC
  • 16 GB RAMMEMORIE
  • 160 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse
  • Backup automat gratuitInclude un spațiu de backup pe care îl poți configura pentru rulare zilnică, săptămânală sau lunară.

EPYC VPS.P5

$39.99 Save  25 %
$29.99 Lunar
  • 8 vCPU AMD EPYC
  • 16 GB RAMMEMORIE
  • 180 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse
  • Backup automat gratuitInclude un spațiu de backup pe care îl poți configura pentru rulare zilnică, săptămânală sau lunară.

EPYC VPS.P6

$59.99 Save  25 %
$44.99 Lunar
  • 8 vCPU AMD EPYC
  • 32 GB RAMMEMORIE
  • 200 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse
  • Backup automat gratuitInclude un spațiu de backup pe care îl poți configura pentru rulare zilnică, săptămânală sau lunară.

EPYC VPS.P7

$69.99 Save  29 %
$49.99 Lunar
  • 16 vCPU AMD EPYC
  • 32 GB RAMMEMORIE
  • 240 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse
  • Backup automat gratuitInclude un spațiu de backup pe care îl poți configura pentru rulare zilnică, săptămânală sau lunară.

Genoa VPS.G2

$24.99 Save  20 %
$19.99 Lunar
  • 2 vCPUAMD EPYC Genoa generația a 4-a 9xx4 cu 3,25 GHz sau similar, pe arhitectura Zen 4. AMD EPYC G4
  • 4 GB DDR5MEMORIE
  • 50 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse
  • Backup automat gratuitInclude un spațiu de backup pe care îl poți configura pentru rulare zilnică, săptămânală sau lunară.

Genoa VPS.G4

$44.99 Save  22 %
$34.99 Lunar
  • 4 vCPUProcesor AMD EPYC cu nuclee vCPU dedicate, pe hardware de server pentru companii. AMD EPYC G4
  • 8 GB DDR5MEMORIE
  • 100 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse
  • Backup automat gratuitInclude un spațiu de backup pe care îl poți configura pentru rulare zilnică, săptămânală sau lunară.

Genoa VPS.G6

$89.99 Save  22 %
$69.99 Lunar
  • 8 vCPUProcesor AMD EPYC cu nuclee vCPU dedicate, pe hardware de server pentru companii. AMD EPYC G4
  • 16 GB DDR5MEMORIE
  • 200 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse
  • Backup automat gratuitInclude un spațiu de backup pe care îl poți configura pentru rulare zilnică, săptămânală sau lunară.

Genoa VPS.G7

$159.99 Save  22 %
$124.99 Lunar
  • 8 vCPUProcesor AMD EPYC cu nuclee vCPU dedicate, pe hardware de server pentru companii. AMD EPYC G4
  • 32 GB DDR5MEMORIE
  • 250 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos. incluse
  • Backup automat gratuitInclude un spațiu de backup pe care îl poți configura pentru rulare zilnică, săptămânală sau lunară.

AMD Ryzen VPS.R1

$16.99 Save  18 %
$13.99 Lunar
  • 1 CPU dedicat AMD Ryzen 9 7950X cu 4,5 GHz sau similar, pe arhitectura Zen 4. vCPU
  • 4 GB DDR5MEMORIE
  • 50 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6 incluse Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos.
  • Backup automat inclus

AMD Ryzen VPS.R2

$29.99 Save  17 %
$24.99 Lunar
  • 2 CPU dedicate AMD Ryzen 9 7950X cu 4,5 GHz sau similar, pe arhitectura Zen 4. vCPU
  • 8 GB DDR5MEMORIE
  • 100 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6 incluse Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos.
  • Backup automat inclus

AMD Ryzen VPS.R4

$109.99 Save  18 %
$89.99 Lunar
  • 8 CPU dedicate AMD Ryzen 9 7950X cu 4,5 GHz sau similar, pe arhitectura Zen 4. vCPU
  • 32 GB DDR5MEMORIE
  • 400 GB NVMeSTOCARE
  • Trafic nelimitat
  • IPv4 & IPv6 incluse Suportul IPv6 este momentan indisponibil în Franța, Finlanda sau Țările de Jos.
  • Backup automat inclus

*VAT excluded.

INCLUDED WITH EVERY PLAN

✓ No setup fees ✓1 Gbps network
✓ Full root access on KVM ✓ Free server monitoring ✓ Firewall management ✓24/7 support

CrowdSec triage order: logs, metrics, decisions, bouncers

When a box misbehaves and no error string jumps out, I run the same four checks in the same order every time. Logs first, journalctl -u crowdsec and /var/log/crowdsec.log, because fatal errors live there and everything downstream is noise if the engine is crash-looping. Metrics second, cscli metrics, because the acquisition and parser tables tell you in ten seconds where the pipeline goes quiet. Decisions third, cscli decisions list, to learn what the system currently intends to block. Bouncers last, cscli bouncers list, to confirm someone is actually enforcing those intentions. Detection problems surface in the first two steps and enforcement problems in the last two, and knowing which half you're in cuts most debugging sessions in half.

If you're setting up fresh rather than firefighting, most of this page becomes irrelevant: LumaDock's Ubuntu 24.04 + CrowdSec one-click template deploys the engine and bouncer pre-wired at order time, in seconds.

And before you attach enforcement to anything that matters, read my rollout order for avoiding lockouts, because half the errors on this page are cheaper to prevent than to fix.

Questions?

How do I test what a parser does with a single log line?

Use cscli explain with a sample: cscli explain --log "your log line" --type nginx walks the line through every parser stage and shows exactly where it matches or falls out. It's the fastest way to settle "is my parser broken or my log format weird" without staring at debug output.

Ellie Grace Hayes
About the author

Ellie Grace Hayes

I grew up in Minnesota and started working remotely before I decided that travelling was going to become a permanent part of my life. And it kinda did, more or less... I tend to stay somewhere for a month or two, sometimes longer if I like the place (so "digital nomad" is technically accurate, even if most days are much less exciting than the term suggests). Usually I'm at a desk in a rented room trying to work out why a command behaved differently on two supposedly identical machines :)

I came into technical writing through support work & community tutorials. Linux was the first subject I wrote about, but since then I've wandered into containers, hosting, networking plus a lot of self-hosted software. I've played Minecraft since I was a kid and still go through phases where I get completely absorbed in it for a few weeks. I don't have a five-year plan. I've tried - it keeps becoming a six-month plan instead.

Deploy your next project in seconds

Bring your winning ideas online faster, with modern hardware and unmetered bandwidth. Join a European cloud trusted by thousands of developers and businesses worldwide.