Title: Fatal error while using any WP CLI command
Last modified: July 13, 2025

---

# Fatal error while using any WP CLI command

 *  Resolved [sergeybv](https://wordpress.org/support/users/sergeybv/)
 * (@sergeybv)
 * [10 months, 3 weeks ago](https://wordpress.org/support/topic/fatal-error-while-using-any-wp-cli-command/)
 * I found a critical bug while using wp cli commands: when the plugin is active,
   it breaks the execution of any WP-CLI command.
   The error message is:
 * `Fatal error: Uncaught Error: Undefined constant "FS_CHMOD_FILE" in /var/www/
   html/wp-content/plugins/fastcgi-cache-purge-and-preload-nginx/includes/wp-filesystem.
   php:95`
 * When I run the same commands with `--skip-plugins=fastcgi-cache-purge-and-preload-
   nginx`, they works fine.
    -  This topic was modified 10 months, 3 weeks ago by [sergeybv](https://wordpress.org/support/users/sergeybv/).

Viewing 2 replies - 1 through 2 (of 2 total)

 *  Plugin Author [Hasan CALISIR](https://wordpress.org/support/users/psauxit/)
 * (@psauxit)
 * [10 months, 3 weeks ago](https://wordpress.org/support/topic/fatal-error-while-using-any-wp-cli-command/#post-18556437)
 * Hello [@sergeybv](https://wordpress.org/support/users/sergeybv/)
 * Thank you! The fix is available [here](https://github.com/psaux-it/nginx-fastcgi-cache-purge-and-preload/commit/17fbbaf41ecf10f76f9be506e3553604dd0bc402).
   You can either apply it manually now or wait for version v2.1.4
 * Please let me know if it’s fixed.
 * Best~Hasan
 *  Plugin Author [Hasan CALISIR](https://wordpress.org/support/users/psauxit/)
 * (@psauxit)
 * [7 months, 4 weeks ago](https://wordpress.org/support/topic/fatal-error-while-using-any-wp-cli-command/#post-18670115)
 * [@sergeybv](https://wordpress.org/support/users/sergeybv/)
 * v2.1.4 is out now. Please let me know if the issue resolved for you.
 * Best.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘Fatal error while using any WP CLI command’ is closed to new replies.

 * ![](https://ps.w.org/fastcgi-cache-purge-and-preload-nginx/assets/icon-256x256.
   png?rev=3245366)
 * [Nginx Cache Purge Preload](https://wordpress.org/plugins/fastcgi-cache-purge-and-preload-nginx/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/fastcgi-cache-purge-and-preload-nginx/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/fastcgi-cache-purge-and-preload-nginx/)
 * [Active Topics](https://wordpress.org/support/plugin/fastcgi-cache-purge-and-preload-nginx/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/fastcgi-cache-purge-and-preload-nginx/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/fastcgi-cache-purge-and-preload-nginx/reviews/)

 * 2 replies
 * 2 participants
 * Last reply from: [Hasan CALISIR](https://wordpress.org/support/users/psauxit/)
 * Last activity: [7 months, 4 weeks ago](https://wordpress.org/support/topic/fatal-error-while-using-any-wp-cli-command/#post-18670115)
 * Status: resolved