Artificial intelligent assistant

How set the "oom_score_adj" when(before) run target program? Directly set by `echo 1000 >/proc/<pid>/oom_score_adj` is unreliable because target program is already running , in this case maybe target program caused OOM before `echo 1000 >/proc/<pid>/oom_score_adj`

`oom_score_adj` is inherited on fork, so you can set its initial value for new children by setting the desired value on the parent process.

Thus if you’re starting the target from a shell script,


echo 1000 > /proc/$$/oom_score_adj


will change the shell’s value to 1000, and any process subsequently forked by the shell will start with `oom_score_adj` set to 1000.

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy 7930d0fc736db05117409ece8c353886