# Troubleshooting If your IIPImage installation does not work, verify each component in turn. Most problems are found in the first three steps. ## 1. Is the server running? Point a browser at the server on the machine where it is installed: ```text http://localhost/fcgi-bin/iipsrv.fcgi ``` You should see a page showing the server version number. Replace `localhost` with the server name when testing remotely. If you are using the Docker image, check that the container is running and inspect its output with `docker ps` and `docker logs`. If the version page is not served, check your web server error log and test with a trivial FastCGI program to confirm that the FCGI handler is configured correctly. With a native systemd service, `systemctl status iipsrv` and `journalctl -u iipsrv -f` show whether the process started and why it exited. ## 2. Check the server log If the server is running but requests fail, look at the iipsrv log. By default this is `/tmp/iipsrv.log`, or wherever the `LOGFILE` startup variable points; setting it to `syslog` sends messages to the system logger. If there is not enough detail, increase `VERBOSITY` in the server configuration and restart — see [Startup variables](). Errors about being unable to read an image almost always mean a path or permission problem (step 3); other errors usually indicate a malformed request or an unsupported image encoding. ## 3. Can the server read the image? Paths supplied to iipsrv (`FIF=` for IIP requests, the identifier in IIIF requests) must be **absolute paths on the server machine**, not paths relative to the web root or to the client's machine. Check that: - the path is correct and uses forward slashes, including on Windows; - the iipsrv process owner has read access to the image and to every directory in its path; - `FILESYSTEM_PREFIX` and `FILESYSTEM_SUFFIX` are not unexpectedly rewriting the path you supplied. The image does not need to be writable, and it does not need to be inside the web server's document root. It can live anywhere on the filesystem (including an NFS or Samba mount) as long as the iipsrv process can read it. ## 4. Is the image encoded correctly? If the server can read the image but returns errors, check that it is **tiled and stored as a multi-resolution pyramid**. Use `tiffinfo yourimage.tif` (or `vipsheader -a yourimage.tif`) to inspect it: the output should list the different resolutions and the tile sizes at each level. [Images]() shows how to generate suitable files with [VIPS](https://www.libvips.org/) or ImageMagick. JPEG2000 images should be encoded using resolution-based progression (RPCL), 256×256 precincts and PLT/TLM markers for fast random access. Plain JPEG input is supported from iipsrv 1.3 but is much slower to decode, so it is not recommended for large images. ## 5. Test a request directly Bypass the viewer and request an image in the browser address bar. For the IIP protocol: ```text http://localhost/fcgi-bin/iipsrv.fcgi?FIF=/path/myimage.tif&WID=200&CVT=jpeg ``` `CVT` must be the last parameter. This should return a 200-pixel-wide JPEG. The equivalent IIIF request is: ```text http://localhost/fcgi-bin/iipsrv.fcgi?IIIF=myimage.tif/full/200,/0/default.jpg ``` If you use clean URLs such as `/iiif/myimage.tif/...`, verify the web server rewrite rules or `URI_MAP`/`BASE_URL` settings described in [Clean URLs]() — the direct query form above will confirm whether the problem is the server or the rewriting. ## 6. If the server works but the viewer does not Open your browser's developer tools (F12), then check: - **Console** for JavaScript errors — for example, a missing viewer library file. - **Network** tab for failed tile requests, their HTTP status codes and the exact URLs being requested. - **CORS**: if tiles are served from a different origin, the response needs an `Access-Control-Allow-Origin` header. Set the `CORS` startup variable on iipsrv or add the header in your web server/proxy. - **Mixed content**: an HTTPS page cannot load tiles over HTTP. Serve both over HTTPS or use protocol-relative/HTTPS URLs. - **Viewer configuration**: the server URL and the image path must match what you tested in step 5 — the image path is the path on the *server*, not the path in the web page. ## 7. Performance problems If images display but loading is slow: - use tiled pyramid TIFF with JPEG or WebP tile compression and enable `CODEC_PASSTHROUGH` (iipsrv 1.3, on by default) so matching tiles are sent without re-encoding; - tune `MAX_IMAGE_CACHE_SIZE` and `OMP_NUM_THREADS` for your server's memory and CPU; - avoid progressive JPEG input and JPEG2000 without PLT/TLM markers; - check the `QLT`/quality settings if files are much larger than expected. ## Still stuck? Include the iipsrv version, the exact request URL, the relevant log output and a description of your platform when asking for help via the [contact page]() or the project's GitHub issue tracker.