exec() problem!
  • Quote:
    jkhost:/home# dpkg -i airtime_1.8.2-3_all.deb
    ******************************** Install Begin *********************************

    Warning: exec() has been disabled for security reasons in /var/lib/airtime/install/include/AirtimeInstall.php on line 31
    Must be root user.
    dpkg: error processing airtime (--install):
    subprocess installed post-installation script returned error exit status 1
    Errors were encountered while processing:
    airtime

    or:
    Quote:
    /home/airtime/install# php airtime-install.php

    ******************************** Install Begin *********************************

    Warning: exec() has been disabled for security reasons in /home/airtime/install/include/AirtimeInstall.php on line 31
    Must be root user.

    If im delete line 31:
        public static function ExitIfNotRoot()
        {
            // Need to check that we are superuser before running this.
            if(exec("whoami") != "root"){
                echo "Must be root user.\n";
                exit(1);
            }
        }


    I have more Warning: exec() has been disabled for security reasons toubles.

    How i can fix this?
    Debian 5.0
  • 3 Comments sorted by
  • Vote Up0Vote Down Andrey PodshivalovAndrey Podshivalov
    Posts: 1,526Member, Administrator, Sourcefabric Team
    "exec() has been disabled for security reasons" means that function "exec" is disabled in php.ini
    Make sure that /etc/php5/cli/php.ini contains:
    safe_mode = Off
    disable_functions =




  • Andrey Podshivalov wrote on Tue, 07 June 2011 07:33
    "exec() has been disabled for security reasons" means that function "exec" is disabled in php.ini
    Make sure that /etc/php5/cli/php.ini contains:
    safe_mode = Off
    disable_functions =

    safe_mode = Off and disable_functions =

    But i have this problem.
  • Vote Up0Vote Down Andrey PodshivalovAndrey Podshivalov
    Posts: 1,526Member, Administrator, Sourcefabric Team
    run this command
    echo "<?phpinfo()?>" | php
    and attach in forum a command output