<!-- fivemad.com, Markdown source of https://fivemad.com/docs/server-setup/common-errors -->
> Source: https://fivemad.com/docs/server-setup/common-errors
> Section: Server setup
> Tags: errors, troubleshooting, license key, couldn't find resource, oversized assets, pure mode, game build, escrow
> Last updated: 2026-09-22
> Site map for assistants: https://fivemad.com/llms.txt

# Common server errors and fixes

Fixes for the errors every FiveM server owner hits: license key, resources that won't load, server not in list, game build and pure mode, oversized assets, escrow and SQL.

Start every diagnosis in the same place: the **server console** (txAdmin > Live Console) for server errors, and the **F8 console** in the game for client errors. Scroll up to the **first** red line. Later errors are often just a result of the first one.

The messages below are paraphrased where their exact wording changes between builds. Search the console for the key words.

## License key problems

**Symptoms:** the server stops right after starting and mentions the license key, "invalid", "failed to verify" or a missing `sv_licenseKey`.

- Check the key is on its own line: `sv_licenseKey "cfxk_..."` with no extra spaces or quotes inside.
- Make sure it is not commented out and that no later `exec`'d file overrides it with an old key.
- Each server needs its **own** key. Two servers with one key fight each other.
- If you pasted the key into a public place, it may have been abused. **Regenerate** it on [portal.cfx.re](https://portal.cfx.re) and update your config.
- On a VPS, a system clock that is far off can break verification. The txAdmin team has a short video on syncing the Windows VPS clock, linked in the [video archive](/docs/videos).

## "Couldn't find resource" / "Couldn't start resource"

**Symptoms:** `Couldn't find resource myresource.` or a failed start for a resource you just added.

1. **Folder name.** `ensure` uses the folder name. `ensure my-car` does not find `My-Car` on Linux (case sensitive) and does not find `my-car-main` (GitHub zip downloads add `-main` or `-master`, rename the folder).
2. **Nested folder.** Unzipping often gives `resources/[local]/mycar/mycar/fxmanifest.lua`. The manifest must be directly inside the folder you ensure.
3. **No manifest.** The folder needs `fxmanifest.lua` (or the ancient `__resource.lua`). Generate a correct one with the [fxmanifest Generator](/tools/fxmanifest-generator).
4. **Wrong working directory.** Starting FXServer from the wrong folder (vanilla setups) means it can't see `resources` at all. Start it from your server data folder.
5. **Not refreshed.** Added the folder while the server runs? Type `refresh`, then `ensure name`.

## Manifest and script errors

**Symptoms:** `Couldn't load resource x` followed by a Lua error in `fxmanifest.lua`, or `SCRIPT ERROR: @resource/file.lua:12: ...`.

- A syntax error in the manifest (missing quote or comma in a `{ }` list) stops the whole resource. The error names the line.
- `SCRIPT ERROR` lines show `@resource/path:line`. Open that file at that line. Common ones:
  - `attempt to index a nil value (global 'QBCore')`: the framework object was never fetched, or the framework started after this resource. Fix `ensure` order.
  - `attempt to call a nil value (field 'xyz')`: calling an export or function that doesn't exist (wrong resource name, wrong version).
  - `No such export xyz in resource abc`: the resource isn't started, has another name, or doesn't export that function in your version.
- `Could not find dependency x for resource y`: install and `ensure` the dependency first.

More on reading errors in [Debugging](/docs/development/debugging).

## Server not in the server list

1. Test direct connect: `connect IP:30120` in F8. If it fails, it's ports or firewall, see [Ports and networking](/docs/server-setup/ports-and-networking).
2. Remove or comment out `sv_master1 ""`.
3. Set `sets sv_projectName` and `sets sv_projectDesc`.
4. Wait up to 8 minutes after start.
5. Check the IP isn't blocked with the [Cfx Blacklist Checker](/tools/cfx-blacklist-checker).
6. Check what your server reports with the [Server Status Checker](/tools/server-status-checker).

## Players get stuck while connecting

| Where it hangs | Usual cause |
| --- | --- |
| "Handshaking with server" | UDP 30120 blocked, or the server is under heavy load at start. |
| "Downloading assets" for ages | Huge streamed packs. Shrink textures with the [YTD Optimizer](/tools/ytd-optimizer), remove unused packs, consider a file server. |
| Loading screen never ends | A loadscreen with `loadscreen_manual_shutdown 'yes'` that never calls `ShutdownLoadingScreenNui()`, or a framework spawn script erroring. Check F8. |
| Kicked with a timeout after joining | A client script erroring in a loop, or a resource sending huge events. Check F8 and the server console. |

## Game build mismatch

**Symptoms:** players are told they need to download game data or a different build, or DLC vehicles and clothes don't appear.

- `sv_enforceGameBuild` must be set at startup, in `server.cfg`, and requires a restart to change.
- A build number that your artifact doesn't know yet does nothing. Update the artifact first.
- DLC content (vehicles, clothes) from a newer build than the one you enforce won't spawn. Check the build in [server.cfg explained](/docs/server-setup/server-cfg#sv_enforcegamebuild).
- Some old MLOs and clothing packs break on newer builds because Rockstar changed the base files. Look for an updated version from the author.

## Pure mode kicks

**Symptoms:** players are refused because of modified game files.

`sv_pureLevel 1` allows audio mods and known graphics mods, `sv_pureLevel 2` blocks everything modified. If legitimate players with graphics mods can't join, lower it to 1 or remove it. On FiveM for GTA V Enhanced, pure mode is always on and can't be disabled.

## Oversized assets and texture loss

**Symptoms:** a console warning that an asset "uses XX MiB of physical memory" and that oversized assets can lead to streaming issues. In game: blurry or missing textures, the city not loading when you drive fast, invisible cars.

- Usually a `.ytd` with 4K textures in a car or clothing pack.
- Resize textures to 2048 or 1024, use DXT compression, generate mipmaps. The [YTD Optimizer](/tools/ytd-optimizer) does this for many files at once.
- Check a whole vehicle resource for broken references with the [Vehicle Pack Validator](/tools/vehicle-pack-validator).
- Remove packs nobody uses. Every streamed MB costs every player memory.

## Escrow errors

**Symptoms:** "Failed to verify protected resource" or an escrowed resource refusing to start.

- The resource was bought on a **different Cfx.re account** than the one that owns the server's license key. Escrowed assets are tied to the buying account.
- Re-download it from the Cfx.re Portal. Files changed or re-zipped by hand (for example opened and saved in an editor) fail verification. Only edit the files the creator left open (usually `config.lua`).
- Too old an artifact: escrow needs a reasonably recent build.
- Some escrowed resources need a minimum game build or OneSync.

## Database errors

See the table at the end of [Database setup](/docs/server-setup/database#common-database-errors). The top three: MariaDB not running, wrong password in `mysql_connection_string`, forgot to import the resource's `.sql`.

## Port already in use

**Symptoms:** FXServer can't bind to `0.0.0.0:30120`, or txAdmin can't use 40120.

Another FXServer (or an old one that didn't close) is running. Close it (Task Manager on Windows, `pkill -f FXServer` or `systemctl stop` on Linux) or use different ports for the second server.

## txAdmin says the server is not responding

- A resource is blocking the main thread (an infinite loop without `Wait`, a slow synchronous query). txAdmin's **hang detection** restarts it. Find the culprit with the profiler: see [Threads and performance](/docs/development/threads-performance) and the [Profiler Analyzer](/tools/profiler-analyzer).
- Server hitches in the console (`server thread hitch warning: timer interval of X milliseconds`) mean the same thing on a smaller scale.

## Still stuck?

Post on [forum.cfx.re](https://forum.cfx.re) (Server Discussion) or the relevant framework Discord with:

- the first red error, copied as text,
- your artifact build and game build,
- what you changed last,
- your `server.cfg` without the license key and passwords.
