This article mainly compiles and summarizes relevant information on PHP signal management knowledge. Friends who need it can refer to it
SIGQUIT Create a CORE file to terminate the process and generate a core file
SIGILL Create a CORE file Illegal command
SIGTRAP Create CORE file Tracing trap
SIGBUS Create CORE file Bus error
SIGSEGV Create CORE file Illegal segment error
SIGFPE Create CORE file Floating point exception
SIGIOT Create CORE file Execute I /O trap
SIGSTOP Stop process Stop signal from non-terminal
SIGTSTP Stop process Stop signal from terminal
SIGTTOU Stop process Background process writes to the terminal
SIGTTIN Stop process Background process reads the terminal
SIGHUP Terminate the process Terminal line hangs up
SIGINT Terminate the process Interrupt the process
SIGXGPU Terminate the process CPU time limit timeout
SIGXFSZ Terminate the process File length is too long
SIGPROF Terminate the process Use for statistical distribution chart The timer expires
SIGUSR1 Terminate the process User-defined signal 1
SIGUSR2 Terminate the process User-defined signal 2
SIGVTALRM Terminate the process Virtual timer expires
SIGKILL Terminate the process Kill the process
SIGPIPE Terminate the process Write data to a pipe with no reading process
SIGALARM Terminate process When timer expires
SIGTERM Terminate process Software terminate signal
SIGCONT Ignore signal Continue to execute a stopped process
SIGURG Ignore signal I /O emergency signal
SIGIO Ignore the signal I/O can be performed on the descriptor
SIGCHLD Ignore the signal Notify the parent process when the child process stops or exits
SIGWINCH Ignore the signal The window size changes
1 SIGHUP
This signal is issued when the user terminal connection (normal or abnormal) ends, usually when the terminal control process ends, notifying each job in the same session , then they are no longer associated with the control terminal.
2, SIGINT
The program terminates (interrupt, signal, when the user types the INTR character (usually Ctrl-C , is issued when
3. SIGQUIT
SIGQUIT is similar to SIGINT, but is controlled by the QUIT character (usually Ctrl-,). When the process exits due to receiving SIGQUIT A core file will be generated, which is similar to a program error signal in this sense.
4, SIGILL
SIGILL executed an illegal instruction. Usually because of the executable file itself An error occurs, or an attempt is made to execute the data segment. This signal may also be generated when the stack overflows.
5, SIGTRAP
SIGTRAP is generated by breakpoint instructions or other trap instructions. Used by the debugger.
6. SIGABRT
SIGABRT is generated when the program finds an error and calls abort.
6. SIGIOT
SIGIOT is generated by the iot command on PDP-11, and is the same as SIGABRT on other machines.
7, SIGBUS
SIGBUS illegal address, including memory address alignment ( alignment, error. eg: Accessing a four-word integer, but its address is not a multiple of 4.
8, SIGFPE
SIGFPE Fatal arithmetic occurred Issued when an operation error occurs. It includes not only floating point operation errors, but also all other arithmetic errors such as overflow and division by 0.
9, SIGKILL
SIGKILL Use to immediately end the running of the program. This signal cannot be blocked, processed or ignored.
10. SIGUSR1
SIGUSR1 is left to the user
11. SIGSEGV
SIGSEGV attempts to access memory that is not allocated to itself, or attempts to write data to a memory address that does not have write permission.
12. SIGUSR2
SIGUSR2 is reserved for users
13、 SIGPIPE
Broken pipe
14、 SIGALRM
SIGALRM clock timing signal, which calculates the actual time or clock time. The alarm function uses this signal.
15, SIGTERM
SIGTERM program End (terminate, signal, unlike SIGKILL, this signal can be blocked and processed. It is usually used to require the program to exit normally. Shell command
Kill generates this signal by default.
17. SIGCHLD
SIGCHLD When the child process ends, the parent process will receive this signal.
18. SIGCONT
SIGCONT allows a stopped process to continue execution. This signal cannot be blocked. A handler can be used to allow the program to continue execution when it changes from the stopped state to Complete a specific job. For example, redisplay the prompt
19, SIGSTOP
SIGSTOP to stop the execution of the process. Note the difference from terminate and interrupt: The process has not ended, but execution is suspended. This signal cannot be blocked, processed or ignored.
20. SIGTSTP
SIGTSTP stops the running of the process, but this signal can be processed and ignored. This signal is emitted when the user types the SUSP character (usually Ctrl-Z)
21, SIGTTIN
SIGTTIN when the background job is to be started from the user terminal When reading data, all processes in the job will receive the SIGTTIN signal. By default, these processes will stop executing.
22, SIGTTOU
SIGTTOU is similar to SIGTTIN , but received when writing the terminal (or modifying the terminal mode).
23, SIGURG
SIGURG There is "urgent" data or out-of-band data arriving. Produced when socket.
24, SIGXCPU
SIGXCPU exceeds the CPU time resource limit. This limit can be read/changed by getrlimit/setrlimit
25. SIGXFSZ
SIGXFSZ exceeds the file size resource limit.
26. SIGVTALRM
SIGVTALRM Virtual clock signal. Similar to SIGALRM, but calculates the CPU time occupied by the process.
27, SIGPROF
SIGPROF is similar to SIGALRM/SIGVTALRM, but includes the CPU time used by the process and System call time.
28. SIGWINCH
SIGWINCH is issued when the window size changes.
29. SIGIO
The SIGIO file descriptor is ready and input/output operations can begin.
30, SIGPWR
SIGPWR Power failure
Yes Two signals can stop a process: SIGTERM and SIGKILL. SIGTERM is more friendly. The process can catch this signal and close the program according to your needs. You can end open log files and complete tasks you are doing before closing the program. In some cases, if the process is working and cannot be interrupted, the process can ignore the SIGTERM signal.
The process cannot ignore the SIGKILL signal. This is a "I don't care what you're doing, stop it now" signal. If you send a SIGKILL signal to a process, Linux stops the process there.
The above is the entire content of this article, I hope it will be helpful to everyone's study.
Related recommendations:
PHP userManagement Commonly used interface call methods
php implementation fileManagementMethods to operate with basic functions
php sessionManagementand control
The above is the detailed content of Summary of PHP signal management knowledge. For more information, please follow other related articles on the PHP Chinese website!

What’s still popular is the ease of use, flexibility and a strong ecosystem. 1) Ease of use and simple syntax make it the first choice for beginners. 2) Closely integrated with web development, excellent interaction with HTTP requests and database. 3) The huge ecosystem provides a wealth of tools and libraries. 4) Active community and open source nature adapts them to new needs and technology trends.

PHP and Python are both high-level programming languages that are widely used in web development, data processing and automation tasks. 1.PHP is often used to build dynamic websites and content management systems, while Python is often used to build web frameworks and data science. 2.PHP uses echo to output content, Python uses print. 3. Both support object-oriented programming, but the syntax and keywords are different. 4. PHP supports weak type conversion, while Python is more stringent. 5. PHP performance optimization includes using OPcache and asynchronous programming, while Python uses cProfile and asynchronous programming.

PHP is mainly procedural programming, but also supports object-oriented programming (OOP); Python supports a variety of paradigms, including OOP, functional and procedural programming. PHP is suitable for web development, and Python is suitable for a variety of applications such as data analysis and machine learning.

PHP originated in 1994 and was developed by RasmusLerdorf. It was originally used to track website visitors and gradually evolved into a server-side scripting language and was widely used in web development. Python was developed by Guidovan Rossum in the late 1980s and was first released in 1991. It emphasizes code readability and simplicity, and is suitable for scientific computing, data analysis and other fields.

PHP is suitable for web development and rapid prototyping, and Python is suitable for data science and machine learning. 1.PHP is used for dynamic web development, with simple syntax and suitable for rapid development. 2. Python has concise syntax, is suitable for multiple fields, and has a strong library ecosystem.

PHP remains important in the modernization process because it supports a large number of websites and applications and adapts to development needs through frameworks. 1.PHP7 improves performance and introduces new features. 2. Modern frameworks such as Laravel, Symfony and CodeIgniter simplify development and improve code quality. 3. Performance optimization and best practices further improve application efficiency.

PHPhassignificantlyimpactedwebdevelopmentandextendsbeyondit.1)ItpowersmajorplatformslikeWordPressandexcelsindatabaseinteractions.2)PHP'sadaptabilityallowsittoscaleforlargeapplicationsusingframeworkslikeLaravel.3)Beyondweb,PHPisusedincommand-linescrip

PHP type prompts to improve code quality and readability. 1) Scalar type tips: Since PHP7.0, basic data types are allowed to be specified in function parameters, such as int, float, etc. 2) Return type prompt: Ensure the consistency of the function return value type. 3) Union type prompt: Since PHP8.0, multiple types are allowed to be specified in function parameters or return values. 4) Nullable type prompt: Allows to include null values and handle functions that may return null values.


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

Video Face Swap
Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

SublimeText3 Chinese version
Chinese version, very easy to use

VSCode Windows 64-bit Download
A free and powerful IDE editor launched by Microsoft

Safe Exam Browser
Safe Exam Browser is a secure browser environment for taking online exams securely. This software turns any computer into a secure workstation. It controls access to any utility and prevents students from using unauthorized resources.

MinGW - Minimalist GNU for Windows
This project is in the process of being migrated to osdn.net/projects/mingw, you can continue to follow us there. MinGW: A native Windows port of the GNU Compiler Collection (GCC), freely distributable import libraries and header files for building native Windows applications; includes extensions to the MSVC runtime to support C99 functionality. All MinGW software can run on 64-bit Windows platforms.

SublimeText3 Mac version
God-level code editing software (SublimeText3)