我今天尝试在我的 ubuntu 16.04 服务器上安装 fail2ban。它似乎安装正确。不幸的是,这个命令已经运行了 3 个多小时。
Creating/Updating SSL(for TLS) information
Creating /etc/mail/tls/starttls.m4...
Creating SSL certificates for sendmail.
这是我的第一个 AWS EC2 Ubuntu 盒子,所以所有这些技术对我来说都是非常新的。我不太确定如何处理这种情况。这是它在此之前发布到控制台的信息hanging
。
Setting up sendmail-bin (8.15.2-3) ...
Updating sendmail environment ...
Reading configuration from /etc/mail/sendmail.conf.
Validating configuration.
Writing configuration to /etc/mail/sendmail.conf.
Writing /etc/cron.d/sendmail.
Disabling HOST statistics file(/var/lib/sendmail/host_status).
Reading configuration from /etc/mail/sendmail.conf.
Validating configuration.
Writing configuration to /etc/mail/sendmail.conf.
Writing /etc/cron.d/sendmail.
Could not open /etc/mail/databases(No such file or directory), creating it.
Reading configuration from /etc/mail/sendmail.conf.
Validating configuration.
Creating /etc/mail/databases...
Checking filesystem, this may take some time - it will not hang!
... Done.
Checking for installed MDAs...
sasl2-bin not installed, not configuring sendmail support.
To enable sendmail SASL2 support at a later date, invoke "/usr/share/sendmail/update_auth"
我不太清楚这里该做什么,是停止 fail2ban 还是取消进程?就像我说的,这是我的第一个 ubuntu 盒子,所以任何帮助都会很感激。
谢谢。
答案1
乍一看,这看起来像是一个熵问题。虚拟机有时缺乏熵,请执行以下操作来检查:
cat /proc/sys/kernel/random/entropy_avail
如果非常低,您可以尝试:
apt-get install rng-tools
rngd -r /dev/urandom
然后再次检查,并尝试再次生成 ssl 证书。
如果不是这种情况,请安装 strace 并运行您尝试的命令;看看是什么挂了。