@cryptotaxi247 / netdata-1 / commits / 72d5b6fd1

relevant error messages on freebsd

Costa Tsaousis (ktsaou) committed Jan 13, 2018 at 03:20 UTC 72d5b6fd198f36ede0f5a69cfd42c7f3177cd4d6
1 file changed +16
src/apps_plugin.c
+16
@@ -715,19 +715,35 @@ static inline int managed_log(struct pid_stat *p, uint32_t log, int status) {
715 p->log_thrown |= log;
716 switch(log) {
717 case PID_LOG_IO:
718 +#ifdef __FreeBSD__
719 + error("Cannot fetch process %d I/O info (command '%s')", p->pid, p->comm);
720 +#else
721 error("Cannot process %s/proc/%d/io (command '%s')", netdata_configured_host_prefix, p->pid, p->comm);
722 +#endif
723 break;
724
725 case PID_LOG_STATM:
726 +#ifdef __FreeBSD__
727 + error("Cannot fetch process %d memory info (command '%s')", p->pid, p->comm);
728 +#else
729 error("Cannot process %s/proc/%d/statm (command '%s')", netdata_configured_host_prefix, p->pid, p->comm);
730 +#endif
731 break;
732
733 case PID_LOG_CMDLINE:
734 +#ifdef __FreeBSD__
735 + error("Cannot fetch process %d command line (command '%s')", p->pid, p->comm);
736 +#else
737 error("Cannot process %s/proc/%d/cmdline (command '%s')", netdata_configured_host_prefix, p->pid, p->comm);
738 +#endif
739 break;
740
741 case PID_LOG_FDS:
742 +#ifdef __FreeBSD__
743 + error("Cannot fetch process %d files (command '%s')", p->pid, p->comm);
744 +#else
745 error("Cannot process entries in %s/proc/%d/fd (command '%s')", netdata_configured_host_prefix, p->pid, p->comm);
746 +#endif
747 break;
748
749 case PID_LOG_STAT: