Closed lbsou closed 6 years ago
You did not specify a frequency or a report id so this will effectively do nothing (though I'm sure it should print the help syntax out).
It should print the help syntax
php -f runtime.php -d -v
does nothing
If I add --debug, it shows the help syntax... weird...
You still haven't specified a frequency or report id. All you have asked is for debugging and verboseness to be turned on. The first will provide mode information about the devices/items being processed, the secoond prints any information normally logged to the cacti.log file to the screen as well
The help indicate that the "-d" stand for daily and when I'm not specifying an ID, it is suppose to run all report...
Sorry, you are correct. It's --debug for the debug option. I use -d with routerconfigs and gexport so it's an automatic assumption.
In that case, I can only suspect that you do not have a daily report scheduled, so can you post the results of:
SELECT a.id, a.template_id, a.scheduled, a.frequency
FROM plugin_reportit_reports as a
INNER JOIN plugin_reportit_templates as b
ON b.locked = 0 AND a.template_id = b.id
"id" "template_id" "scheduled" "frequency" "1" "1" "1" "daily"
I tried with no success
php runtime.php 1
Ah, one thing, try with php -q runtime.php (that suppresses the creation of HTTP headers which are not needed at the cli).
root@Tcn00qubc01508 (CACTI):/usr/share/cacti-1.1.38/plugins/reportit #php -q -f runtime.php 1 root@Tcn00qubc01508 (CACTI):/usr/share/cacti-1.1.38/plugins/reportit #
Still no luck
SELECT * FROM plugin_reportit_reports WHERE id = 1
"id" "name" "description" "user_id" "template_id" "host_template_id" "data_source_filter" "preset_timespan" "last_run" "runtime" "public" "start_date" "end_date" "ds_description" "rs_def" "sp_def" "sliding" "present" "scheduled" "autorrdlist" "auto_email" "email_subject" "email_body" "email_format" "subhead" "state" "graph_permission" "frequency" "autoarchive" "autoexport" "autoexport_max_records" "autoexport_no_formatting" "1" "" "R_Rapport" "13" "1" "0" "%10Mbps%" "Today" "2018-06-29 09:57:25" "326" "1" "2018-06-29" "2018-06-29" "traffic_in|traffic_out" "1-1" "-0" "1" "0" "1" "1" "1" "" "" "" "" "0" "1" "daily" "1" "" "0" "0"
Fixed with the latest update.
Cacti 1.1.38 Reportit git clone develop branch 2018-06-28 PHP 5.4.16 CentOS Linux release 7.5.1804
Unable to run reportit from CLI like I was doing on pre 1.x versions
prompt> php -f runtime.php prompt> (it print nothing and goes back to prompt)
Thank you!