PacketFence - BTS - PacketFence
View Issue Details
0001249PacketFenceweb adminpublic2011-08-22 13:132012-06-14 12:25
maikel 
obilodeau 
normaltrivialalways
closedno change required 
devel 
3.0.0 
0001249: pfcmd node lookup fails on new accounting feature
Error: Problems executing 'PFCMD lookup node 00:01:6c:da:f0:00'
    /usr/local/pf/lib/pf/accounting.pm line 181 (0000001) Can't call method "fetchrow_hashref" on an undefined value at /usr/local/pf/lib/pf/accounting.pm line 181. at /usr/local/pf/lib/pf/accounting.pm line 181 pf::accounting::node_accounting_view('00:01:6c:da:f0:00') called at /usr/local/pf/lib/pf/lookup/node.pm line 167 pf::lookup::node::lookup_node('00:01:6c:da:f0:00') called at /usr/local/pf/bin/pfcmd line 1818 main::lookup() called at /usr/local/pf/bin/pfcmd line 179 main::__ANON__() called at /usr/local/pf/bin/pfcmd line 218
No accounting was set sofar, so hence it cant look it up. Its a good new feature btw ;)
No tags attached.
Issue History
2011-08-22 13:13maikelNew Issue
2011-08-22 13:53fgaudreaultNote Added: 0002143
2011-08-22 13:59fgaudreaultNote Added: 0002144
2011-08-23 08:52obilodeauNote Added: 0002145
2011-08-23 08:52obilodeauStatusnew => feedback
2011-08-23 10:06maikelNote Added: 0002146
2011-08-23 10:09obilodeauStatusfeedback => resolved
2011-08-23 10:09obilodeauResolutionopen => no change required
2011-08-23 10:09obilodeauAssigned To => obilodeau
2011-08-23 10:10obilodeauNote Added: 0002147
2012-06-14 12:25obilodeauStatusresolved => closed
2012-06-14 12:25obilodeauFixed in Version => 3.0.0

Notes
(0002143)
fgaudreault   
2011-08-22 13:53   
Hi,

What PF logs have to say about it? Did you run the database update script or you installed from scratch? Looks like a missing table to me, that query should not return undef....
(0002144)
fgaudreault   
2011-08-22 13:59   
We had the same issue on our dev box, we ran the upgrade script (2.2.0 -> 3.0) and everything is working. There are 2 tables, and some stored proc to insert.
(0002145)
obilodeau   
2011-08-23 08:52   
Waiting on a confirmation from reporter.
(0002146)
maikel   
2011-08-23 10:06   
Indeed works.
Using yum update doesn't patch the database tables on a 3.0.0 beta
Edited the script and with the tables there, pf runs ok
(0002147)
obilodeau   
2011-08-23 10:10   
We do not provide sql upgrade script for in active development version. 3.0 final will have a 2.2 to 3.0 upgrade script and UPGRADE tells users how to run the upgrade script.