我正在努力在运行 Amazon Linux 的 Amazon EC2 服务器上安装 darkstat。有什么建议吗?

我正在努力在运行 Amazon Linux 的 Amazon EC2 服务器上安装 darkstat。有什么建议吗?

您好,提前感谢您阅读这个问题。免责声明:在管理服务器方面,我还是个新手。我正在运行一个 Amazon EC2 服务器(运行 Amazon Linux),我正在尝试安装 darkstat(一个流量监视器 -https://unix4lyfe.org/darkstat) 但遇到了困难。

不幸的是,sudo yum install darkstat不起作用(显然 darkstat 不是 Amazon 存储库的一部分)。我尝试按照以下步骤手动安装 darkstat(这是 darkstat 网站上推荐的):

  • 首先,我安装了先决条件:

    sudo yum groupinstall "Development Tools"
    sudo yum install libpcap-devel
    
  • 然后我开始安装darkstat:

    cd /usr/src (which could be the wrong location for all I know)
    wget https://unix4lyfe.org/darkstat/darkstat-3.0.719.tar.bz2
    tar xjvf darkstat-3.0.719.tar.bz2
    cd darkstat-3.0.719
    ./configure
    make
    

根据 darkset 指南,此时我应该能够输入“darkstat -i eth0”(当然不带引号),然后魔法就开始了。不幸的是,我收到了一条可怕的“bash: darkstat: 未找到命令”消息,这表明 darkstat 安装失败。

知道我在尝试安装时哪里出错了吗?我在安装过程中没有发现任何明显的错误 - 这是安装日志,以防它有用。再次感谢您查看这个问题,如果您有任何建议,我将不胜感激:

[root@ip-xx-xx-xx-xx darkstat-3.0.719]# ./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for C/C++ restrict keyword... __restrict
checking if we want debug code... sure
checking if your C compiler wants a hit off the pipe... sure does
checking if your C compiler has a link-time optimizer... sure does
checking for deflate in -lz... yes
checking for library containing gethostbyname... none required
checking for library containing socket... none required
checking for library containing hstrerror... none required
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking sys/filio.h usability... no
checking sys/filio.h presence... no
checking for sys/filio.h... no
checking for library containing getifaddrs... none required
checking ifaddrs.h usability... yes
checking ifaddrs.h presence... yes
checking for ifaddrs.h... yes
checking sys/sockio.h usability... no
checking sys/sockio.h presence... no
checking for sys/sockio.h... no
checking for pcap_loop in -lpcap... yes
checking pcap.h usability... yes
checking pcap.h presence... yes
checking for pcap.h... yes
checking for library containing setproctitle... no
checking for library containing strlcpy... no
checking for library containing strlcat... no
checking bsd/string.h usability... no
checking bsd/string.h presence... no
checking for bsd/string.h... no
checking bsd/unistd.h usability... no
checking bsd/unistd.h presence... no
checking for bsd/unistd.h... no
checking for library containing clock_gettime... none required
configure: creating ./config.status
config.status: creating Makefile
config.status: creating darkstat.8
config.status: creating config.h
config.status: config.h is unchanged
[root@ip-xx-xx-xx-xx darkstat-3.0.719]#

相关内容