marsadm: automatically delete deprecated conncetion messages

This commit is contained in:
Thomas Schoebel-Theuer 2017-11-30 13:23:07 +01:00 committed by Thomas Schoebel-Theuer
parent cb8806d060
commit 3a87569bbe
1 changed files with 5 additions and 0 deletions

View File

@ -2450,6 +2450,11 @@ sub logdelete_res {
unlink($leftlink);
}
foreach my $leftlink (glob("$mars/{,resource-$res/}actual-*/msg-*")) {
if ($leftlink =~ m:/msg-conncetion-from-:) {
lprint " unlink deprecated '$leftlink'\n" if $verbose;
unlink($leftlink);
next;
}
my $stamp = get_link_stamp($leftlink);
next unless $stamp + 3600 * 4 < $start_time;
lprint " unlink '$leftlink'\n" if $verbose;