For some operations such as database export, WP-CLI uses PHP exec() function which is disabled on most shared hosting servers.
So if you do wp db export and no file was created, make sure to check your error_log file and if you notice this error:
PHP Fatal Error: Uncaught Error: Call to undefined function exec()
To fix this you need to enable the exec extension if possible. For cPanel enable the exec extension in PHP Selector
or if you have WHM access (VPS or Dedicated server) then you can also edit the php.ini file directly.
Was this post helpful?
Let me know if you liked the post. That’s the only way I can improve. 🙂