以LINUX REDHAT6.3为例:
本机插入 REDHAT6.3系统ISO镜像CD1
1.配置yum本地安装源:
以root用户登录系统
mkdir /mnt/cdrom
mount -t iso9660 /dev/sr0 /mnt/cdrom
cd /etc/yum.repos.d
查看目录是否有.repo后缀文件,没有则创建一个.repo文件,文件名随意。
vi local.repo
[LOCAL]
name=local
baseurl=file:///mnt/cdrom
enable=1
gpgcheck=0
yum clean all
2.安装nmap,并测试172.24.40.5是否开放80端口
[root@openlab named]# yum install nmap Loaded plugins: rhnplugin Repository 'LOCAL' is missing name in configuration, using id This system is not registered with RHN. RHN support will be disabled. Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package nmap.i686 2:5.21-3.el6 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: nmap i686 2:5.21-3.el6 LOCAL 2.2 M Transaction Summary ================================================================================ Install 1 Package(s) Upgrade 0 Package(s) Total download size: 2.2 M Installed size: 7.2 M Is this ok [y/N]: y Downloading Packages: Running rpm_check_debug Running Transaction Test Transaction Test Succeeded Running Transaction Installing : 2:nmap-5.21-3.el6.i686 1/1 Installed: nmap.i686 2:5.21-3.el6 Complete!
[root@openlab named]# nmap -p 80 172.24.40.5 Starting Nmap 5.21 ( http://nmap.org ) at 2013-01-09 17:00 CST mass_dns: warning: Unable to determine any DNS servers. Reverse DNS is disabled. Try using --system-dns or specify valid servers with --dns-servers Nmap scan report for 172.24.40.5 Host is up (0.00034s latency). PORT STATE SERVICE 80/tcp open http MAC Address: 00:0C:29:4E:7D:FE (VMware) Nmap done: 1 IP address (1 host up) scanned in 0.07 seconds
nmap -p 1-200 目标主机 IP
#1-200为端口范围
本文出自 “一路向北” 博客,请务必保留此出处http://showerlee.blog.51cto.com/2047005/1119506
查看本栏目更多精彩内容:http://www.bianceng.cnhttp://www.bianceng.cn/OS/Linux/
以上是小编为您精心准备的的内容,在的博客、问答、公众号、人物、课程等栏目也有的相关内容,欢迎继续使用右上角搜索按钮进行搜索http
, package
, 端口
, nmap
, transaction
, running
求教Nmap
linux启动端口命令、linux开放端口命令、linux查看端口命令、linux 打开端口命令、linux 监听端口命令,以便于您获取更多的相关知识。