In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces "the common shortcut key function of the Linux top command". In the daily operation, I believe that many people have doubts about the common shortcut key function of the Linux top command. The editor consulted all kinds of materials and sorted out the simple and easy-to-use operation methods. I hope it will be helpful to answer the doubts of "the common shortcut key function of the Linux top command". Next, please follow the editor to study!
1. Default output of top command
In this case, it will display information such as tasks, memory, cpu, and swapping. Press Q to exit the window.
Top
two。 Use the `top` command to sort shortcut keys
Sort with O (capital "O")
Sort the fields by (Shift+O) by field letters, such as PID (process ID) by a letter.
Type any key to return to the main top window, and the PID order is shown in the following figure. Press Q to exit the window.
3. Show user-specific process shortcuts
Using the top command with the u option will show the details of the user's process.
Top-uroot
4. Highlight the shortcut key for the running process
Pressing the z option when running the top command displays the color of the running process, which may make it easier for you to identify the running process.
5. Keyboard shortcuts that display the absolute path of the process
Pressing the c option while running the top command will display the absolute path of the running process.
6. Modify the delay of `top` or set the shortcut key for screen refresh interval
The default screen refresh interval is 3.0 seconds, which can also be changed by pressing the d option while running the top command, as shown in the following figure.
7. Use the parameter `k` to terminate the shortcut key of a running process
You can check the PID of the process by pressing k while running the top command without having to exit from the top window, as shown below.
8. Keyboard shortcuts sorted by CPU usage
Sort processes by (Shift+P) by CPU utilization. See the screenshot below.
9. Shortcut keys for Renice process
You can use the r option to change the priority of the process (also known as Renice).
10. Keyboard shortcuts to save the results of the `top` command
To save the result output of the running top command to the file / root/. Toprc uses the following command.
Top-n1-b > top-output.txt
11. Get the shortcut key for the help of the `top` command
Press the h option to get top command help.
twelve。 A shortcut to exit the `top` command after a specific repetition
The top output remains refreshed until you press Q. With the following command, the top command will automatically exit after repeating 10 times.
Top-n10 at this point, on the "Linux top command of the common shortcut key function" study is over, I hope to be able to solve everyone's doubts. The collocation of theory and practice can better help you learn, go and try it! If you want to continue to learn more related knowledge, please continue to follow the website, the editor will continue to work hard to bring you more practical articles!
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.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.