Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What are the interview questions for Linux?

2025-02-27 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)05/31 Report--

This article mainly introduces the relevant knowledge of the Linux interview questions, the content is detailed and easy to understand, the operation is simple and fast, and it has a certain reference value. I believe you will gain something after reading this Linux interview questions. Let's take a look at it.

1. Write out the most technical working language technical process in previous work.

2. What should a mysql database server with high load during the day do on a regular basis? How to do it?

3. It is difficult to record a large number of remote linux users' passwords. Is there a way to log in to these servers safely and quickly? If there is a remote server that needs a password change, what should I pay attention to?

Trust relationship ~ or add an authentication server

I use except plus small database = myself. =

Because there are a large number of machines

And the password is not unique.

4. There is a linux server An in the company and a linux server B on internet. The remote office has a linux host C behind NAT. How to use the port forwarding function of OPENSSH to log in from C to B

5. What is the first thing you need to do when modifying any linux configuration file?

6. A web server with redhat installed by default runs for a period of time and is unstable at the beginning. Please find out the ultimate cause of the instability and list the possible causes.

7. Which SSH tools do you like best, and briefly describe which functions you appreciate most

8. How to change the hostname to wanmei without restarting the linux system?

# hostname wanmei

/ etc/sysconfig/network

Hostname=wanmei

/ etc/hosts

9. What is MBR? What's the use? How to back up on the linux system?

MBR is the abbreviation of English Master Boot Record, which means the main boot record in Chinese.

The first sector of track 0 of the hard disk is called MBR, which is 512 bytes in size, and this area can be divided into two parts. The first part is the pre- boot area (pre-startup area), accounting for 446 bytes; the second part is the Partition table section (partition table), which is equivalent to a Mini Program, which is used to determine which partition is marked as the active partition, then to read the startup area of that partition and run the code in that area.

10. How do I make a NFS service run in 5 open mode and turn off in other modes?

/ sbin/chkconfig-- level 5 NFS ON

What is the name of the service that records LOG?

Syslogd

12. How to change the current terminal character set to zh_CN_UTF8?

Export LANG=zh_CN.UTF-8

Vi / etc/sysconfig/i18n

LANG= "zh_CN.UTF8"

13. How to modify the system time to May 9, 1985 and list the specific orders?

Date-s 05Universe 09Universe 1985

14. What does it mean that the following services are related to those services?

5 * ping-C 100 wangm.com > / root/log > 2 > & 1

The 5th minute of every hour automatically pingwangm.com100 this bar result log to / root/log error log standard output.

15. How to view the current login user and guide yourself to use the login name?

W 、 who/ id logname

16, the current system does not have any editor, how to filter comment lines and blank lines. View / etc/ssh/ssh_config file?

Cat / etc/ssh/ssh_config | grep-v'#'| sed / ^ $/ d

17. How do I delete\ a files in the current directory?

There are two partitions, sda2 and sda3 (both of which have been used and not hung on), and sda2 is made into a swap partition. Sda3 is made into a NFS file system and hung on / tmp/sda3. Please write down the steps.

19. How do I view all the information about the operation of the system (CPU, MEM, PCI, network, disk space, IO, etc.) to list the detailed commands?

Cat / proc/cpuinfo vmstat 1 vmstat 1----CPU

MEM

# / usr/bin/time-v date

# / usr/bin/time-v evolution

# cat / proc/meminfo

I/O

# iostat-x 1

# iostat-d 5-P

NET

# ethtool eth0

# iptraf-d eth0

View sock connection status

# netstat-npt | awk'{if ($6 = "Foreign" & & $6 = "") arr [$6] +;} END {for (i in arr [I];}') | sort-rn-K2

# ss | awk'{if ($1 = "State") arr [$1] +;} END {for (i in arr) print I "\ t" arr [I];}'| sort-rn-K2

1. View CPU information

$cat / proc/cpuinfo

two。 View memory information

$cat / proc/meminfo

View memory size

$grep MemTotal / proc/meminfo

3. View all PCI Devic

$/ sbin/lspci

4. View all usb devices

$/ sbin/lsusb

5 display all loaded modules in the system

$/ sbin/lsmod

6. Show current memory usage

$free-m

7. Check the usage of each partition of the system (used space, available space, etc.)

$df-h

8. View the partition and file system format of the disk (root permission is required)

Fdisk-l

9. Check the CPU utilization rate, idle rate and the resource utilization of each process, such as CPU, memory, IO, etc.

$top

10. Another way to check the CPU utilization and idle rate in the system.

$vmstat 5 # 5 seconds refresh

11. Check the running time and load of the system

$uptime

twelve。 View IDE hard disk parameters

Hdparm / dev/hda # requires root permission

13. View information such as network interface and IP address

$/ sbin/ifconfig

14. View Nic setting information (Nic speed, connection status, etc.)

$/ sbin/ethtool eth0 # you can check whether the network cable is connected

15. View network connection information

Netstat-an

16. View routing information

$route-n

17. View firewall settings

$iptables-L

18. View the current login user and login time

$w

19. View logged-in user history

$last

20. View hostname

$hostname

21. View kernel version information

$uname-a

Check the number of local port connections

Ss | awk'{print $4}'| grep "`hostname-i`: 80" | wc-l

This is the end of the article on "what are the interview questions for Linux". Thank you for your reading. I believe you all have a certain understanding of the knowledge of "what are the interview questions of Linux". If you want to learn more knowledge, you are welcome to follow the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report