Loading...


Related Products


Date Published: July 11, 2025

Errno 13: Permission Denied

Issue

If you encounter Errno 13: Permission Denied, this typically indicates a missing executable permission on the file or script.

For Example:

$ drush @mysitegroup.dev

status Warning: pcntl_exec(): Error has occurred: (errno 13) Permission denied in /usr/local/drush8/vendor/drush/drush/includes/startup.inc on line 422 
Error has occurred executing the Drush script found at /mnt/www/html/mysitegroupdev/vendor/bin/drush 
(errno 13) Permission denied

This error tends to be more prevalent in Windows. 

Resolution

Executable permission

Check the permissions of the file to confirm it is executable. If it's not executable, you will need to modify the file in your repository, add executable privilege to the file, then commit and push to the cloud.

  • On Unix/Linux/macOS (from your local machine):
chmod a+x ./drush
git add ./drush
git commit -m 'Add execute bit to drush'
git push
  • On Windows:
git update-index --chmod=+x ./drush
git commit -m 'Add execute bit to drush (Windows)'
git push

If you are on Windows, use the above git update-index command as Windows does not support Unix-style file permissions natively.
Verify the file is executable in your repository. After updating the permission, commit and push the changes to the cloud.

Drush missing from composer.json

If Drush is missing from composer.json, see the following option to fix this, do all these steps in your local machine:

  • Run the following commands
composer config vendor-dir vendor
composer require drush/drush
  • If vendor/bin still does not contain the Drush, you can try regenerating the entire vendor directory again:
rm -rf vendor
composer install

Summary

  • Ensure that any script or binary, such as Drush, is set as executable before pushing to your repo.
  • Use the appropriate method for your operating system to set the executable bit.
  • After permissions are set, always commit and push to ensure the change is reflected in the remote environment.
  • If Drush is missing, make sure it is required in composer.json and correctly installed.

Did not find what you were looking for?

If this content did not answer your questions, try searching or contacting our support team for further assistance.

Back to Section navigation