#63314 closed defect (bug) (invalid)
chmod(): Operation not permitted
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | normal | Version: | 6.8 |
Component: | Filesystem API | Keywords: | |
Focuses: | Cc: |
Description
Wordpress started logging the following in apache error log:
[Fri Apr 18 16:30:50.686300 2025] [proxy_fcgi:error] [pid 3909184:tid 3909284] [client ###.###.##.##:0] AH01071: Got error 'PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173; PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173', referer: https://**********.*********/wp-login.php
[Fri Apr 18 17:29:26.814565 2025] [proxy_fcgi:error] [pid 3909307:tid 3909409] [client ###.###.##.##:0] AH01071: Got error 'PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173; PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173', referer: https://**********.*********/wp-admin/options-permalink.php
[Fri Apr 18 17:38:02.205146 2025] [proxy_fcgi:error] [pid 3909307:tid 3909428] [client ###.###.##.##:0] AH01071: Got error 'the log buffer is full (1024). The access log request has been truncated.', referer: https://**********.*********/wp-admin/post-new.php?post_type=page
[Fri Apr 18 18:13:20.724878 2025] [proxy_fcgi:error] [pid 3909307:tid 3909379] [client ###.###.##.##:0] AH01071: Got error 'PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173; PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173', referer: https://**********.*********/wp-login.php
[Fri Apr 18 18:31:10.952583 2025] [proxy_fcgi:error] [pid 3909307:tid 3909345] [client ###.###.##.##:0] AH01071: Got error 'PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173; PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173', referer: https://**********.*********/wp-login.php
Checked all file/folder permissions and they are the correct ones. Worked with hosting provider and they confirmed permissions are correct as well.
This site was updated to v6.8 but other sites still on 6.7.2 are getting them too.
Not sure which Component to put this under so selected Filesystem.
Change History (5)
#1
follow-up:
↓ 2
@
4 weeks ago
- Keywords needs-patch removed
- Resolution set to invalid
- Status changed from new to closed
#2
in reply to:
↑ 1
;
follow-up:
↓ 4
@
4 weeks ago
Replying to threadi:
The message comes from a PHP function that wants to set the file permissions on a file. It only occurs if the directory permissions are not set correctly. Your hosting support should take a closer look at this. WordPress cannot solve this because the problem lies in the host’s file system.
Ok thank you for responding. I did contact our hosting provider before logging this and they said all permissions we set correctly. So I'm stumped.
#3
in reply to:
↑ description
@
4 weeks ago
Replying to wynot:
WordPress started logging the following in apache error log:
[Fri Apr 18 16:30:50.686300 2025] [proxy_fcgi:error] [pid 3909184:tid 3909284] [client ###.###.##.##:0] AH01071: Got error 'PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173; PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173', referer: https://**********.*********/wp-login.php
[Fri Apr 18 17:29:26.814565 2025] [proxy_fcgi:error] [pid 3909307:tid 3909409] [client ###.###.##.##:0] AH01071: Got error 'PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173; PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173', referer: https://**********.*********/wp-admin/options-permalink.php
[Fri Apr 18 17:38:02.205146 2025] [proxy_fcgi:error] [pid 3909307:tid 3909428] [client ###.###.##.##:0] AH01071: Got error 'the log buffer is full (1024). The access log request has been truncated.', referer: https://**********.*********/wp-admin/post-new.php?post_type=page
[Fri Apr 18 18:13:20.724878 2025] [proxy_fcgi:error] [pid 3909307:tid 3909379] [client ###.###.##.##:0] AH01071: Got error 'PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173; PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173', referer: https://**********.*********/wp-login.php
[Fri Apr 18 18:31:10.952583 2025] [proxy_fcgi:error] [pid 3909307:tid 3909345] [client ###.###.##.##:0] AH01071: Got error 'PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173; PHP message: PHP Warning: chmod(): Operation not permitted in /home///public_html/wp-admin/includes/class-wp-filesystem-direct.php on line 173', referer: https://**********.*********/wp-login.php
Checked all file/folder permissions and they are the correct ones. Worked with hosting provider and they confirmed permissions are correct as well.
This site was updated to v6.8 but other sites still on 6.7.2 are getting them too.
Not sure which Component to put this under so selected Filesystem.
It is not about WordPress but encountering the "chmod: Operation not permitted" error in Linux typically means you lack the necessary permissions. By using sudo to execute commands with superuser privileges or changing the file ownership to your user, you can resolve this issue and successfully modify file permissions.
#4
in reply to:
↑ 2
;
follow-up:
↓ 5
@
4 weeks ago
Replying to wynot:
Replying to threadi:
The message comes from a PHP function that wants to set the file permissions on a file. It only occurs if the directory permissions are not set correctly. Your hosting support should take a closer look at this. WordPress cannot solve this because the problem lies in the host’s file system.
Ok thank you for responding. I did contact our hosting provider before logging this and they said all permissions we set correctly. So I'm stumped.
When you encounter this problems what I generally do first of all is set full 777 all files and folders and see if it works (should). Then you can revert to set the right permissions to each folder/file once you have discovered if it was actually a permission issue (which should)
But be aware that PHP itself is VERY pesky with this topic. I've reported in the past about permissions issues with PHP (nothing to do with WordPress itself). But I found difficult to replicate.
But as @threadi said, this is not a WordPress topic to treat here, but in the WordPress forums
https://wordpress.org/support/forum/how-to-and-troubleshooting/
#5
in reply to:
↑ 4
@
4 weeks ago
Thank YOU! I will check that out.
Replying to SirLouen:
Replying to wynot:
Replying to threadi:
The message comes from a PHP function that wants to set the file permissions on a file. It only occurs if the directory permissions are not set correctly. Your hosting support should take a closer look at this. WordPress cannot solve this because the problem lies in the host’s file system.
Ok thank you for responding. I did contact our hosting provider before logging this and they said all permissions we set correctly. So I'm stumped.
When you encounter this problems what I generally do first of all is set full 777 all files and folders and see if it works (should). Then you can revert to set the right permissions to each folder/file once you have discovered if it was actually a permission issue (which should)
But be aware that PHP itself is VERY pesky with this topic. I've reported in the past about permissions issues with PHP (nothing to do with WordPress itself). But I found difficult to replicate.
But as @threadi said, this is not a WordPress topic to treat here, but in the WordPress forums
https://wordpress.org/support/forum/how-to-and-troubleshooting/
The message comes from a PHP function that wants to set the file permissions on a file. It only occurs if the directory permissions are not set correctly. Your hosting support should take a closer look at this. WordPress cannot solve this because the problem lies in the host’s file system.