Psad not working on Debian stretch
Doemela opened this issue · 5 comments
When I do
wget http://cipherdyne.org/psad/download/psad-2.4.6.tar.gz
and install it I get:
`root@cyberguerrilla ~/sources/psad/psad-2.4.6 # ./install.pl
[+] mkdir /var/log/psad, 700
[+] Thu Oct 4 18:10:49 2018 Installing psad on hostname: cyberguerrilla.org
[+] Creating /var/run/psad
[+] mkdir /var/run/psad, 700
[+] Creating /var/lib/psad
[+] mkdir /var/lib/psad, 700
[+] Creating /etc/psad
[+] mkdir /etc/psad, 700
[+] Creating /etc/psad/archive
[+] mkdir /etc/psad/archive, 700
[+] Creating /usr/lib/psad
[+] mkdir /usr/lib/psad, 755
[+] Creating /var/log/psad/fwdata file
[*] Could not chmod(493, /usr/bin/whois_psad): No such file or directory at ./install.pl line 1825.
`
If I install it with the github here it installs but when I start I get:
`root@cyberguerrilla ~/sources/psad/psad-git # systemctl status psad.service
● psad.service - The Port Scan Attack Detector (psad)
Loaded: loaded (/lib/systemd/system/psad.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Thu 2018-10-04 18:32:33 CEST; 13min ago
Docs: man:psad(8)
https://www.cipherdyne.org/psad/
Main PID: 1872 (code=killed, signal=TERM)
Oct 04 18:32:33 cyberguerrilla.org systemd[1]: Starting The Port Scan Attack Detector (psad)...
Oct 04 18:32:33 cyberguerrilla.org psad[3129]: Can't load '/usr/lib/psad/x86_64-linux-gnu-thread-multi/auto/Date/Calc/Calc.so' for module Date::Calc:
Oct 04 18:32:33 cyberguerrilla.org psad[3129]: Compilation failed in require at /usr/sbin/psad line 3269.
Oct 04 18:32:33 cyberguerrilla.org systemd[1]: psad.service: Control process exited, code=exited status=2
Oct 04 18:32:33 cyberguerrilla.org systemd[1]: Failed to start The Port Scan Attack Detector (psad).
Oct 04 18:32:33 cyberguerrilla.org systemd[1]: psad.service: Unit entered failed state.
Oct 04 18:32:33 cyberguerrilla.org systemd[1]: psad.service: Failed with result 'exit-code'.
`
Perl version v5.24.1
Operating system | Debian Linux 9
Kernel and CPU | Linux 4.9.0-8-amd64 on x86_64
ip6tables v1.6.0 | iptables v1.6.0
psad v2.4.6
In git master, I have updated the whois client so hopefully the whois issue is solved. For the Date::Calc issue, can you try installing libdate-calc-perl from the Debian package tree? By default, the psad installer only installs perl modules that don't appear to be available already on the system. So, if you are ok with re-running the installer, just '# rm -rf /usr/lib/psad' first and then run the installer, but after you have '# apt-get install libdate-calc-perl'. I believe this should fix the issue.
Had already the libdate-calc-perl think the '# rm -rf /usr/lib/psad' did the trick it is working now. Ty
Great, thanks for letting me know.
I had the same problem. I tried installing libdate-calc-perl, but it didn't seem to help. What fixed it for me was to create the missing directory: mkdir /usr/bin/whois_psad
*edit - then I had errors with permissions. I ended up installing using apt install psad.
Trying to install PSAD 2.4.6 on Ubuntu 20.04 i tried the above solutions and it takes me past the whos_psad directory but now I get stuck at the following line:
[*] Could not copy psadwatchd -> /usr/sbin/psadwatchd: No such file or directory at ./install.pl line 516.