Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Workspace processes are not reaped #2398

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
sreya opened this issue Jun 16, 2022 · 8 comments · Fixed by #2441
Closed

Workspace processes are not reaped #2398

sreya opened this issue Jun 16, 2022 · 8 comments · Fixed by #2441
Assignees
Labels
api Area: HTTP API

Comments

@sreya
Copy link
Collaborator

sreya commented Jun 16, 2022

Noticed the following while developing throughout the day

coder@dev database (main) ✗ ps aux
USER         PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME COMMAND
coder          1  0.6  0.0 745980 47296 ?        Ssl  Jun15   4:02 /tmp/tmp.codert7WFxT/coder agent
coder         68  0.0  0.0 710632 57436 ?        Sl   Jun15   0:00 /usr/lib/code-server/lib/node /usr/lib/code-serv
coder        260  0.0  0.0 645884 58496 ?        Sl   Jun15   0:01 /usr/lib/code-server/lib/node /usr/lib/code-serv
coder       2518  0.0  0.0   5100  3124 ?        S    Jun15   0:00 /bin/zsh
coder       2520  0.0  0.0   4504  3848 ?        S    Jun15   0:00 bash
coder       2564  0.0  0.0   2608   532 ?        S    Jun15   0:00 sh /home/coder/.vscode-server/bin/c3f126316369cd
coder       2571  0.2  0.1 981768 121112 ?       Sl   Jun15   1:23 /home/coder/.vscode-server/bin/c3f126316369cd610
coder       2651  0.0  0.0 656600 39904 ?        Sl   Jun15   0:01 /home/coder/.vscode-server/bin/c3f126316369cd610
coder       2675  0.0  0.1 928244 67116 ?        Sl   Jun15   0:06 /home/coder/.vscode-server/bin/c3f126316369cd610
coder       2705  2.3  0.2 1023124 165288 ?      Sl   Jun15  12:44 /home/coder/.vscode-server/bin/c3f126316369cd610
coder       2727  0.0  0.1 673080 126076 ?       Sl   Jun15   0:03 /home/coder/.vscode-server/bin/c3f126316369cd610
coder       2733  0.3  0.9 1128000 599352 ?      Sl   Jun15   1:36 /home/coder/.vscode-server/bin/c3f126316369cd610
coder       2761  1.0  1.0 3163308 711264 ?      Sl   Jun15   5:39 /usr/local/bin/gopls -mode=stdio
coder       2804  0.0  0.0 612920 61816 ?        Sl   Jun15   0:00 /home/coder/.vscode-server/bin/c3f126316369cd610
coder       3031  0.0  0.0 615216 40068 ?        Sl   Jun15   0:01 /home/coder/.vscode-server/bin/c3f126316369cd610
coder      16432  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      18179  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      18625  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      19056  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      19559  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      19633  0.0  0.0      0     0 ?        Z    Jun15   0:00 [gpg-agent] <defunct>
coder      19634  0.0  0.0  78232  3168 ?        Ss   Jun15   0:01 gpg-agent --homedir /home/coder/.gnupg --use-sta
coder      20444  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      20569  0.0  0.0  11312  7684 pts/0    Ss+  Jun15   0:09 /bin/zsh
coder      20603  0.0  0.0  11480  8228 pts/1    Ss   Jun15   0:13 /bin/zsh
coder      29055  0.0  0.0      0     0 ?        Z    Jun15   0:02 [go] <defunct>
coder      29335  0.0  0.0      0     0 ?        Z    Jun15   0:01 [compile] <defunct>
coder      30716  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      36671  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      38731  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      39785  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      41364  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      41904  0.0  0.0      0     0 ?        Z    Jun15   0:03 [go] <defunct>
coder      42468  0.0  0.0      0     0 ?        Z    Jun15   0:00 [compile] <defunct>
coder      42474  0.0  0.0      0     0 ?        Z    Jun15   0:00 [compile] <defunct>
coder      43318  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      44477  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      50654  0.0  0.0      0     0 pts/1    Z    Jun15   0:00 [sh] <defunct>
coder      50666  0.0  0.0      0     0 pts/1    Z    Jun15   0:00 [sh] <defunct>
coder      50794  0.0  0.0      0     0 pts/1    Z    Jun15   0:00 [bash] <defunct>
coder      50795  0.0  0.0      0     0 pts/1    Z    Jun15   0:00 [node] <defunct>
coder      50796  0.0  0.0      0     0 pts/1    Z    Jun15   0:03 [go] <defunct>
coder      50829  0.0  0.0      0     0 pts/1    Z    Jun15   0:00 [sh] <defunct>
coder      50830  0.3  0.0      0     0 pts/1    Z    Jun15   1:16 [webpack] <defunct>
coder      51152  0.0  0.0      0     0 pts/1    Z    Jun15   0:05 [main] <defunct>
coder      54798  0.0  0.0      0     0 pts/1    Z    Jun15   0:00 [bash] <defunct>
coder      54799  0.0  0.0      0     0 pts/1    Z    Jun15   0:00 [node] <defunct>
coder      54800  0.0  0.0      0     0 pts/1    Z    Jun15   0:07 [go] <defunct>
coder      54833  0.0  0.0      0     0 pts/1    Z    Jun15   0:00 [sh] <defunct>
coder      54834  0.4  0.0      0     0 pts/1    Z    Jun15   1:34 [webpack] <defunct>
coder      55098  0.0  0.0      0     0 pts/1    Z    Jun15   0:13 [main] <defunct>
coder      70980  0.0  0.0      0     0 ?        Z    Jun15   0:00 [go] <defunct>
coder      72272  0.0  0.0      0     0 ?        Zs   Jun15   0:00 [gopls] <defunct>
coder      72310  0.0  0.0      0     0 ?        Zs   Jun15   0:01 [gopls] <defunct>
coder     118180  0.0  0.0      0     0 ?        Zs   Jun15   0:00 [gopls] <defunct>
coder     118218  0.5  0.0      0     0 ?        Zs   Jun15   0:12 [gopls] <defunct>

Will fix.

@sreya sreya self-assigned this Jun 16, 2022
@kylecarbs
Copy link
Member

Oh neato

@kylecarbs
Copy link
Member

How are you going to fix @sreya?

@kylecarbs
Copy link
Member

@ketang
Copy link
Contributor

ketang commented Jun 16, 2022

Er do we need a reaper? Shouldn't they be exiting?

@misskniss misskniss added the api Area: HTTP API label Jun 16, 2022
@ammario
Copy link
Member

ammario commented Jun 16, 2022

Nice throwback here

@sreya
Copy link
Collaborator Author

sreya commented Jun 16, 2022

@ketang Since our agent is running as PID 1 we have to. Just a rule of Linux.

@ketang
Copy link
Contributor

ketang commented Jun 16, 2022

@mafredri
Copy link
Member

@ketang I like the solution in #2441 since it will essentially work in all environments and doesn't prevent anyone from using tini if they would like a more battle-tested init process.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Area: HTTP API
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants