Re: Fedora 40 apache now giving errors

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Apr 23, 2024 at 08:52:18PM -0400, Steven A. Falco wrote:
> I upgraded to F40, and suddenly an apache cgi script that was working perfectly in F39 (and earlier) is giving me a "Read-only file system" error when trying to write data into a file.
> 
> The directory where the cgi is trying to write is owned by 
> apache:apache, and it is mode 777.  The file the cgi is trying to 
> write to is also owned by apache:apache and is mode 666.
> 
> If I manually run the cgi (a trivial perl script), it works perfectly, 
> but apache gives the "Read-only file system" error.  Apache can read 
> the file fine, it just cannot write to it.
> 
> I also tried having the cgi simply touch a file in /tmp, and that fails too.
> 
> Any suggestions gratefully accepted.

As Xose suggests it is likely related to the new systemd hardening 
restrictions which are applied for httpd from Fedora 40. There is a bit 
more information in "man httpd.service."

Exactly what directory are you trying to write to? /usr is blocked by 
ProtectSystem=yes, /home is blocked by ProtectHome=yes, for example.

Writing to /tmp works fine OOTB for a trivial CGI in /var/www/cgi-bin 
for me - if that is failing you please file a bug. (Because PrivateTmp 
has been used for a *long* time in httpd, httpd's /tmp is different to 
the system /tmp)

Regards, Joe
--
_______________________________________________
devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Users]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]

  Powered by Linux