How to Solve Permission denied error for User cron job ?

Linux Dedicated Web Hosting provides free cPanel/whm. By using your cPanel, you can set a cron job. Cron job is a scheduled task. Cron jobs can be very useful to run a simple tasks from a script file.

Please check the below procedure to solve the Permission denied error cron job as user.

Sometimes you may received Permission denied error with the wget command while the execution on cronjobs in cPanel.

Error :-

/usr/local/cpanel/bin/jailshell: /usr/bin/wget: Permission denied

Solution:-

  1. First check the permission using the following command.

ls -l /usr/bin/wget

Sample Output : -rwx——. 1 root root

Output Should be : -rwxr-xr-x. 1 root root

If not you can use the below command to change the Permission.

chmod 755 /usr/bin/wget

That’s it!

Now you can try to execute wget command as a cpanel user.