file edit option not available
Hi
I had an error log I can't edit in file manager (edit button unhighlighted) so I renamed it to error_log-old and created a new error_log file which I can edit:
Old file renamed which I can't edit:
File and ownership the same, so any reason I can edit one and not the other?
-
You *probably* can't edit the file because it is "open" by a system process (such as Apache or PHP). Do not try to move, rename, change permissions or edit those files as you may cause issues. Copying it would be fine.
The reason why, even after renaming it, you still can't edit it is because Apache/PHP will have locked it at the "file" level (the filename is just a pointer towards the file and - usually - can be changed without problems: it's when the process "releases" the lock and then tries to to reopen it based on the filename that issues might start).
1 -
Excellent answer, rbairwell!!
0 -
Hey, I’ve run into this before — when the Edit or HTML Editor options are grayed out in cPanel’s File Manager, it’s usually because of file permission issues or the file being temporarily locked by a process (like logging).
You did the right thing by renaming the old error_log and creating a new one. That’s actually a common quick fix to:
- Regain control over the file
- Stop whatever process was locking the original log
Now that your new error_log is editable, you should be fine — just keep an eye on whether the issue comes back. If it does, you might want to check:
- If any plugin/module is aggressively writing to the log
- Or if file ownership/permissions got altered by a script or auto-update
0
Please sign in to leave a comment.
Comments
3 comments