1 --------------------------
2 -- General Installation --
3 --------------------------
5 This file contains some general guidelines for installing infobot on your
6 system. At this point it is very basic, but should hopefully clear up some of
11 - Copy files/sample/* to files/
13 - Edit files/infobot.config, modify to taste.
14 - Edit files/infobot.servers to modify list of IRC servers to connect.
15 - Edit files/infobot.chan to set which channels to join.
17 Required Perl modules:
19 - Net::IRC perl module
20 - Debian: (apt-get install libnet-irc-perl)
22 - Debian: (apt-get install libwww-search-perl)
24 - Debian: (apt-get install libwww-perl)
26 - Debian: (apt-get install libhtml-parser-perl)
28 - Debian: (apt-get install libxml-feed-perl)
31 - MySQL, read the section MySQL below
32 - SQLite or SQLite2, read the section SQLite below
33 - PgSQL, read the section PostgreSQL below
35 NOTE: There are "bugs" in the perl modules. Read the section "Patches" below, on how to fix.
37 Finally, start your bot by changing to the base dir and type:
47 - Debian: (apt-get install postgresql)
48 - Debian: (apt-get install libpg-perl)
51 As of now, infobot has full pgsql support. It seems to be working 100%, but it
52 assumes that you have precreated the database and user for now. As long as you
53 already created the database and user and stored this info in the
54 infobot.config, then the tables will automatically be created on startup. Until
55 I get setup.pl fixed, run the following commands as root (or postgres if root
56 doesnt have permission to create users/db's):
58 > createuser --no-adduser --no-createdb --pwprompt --encrypted <user>
59 > createdb --owner=<user> <dbname> [<description>]
61 Dont forget to replace <user> and so forth with actual values you intend to use,
62 and dont include the <>'s ;) If you run these commands, you should get a user
63 with an encrypted password that cannot create new db's or user's (as it should
64 be!), and the user will own the newly created database <dbname>. Congrats!
66 If everything went fine, you should have everything infobot needs to use pgsql.
67 Next simply cd to the base directory you installed the bot to and type:
72 Thats it! Everything the bot needs should be automatically created when it loads
75 In the future I will try to get around to editing the setup.pl file to ask the
76 same questions it does for mysql (your root password etc) so that you can skip
77 manually creating the database/user. But for now, this should be just fine for
78 most of you techies out there.
87 - Install a MySQL server and the DBI Perl modules.
88 - Debian: (apt-get install mysql-server libdbd-mysql-perl)
90 - Run 'mysqladmin -u root -p create <DB NAME>'
91 Where <DB NAME> is the same as specified in infobot.config.
93 - Run 'setup/setup.pl'
94 FIXME: This script is horribly broken! Do NOT use it! The bot will
95 automatically create the tables when it starts. You just need to ensure that
96 the database and the login information are correct, and start the bot.
100 - if connection to localhost is (short) refused, run
101 '/etc/init.d/mysql stop'
102 '/etc/init.d/mysql start'
103 - if connection for user is refused, reload grant tables with
104 'mysqladmin -u root -p reload'
107 - run 'scripts/dbm2mysql.pl old-db' to convert dbm database file
113 You can add a new user manually by connecting to MySQL and performing these
118 mysql> CREATE DATABASE infobot;
119 mysql> GRANT USAGE ON *.* TO 'user'@'localhost' IDENTIFIED BY 'yourpassword';
120 mysql> GRANT ALL PRIVILEGES ON infobot.* TO 'user'@'localhost';
122 FULL FACTOID DATABASE
123 ---------------------
124 You can get the data from the MySQL database that the apt bot uses on
125 #debian at freenode (irc.freenode.net), at:
127 http://lain.cheme.cmu.edu/~apt/infobot/apt.sql.bz2
136 SQLite is a C library that implements an embeddable SQL database engine.
137 Programs that link with the SQLite library can have SQL database access without
138 running a separate RDBMS process. The distribution comes with a standalone
139 command-line access program (sqlite) that can be used to administer an SQLite
140 database and which serves as an example of how to use the SQLite library.
142 infobot will create a file called <DBname>.sqlite and populate the tables for
143 you if they do not already exist.
145 - Install SQLite libraries and DBI Perl modules.
146 - Debian: (apt-get install libsqlite0 libdbd-sqlite-perl)
148 other distros might need to build from sources.
150 You may use either DBD::SQLite or DBD::SQLite2
154 http://www.hwaci.com/sw/sqlite/
158 http://search.cpan.org/author/MSERGEANT/DBD-SQLite/
160 You will also need the normal Perl DBD stuff which should be included in your
163 # vim:ts=4:sw=4:expandtab:tw=80