collapse collapse
* User Info
 
 
Welcome, Guest. Please login or register.
* Search

* Board Stats
  • stats Total Members: 989
  • stats Total Posts: 18363
  • stats Total Topics: 2500
  • stats Total Categories: 7
  • stats Total Boards: 35
  • stats Most Online: 1144

Author Topic: Edit: bot going off when I close session (on shell account)  (Read 2180 times)

0 Members and 1 Guest are viewing this topic.

Offline Kepha

  • BeBot User
  • **
  • Posts: 36
  • Karma: +0/-0
Hi there. I'm learning about BeBot and am looking for help on installing on a Shell Account.

The requirements should all be matched, including a database (name, login, password).

I'm not seeing what to replace here, doubt there is a *.exe

Code: [Select]
$php_bin = "php.exe";
$php_args = " -c ./ ";

If I understood correctly, in this field I can keep the "Main.php" if I didn't move files inside the folder, correct?
Code: [Select]
$main_php = "Main.php";

Sorry for the noobish.


EDIT: to add another doubt.

On the *.conf file, I can't find the $guild_name line to edit Guild Name

(following Install instructions)

Quote
Guild bot

To make a guild bot set “$guildbot” to true. Change “$guild_name” to the exact name of your guild.
« Last Edit: July 27, 2011, 05:22:54 pm by Kepha »

Offline Kepha

  • BeBot User
  • **
  • Posts: 36
  • Karma: +0/-0
Re: Help to install BeBot on Shell Account
« Reply #1 on: July 27, 2011, 09:24:06 am »
Just to let know if someone else has a Shell account but isn't used to run game bots from there. It works pretty equal to Eggdrops (old school IRC).

To my questions above, I didn't touch the fields below and seems to be the right thing to do
Code: [Select]
$php_bin = "php.exe";
 $php_args = " -c ./ ";
$main_php = "Main.php";
The $guild_name field which I didn't find, doesn't seem to have a problem now, so basically everything else was changed as needed,

- type of bot (Guild Bot)
- account login/password
- database name/login/password, server set as "localhost"

Then I entered SSH - used the old Putty - went to bot folder, then: php5 start.php
Everything was loaded fine and Bot is active on Guild to my happyness.


Now I just need to learn what he can do and how :)

Offline Kepha

  • BeBot User
  • **
  • Posts: 36
  • Karma: +0/-0
Re: Edit: bot going off when I close session (on shell account)
« Reply #2 on: July 27, 2011, 05:24:01 pm »
Just noticed that the Bot leaves when I close Putty, while installed and running in my shell.

What did I do wrong?

Offline Glarawyn

  • BeBot Hero
  • ******
  • Posts: 521
  • Karma: +0/-0
Re: Edit: bot going off when I close session (on shell account)
« Reply #3 on: July 27, 2011, 08:32:14 pm »
If you're on a Linux/UNIX host, delete the php.ini that came with BeBot. You don't need it and odds are it'll just confuse things.

To keep your bot running when you disconnect, I recommend using an application called screen.

# screen -S friendlyname
# php StartBot.php
Press Ctrl+A, then D.
You should get Detached, then back to your prompt.

List running screens:
# screen -ls

Reattach a screen:
# screen -r friendlyname

Offline Kepha

  • BeBot User
  • **
  • Posts: 36
  • Karma: +0/-0
Re: Edit: bot going off when I close session (on shell account)
« Reply #4 on: July 27, 2011, 08:59:20 pm »
Hi mate and thanks for your reply.

I can't find the php.ini , maybe don't have it at all. I will try do what you said.

EDIT: THANK YOU alot Glarawyn, seem's to be working perfectly, session closed and bot still running.

When I go there if I want to have a look of what he is reading I do "screen -r friendlyname" (I kept the name), and to close it again CTRL + A, then D.


Since you seem to know about this, for the future, can you tell me how to:
- "kill" the bot ?
- how to properly restart ? (when installing new modules)
- proper way to re-run afters ?

TIA :)
« Last Edit: July 27, 2011, 09:10:43 pm by Kepha »

Offline Glarawyn

  • BeBot Hero
  • ******
  • Posts: 521
  • Karma: +0/-0
Re: Edit: bot going off when I close session (on shell account)
« Reply #5 on: July 28, 2011, 09:50:25 pm »
Could be that php.ini finally got removed from the bot distribution and put in the php bundle where it belongs, it used to be in the top level directory of the bot's directory.

Since you seem to know about this, for the future, can you tell me how to:
- "kill" the bot ?
- how to properly restart ? (when installing new modules)
- proper way to re-run afters ?

Shutdown: Attach screen and press Ctrl+C to terminate the current process. Otherwise /tell botname shutdown in game chat.

Restart: Ctrl+C and restart normally, or /tell botname restart in game chat.

Restart normally in screen.

If you search the forums there are scripts and other Linux tips for managing your bot on a Linux or other UNIX like operating systems.

Offline Kepha

  • BeBot User
  • **
  • Posts: 36
  • Karma: +0/-0
Re: Edit: bot going off when I close session (on shell account)
« Reply #6 on: July 29, 2011, 02:40:55 pm »
Thank you once again. Killing the process also seems to work  :P

 

* Recent Posts
[AoC] special char for items module by bitnykk
[February 09, 2024, 09:41:18 pm]


0.8.x updates for AoC by bitnykk
[January 30, 2024, 11:16:08 pm]


0.8.x updates for AO by bitnykk
[January 30, 2024, 11:15:37 pm]


BeBot still alive & kicking ! by bitnykk
[December 17, 2023, 12:58:44 am]


Bebot and Rasberry by bitnykk
[November 29, 2023, 11:04:14 pm]

* Who's Online
  • Dot Guests: 291
  • Dot Hidden: 0
  • Dot Users: 0

There aren't any users online.
* Forum Staff
bitnykk admin bitnykk
Administrator
Khalem admin Khalem
Administrator
WeZoN gmod WeZoN
Global Moderator
SimplePortal 2.3.7 © 2008-2024, SimplePortal