Linux Mint and Budabot

General discussion on Budabot.
Datch
Member
Posts: 4
Joined: Wed Feb 27, 2013 8:06 pm
antispam: rimor

Linux Mint and Budabot

Postby Datch » Wed Nov 27, 2013 12:43 pm

Hi All,
I'm Having some problems installing budabot 3.05 on my linux mint server. I am new to linux but do have programming skills so i'm not a dummy. I have downloaded the latest version and Followed the setup that was posted in 2010. I downloaded the aokex file but my system does not want to make it. It keeps coming up with error file not found. Can anyone help me out please?

Datch
:?
Captank
Member
Posts: 77
Joined: Sun Sep 09, 2012 6:36 pm
antispam: Rimor
Location: irc.funcom.com #budabot

Re: Linux Mint and Budabot

Postby Captank » Thu Nov 28, 2013 6:58 pm

Download the latest version of budabot for linux (3.05 ? do you mean 3.0RC5?)

https://code.google.com/p/budabot2/downloads/list

To run budabot you have to install a couple things:

Code: Select all

sudo apt-get install php5-cli


Depending what database you wanna run it with:

Code: Select all

sudo apt-get install php5-mysql

or

Code: Select all

sudo apt-get install php5-sqlite


Then extract the archive to any directory ... move by terminal into it, then type

Code: Select all

./chatbot.sh

If you get an permission denied error or something like that do

Code: Select all

chmod +x chatbot.sh

and re run the chatbot.sh

That should be it.

If you get any errors, please say which they are exactly


cap
Datch
Member
Posts: 4
Joined: Wed Feb 27, 2013 8:06 pm
antispam: rimor

Re: Linux Mint and Budabot

Postby Datch » Fri Nov 29, 2013 8:14 pm

Thanks that's got one of the bots up and running. I assume I just open a new terminal widow for each bot I wish to run as I currently run 8 of them.

4 org bots and 4 raid bots

Can I also copy modules direct from the windows version of the bot as I have added a couple for our org written in php. I'm assuming they should still work the same?

Thanks again

Datch
:D
Captank
Member
Posts: 77
Joined: Sun Sep 09, 2012 6:36 pm
antispam: Rimor
Location: irc.funcom.com #budabot

Re: Linux Mint and Budabot

Postby Captank » Fri Nov 29, 2013 11:19 pm

well, (with some exceptions) php usually is platform independend.

You can run all bots in different session, that way you would have only one terminal running..

a common tool for that is "screen"

i hope you are not using one budabot installation for each bot u are running, are u?

cap
Datch
Member
Posts: 4
Joined: Wed Feb 27, 2013 8:06 pm
antispam: rimor

Re: Linux Mint and Budabot

Postby Datch » Fri Nov 29, 2013 11:42 pm

No i'll do it the same as on my windows server - 8 folders - 8 bots

most of my coding is standard php so there should be no conflics i hope, the only one I have to get my head round is the website update from the bot - I have set it up the save a text file of the high ranks in the bot and then php code on the web page displays it real time so people can see who to talk to talk if the need help etc. just got to work out where to put it! - I'm very new to linux so its taking me time to get my head round it.
:)
Captank
Member
Posts: 77
Joined: Sun Sep 09, 2012 6:36 pm
antispam: Rimor
Location: irc.funcom.com #budabot

Re: Linux Mint and Budabot

Postby Captank » Sat Nov 30, 2013 12:01 am

hrmmm bot single threaded vs multi threaded webserver... great chances to get a write and read access at the same time ... id recommend mysql for such things...

on windows and on linux u can run multiple bots from the same installation ... for linux its quite easy ... u just have to do do something like

Code: Select all

./chatbot.sh <BotNameOrSomeOtherIdentifier>

for windows just copy the chatbot.bat, open it and change the "config.php" to any other file (better to keep it with php-file extension)

also note that u have to edit the database name if you are running them in same installation and with sqlite (in the end imho mysql would be better anyway besides for raidbots)

cap
Jabberwock
Member
Posts: 5
Joined: Fri Jul 15, 2016 7:43 pm
antispam: Rimor

Re: Linux Mint and Budabot

Postby Jabberwock » Fri Jul 15, 2016 7:54 pm

Hi, I've been running an earlier version on Budabot on an Ubuntu machine.
Before upgrading Budabot i changed to Linux Mint 18 MATE.
In other words it's clean machine :-)

The guide above does not work for me, because php5 is outdated.

Instead I installed php7.0-cli and php7.0-mysql directly from the software manager.

I did need to use the chmod command.

When running ./chmod.sh I get the following error. Any idea where I went wrong?

Code: Select all

**************************************************
Budabot 3.4_GA

Project Site:     https://github.com/Budabot/Budabot
Support Forum:    http://www.budabot.com/forum
In-Game Contact:  Tyrence27
**************************************************

PHP Fatal error:  Uncaught Error: Call to undefined function simplexml_load_file() in /home/myname/Budabot/lib/apache-log4php-2.2.0/configurators/LoggerConfigurationAdapterXML.php:82
Stack trace:
#0 /home/myname/Budabot/lib/apache-log4php-2.2.0/configurators/LoggerConfigurationAdapterXML.php(43): LoggerConfigurationAdapterXML->loadXML('conf/log4php.xm...')
#1 /home/myname/Budabot/lib/apache-log4php-2.2.0/configurators/LoggerConfiguratorDefault.php(162): LoggerConfigurationAdapterXML->convert('conf/log4php.xm...')
#2 /home/myname/Budabot/lib/apache-log4php-2.2.0/configurators/LoggerConfiguratorDefault.php(118): LoggerConfiguratorDefault->parseFile('conf/log4php.xm...')
#3 /home/myname/Budabot/core/BotRunner.php(178): LoggerConfiguratorDefault->parse('conf/log4php.xm...')
#4 /home/myname/Budabot/core/BotRunner.php(54): Budabot\Core\BotRunner->configureLogger('Mysteryvoice.5')
#5 /home/myname/Budabot/main.php(6): Budabot\Core\BotRunner->run()
#6 {main}
  thrown in /home/myname/Budabot/lib/apache-log4php-2.2.0/configurators/LoggerConfigurationAdapterXML.php on line 82
Tyrence
The Team
Posts: 1876
Joined: Sat Jan 09, 2010 1:32 am

Re: Linux Mint and Budabot

Postby Tyrence » Fri Jul 15, 2016 8:16 pm

It looks like you need the XML support for PHP installed. In PHP 5, that is usually included by default. You might have to Google to find out how to install/enable that in PHP 7. You will likely need to install several other PHP modules as well. Take a look at the Linux How-To to see the modules that are required: viewtopic.php?f=5&t=850

I don't know that anyone has ever ran Budabot on PHP 7 before, so I don't know if it will actually work. The easy thing to do would be to go back to PHP 5. But if you do decide to use PHP 7 and manage to get it working, it would be helpful for other people if you could post a quick tutorial with the list of commands/steps you used to get it running.
"Those who expect to reap the blessings of freedom, must, like men, undergo the fatigues of supporting it." — Thomas Paine
"Nearly all men stand adversity, but if you want to test a man's character, give him power." — Abraham Lincoln
Budabot Releases and Downloads: https://github.com/Budabot/Budabot/releases
Jabberwock
Member
Posts: 5
Joined: Fri Jul 15, 2016 7:43 pm
antispam: Rimor

Re: Linux Mint and Budabot

Postby Jabberwock » Sat Jul 16, 2016 1:05 pm

Thanks for a quick reply :-)
Aha, so php5 is pre-installed? When trying the apt-get I get that the package is missing. This is where they referred to php7.0
If not it's probably possible to add some repository from somewhere...)

I did install php7.0-xml and php7.0-gmp via the software manager (guessing apt-get would work equally well, but I like the search function...)

I do not get it to work with sqlite, and it seems it has changed the name to sqlite3 (php7.0-sqlite3). Maybe that was part of the problem?

I went over to good old mySQL and set up the database via command line from your guide, and it seemed to work.

Howerver, when starting the bot and setting it up i get the following problem:

Code: Select all

Sat Jul 16 12:44:01 2016 INFO StartUp - Starting Botname (3.4_GA) on RK5...
Sat Jul 16 12:44:01 2016 INFO ClassLoader - Loading CORE modules...
Sat Jul 16 12:44:01 2016 INFO ClassLoader - Loading USER modules...
Sat Jul 16 12:44:13 2016 ERROR SQL - Error loading sql file 'trickle.sql': Unknown table 'DatabaseName.trickle' in: DROP TABLE trickle; - Array
(
)

Sat Jul 16 12:44:37 2016 INFO Budabot - Connecting to AO Server...(chat.d1.funcom.com:7105)
Sat Jul 16 12:44:37 2016 INFO Budabot - Authenticate login data...

Fatal error: Uncaught Error: Call to undefined function Budabot\Core\bccomp() in /home/myName/Budabot/core/AOChat.class.php:689
Stack trace:
#0 /home/myName/Budabot/core/AOChat.class.php(775): Budabot\Core\AOChat->ReduceTo32Bit(614116843)
#1 /home/myName/Budabot/core/AOChat.class.php(757): Budabot\Core\AOChat->aochat_crypt('bd855b61fc7b1c3...', '\xEB\xAD\x9A$\xE1\xA4?L\x00\x00\x009Cre...')
#2 /home/myName/Budabot/core/AOChat.class.php(298): Budabot\Core\AOChat->generate_login_key('2e23b5d3337dcc3...', 'AccountName', 'myTopSecretPassword')
#3 /home/myName/Budabot/core/Budabot.class.php(171): Budabot\Core\AOChat->authenticate('AccountName', 'myTopSecretPassword')
#4 /home/myName/Budabot/core/BotRunner.php(83): Budabot\Core\Budabot->connectAO('AccountName', 'myTopSecretPassword', 'chat.d1.funcom....', 7105)
#5 /home/myName/Budabot/main.php(6): Budabot\Core\BotRunner->run()
#6 {main}
  thrown in /home/myName/Budabot/core/AOChat.class.php on line 689

Would it help to manually create that 'trickle' table? And if so... anything special to think about with rights?
Tyrence
The Team
Posts: 1876
Joined: Sat Jan 09, 2010 1:32 am

Re: Linux Mint and Budabot

Postby Tyrence » Sat Jul 16, 2016 5:31 pm

For that error, the php7.0-gmp package should be sufficient, but maybe it's changed in PHP 7. See if you can find a package called bcmath and install that and see if that fixes the problem.

The problem with the trickle table is separate and is an actual problem with the bot on any version of PHP. If that keeps happening, then yes you might need to load the trickle.sql file manually.

And as far as getting it to work with SQLite, it should work with SQLite v3. I guess I'd have to see the error.
"Those who expect to reap the blessings of freedom, must, like men, undergo the fatigues of supporting it." — Thomas Paine
"Nearly all men stand adversity, but if you want to test a man's character, give him power." — Abraham Lincoln
Budabot Releases and Downloads: https://github.com/Budabot/Budabot/releases

Return to “General Discussion”

Who is online

Users browsing this forum: No registered users and 1 guest