cacti+nagios+npc 报错 ndo2db-3x: mysql_error: ‘Unknown column ‘long_output’ in ‘field list”
提示确少long_output字段
解决方法如下(nagios 4.0以上的执行)
mysql -uroot -ppasswd
use nagios;
ALTER
TABLE
`npc_hostchecks`
ADD
COLUMN
`long_output`
varchar
(8192)
NOT
NULL
default
''
AFTER
`
output
`;
ALTER
TABLE
`npc_hoststatus`
ADD
COLUMN
`long_output`
varchar
(8192)
NOT
NULL
default
''
AFTER
`
output
`;
ALTER
TABLE
`npc_servicechecks`
ADD
COLUMN
`long_output`
varchar
(8192)
NOT
NULL
default
''
AFTER
`
output
`;
ALTER
TABLE
`npc_servicestatus`
ADD
COLUMN
`long_output`
varchar
(8192)
NOT
NULL
default
''
AFTER
`
output
`;
ALTER
TABLE
`npc_statehistory`
ADD
COLUMN
`long_output`
varchar
(8192)
NOT
NULL
default
''
AFTER
`
output
`;
ALTER
TABLE
`npc_eventhandlers`
ADD
COLUMN
`long_output`
varchar
(8192)
NOT
NULL
default
''
AFTER
`
output
`;
ALTER
TABLE
`npc_systemcommands`
ADD
COLUMN
`long_output`
varchar
(8192)
NOT
NULL
default
''
AFTER
`
output
`;
ALTER
TABLE
`npc_notifications`
ADD
COLUMN
`long_output`
varchar
(8192)
NOT
NULL
default
''
AFTER
`
output
`;
exit;