@Washington,
am not a guru but i have repaired table events and when it came to reparing hosts, look below
 
mysql> repair table hosts;
+--------------+--------+----------+------------------------------------+
| Table        | Op     | Msg_type | Msg_text                           |
+--------------+--------+----------+------------------------------------+
| jffnms.hosts | repair | Error    | Table 'jffnms.hosts' doesn't exist |
| jffnms.hosts | repair | error    | Corrupt                            |
+--------------+--------+----------+------------------------------------+
2 rows in set (0.00 sec)

mysql>
mysql>
mysql>
mysql> repair table events;
+---------------+--------+----------+-------------------------------------+
| Table         | Op     | Msg_type | Msg_text                            |
+---------------+--------+----------+-------------------------------------+
| jffnms.events | repair | Error    | Table 'jffnms.events' doesn't exist |
| jffnms.events | repair | error    | Corrupt                             |
+---------------+--------+----------+-------------------------------------+
2 rows in set (0.00 sec)

mysql>

@ Peter, it does not exist so i dont think it can be the source.


2009/6/11 Peter Karunyu <pkarunyu@gmail.com>
Also check if the table events exists;

"Query Failed - table_insert(events) - insert into events (date,type,host,interface,state,username,info) VALUES ('2009-06-11 17:09:05','43','1','Login','failed','jffnms','from 127.0.0.1') - Table 'jffnms.events' doesn't exist"


2009/6/11 Odhiambo ワシントン <odhiambo@gmail.com>


On Thu, Jun 11, 2009 at 5:17 PM, [dan buria] <dimbega@gmail.com> wrote:
Hi guys,
am working on this project and get the above error.
Am working in DEBIAN 5.0 using jffnms.


17:08:56 db_ping(mysql) Connection to DB Restored... 17:08:57 db_ping(mysql) Connection to DB Restored... 17:08:58 db_ping(mysql) Connection to DB Restored... 17:08:59 db_ping(mysql) Connection to DB Restored... 17:09:00 db_ping(mysql) Connection to DB Restored...
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /opt/jffnms/lib/api.db.inc.php on line 306
17:09:01 db_ping(mysql) Connection to DB Restored... 17:09:02 db_ping(mysql) Connection to DB Restored... 17:09:03 db_ping(mysql) Connection to DB Restored... 17:09:04 db_ping(mysql) Connection to DB Restored... 17:09:05 db_ping(mysql) Connection to DB Restored...
Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource in /opt/jffnms/lib/api.db.inc.php on line 306
17:09:06 db_ping(mysql) Connection to DB Restored... 17:09:07 db_ping(mysql) Connection to DB Restored... 17:09:08 db_ping(mysql) Connection to DB Restored... 17:09:09 db_ping(mysql) Connection to DB Restored... 17:09:10 db_ping(mysql) Connection to DB Restored... 17:09:10 Query Failed - table_insert(events) - insert into events (date,type,host,interface,state,username,info) VALUES ('2009-06-11 17:09:05','43','1','Login','failed','jffnms','from 127.0.0.1') - Table 'jffnms.events' doesn't exist17:09:11 db_ping(mysql) Connection to DB Restored... 17:09:12 db_ping(mysql) Connection to DB Restored... 17:09:13 db_ping(mysql) Connection to DB Restored... 17:09:14 db_ping(mysql) Connection to DB Restored... 17:09:15 db_ping(mysql) Connection to DB Restored...
Warning: join() [function.join]: Invalid arguments passed in /opt/jffnms/lib/api.events.inc.php on line 246
Query Failed - events_list() - Table 'jffnms.hosts' doesn't exist
                                              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
mysql -e "use jffnms; show tables;"

Does the table "hosts" exist?
If it does, then perhaps it needs some fixups/repair:

mysql -e "use jffnms; repair table hosts;"

Maybe... but the clue is right there on the line marked with ^^^^^^.


--
Best regards,
Odhiambo WASHINGTON,
Nairobi,KE
+254733744121/+254722743223
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
"If you have nothing good to say about someone, just shut up!."
              -- Lucky Dube

_______________________________________________
Skunkworks mailing list
Skunkworks@lists.my.co.ke
http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks
Other services @ http://my.co.ke
Other lists
-------------
Skunkworks announce: http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks-announce
Science - http://lists.my.co.ke/cgi-bin/mailman/listinfo/science
kazi - http://lists.my.co.ke/cgi-bin/mailman/admin/kazi/general



_______________________________________________
Skunkworks mailing list
Skunkworks@lists.my.co.ke
http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks
Other services @ http://my.co.ke
Other lists
-------------
Skunkworks announce: http://lists.my.co.ke/cgi-bin/mailman/listinfo/skunkworks-announce
Science - http://lists.my.co.ke/cgi-bin/mailman/listinfo/science
kazi - http://lists.my.co.ke/cgi-bin/mailman/admin/kazi/general