为配合上级部门的检查,Linux机器下都要安装非法信息监控软件,现记录如下:
第一步:从网站上下载安装包,不幸的是提供的是rar,我只好将其转成zip格式,然后上传的服务器。
[root@s170 ~]# mkdir install
[root@s170 ~]# cd install
[root@s170 install]# ls
上传文件。
[root@s170 install]# ls
linux3.0.zip
第二步:解压安装
[root@s170 install]# unzip linux3.0.zip
Archive: linux3.0.zip
creating: Linux3.0/
creating: Linux3.0/bin/
creating: Linux3.0/bin/libc.so.5/
creating: Linux3.0/bin/libc.so.5/32/
inflating: Linux3.0/bin/libc.so.5/32/sitemanager
inflating: Linux3.0/bin/libc.so.5/32/stUpdate
inflating: Linux3.0/bin/libc.so.5/32/Transfer
creating: Linux3.0/bin/libc.so.5/64/
creating: Linux3.0/bin/libc.so.6/
creating: Linux3.0/bin/libc.so.6/32/
creating: Linux3.0/bin/libc.so.6/32/libstdc++.so.6/
inflating: Linux3.0/bin/libc.so.6/32/libstdc++.so.6/sitemanager
inflating: Linux3.0/bin/libc.so.6/32/libstdc++.so.6/stUpdate
inflating: Linux3.0/bin/libc.so.6/32/libstdc++.so.6/Transfer
creating: Linux3.0/bin/libc.so.6/32/libstdc++.so.other/
inflating: Linux3.0/bin/libc.so.6/32/libstdc++.so.other/sitemanager
inflating: Linux3.0/bin/libc.so.6/32/libstdc++.so.other/stUpdate
inflating: Linux3.0/bin/libc.so.6/32/libstdc++.so.other/Transfer
creating: Linux3.0/bin/libc.so.6/64/
creating: Linux3.0/bin/libc.so.6/64/.svn/
inflating: Linux3.0/bin/libc.so.6/64/.svn/all-wcprops
inflating: Linux3.0/bin/libc.so.6/64/.svn/entries
creating: Linux3.0/bin/libc.so.6/64/.svn/prop-base/
inflating: Linux3.0/bin/libc.so.6/64/.svn/prop-base/sitemanager.svn-base
inflating: Linux3.0/bin/libc.so.6/64/.svn/prop-base/stUpdate.svn-base
inflating: Linux3.0/bin/libc.so.6/64/.svn/prop-base/Transfer.svn-base
creating: Linux3.0/bin/libc.so.6/64/.svn/props/
creating: Linux3.0/bin/libc.so.6/64/.svn/text-base/
inflating: Linux3.0/bin/libc.so.6/64/.svn/text-base/sitemanager.svn-base
inflating: Linux3.0/bin/libc.so.6/64/.svn/text-base/stUpdate.svn-base
inflating: Linux3.0/bin/libc.so.6/64/.svn/text-base/Transfer.svn-base
creating: Linux3.0/bin/libc.so.6/64/.svn/tmp/
creating: Linux3.0/bin/libc.so.6/64/.svn/tmp/prop-base/
creating: Linux3.0/bin/libc.so.6/64/.svn/tmp/props/
creating: Linux3.0/bin/libc.so.6/64/.svn/tmp/text-base/
inflating: Linux3.0/bin/libc.so.6/64/sitemanager
inflating: Linux3.0/bin/libc.so.6/64/stUpdate
inflating: Linux3.0/bin/libc.so.6/64/Transfer
inflating: Linux3.0/check.sh
inflating: Linux3.0/install.sh
inflating: Linux3.0/install.sh~
inflating: Linux3.0/README
creating: Linux3.0/Resources/
inflating: Linux3.0/Resources/Client.pri
inflating: Linux3.0/Resources/Client.pub
inflating: Linux3.0/Resources/DynamicData.dat
inflating: Linux3.0/Resources/gb2312.txt
inflating: Linux3.0/Resources/Server.pri
inflating: Linux3.0/Resources/Server.pub
inflating: Linux3.0/Resources/st-os-version.txt
creating: Linux3.0/Scripts/
inflating: Linux3.0/Scripts/install.sh
inflating: Linux3.0/Scripts/killall.sh
inflating: Linux3.0/Scripts/stsniffer
inflating: Linux3.0/Scripts/stupdate
inflating: Linux3.0/Scripts/suse_install.sh
inflating: Linux3.0/Scripts/ubuntu.local
inflating: Linux3.0/Scripts/ubuntu_install.sh
creating: Linux3.0/syslib/
creating: Linux3.0/syslib/32/
inflating: Linux3.0/syslib/32/libcrypto.so.4
inflating: Linux3.0/syslib/32/libssl.so.4
creating: Linux3.0/syslib/64/
inflating: Linux3.0/syslib/64/libcrypto.so.0
inflating: Linux3.0/syslib/64/libdl.so.2
inflating: Linux3.0/syslib/64/libssl.so.0
inflating: Linux3.0/syslib/64/libssl.so.6
inflating: Linux3.0/捆+便竿蚅inuxΦΕΖ桅-doc
[root@s170 install]# cd Linux3.0/
[root@s170 Linux3.0]# ls
bin check.sh install.sh install.sh~ README Resources Scripts syslib 捆+便竿?-蚅inuxΦΕΖ桅-?+?.doc
此处尝试了一下执行install.sh,发现没有权限。
[root@s170 Linux3.0]# chmod +x *.sh
[root@s170 Linux3.0]# ./install.sh
Usage: ./install.sh { install os_name | uninstall os_name | update os_name | SiteManager os_name | Transfer os_name }
Details:
install : install all of the packages of stsniffer
uninstall : uninstall all of the packages of stniffer
update : update the SiteManager application and Transfer application
sitemanager : re-install SiteManager only
transfer : re-install Transfer only
./install.sh: line 18: os_name:: command not found
[root@s170 Linux3.0]# ./check.sh
Linux version 2.6.18-308.el5PAE ([email protected]) (gcc version 4.1.2 20080704 (Red Hat 4.1.2-52)) #1 SMP Tue Feb 21 20:46:05 EST 2012
GNU C Library stable release version 2.5, by Roland McGrath et al.
[root@s170 Linux3.0]# cat check.sh
#! /bin/bash
more /proc/version
if [ $(getconf LONG_BIT) = 32 ]; then
/lib/libc.so.6 | head -1
else
/libi64/libc.so.6 | head -1
fi
似乎不是这样安装的,还是老老实实的看安装手册吧。找到了,如下:
[root@s170 Linux3.0]# ./install.sh install centos
./install.sh: line 45: /root/install/Linux3.0/Scripts/suse_install.sh: 权限不够
为什么就不打包成tar.gz格式呢?只好把目录及子目录中全部sh脚本全部改成可执行的。
[root@s170 Linux3.0]# find . -name "*.sh" | xargs chmod +x
[root@s170 Linux3.0]# ./install.sh install centos
installing package ....
/root/install/Linux3.0
Installing stsniffer application ....
config application to boot on system startup
/root/install/Linux3.0/Scripts/suse_install.sh: line 168: /etc/init.d/stsniffer: 权限不够
/root/install/Linux3.0/Scripts/suse_install.sh: line 169: /etc/init.d/stupdate: 权限不够
没办法,还是把所有文件都改成可执行的算了,真不知道有哪些文件该是可执行的。
[root@s170 Linux3.0]# find . | xargs chmod +x
[root@s170 Linux3.0]# ./install.sh install centos
remove pre-install SiteManager
begin to uninstall the sniffer software and update software.
/root/install/Linux3.0/Scripts/suse_install.sh: line 174: /etc/init.d/stsniffer: 权限不够
/root/install/Linux3.0/Scripts/suse_install.sh: line 175: /etc/init.d/stupdate: 权限不够
uninstall successfully.
installing package ....
/root/install/Linux3.0
Installing stsniffer application ....
the ssl library is already exists...
the crypto library is already exists...
config application to boot on system startup
Starting sitemanager and transfer: ok
Starting stUpdate:
应该是成功了。
第三步:确认是否安装好。按照文档来。
[root@s170 Linux3.0]# ps x | grep sitemanager
1330 ? Ssl 0:00 /usr/local/bin/sitemanager
1470 pts/2 S+ 0:00 grep sitemanager
[root@s170 Linux3.0]# ps x | grep Transfer
1358 ? Ss 0:00 /usr/local/bin/Transfer
1359 ? S 0:00 /usr/local/bin/Transfer
1360 ? S 0:00 /usr/local/bin/Transfer
1406 ? S 0:00 /usr/local/bin/Transfer
1505 pts/2 S+ 0:00 grep Transfer
[root@s170 Linux3.0]#
[root@s170 Linux3.0]#
[root@s170 Linux3.0]# tail -f /var/log/Transfer.log
tail: 无法打开 “/var/log/Transfer.log” 读取数据: 没有那个文件或目录
tail: no files remaining
[root@s170 Linux3.0]#
这个软件装起来还是有点费劲,主要提供的软件压缩包太不符合Linux的习惯了。