The Commands about the Processes
来源:互联网 发布:java 轻量分词 编辑:程序博客网 时间:2024/06/05 04:24
Here will introduce some commands about the Processes:
● ps – Report a snapshot of current processes
● top – Display tasks
● jobs – List active jobs
● bg – Place a job in the background
● fg – Place a job in the foreground
● kill – Send a signal to a process
● killall – Kill processes by name
● shutdown – Shutdown or reboot the system
How a process work
When a system starts up,the kernel initiates a few of its own activities as processes and launches a program init(/etc/init),and the init will start all system services, and many of them are implemented as daemon process(sit in background and just do their own things without having any user interface).
A program can launch other programs is expressed in the process scheme as a parent process producing a child process.
Each process has a PID,the init always getting PID 1.
ps
psps x ##will show all of our processes no matter which terminalps aux ##will give us more information about the CPU/MEM usage,virtual memory size and so on.
top
top will give us dynamic view of the machine’s activities.
top
Controlling processes
jobs will list the jobs that have been launched from our terminal and every job has a number.
if you want to change a process from background to foreground,using fg,like:
fg %num ##num is the number that the command of jobs shows
bg is similar
kill
kill is used to send signals to programs,the common pattern is like:
kill [-signal] PID
the signal introduces:
- 1:HUP,Hangup
- 2:INT,Interrupt,just like ctrl+c
- 9:KILL
- 15:TERM,Terminate
- 18:CONT,Continue
- 19:STOP
- The Commands about the Processes
- Detection of the hidden processes
- The Gaussian Processes Web Site
- Detection of the hidden processes
- The useful commands in linux
- The list of Vim commands
- The list of Vim commands
- Help of the linux commands
- The mkdir and rmdir commands
- The Opensource about SIP
- About the AOSA
- About the class Crgn
- About the Poem
- About the Copyright
- About the schedule
- The truth about schedules
- the books about java
- About the SMM rootkit
- ValueError: could not broadcast input array from shape (300,2,300,1) into shape (300,2,1,1)
- bison: m4: Invalid argument 玄学解决了
- 记录tomcat在Myeclipse中可能卡死的状态
- Androidstudio打包jar和arr包
- Android 在子线程中更新UI的几种方法
- The Commands about the Processes
- windows下安装redis
- initializer_list类型详解
- android jar包下载地址
- ajax提交两个表单到一个Controller,后台用两个对象接收
- 欢迎使用CSDN-markdown编辑器
- 【LeetCode】167. Two Sum II
- js 单页应用 css样式冲突
- Zookeeper集群配置