Linux进程控制1

Linux进程控制1

Info icon This preview shows pages 1–11. Sign up to view the full content.

View Full Document Right Arrow Icon
    www.chinaeda.cn Linux 进进进进
Image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
www.chinaeda.cn 1 进进进进进进 1.1  进进 进进进 program 进进进进进进进进进进进进进进进进进 1.2  进进进进进 ID 进进进进进进进进进进进进 (process) 进进进进进进进进进进进进进进进进进进进进进进进进进进 进进进进进进进进进进进 进进 linux 进进进进进进进进进进进进进进进进进进进进进 ID process ID 进进 进进 ID 进进进进进进进进
Image of page 2
www.chinaeda.cn 1.3 linux 进进进进进进       Linux 进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进       linux 进进进进进 3 进进进进进进“进进进”进“进进进”进“进进进”进 进进进 进进进 进进进
Image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
www.chinaeda.cn “ 进进进”进进进进进进进进进进进进进进进进进进进进进 malloc 进进进进进进进进进 “ 进进进”进进进进进进进 “ 进进进”进进进进进进进进进进进进进进进进进进进进进进进进进进进
Image of page 4
www.chinaeda.cn 1.3 init 进进 进进 ID 进 1 进进进 init 进进进进进进进进进进进进进进进进进 init 进进进进进进进进 进进进进进进进进进进进 ( 进进进进进进进进进进进进进进进进进进进 ) 进进进进进进进进进进进进进进
Image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
www.chinaeda.cn 1.4  进进进进进进 #include <sys/types.h> #include <unistd.h> pid_t getpid(void);  进进进进进进进进进进 I D pid_t getppid(void);  进进进进进进进进进进进 I D uid_t getuid(void);  进进进进进进进进进进进进 I D uid_t geteuid(void);  进进进进进进进进进进进进 I D gid_t getgid(void);  进进进进进进进进进进进 I D gid_t getegid(void);  进进进进进进进进进进进 I D
Image of page 6
www.chinaeda.cn 1.5 fork 进进 #include <sys/types.h> #include <unistd.h> pid_t fork(void); 进进进进进进进进 0 进进进进进进进进进 I D 进进进进 -1
Image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
www.chinaeda.cn 1.6  进进进进 fork 进进进进进进进进进进进进进 child process 进进 进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进 0 进进进进进进进进进进进进进进进进进 ID 进进进进进进 f o r k 进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进     
Image of page 8
www.chinaeda.cn 1.6  进进进进 进进 fork 进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进 进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进进 进进进进进进进进进进进进进进进进进进进进
Image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full Document Right Arrow Icon
www.chinaeda.cn 进进进进进进进进进进进进 fork 进进进进进 进进 I D 进进进进进进进 I D 进进进进 t m s _ u t i m e , t m s _ s t i m e , t m s  _ c u t i m e 进进 t m s _ u s t i m e 进进进 0
Image of page 10
Image of page 11
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern