`
zqjshiyingxiong
  • 浏览: 441378 次
  • 性别: Icon_minigender_1
  • 来自: 无锡
社区版块
存档分类
最新评论

每日一搬(1):PROCESS AND JOB CONTROL

阅读更多

 

 

在linux里面,用户是已UID/GID来区分和分配资源的,那我们的程序(process)的执行,也同样会有PID;

 

这时我们就要了解PID的概念了:

 

PID是进程标识号,它是一个进程的唯一性标识。PPID是该进程父进程的进程标识号。

 

PROCESS & PROGRAM

 

      PID是怎么产生的了?每个用户登录后,根据他们的不同的UID/GID来产生他们各自的PID.

 

而这里又有父程序和子程序的概念,子程序是父程序的衍生,并且会不断的衍生下去。就是说子程序

 

还可以有子子程序……如果当一个程序死掉,或者不断的有程序运行,那么只要找到他们的父程序

 

并将它kill掉,就ok了。

 

linux是多人多任务的环境

 

     除了root,有至高无上的权限外,其他用户要受到限制,并且他们的PID都不相同。

 

多重登录环境:有七个基本的终端窗口(ALT + F1...F7),这也是为什么不会死机的原因,你可以穿梭在

 

不同的窗口,这个窗口死掉,可进入另一个窗口将其kill掉。

 

JOB CONTROL(以下是一些相关的命令)

 

& : 直接将任务掉到窗口后执行(cp /root /tmp  &)

 

bg (background): 将目前的工作中丢到背景中工作

 

fg (foreground): 将背景中的工作发到前台来工作 (fg %i)

 

ctrl + z :将目前的任务,丢到背景中(bg)

 

jobs:观察背景中工作的任务状态

 

kill : 管理背景中的工作

 

 

这里只是给大家介绍一下,有不对的地方请指出,希望大家和我分析宝贵的经验。

 

 

 

 

 

分享到:
评论

相关推荐

    centos7安装数据库MySQL启动报错Job for mysqld

    在 CentOS 7 操作系统中安装 MySQL 数据库时,可能会出现启动报错的现象,报错信息为 "Job for mysqld.service failed because the control process exited with error code"。这类错误的出现绝大部分是由于 my.cnf ...

    jobcontrol:作业调度与跟踪库

    作业控制 作业调度和跟踪库。 为“作业”的调度、运行、跟踪和检索结果提供基本接口。 每个作业定义都是任何 Python 可调用的,以及...git clone https://github.com/rshk/jobcontrol.git Python 包索引 该项目可以

    解决MySQL因不能创建 PID 导致无法启动的方法

    例如,在提供的日志中,可以看到“MySQL Daemon failed to start.”和“control process exited, code=exited status=1”,这表明MySQL服务启动时遇到了错误。 2. **检查PID文件**: PID文件通常位于MySQL的数据...

    csapp-shell-labcsapp-shell-labcsapp-shell-lab

    In this lab assignment, the primary objective is to deepen your understanding of process control and signaling by creating a simple Unix shell program that supports job control. The assignment is ...

    Agile.Application.Lifecycle.Management.Using.DevOps.epub

    Flexible and robust, Agile ALM offers “just enough process” to get the job done efficiently and utilizes the DevOps focus on communication and collaboration to enhance interactions among all ...

    PHP.and.Algorithmic.Thinking.for.the.Complete.Beginner.1503015

    Of course, if you are wondering whether this book is going to teach you how to create amazing websites or incredible applications, the answer is "no"—that is a job for other books. So many books out...

    Java - J2EE Job Interview Companion.pdf

    ### Java - J2EE Job Interview Companion: Key Knowledge Points on Log4j #### Introduction to Log4j Log4j is an open-source logging utility designed for Java applications. It provides a flexible and ...

    电子商务概论英文课件:ch03 Retailing in Electronic Commerce.ppt

    Online job boards, LinkedIn, and freelance marketplaces like Upwork facilitate the hiring process, providing benefits like wider reach and faster placement. However, limitations include potential ...

    Handbook of Data Center Management, 2nd Edition

    2 Update on Change Control and Problem Tracking Systems 3 Improving Productivity by Implementing a Tape Workstation 4 File Retention and Backup 5 Checklists for Reviewing MVS Data Center Controls. 6...

    Modern Operating Systems 3rd

    They cover a wide range of operations, including process management, file manipulation, and device control. 8. **Operating System Structure:** Different architectural models are discussed, including...

    操作系统作业管理练习及答案.doc

    1. 作业(Job):顾客规定计算机解决旳一种计算问题称为一种作业。 2. 作业步(Job Step):一种作业旳完毕要通过若干加工环节,这每个环节称为作业步。 3. 批解决(Batch Processing):操作系统提供旳一种作业...

    thinkphp Apache配置重启Apache1 restart 出错解决办法

    错误信息通常是:“Job for httpd.service failed because the control process exited with error code.”,并建议通过`systemctl status httpd.service`和`journalctl -xe`命令查看详细状态和日志。从给出的日志中...

    In-plan操作手册

    - 定义并运行Process Tree,这决定了电路板制造的具体工艺步骤,保存以备后续使用。 11. 添加额外工具: - 通过控制脚本control.bat添加或更新工具库,以满足特定的生产需求。 12. 审查与更新矩阵: - 更新...

    ICETOOL.PDF

    It covers the Job Control Language (JCL) and control statements extensively, providing numerous examples to demonstrate how to utilize ICETOOL effectively. #### Additional Sources for ICETOOL ...

    CommonsWare.The.Busy.Coders.Guide.to.Android.Development.Version.8.2.2017

    The Android platform gives developers a fair bit of control while still supporting a familiar programming language. However, the frameworks, GUI widgets, and development model is different than any ...

    AIX命令参考大全中文版,卷 5,s - u_Operate_aix_

    2. **Process and Job Control Commands (s-u)** - `ps`:显示当前系统中的进程状态,有助于理解系统的运行状况和进程间的相互关系。 - `kill`:发送信号给进程,用于终止或改变进程的状态。 - `nice`:调整进程...

Global site tag (gtag.js) - Google Analytics