[PHP/VirtualHost]Error getting php files to run

  • When I create a virtualhost with the default apache settings, everytime I try to run a php file it will download it instead of executing it. When I borrow a snippet from the OMV virtualhost in the directory section of the conf file:


    Code
    <FilesMatch \.php$>
            FcgidWrapper /var/www/openmediavault/php-fcgi .php
            SetHandler fcgid-script
            Options +ExecCGI
        </FilesMatch>


    I will get a 500 error. The logging will show:


    Code
    [Wed May 01 15:14:50 2013] [warn] [client xxx.xxx.xxx.xxx] (104)Connection reset by peer: mod_fcgid: error reading data from FastCGI server
    [Wed May 01 15:14:50 2013] [error] [client xxx.xxx.xxx.xxx] Premature end of script headers: info.php


    Any thoughts?

    • Offizieller Beitrag

    I would copy /var/www/openmediavault/php-fcgi to your virtual host directory and edit the phprc line. Then copy OMV's /var/www/openmediavault/cgi/php.ini to your virtual host and make changes. That's what my owncloud install script does.

    omv 7.0.4-2 sandworm | 64 bit | 6.5 proxmox kernel

    plugins :: omvextrasorg 7.0 | kvm 7.0.10 | compose 7.1.2 | k8s 7.0-6 | cputemp 7.0 | mergerfs 7.0.3


    omv-extras.org plugins source code and issue tracker - github


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!