【linux】常用技巧
26.如何快速切换到用户John的主目录下?
A. cd @John
B. cd #John
C. cd &John
D. cd ~John
答案:D
27.把一个流中所有字符转换成大写字符,可以使用下面哪个命令?
A. tr a-z A-Z
B. tac a-z A-Z
C.sed /a-z/A-Z
D. sed --toupper
答案:A
28.使用什么命令可以查看Linux的启动信息?
A. mesg -d
B. dmesg
C. cat /etc/mesg
D. cat /var/mesg
答案:B
37.如何在文件中查找显示所有以" * "打头的行?
A. find * file
B. wc -l * < file
C. grep -n * file
D. grep ‘^*’ file
答案:D
38.在ps命令中什么参数是用来显示所有用户的进程的?
A. a
B. b
C. u
D. x
答案:A
40.如何显示Linux系统中注册的用户数(包含系统用户)?
A. account -l
B. nl /etc/passwd |head
C. wc --users /etc/passwd
D. wc --lines /etc/passwd
答案:D
42.命令 kill 9 的含义是:
A. kills the process whose PID is 9.
B. kills all processes belonging to UID 9.
C. sends SIGKILL to the process whose PID is 9.
D. sends SIGTERM to the process whose PID IS 9.
答案:D
44.使用什么命令可以在今天午夜运行命令 cmd1 ?
A. at midnight cmd1
B. cron -at “00:00” cmd1
C. batch -t “00:00” < cmd1
D. echo “cmd1” | at midnight
答案:D
49.下面哪种写法表示如果cmd1成功执行,则执行cmd2命令?
A. cmd1&&cmd2
B. cmd1|cmd2
C. cmd1;cmd2
D. cmd1||cmd2
答案:A
51.Linux中,提供TCP/IP包过滤功能的软件叫什么?
A. rarp
B. route
C. iptables
D. filter
答案:C
60.在安装软件时下面哪一步需要root权限?
A. make
B. make deps
C. make config
D. make install
答案:D
61.什么命令用来只更新已经安装过的rpm软件包?
A. rpm -U * .rpm
B. rpm -F * .rpm
C. rpm -e * .rpm
D. rpm -q * .rpm
答案:B
63.ldconfig的配置文件是
A. /lib/ld.so
B. /etc/ld.so.conf
C. /etc/ld.so.cache
D. /etc/modules.conf
答案:B Idconfig是个啥?
64.下面哪个命令可以压缩部分文件:
A. tar -dzvf filename.tgz *
B. tar -tzvf filename.tgz *
C. tar -czvf filename.tgz *
D. tar -xzvf filename.tgz *
答案:C
65.网络服务的daemon是:
A. lpd
B. netd
C. httpd
D. inetd
答案:D
66.Linux与windows 的网上领居互联,需要提供什么daemon?
A. bind
B. smbd
C. nmbd
D. shard
答案:B smb service
71.在 Linux 中,如何关闭邮件提示?
A. biff n
B. mesg n
C. notify off
D. set notify=off
答案:A
72.在 bash shell 环境下,当一命令正在执行时,按下 control-Z 会:
A. 中止前台任务
B. 给当前文件加上 EOF.
C. 将前台任务转入后台
D. 注销当前用户
答案:C
74.下面哪条命令用来显示一个程序所使用的库文件?
A. ldd
B. ld so
C. modprobe
D. ldconfig
答案:B
78.什么命令解压缩tar文件?
A. tar -czvf filename.tgz
B. tar -xzvf filename.tgz
C. tar -tzvf filename.tgz
D. tar -dzvf filename.tgz
答案:B
84.命令 netstat -a 停了很长时间没有响应,这可能是哪里的问题?
A. NFS.
B. DNS.
C. NIS.
D. routing.
答案:B
85.ping使用的协议是:
A. TCP
B. UDP
C. SMB
D. ICMP
答案:D
89.下面哪个文件定义了网络服务的端口?
A. /etc/netport
B. /etc/services
C. /etc/server
D. /etc/netconf
答案:B
95.smbd and nmbddaemons 的配置文件是:
A. /etc/exports
B. /etc/smb.conf
C. /etc/samba/config
D. /usr/local/samba.cfg
答案:B
100.下面哪个命令可以查看网卡的中断?
A. cat /proc/ioports
B. cat /proc/interrupts
C. cat /proc/memoryinfo
D. which interrupts
答案:B