差分
このページの2つのバージョン間の差分を表示します。
両方とも前のリビジョン 前のリビジョン 次のリビジョン | 前のリビジョン最新のリビジョン両方とも次のリビジョン | ||
linux:commands:process [2019/01/21 23:26] – [プロセス表示[ps]] ともやん | linux:commands:process [2024/03/31 05:27] – [参考文献] ともやん | ||
---|---|---|---|
行 1: | 行 1: | ||
====== プロセス関連 ====== | ====== プロセス関連 ====== | ||
+ | |||
===== プロセス表示[ps] ===== | ===== プロセス表示[ps] ===== | ||
現在実行されているプロセスのスナップショットを表示する。 | 現在実行されているプロセスのスナップショットを表示する。 | ||
- | <code> | + | <WRAP color_term> |
- | $ ps | + | <WRAP color_command>< |
- | </code> | + | <font color="# |
- | <code> | + | </pre></ |
- | | + | <WRAP color_result>< |
- | | + | PID TTY TIME CMD |
- | | + | 851455 |
- | </ | + | 854417 |
- | aux オプションでユーザー、CPU使用率、メモリー使用率などを表示する。 | + | </pre></ |
- | <code> | + | </ |
- | $ ps aux | + | |
- | </code> | + | < |
- | <code> | + | <WRAP color_term> |
+ | <WRAP color_command>< | ||
+ | <font color="# | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND | ||
+ | tomoyan | ||
+ | tomoyan | ||
+ | tomoyan | ||
+ | tomoyan | ||
+ | tomoyan | ||
+ | tomoyan | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | < | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | </pre></ | ||
+ | <WRAP color_result_hlong>< | ||
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND | USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND | ||
root 1 0.1 0.2 105560 12216 ? Ss | root 1 0.1 0.2 105560 12216 ? Ss | ||
- | root 607 0.0 0.0 32760 1840 ? S<sl 17:52 0:00 / | + | root 607 0.0 0.0 32760 1840 ? S<sl 17:52 0:00 / |
root 634 0.0 0.2 258548 16444 ? Ssl 17:52 0:05 / | root 634 0.0 0.2 258548 16444 ? Ssl 17:52 0:05 / | ||
root 636 0.0 0.0 17112 5932 ? Ss | root 636 0.0 0.0 17112 5932 ? Ss | ||
行 63: | 行 83: | ||
〜省略〜 | 〜省略〜 | ||
tomoyan | tomoyan | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ===== プロセス優先度の変更[renice] ===== | ||
+ | < | ||
+ | $ sudo renice -3 1982 | ||
+ | 1982 (process ID) 従来の優先順位は 0 で, 新しい優先順位は -3 です | ||
</ | </ | ||
行 108: | 行 135: | ||
| Shift + w | 設定の保存 | | | Shift + w | 設定の保存 | | ||
| q | top コマンドの終了 | | | q | top コマンドの終了 | | ||
+ | |||
+ | ===== 参考文献 ===== | ||
+ | [[https:// | ||
+ | [[https:// | ||
+ |