Skip to content

Commit

Permalink
added a caveat in 'serv.pm' and its doc about to have different logfi…
Browse files Browse the repository at this point in the history
…les when a service is defined multiple times
  • Loading branch information
mikaku committed Sep 28, 2023
1 parent 1a56eff commit bba651d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/serv.pm
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,11 @@ sub serv_update {
$sc[3] = "\".\"" unless $sc[3] ne "\"\""; # set "." as a minimal regex
my @regex = split('\+', $sc[3]);
my $IN;

# FIXME
# $seek_pos does not distinguish between different
# logfiles when a service is defined multiple times.

my $seek_pos = $config->{serv_hist}->{$seek_str} || 0;
if($logfile =~ m/^file:.+/) {
$logfile =~ s/^file://;
Expand Down
2 changes: 2 additions & 0 deletions man/man5/monitorix.conf.5
Original file line number Diff line number Diff line change
Expand Up @@ -3212,6 +3212,8 @@ You can create multiple definitions of the same service with different values, s
.RE
.P
You can define as much entries as you want.
.P
Caveat: it does not distinguish between different logfiles when a service is defined multiple times.
.RE
.P
.BI mode
Expand Down

0 comments on commit bba651d

Please sign in to comment.