Manage processes and set up scheduled tasks

Source: Internet
Author: User

Case study: Managing processes and setting up scheduled tasks

Requirements: Managing processes in the system

Set up system administration tasks for scheduled runs

Steps:

1 process in the management system

Start the Portmap service in the system, confirm the service running status, and view the process information of portmap through the PS or PGREP command

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image002 "border=" 0 "alt=" clip_image002 "src=" http://s3.51cto.com/wyfs02/M01/77/8D/ Wkiom1zpgp6qy9qzaaamvldc580660.jpg "" 244 "height="/>

Ps: View static process Statistics, a: Displays all process information under the current terminal, U: output process information in a user-oriented format, x: Displays process information for the current user under all terminals,-e: Displays all process information in the system,-L: Displays process information in long format,-F: Displaying process information in full format

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image004 "border=" 0 "alt=" clip_image004 "src=" http://s3.51cto.com/wyfs02/M00/77/8B/ Wkiol1zpgqdhyxahaaadinbqzba935.jpg "" 244 "height="/>

Ps–elf: Displays all process information in the system in a long format

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image006 "border=" 0 "alt=" clip_image006 "src=" http://s3.51cto.com/wyfs02/M01/77/8D/ Wkiom1zpgqba_yffaaahxhdlmj4309.jpg "" 244 "height="/>

Ps aux: All process information will be displayed as a simple list

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image007 "border=" 0 "alt=" clip_image007 "src=" http://s3.51cto.com/wyfs02/M02/77/8D/ Wkiom1zpgqatkaczaaagiw8dr2o007.jpg "" 244 "height="/>

Execute the "cpuburn-in 10" command from another terminal, perform a 10-minute high load test, look for a higher CPU utilization PID number, and terminate its operation

Mount will/dev/cdrom in the/media/directory of the Mount Road

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image009 "border=" 0 "alt=" clip_image009 "src=" http://s3.51cto.com/wyfs02/M01/77/8B/ Wkiol1zpgqfccb6baaai65n8c3g886.jpg "" 244 "height="/>

CD switch/media/directory, ls list displays directory contents

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image010 "border=" 0 "alt=" clip_image010 "src=" http://s3.51cto.com/wyfs02/M02/77/8B/ Wkiol1zpgqitdgqjaaac2q1l6i0236.jpg "" 244 "height="/>

Unzip the Cpuburn-in CPU test tool and release it to the/opt/directory

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image012 "border=" 0 "alt=" clip_image012 "src=" http://s3.51cto.com/wyfs02/M00/77/8C/ Wkiol1zpgqjsistkaaaiuowy_x4074.jpg "" 244 "height="/>

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image014 "border=" 0 "alt=" clip_image014 "src=" http://s3.51cto.com/wyfs02/M00/77/8D/ Wkiom1zpgqmhjxkyaaacxjo-zz4609.jpg "" 244 "height="/>

The pgrep command can specify a part of the process name for querying, and the-l option queries the process running at a specific terminal

-u: Option to query a specific user's process,-t: Option to query a process running at a specific terminal

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image016 "border=" 0 "alt=" clip_image016 "src=" http://s3.51cto.com/wyfs02/M00/77/8C/ Wkiol1zpgqrjo8ptaaaj_6prny4028.jpg "" 244 "height="/>

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image018 "border=" 0 "alt=" clip_image018 "src=" http://s3.51cto.com/wyfs02/M00/77/8D/ Wkiom1zpgqrzuh3daaaioxtugok169.jpg "" 244 "height="/>

Pstree: View the Process tree (-the name of the process is displayed by default)-A option to list the complete command information-u: can list the corresponding user name,-p: can be used to list the corresponding ID number

PSTREE–AUP: command to view the process tree of the current system

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image020 "border=" 0 "alt=" clip_image020 "src=" http://s3.51cto.com/wyfs02/M01/77/8C/ Wkiol1zpgqrrjyx3aaai0jcihg4108.jpg "" 244 "height="/>

Using the KILL command to terminate a process requires a PID process number as a parameter

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image022 "border=" 0 "alt=" clip_image022 "src=" http://s3.51cto.com/wyfs02/M01/77/8D/ Wkiom1zpgq7gmbduaaalfdig5km141.jpg "" 244 "height="/>

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image024 "border=" 0 "alt=" clip_image024 "src=" http://s3.51cto.com/wyfs02/M00/77/8C/ Wkiol1zpgq-wvefpaaaj7nz5qim218.jpg "" 244 "height="/>

2 Set up system administration tasks for scheduled runs

Confirm Start Crond system service

Perform "Crontab–e" to set up scheduled tasks based on requirements

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image026 "border=" 0 "alt=" clip_image026 "src=" http://s3.51cto.com/wyfs02/M02/77/8C/ Wkiol1zpgq_sn0icaaahmpyrhp4147.jpg "" 244 "height="/>

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; margin:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image028 "border=" 0 "alt=" clip_image028 "src=" http://s3.51cto.com/wyfs02/M01/77/8C/ Wkiol1zpgrciccpsaaalw0ikcsg884.jpg "" 244 "height="/>

Perform "crontab-l" to see a list of scheduled tasks for all settings

650) this.width=650; "Style=" background-image:none; border-bottom:0px; border-left:0px; padding-left:0px; padding-right:0px; border-top:0px; border-right:0px; padding-top:0px "title=" clip_image030 "border=" 0 "alt=" clip_image030 "src=" http://s3.51cto.com/wyfs02/M00/77/8C/ Wkiol1zpgrdakrlzaaaoeciker8063.jpg "" 244 "height="/>

Manage processes and set up scheduled tasks

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.