nbtstat -a ip 命令查主机名

在网上查到的,用nbtstat -a 命令,实验成功:

C:Documents and Settingszxh.ZXH-CYZZ>nbtstat -a 192.168.1.7

本地连接:
Node IpAddress: <192.168.1.7> Scope Id: <>

           NetBIOS Remote Machine Name Table

       Name               Type         Status
    ---------------------------------------------
    SERVER       <00> UNIQUE      Registered
    SERVER       <20> UNIQUE      Registered
    CY           <00> GROUP       Registered
    CY          <1E> GROUP       Registered
    CY          <1D> UNIQUE      Registered
    ..__MSBROWSE__.<01> GROUP       Registered

    MAC Address = 00-1C-C4-43-9D-CC

查到IP为192.168.1.7的机器名为“server”,隶属工作组“CY”及其MAC地址。

该命令详细内容如下

Displays protocol statistics and current TCP/IP connections using NBT
(NetBIOS over TCP/IP).

(显示协议统计和当前TCP/IP连接使用的NBT)

NBTSTAT < <-a RemoteName> <-A IP address> <-c> <-n>
        <-r> <-R> <-RR> <-s> <-S> >

-a   (adapter status) Lists the remote machine's name table given its name

通过给出的机器名列出远程机器的名字表
-A   (Adapter status) Lists the remote machine's name table given its
                        IP address.

通过给出的IP地址列出远程机器的名字表
-c   (cache)          Lists NBT's cache of remote names and their IP addresses

列出NBT缓存中远程机器的名字机器IP地址
-n   (names)          Lists local NetBIOS names.

列出本机NetBIOS名字
-r   (resolved)       Lists names resolved by broadcast and via WINS
-R   (Reload)         Purges and reloads the remote cache name table
-S   (Sessions)       Lists sessions table with the destination IP addresses
-s   (sessions)       Lists sessions table converting destination IP
                        addresses to computer NETBIOS names.
-RR (ReleaseRefresh) Sends Name Release packets to WINS and then, starts Refresh

RemoteName   Remote host machine name.
IP address   Dotted decimal representation of the IP address.
interval     Redisplays selected statistics, pausing interval seconds
               between each display. Press Ctrl+C to stop redisplaying
               statistics.

  只有当网际协议 (TCP/IP) 协议在 网络连接中安装为网络适配器属性的组件时,该命令才可用。
  范例
  要想显示以太网统计信息和所有协议的统计信息,请键入下列命令:

  netstat -e -s

  要想仅显示 TCP 和 UDP 协议的统计信息,请键入下列命令:

  netstat -s -p tcp udp

  要想每 5 秒钟显示一次活动的 TCP 连接和进程 ID,请键入下列命令:

  nbtstat -o 5

     要想以数字形式显示活动的 TCP 连接和进程 ID,请键入下列命令:

      nbtstat -n -o

  • 0
    点赞
  • 5
    收藏
    觉得还不错? 一键收藏
  • 5
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 5
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值