📄 00000002.htm
字号:
<HTML><HEAD> <TITLE>BBS水木清华站∶精华区</TITLE></HEAD><BODY><CENTER><H1>BBS水木清华站∶精华区</H1></CENTER>作者: bbs.ee.ntu.edu.tw (连线精华区) <BR>标题: Linux 网路指令 <BR>时间: Sun Aug 10 11:07:41 1997 <BR> <BR>发信人: <A HREF="mailto:vc0328@tpts1.seed.net.tw">vc0328@tpts1.seed.net.tw</A> (Vincent Chen), 信区: Linux <BR> <BR>三、 网路指令示□ <BR> <BR> <BR> <BR>1. ping <BR> <BR> 用ping指令可以确认远端的主机是否处是可连线状态,同时 <BR> 也会计算出资料封包的平均传输时间,我们可以据此判断从 <BR> 该主机接收资料的速度。 <BR> <BR>bash# ping -c 10 vr386.orient.net.tw <BR>PING vr386.orient.net.tw (192.168.1.10): 56 data bytes <BR>64 bytes from 192.168.1.10: icmp_seq=0 ttl=255 time=3.3 ms <BR> . <BR> . <BR> . <BR>64 bytes from 192.168.1.10: icmp_seq=9 ttl=255 time=1.9 ms <BR> <BR>--- vr386.orient.net.tw ping statistics --- <BR>10 packets transmitted, 10 packets received, 0% packet loss <BR>round-trip min/avg/max = 1.9/2.0/3.3 ms <BR> <BR> <BR> <BR>2. finger <BR> <BR> 本指令可从主机端取得一些和使用者有关的资料,例如当您 <BR> 发一封信给其他人後,您可用finger指令看信件是否送达, <BR> 主机的输出会有一行No mail或Mail unread since xxxxx, <BR> 我们可据此判断。 <BR> <BR> 同时,使用者可在自已的目录内建立.plan和.project两个档 <BR> 案,主机会把这两个档案输出到查询端,作为简单的留言。 <BR> <BR> <BR>bash# finger <A HREF="mailto:vincent@vr386.orient.net.tw">vincent@vr386.orient.net.tw</A> <BR>[vr386.orient.net.tw] <BR> <BR>Welcome to Linux version 1.1.78 at vr386.orient.net.tw ! <BR> <BR> 5:44am up 1 day, 20:56, 0 users, load average: 0.16, 0.04, 0.01 <BR> <BR>Login: vincent Name: Vincent Chen <BR>Directory: /home/vincent Shell: /bin/bash <BR>Last login Sun Jan 29 05:33 ( ) on ttyp0 from vr486.orient.net.tw <BR>No Mail. <BR>Project: <BR> <BR>1. Will write some document about linux in chinese. <BR> <BR>2. Gopher server on another machine has some problem, <BR> will fix it later. <BR> <BR>Plan: <BR> <BR>Vincent Chen (<A HREF="mailto:vincent@vr386.orient.net.tw)">vincent@vr386.orient.net.tw)</A> <BR> <BR>Hi, <BR> <BR> I will be on vacation during 1/28~2/5. <BR> If you can't contact me, drop me some e-mail. <BR> <BR>Regards, vincent <BR> <BR> <BR> finger也可以针对主机作为查询的对象,这时候主机会回覆 <BR> 目前在线上的使用者,及一些主机的基本资料。 <BR> <BR> <BR>bash# finger @vr386 <BR>[vr386] <BR> <BR>Welcome to Linux version 1.1.78 at vr386.orient.net.tw ! <BR> <BR> 5:45am up 1 day, 20:57, 0 users, load average: 0.12, 0.03, 0.01 <BR> <BR>No one logged on. <BR> <BR>* 有些主机基於安全上的考虑,不允许外界作finger查询,因为 <BR> finger显示的个人资料可能会成为闯入者猜测密码的线索。 <BR> <BR> <BR> <BR>3. 由IP查主机名称 <BR> <BR> 这是以SLIP连上台大後,以IP查domain name的结果。由於您 <BR> 的linux并不是网路上已注册登记之主机,而且这个IP是由台 <BR> 大暂时供您使用,所以查询的结果是台大name server所回覆 <BR> 的主机名称。 <BR> <BR>bash# host 140.112.186.219 <BR>Name: DialIP219.cc.ntu.edu.tw <BR>Address: 140.112.186.219 <BR>Aliases: <BR> <BR> <BR> <BR>4. nslookup <BR> <BR> 常用指令: <BR> <BR> <host> - 查询<host>的IP <BR> <host> <server> - 向<server>查询<host>的IP <BR> help / ? - 指令说明 <BR> exit - 结束程式 <BR> ls <opt> domain - 列出和某一domain相关资料 <BR> -a - 查询主机别名(alias) <BR> -h - 查询主机OS及CPU <BR> -s - 查询所提供的服务 <BR> -d - 查询所有主机列表 <BR> -t - 查询所有相同型态主机(NS、MX..) <BR> <BR>bash# nslookup <BR>Default Server: NCTU.edu.tw <BR>Address: 140.113.1.1 <BR> <BR>><I> tpts1.seed.net.tw <- 查询单一主机 </I><BR>Server: NCTU.edu.tw <BR>Address: 140.113.1.1 <BR> <BR>Name: tpts1.seed.net.tw <BR>Address: 139.175.1.10 <BR> <BR>Default Server: vr486.orient.net.tw <BR>Address: 192.168.1.1 <BR> <BR>><I> ls -h orient.net.tw <- 查询整个子网路内的 </I><BR>[vr486.orient.net.tw] 主机硬体、作业系统 <BR> vr386 PC386/DX33 Linux <BR> vr486 PC486/SX33 Linux <BR>><I> ls -t NS orient.net.tw <- 查询整个子网路内的 </I><BR>[vr486.orient.net.tw] name server。 <BR> orient.net.tw. server = vr486.orient.net.tw <BR>><I> exit </I><BR> <BR> <BR> <BR>5. 以ftp作档案传输 <BR> <BR> 一般而言,ftp主机都接受ftp及anonymous这两个匿名帐号签 <BR> 入,而以e-mail address为密码,但是活动□围以Slackware <BR> 为例,限制在/home/ftp以下的目录。如果您在该主机有正式 <BR> 终端机帐号,可用该帐号进入,您会先在home directory下 <BR> ,但是活动□围可遍及整个系统,而档案的传输视您对该档 <BR> 的存取权限而定。 <BR> <BR> 常用指令: <BR> <BR> ? / help - 列出所有指令或取得指令说明 <BR> binary - 以二进位方式传输档案 <BR> bye - 结束连线并离开ftp程式 <BR> cd - 切换主机端目录 <BR>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -