BeBot - An Anarchy Online and Age Of Conan chat automaton

Archive => Anarchy Online Archive => AO 0.6 support => Topic started by: Setalio on July 11, 2009, 02:34:10 pm

Title: bebot starts with failure
Post by: Setalio on July 11, 2009, 02:34:10 pm
hi all, i hope any can help me, i will run this bot on a server (Linux Suse11 - 64bit), the script makes the conf files fine, after start comes this

im not a "linux"crack..., and german with a bad engl.


Code: [Select]
bigcrusher:/home/bebot/BeBot-0.6.4-pre2> php ./StartBot.php flaemmchen                                                
PHP Warning:  shell_exec(): Cannot execute using backquotes in Safe Mode in /home/bebot/BeBot-0.6.4-pre2/StartBot.php on line 68
PHP Notice:  Undefined property: Conf::$cf in /home/bebot/BeBot-0.6.4-pre2/Sources/Conf.php on line 70
PHP Notice:  Undefined variable: pw in /home/bebot/BeBot-0.6.4-pre2/StartBot.php on line 100
sh: /: is a directory
PHP Notice:  Undefined variable: pw in /home/bebot/BeBot-0.6.4-pre2/StartBot.php on line 100
sh: /: is a directory
PHP Notice:  Undefined variable: pw in /home/bebot/BeBot-0.6.4-pre2/StartBot.php on line 100
sh: /: is a directory
^C(operation breaked)
Title: Re: bebot starts with failure
Post by: Khalem on July 11, 2009, 07:42:50 pm
Your PHP seems to be set to safe mode and BeBot cannot function in a safe mode enviroment.

Either turn safe mode off in php.ini, setup a separate php.ini for use with the bots or compile a separate php install for BeBot usage.

Title: Re: bebot starts with failure
Post by: Setalio on July 11, 2009, 08:41:55 pm
the safemode for this user is disabled

http://bebot.mine.nu/phpinfo.php
Title: Re: bebot starts with failure
Post by: Khalem on July 11, 2009, 10:18:29 pm
Quote
bigcrusher:/home/bebot/BeBot-0.6.4-pre2> php ./StartBot.php flaemmchen                                               
PHP Warning:  shell_exec(): Cannot execute using backquotes in Safe Mode in /home/bebot/BeBot-0.6.4-pre2/StartBot.php on line 68

Yet there is php telling you it cannot run shell_exec() because it is in safe mode. Just because php is reporting safe mode as disabled for the webserver does not mean it wont be enabled for the command line client for php.

Try running a file containing the following from command line:
Code: [Select]
<?php
phpinfo
();
?>


You could try running the bot directly from Main.php, but it will not automatically restart, and I am honestly not sure if anything else will break as no coding have been made with safe mode in mind.

Basically in any scenario where you run the bot on a system where PHP is used for something else, you will want to use a separate PHP install altogether or a separate php.ini for it. The reason for this is simply because the bot requires PHP to have sockets enabled which in considered dangerous to have on a webserver for example.
Title: Re: bebot starts with failure
Post by: Setalio on July 12, 2009, 11:33:30 am
thx Khalem for your help, i set the variable from php-safe now correct ^^

next failure:

Sockets extention required to run this bot
PHP Notice:  Undefined variable: pw in /srv/www/vhosts/bebot.mine.nu/private/bebot/StartBot.php on line 100


Code: [Select]
===================================================

    _/_/_/              _/_/_/                _/

   _/    _/    _/_/    _/    _/    _/_/    _/_/_/_/

  _/_/_/    _/_/_/_/  _/_/_/    _/    _/    _/

 _/    _/  _/        _/    _/  _/    _/    _/

_/_/_/      _/_/_/  _/_/_/      _/_/        _/_/

         An Anarchy Online Chat Automaton

                     And

          An Age of Conan Chat Automaton

             v.0.6.4.dev - PHP 5.2.6

                         OS: linux

        Your operating system is detected as 64bit

===================================================

Sockets extention required to run this bot
PHP Notice:  Undefined variable: pw in /srv/www/vhosts/bebot.mine.nu/private/bebot/StartBot.php on line 100
Title: Re: bebot starts with failure
Post by: Setalio on July 12, 2009, 11:50:45 am
the extensionfailure resolved

go to yast, and search extensions for php5 and install this, next failure the AoChat need bcmath, search it in Yast and install it to

big thx for all will help me, BeBot runs @ SuSE 11.0 64bit
SimplePortal 2.3.7 © 2008-2025, SimplePortal