Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 678500 - app-admin/restart-services-0.14.1 always restarts fail2ban
Summary: app-admin/restart-services-0.14.1 always restarts fail2ban
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Marc Schiffbauer
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-02-21 15:24 UTC by Matthias Vill
Modified: 2019-02-24 12:03 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Matthias Vill 2019-02-21 15:24:24 UTC
Hi,

this is probably similar to #648356.

I am currently unaware why, but in my fail2ban configuration it will always reference a deleted file in /tmp.

I tried to gather some useful information for you:

# restart-services -ld
debug: loading config file: /etc/restart-services.conf
debug: loading config file: /etc/restart-services.d/00-local.conf
-> Searching for services that need to be restarted ...  debug: analyzing lib_users output ...
debug: checking pid 7063
debug: lu_pid set to its ppid: 7063
debug: process root is /
debug: direct hit: found /etc/init.d/fail2ban for /usr/bin/python3.6m (7063)
debug: adding to INIT_SCRIPTS: /etc/init.d/fail2ban
debug: adding to KNOWN_PROCESSES: /usr/bin/python3.6m
debug: analyzing remaining processes (not direct hits) ...
debug: TODO_PROCESSES_EXE:                                                                                                                                                                                                                                                     done
=> Found 1 services that need to be restarted or reloaded
=-> unclassified services (1): fail2ban
=> Found 0 inittab processes that need to be restarted
debug: looking for false positives in unknown processes

# restart-services --version
restart-services 0.14.1
Copyright 2014-2018 by Marc Schiffbauer <mschiff@gentoo.org>

# lsof +L1 | grep fail2ban
fail2ban-  7063   root    7u   REG    8,2     4096     0 38797473 /tmp/#38797473 (deleted)

# lib_users -m | grep fail2ban
7063;/tmp/#38797473;/usr/bin/python3.6 /usr/bin/fail2ban-server --async -b -s /run/fail2ban/fail2ban.sock -p /run/fail2ban/fail2ban.pid --loglevel INFO --logtarget /var/log/fail2ban.log --syslogsocket auto

I would really like a way to exclude /tmp/#* as an indicator to restart fail2ban.

Best regards

Matthias
Comment 1 Marc Schiffbauer gentoo-dev 2019-02-22 17:24:09 UTC
Thanks you for your report.

I will have to think about that a bit. Maybe we should always exclude /tmp
Or I will add another config option where you can define paths that should always be excluded.
Comment 2 Marc Schiffbauer gentoo-dev 2019-02-22 19:05:21 UTC
should be fixed in 0.14.3 ;)
Comment 3 Matthias Vill 2019-02-24 10:49:56 UTC
Seems fixed, but you removed the only/latest stable version 0.14.1 from portage tree.
Comment 4 Marc Schiffbauer gentoo-dev 2019-02-24 12:03:57 UTC
Thanks, recovered :-/