I’m using NeDi as a network monitoring solution (actually it is the only network discovery and monitoring solution I’m using when not talking about graphs generation). There might be situations when NeDi fails, like it happened for me:

DBD::mysql::st fetchrow_array failed: fetch() without execute() at /usr/local/www/nedi/inc/libmsq.pl line 244.
DBD::mysql::st fetchrow_array failed: fetch() without execute() at /usr/local/www/nedi/inc/libmsq.pl line 244.

After searching several forums and asking perl guys from the IRC, I found the solution.
The problem is not a bug in the code, the problem is that your database was corrupted.

To solve this issue, you should try repairing your database, which far easier than debugging perl scripts:

$ NEDIUSER=nedi; #Nedi database username
$ NEDIDB=nedi; #Nedi database password
$ NEDIPASS=nedipass; #Nedi database password
$ mysql -u $NEDIUSER --password=$NEDIPASS $NEDIDB -e 'repair table
configs,devdel,devices,incidents,interfaces,links,messages,
modules,monitoring,networks,nodes,nodiflog,nodiplog,stock,
stolen,user,vlans,wlan'

Long live NeDi!

stas?d=YwkR-u9nhCs stas?d=yIl2AUoC8zA stas?i=-kmvWPWbC9U:YEb3neXYo8o:D7DqB2pKExk stas?i=-kmvWPWbC9U:YEb3neXYo8o:F7zBnMyn0Lo stas?d=qj6IDK7rITs stas?i=-kmvWPWbC9U:YEb3neXYo8o:V_sGLiPBpWU -kmvWPWbC9U