Timeline for Which process has PID 0?
Current License: CC BY-SA 3.0
11 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Jun 8, 2024 at 15:47 | comment | added | Braiam | Wikipedia changed the text with a more authoritatively source, that invalidates some of the previous claims. | |
| Oct 4, 2022 at 22:48 | comment | added | mtraceur |
@roottraveller no, when you create a new process using fork, the child gets a 0 return value from fork, because fork has nothing useful to return to the child but needs to return something distinct from an actual PID. But the child itself does not have PID 0, and that zero isn't really a PID - or at least it's certainly not the PID of any actual process.
|
|
| Oct 4, 2022 at 22:44 | comment | added | mtraceur | @slm that's not what @/roottraveller is asking. | |
| Sep 9, 2017 at 12:03 | comment | added | slm♦ | @roottraveller not necessarily, whatever the parents PID is where the fork occurred will be what shows up. | |
| Sep 9, 2017 at 6:32 | comment | added | roottraveller | well, but when we create a new process using fork child process get pid 0? | |
| Jan 12, 2017 at 13:43 | comment | added | slm♦ | @Ruslan - if you have follow on questions please ask them on the main site, comments are not meant for this. Reference this question in your new question. | |
| Jan 12, 2017 at 12:35 | comment | added | Ruslan |
So if PID 0 is swapper, then what is kswapd[0-9]*, which on my system has PID 52 currently? It seems to also be responsible for paging.
|
|
| Jul 24, 2013 at 6:06 | vote | accept | user9744 | ||
| Jul 24, 2013 at 6:06 | vote | accept | user9744 | ||
| Jul 24, 2013 at 6:06 | |||||
| Jul 17, 2013 at 4:22 | history | edited | slm♦ | CC BY-SA 3.0 |
added 619 characters in body
|
| Jul 17, 2013 at 4:12 | history | answered | slm♦ | CC BY-SA 3.0 |