kazmax - Linux で自宅サーバー

top - コマンド (プログラム) の説明 - Linux コマンド集 一覧表

  1. 名前
  2. 書式
  3. 説明
  4. 概要
  5. 1. コマンドラインオプション
  6. 2. フィールド / カラム
  7. 3. 対話的コマンド
  8. 4. 別形式の表示モード
  9. 5. ファイル
  10. 6. くだらないトリックのサンプル
  11. 7. バグ
  12. 8. 以前の top の履歴
  13. 9. 著者
  14. 10. 関連項目
  15. GNU Free Documentation License
  16. \fRend of\fB GNU Free Documentation License

名前

top - Linux のタスクを表示する

書式

top -hv | -bcisS -d delay -n iterations -p pid [, pid ...]
昔からのスイッチ '-' と空白の指定は任意である。

説明

top プログラムは稼働中のシステムの 動的なリアルタイムの概要を報告する。 Linux カーネルが現在管理しているタスク の一覧だけでなく、 システム の概要情報も表示できる。 表示されるシステムの概要情報のタイプと 各タスクについて表示される情報のタイプ・順序・サイズは、 ユーザーが全て設定可能で、その設定は次に起動したときにも保存できる。
このプログラムはプロセスの操作に関する 限定された対話型インタフェースだけでなく、 個人用の設定についての特に拡張されたインタフェースも提供している。 (EM 操作の全ての面についての包括的なインタフェースを提供している。 このプログラムは、この文書を通して top という名前で呼ばれているが、 希望する任意の名前にすることができる。 新しい名前 (エイリアスでもよい) は、top の表示に反映され、 設定ファイルを読み書きの際に使用される。

概要

ドキュメント

これ以降の目次 1. コマンドラインオプション 2. フィールド / カラム a. フィールドの説明 b. カラムの選択と順序指定 3. 対話的コマンド a. グローバルなコマンド b. サマリーエリアのコマンド c. タスクエリアのコマンド d. カラーマップ 4. 別形式の表示モード a. ウィンドウの概要 b. ウィンドウのコマンド 5. ファイル a. システム設定ファイル b. 個人設定ファイル 6. くだらないトリックの例 a. カーネルのトリック b. バウンドするウィンドウ c. 大きな雛鳥のようなウィンドウ 7. バグ, 8. 以前の top の履歴, 9. 著者, 10. 関連項目

操作

top を操作するときの最も重要な 2 つのキーは、 ヘルプ ('h' または '?') と終了 ('q') キーである。 終了させるときには、代わりとして、 単純に昔からの割り込みキー ('^C') を使うこともできる。
最初に top を起動する場合、 昔からの以下のスクリーンの要素が表示される: 1) サマリーエリア; 2) メッセージ/プロンプト行 3) カラムヘッダ; 4) タスクエリア。 しかし、以前の top と比較すると、いくつかの違いがある。

ハイライト
サマリーエリア :負荷 (load) / 稼働時間 (uptime) の値はハイライトされず、 その他の要素の値のみがハイライトされる。
タスクエリア :実行中 (または実行の準備がされている) のタスクがハイライトされる。 これらのプロセスを強調する唯一の手段は太字で表示することである。
内容/ラベル
サマリーエリア :プログラム名が表示される。 シンボリックリンク名またはエイリアスが表示される場合もある。 Cpu(s) 状態ラベルは他のものが表示される可能性を暗に示している。 メモリ統計では小文字 'k' が使用される。
カラムヘッダ :新しいフィールドといくつかの変更されたラベルが表示される。 top をカスタマイズすれば新しいフィールドが更に表示される。

注意: top の表示は 512 文字に制限される。 全てのフィールドを表示するためには最低 160 文字が必要である。 残りの幅は 'Command' カラムに使用できる。

起動時のデフォルト値

以下の起動時のデフォルトは、設定ファイルの使用を仮定していないので、 ユーザーはカスタマイズできない。 しかし、(AS の付いたコマンドはコマンドラインで上書きできる。
全体のデフォルト 'A' - 別形式表示 Off (全画面) * 'd' - 遅延時間 3.0 秒 'I' - Irix モード On('solaris' smp ではない) * 'p' - PID の監視 Off * 's' - セキュアモード Off (非セキュアモード) 'B' - 太字表示 Off サマリーエリアのデフォルト 'l' - 負荷平均/稼働時間 On(プログラム名が表示される) 't' - タスク/Cpu 統計 On(1+1 行。'1' を参照) 'm' - メモリ/スワップ使用量 On(2 行を使う) '1' - シングル Cpu On(smp の場合 1 行になる) タスクエリアのデフォルト 'b' - 太字によるハイライト On(背景と前景を「反転」しない) * 'c' - コマンドライン Off (コマンドラインではない名前) * 'i' - アイドルタスク On(全てのタスクを表示する) 'R' - 逆順ソート On(pid の降順でソートする) * 'S' - 累積時間 Off (死んだ子プロセスを累積しない) 'x' - カラムのハイライト Off(フィールドをソートする) 'y' - 行のハイライト On(実行中のタスクが表示される) 'z' - カラー/単色 Off(カラー表示しない)

1. コマンドラインオプション

top のコマンドラインの書式は、以下のように構成される:
-hv |-bcisS -ddelay -niterations -ppid [,pid ...]
一般には必須とされているスイッチ ('-') と空白でさえ、完全にオプションである。

-b : バッチモード 操作
top を「バッチモード」で起動する。 top の出力を他のプログラムやファイルに送る場合に役立つ。 このモードでは、top は入力を受け付けず、 '-n' (COで設定された繰り返し回数に達するか、 kill されるまで実行を続ける。
-c : コマンドライン/プログラム名 トグル
最後に記録された 'c' の状態を逆にして、top を起動する。 よって、top がコマンドラインを表示していた場合は、プログラム名を表示する。 プログラム名を表示していた場合は、コマンドラインを表示する。 より詳しい情報は(CI 'c' (XC。
-d : 遅延時間 間隔:-d ss.tt ( .1/10秒 )
スクリーンを更新する間隔を指定する。 ユーザー個人の設定ファイルにあるこれに対応する値、 または起動時のデフォルトの値を上書きする。 実行後に(CI 'd' または 's' で変更できる。
小数点以下の秒も指定できるが、負数は許可されない。 しかし全ての場合において、 top が「セキュアモード」で実行されているときには、 このような変更は禁止されている。 ただし root の場合 (かつ(CO 's' が使われていない場合) は除く。 「セキュアモード」についてのより詳しい情報は、 「5a. システム設定ファイル」(Xt。
-h : ヘルプ
ライブラリのバージョンと使用法のプロンプトを表示して、終了する。
-i : アイドルプロセス トグル
最後に記録された 'i' の状態を逆にして、top を起動する。 トグルが F の場合、アイドルタスクまたはゾンビタスクは表示されない。
-n : 繰り返し回数 制限:-n number
top が終了するまでの繰り返し回数またはフレームの最大数を指定する。
-u : ユーザーを指定して監視する :-u somebody
指定された実効 UID または実効ユーザー名にマッチするプロセスのみを監視する。
-U : ユーザーを指定して監視する :-U somebody
指定された UID またはユーザー名にマッチするプロセスのみを監視する。 実・実効・保存・ファイルシステム UID とマッチするものが選ばれる。
-p : PID を指定して監視する :-pN1 -pN2 ... または-pN1, N2 [,...]
指定されたプロセス ID とマッチするプロセスのみを監視する。 このオプションを 20 個まで指定するか、 コンマで区切った 20 個までのプロセス ID を指定することができる。 両方を混ぜて使用することもできる。
これは(COでのみ指定できる。 通常の操作に戻したい場合は、top を終了して再起動する必要はなく (EM (CI '=' を実行するだけでよい。
-s : セキュアモード 操作
たとえ root であっても、強制的にセキュアモードにして top を起動する。 このモードはシステムの設定ファイルで制御する方が、更に良い。 (「5. ファイル」(Xt)。
-S : 累積時間モード トグル
最後に記録された 'S' の状態を逆にして、top を起動する。 「累積モード」が O の場合、各プロセスは そのプロセスとそのプロセスの終了した子プロセスで使われた (Pu 時間とともに表示される。 このモードのより詳しい情報については、(CI 'S' (XC。
-v : バージョン
ライブラリのバージョンと使用法のプロンプトを表示して、終了する。

2. フィールド / カラム

2a. フィールドの説明

top で表示可能なフィールドを以下にリストする。 これらのフィールドは、 (CI 'o' (フィールドの順序変更) で指定できる位置に関わらず、 以下で示す文字と常に関連付けられている。
全てのフィールドはソート対象として選択可能であり、 降順でソートするか昇順でソートするかを制御できる。 ソート機能についての詳しい情報は「3c. タスクエリアコマンド」(Xt。

a: PID (EM プロセス ID
タスクの一意なプロセス ID。 定期的に同じ番号が使われるが、0 から再スタートすることはない。
b: PPID (EM 親プロセスのプロセス ID
タスクの親タスクのプロセス ID。
c: RUSER (EM 実ユーザー名
タスクの所有者の実ユーザー名。
d: UID (EM ユーザー ID
タスクの所有者の実効ユーザー ID。
e: USER (EM ユーザー名
タスクの所有者の実効ユーザー名。
f: GROUP (EM グループ名
タスクの所有者の実効グループ名。
g: TTY (EM 制御端末
制御端末の名前。 通常はプロセスが開始されたデバイス (シリアルポート、疑似端末 (pty) など) であり、入出力に使われる。 しかしタスクは端末に関連付ける必要はなく、その場合は '?' が表示される。
h: PR (EM 優先度
タスクの優先度
i: NI (EM nice 値
タスクの nice 値。 負の nice 値は高い優先度を意味し、正の nice 値は低い優先度を意味する。 このフィールドが 0 の場合、タスクの割り当て (dispatchability) を決定する際に 優先度を調整していないこと意味する。
j: P (EM 最後に使用された (PU (SMP)
最後に利用されたプロセッサを表す値。 カーネルはわざと weak affinity を使っているので、 本当の SMP 環境では、この値は頻繁に変わりやすくなる。 また実行中の top の動作そのものが ((Pu 時間に対する余分な要求となることによって) weak affinity を壊すかもしれず、 プロセスの (PU 変更がより多くなるかもしれない。
k: %CPU (EM (PU 使用率
前回のスクリーン更新からの、タスクの所要 CPU 時間の占有率。 総 (PU 時間のパーセンテージで表される。 本当の SMP 環境では、「Irix モード」が F の場合、 top は「Solaris モード」で操作し、 タスクの (Pu 使用率は総 (PU 数で割り算される。 Irix/Solaris' モードは(CI 'I' でトグルできる。
l: TIME (EM (PU 時間
タスクが開始してから利用した (PU 時間の総計。 「累積モード」が O の場合、 各プロセスは終了した子プロセスが使った (Pu 時間とともにリストされる。 「累積モード」は(COと(CIの 'S' でトグルできる。 このモードについての更なる情報は、(CI 'S' (XC。
m: TIME+ (EM (PU 時間 (1/100 単位)
TIME' と同じであるが、精度を 1/100 秒単位まで反映させる。
n: %MEM (EM メモリ使用率 (RES)
タスクが現在使用している利用可能な(MPの占有率。
o: VIRT (EM 仮想イメージ (kb)
タスクが使用している(MVの総量。 コード・データ・共有ライブラリ・スワップアウトされているページが含まれる。
VIRT = SWAP + RES.
p: SWAP (EM スワップされたサイズ (kb)
タスクの総(MVイメージのうちスワップアウトされた部分。
q: RES (EM 常駐サイズ (kb)
タスクが使用しているスワップされていない(MP。
RES = CODE + DATA.
TP 3 r: CODE (EM コードサイズ (kb) 実行可能コードに割かれる(MPの総量。 「テキスト常駐サイズ (text resident set)」または TRS とも呼ばれる。
s: DATA (EM 「データ+スタック」のサイズ (kb)
実行可能コード以外に割かれる(MPの総量。 「データ常駐サイズ (data resident set)」または DRS とも呼ばれる。
t: SHR (EM 共有メモリサイズ (kb)
タスクが利用している共有メモリの総量。 他のプロセスと共有される可能性のあるメモリを単純に反映している。
u: nFLT (EM ページフォールト回数
あるタスクに対して起こったメジャー ページフォールトの回数。 ページフォールトは、現在、アドレス空間にない 仮想ページに対してプロセスが読み書きしようとしたときに起こる。 メジャーページフォールトとは、あるページを利用可能にするために ディスクアクセスが起こる場合のことである。
v: nDRT (EM ダーティページ数
最後に書き込まれてから変更されたページの数。 ダーティページは、対応する物理メモリの場所が他の仮想ページで使用される前に、 ディスクに書き込まれなければならない。
w: S (EM プロセス状態
タスクの状態は以下のいずれかである: 'D ' = 割り込み不可能なスリープ状態 'R ' = 実行中 'S ' = スリープ状態 'T ' = トレース中/停止された 'Z ' = ゾンビ
実行中と表示されるタスクは「実行準備済み」と考えるのがより正しいだろう。 (EM タスクの task_struct は Linux の実行キューで表現されている。 本当の SMP マシン以外でさえ、top の遅延間隔と nice 値に依っては、 この状態のタスクを非常に多く目にするだろう。
x: Command (EM コマンドライン またはプログラム
タスクを開始するのに使ったコマンドライン、 またはタスクに関連づけられたプログラムの名前を表示する。 コマンドライン とプログラム は、 (COと(CIの 'c' でトグルできる。
コマンドラインの表示を選択した場合、 (カーネルスレッドのように) コマンドラインのないプロセスは、 以下の例のように、プログラム名だけが括弧で括られて表示される。 ( mdrecoveryd )
コマンドライン・プログラム名の表示が 現在のフィールド幅に対して長すぎる場合は、切り詰められる場合がある。 フィールド幅はその他に選択されているフィールド・フィールドの順番・ 現在のスクリーン幅に依存する。
注意: 'Command' フィールド/カラムは固定幅でないという点が特殊である。 表示の際、このカラムは残りの全てのスクリーン幅 (最大 512 文字) が割り当てられる。 これは、プログラム名からコマンドラインへの切り替えで 文字数が増える場合に備えるためである。
y: WCHAN (EM スリープしている関数
カーネルリンクマップ ('System.map') が利用可能かに否かによって、 タスクが現在スリープしているカーネル関数の名前またはアドレスが表示される。 実行中のタスクでは、このカラムにダッシュ ('-') が表示される。
注意: このフィールドを表示すると、 top 自身のワーキングセットが 700Kb 増加する。 このオーバーヘッドを減らす唯一の方法は、top を停止して再起動することである。
z: Flags (EM タスクフラグ
このカラムにはタスクの現在のスケジューリングフラグが 0 を省略した 16 進数で表示される。 これらのフラグは公式には <linux/sched.h> に書かれている。 公式なものではないが、「フィールド選択」スクリーンと 「フィールド順序指定」スクリーンにも説明がある。

2b. カラムの選択と順序指定

(CI 'f' (フィールド選択) または o' (フィールド順序指定) を入力すると、 現在のフィールド文字列 とその説明が記述されたスクリーンが表示される。
以下は、top の 4 つのウィンドウ・フィールドグループのうちの 1 つの サンプルのフィールド文字列 と、 使用される代表的なフィールドの説明である。 サンプルのフィールド文字列: ANOPQRSTUVXbcdefgjlmyzWHIK 表示されるフィールドの順番は、文字列中の文字の順番に対応する。 文字が大文字 の場合、(スクリーン幅が許すならば) そのフィールド自身が(TDの一部として表示される。 これは以下の抜粋のように、先頭の(ASでも示される: ... * K: %CPU = CPU usage l: TIME = CPU Time m: TIME+ = CPU Time, hundredths * N: %MEM = Memory usage (RES) * O: VIRT = Virtual Image (kb) ...

フィールド選択 スクリーン (EM (CI 'f'
対応する文字を入力することで表示トグル できる。
フィールド順序指定 スクリーン (EM (CI 'o'
対応する大文字 を入力することでフィールドを移動 できる。 また小文字 を入力することで移動 できる。

3. 対話的コマンド

以下に挙げたものは、コマンドをカテゴリ分けした簡単な索引である。 いくつかのコマンドは 1 回以上書かれている (EM これはコマンドの意味やスコープが、 そのコマンドが発行された状況に依存するためである。
3a. グローバルなコマンド <Ret/Sp> ?, =, A, B, d, G, h, I, k, q, r, s, W, Z 3b. サマリーエリアのコマンド l, m, t, 1 3c. タスクエリアのコマンド 外観: b, x, y, z 内容: c, f, o, S, u サイズ: #, i, n ソート: <, >, F, O, R 3d. カラーマッピング <Ret>, a, B, b, H, M, q, S, T, w, z, 0 - 7 4b. ウィンドウのコマンド -, _, =, +, A, a, G, g, w

3a. グローバルなコマンド

グローバルな(CIは常に (FMと(AMで使用可能である。 しかし「セキュアモード」で動作している場合には、 これらの(CIのいくつかは使用できなくなる
top がセキュアモードか否かを前もって知りたい場合は、 ヘルプコマンドを実行し、2 行目のシステムサマリーを見るだけでよい。

Enter > または <Space > :表示の再描画
これらのコマンドは何も行わず、単に無視される。 しかし、これらのコマンドは top を目覚めさせ、 (最後の画面更新の) 後で表示全体が再描画される入力が 受け付けられていた場合はそれを知らせる。
遅延間隔が長いときに現在の状態を知りたい場合は、 これらのキーのいずれかを使うこと。
? または h :ヘルプ
2 つのヘルプレベルが使用可能である。 1 つ目では全ての基本的な(CIのメモを表示する。 top がセキュアな 場合、このスクリーンは省略される。
ヘルプスクリーンで 'h' または '?' を入力すると、 (AMの(CIのヘルプに移動する。
= :タスク制限の終了
表示されるタスクの制限をなくす。 このコマンドは有効になっている 'i' (アイドルタスク) コマンドと n' (最大タスク数) コマンドを無効にする。 このコマンドは PID を指定した監視の「終了」も行う。 PID を指定した監視についての議論は、(CO '-p' を参照すること。
(AMで実行すると、このコマンドは少し広い意味を持つ。
A :別形式の表示モードのトグル
このコマンドは(FMと(AMを切り替える。 (CWとフィールドグループについて知るには、 4. 別形式の表示モードと(CI 'G' (XT。
B :太字の有効/無効のトグル
このコマンドは terminfo の「太字」機能を使用するか否かに影響し、 (SAと(TAの両方 の(CWを変更する。 このコマンドは本来はダム端末での使用を意図したものであるが、 いつでも適用できる。
注意: このトグルが O で top がモノクロモードで動作している場合、 表示全体 が通常のテキストになる。 よって、'x' と 'y' (またはその一方) のトグルを使って、 強調のために表示状態を逆にしない限り、 これらのトグルが O になっていても、表示上は確認できない。
*d または s :遅延時間間隔の変更
秒単位の遅延時間 (表示を更新する間隔) を入力するための プロンプトが表示される。
小数以下の秒も受け付けるが、負の数は許されない。 0 を入力すると (ほぼ) 連続で更新され、 システムと端末ドライバが top の要求に遅れないようするので、 不満足な表示になってしまう。 システムの負荷は遅延の値に反比例するので、 気をつけて設定すること。
現在の遅延時間を知りたい場合は、好きなときに単にヘルプコマンドを実行して、 システムサマリーの 2 行目を見ればよい。
G :別ウィンドウ/フィールドグループの選択
1 から 4 までの数字を入力するためのプロンプトが表示される。 この数字は(CWに設定するウィンドウ/フィールドグループを示す。 特に(AMを試してみると、 すぐにこれらの 4 つのウィンドウの満足度が増すだろう。
I :Irix/Solaris モードのトグル
「Solaris モード」('I' トグルの F) で動作している場合、 タスクの (Pu 使用率は (PU の個数で割り算される。 このコマンドを実行すると、このトグルの新しい状態が表示される。
u :ユーザーの選択
UID またはユーザー名を入力するプロンプトが出る。 選択されたユーザーに属するプロセスのみが表示される。 このオプションは実効 UID にマッチする。
U :ユーザーの選択
UID またはユーザー名を入力するプロンプトが出る。 選択されたユーザーに属するプロセスのみが表示される。 このオプションは実・実効・保存・ファイルシステム UID にマッチする。
*k :タスクの kill
最初に PID を入力するプロンプトが出され、 その後、送信するシグナルを入力するプロンプトが出される。 プロンプトから反映されるデフォルトのシグナルは SIGTERM である。 しかし、数値または名前を指定して任意のシグナルを送ることができる。
kill を行う手順から抜けたい場合は、 どこまで進んだかによって、以下の何れかを行えばよい: 1) pid プロンプトでは、単に <Enter> を押す。 2) シグナルプロンプトでは、0 を入力する。
q :終了

*r :タスクの renice
最初に PID を入力するプロンプトが出され、 その後、そのプロセスに設定する nice の値を入力するプロンプトが出される。 正の値を入力すると、プロセスの優先度は低くなる。 逆に負の値を入力すると、そのプロセスはカーネルから現在より有利に扱われる。
W :設定ファイルの書き出し
オプション・トグル・現在のディスプレイモード・遅延時間の全てを保存する。 top を終了する直前にこのコマンドを発行すると、 全く同じ状態で後から再起動できる。
Z :カラーマッピングの変更
このキーを入力すると、(CWまたは全てのウィンドウの色を 変更する別のスクリーンに移る。 この(CIについての詳細は、3d. カラーマッピング(Xt。

(AS が付いたコマンドは「セキュアモード」では使用できない。 また、これらのコマンドはレベル 1 のヘルプスクリーンに表示されない。

3b. サマリーエリアにおけるコマンド

(SAの(CIは(FMと(AMの両方において常に利用可能 である。 これらは表示の先頭行に影響し、メッセージとプロンプトの位置を決定する。
これらのコマンドは常に(CW/フィールドグループにだけ影響を与える。 (CWとフィールドグループについての洞察は、 4. 別形式の表示モードと(CI 'G' (XT。

l :負荷平均/uptime のトグル (EM On/Off
(FMで動作している場合は、 プログラム名 (エイリアスの可能性もある) の行も含まれる。 また(AMで動作している場合は、(CW名も含まれる。
m :メモリ/スワップ利用量のトグル (EM On/Off
このコマンドは(SAの 2 行に影響する。
t :タスク/CPU 状態のトグル (EM On/Off
このコマンドは、'1' トグルの状態と top が本当の SMP で 動作しているか否かによって、(SAの 2 行以上に影響する。
1 :1 つに纏めた CPU 状態/個々の CPU 状態のトグル (EM On/Off
このコマンドは 't' コマンドで CPU 状態の部分をどのように表示するかに影響する。 このコマンドは元々は大規模並列な SMP マシンで使用するためにあるが、 SMP 環境にのみ限定されるわけではない。
(SA で 'Cpu(s):' と表示されている場合、'1' トグルは O であり、 全ての (Pu 情報が 1 行に集計される。 そうでないの場合、各 (Pu は 'Cpu0, Cpu1, ...' のように分けて表示される。

注意: どのウィンドウにおいても(SA全体のトグルが F の場合は、 メッセージ行 のみが残される。 このようにして、(FMにおけるプログラム名 または(AMにおける(CW名を (一時的に) 犠牲にして、 利用可能なタスク行を最大化できる。

3c. タスクエリアにおけるコマンド

(TAの(CIは(FMにおいて常に 利用可能である。
(TAの(CIは、(CWの(TDが F になっている場合 (4. 別形式の表示モード(Xt) は、(AMでは全く利用できない

(TWの外観

以下のコマンドもグローバルな 'B' (太字の無効) トグルの状態に影響を受ける。

b :太字/反転のトグル
このコマンドは 'x' と 'y' トグルがどのように表示されるかに影響する。 さらにこのコマンドはこれらのトグルのうち 少なくとも 1 つが O になっている時にのみ利用可能である。
x :カラムのハイライトのトグル
現在のソートフィールドのハイライトを変更する。 ソートフィールドを常に視覚的に知らせる必要はたぶんない。 またパスが長くなってしまうので、ユーザーは常に 「カラムのハイライト」を F にして実行するだろうと top は仮定している。
どのフィールドでソートされているかを忘れてしまった場合、 このコマンドはすぐに視覚的に知らせてくれる。
y :行のハイライトのトグル
「実行中」のタスクのハイライトを変更する。 このタスク状態についての更なる考察は、 2a. フィールドとプロセス状態の説明(Xt。
この機能はシステムの健康状態をみるための重要な情報を提供する。 このコマンドのコストは、端末のエスケープシーケンスするだけで、 わずかなものである。
z :カラー/モノクロのトグル
(CWの色を、最も最近使われたカラー形式と、 白地に黒または黒地に白という古くからの形式で切り替える。 このコマンドは(SAと(TAの両方 を変更するが、 x', 'y', 'b' トグルの状態には影響しない。

(TWの内容

c :コマンドライン/プログラム名のトグル
このコマンドは「コマンド」カラムが 現在表示されているか否かによらず、受け付けられる。 後でコマンドフィールドが表示に含まれるようになると、 ユーザーが適用した変更はすぐに反映される。
fo :フィールド選択 または順序指定
これらのキーを押すと、別のスクリーンが表示される。 このスクリーンでは、どのフィールドを表示するかと フィールドの順序が変更できる。 これらの(CIについての更なる情報は、 2b. カラムの選択と順序指定(Xt。
S :累積時間モードのトグル
「累積モード」が O の場合、各プロセスはそのプロセス自身と そのプロセスの死んだ子プロセスの (Pu 時間とともにリストされる。
F の場合、多くの別々のタスクにフォークするプログラムは、現れづらい init' やシェルのようなプログラムは表示されるが、 その他のコンパイラなどはたぶん表示されない。 ソートフィールドが等しく 'S' の状態が異なる 2 つの(TWを試して、 どちらの表示法がよいか見て欲しい。
このコマンドを発行すると、このトグルの新しい状態が表示される。 「累積モード」が有効になっているかを前もって知りたい場合は、 単にヘルプを実行して、ウィンドウサマリーの 2 行目を見ればよい。
u :指定されたユーザーのみの表示
表示するユーザーの名前を入力するプロンプトが出される。 それ以降は、(TWにはマッチするユーザー ID のみが表示される。 タスクが何も表示されなくなる場合もある。
後になって全てのタスクを再び監視したくなった場合は、 このコマンドを再度発行すればよい。 ただし、プロンプトに名前は入力せず、単に <Enter> を押す。

(TWのサイズ

i :アイドルプロセスのトグル
全てのタスクまたはアクティブなタスクのみを表示する。 このトグルが F の場合、アイドルプロセスまたはゾンビプロセスは表示されない。
(AMにおいて最後の(TDに対してこのコマンドが適用されても、 それより前の全ての(TDは既に表示されているので、 ウィンドウのサイズには影響しない。
n または # :最大タスク数の設定
表示するタスク数を入力するプロンプトが出される。 ユーザーが指定した数以下で、 かつ利用可能なスクリーンの行数が使用される。
(AMにおいて使用されると、 このコマンドは、最後の(TDを除き、 現在表示されている各(TDのサイズを正確に制御できる。 それより前の全ての(TDは既に描画されているので、 最後のウィンドウのサイズには影響しない。
注意: (AMにおいて最後に表示される(TDのサイズを大きくしたい場合は、 それより前の(TDのサイズを小さくすること。

(TWのソート

互換性のため、この top は以前の top で使われていた 多くのソートキーをサポートしている。 元来これは以前の top のユーザーへのサービスなので、 これらのコマンドはヘルプスクリーンには現れない 。 コマンド ソートフィールド サポート A 開始時間 (非表示) No M %MEM Yes N PID Yes P %CPU Yes T TIME+ Yes
以下のソート機能を使う前に、(CI 'x' を使って カラムのハイライトを一時的に有効にすることを奨める。 これは実際のソート環境がユーザーの意図に合っているかを確認する助けになる。
現在のソートフィールドが表示されている 場合にのみ 、 以下の(CIを受け付ける。 ソートフィールドは次の理由により表示されていない かもしれない: 1) スクリーン幅 が足りない。 2) (CI 'f' が F である。

< :ソートフィールドを左へ移動
ソートフィールドが表示されている最初のフィールドでない限り、 ソートカラムを左へ移動する。
> :ソートフィールドを右へ移動
ソートフィールドが表示されている最後のフィールドでない限り、 ソートカラムを右へ移動する。


現在のソートフィールドが表示されているか否かに関わらず、 以下の(CIは常に 受け付ける。

F または O :ソートフィールドの選択
これらのキーは別のスクリーンを表示させる。 このスクリーンでは、どのフィールドをソートカラムとするかを変更できる。
以前には表示されていなかったフィールドが選択された場合、 そのフィールドは top の表示に戻るときに強制的に O にされる。 しかし、スクリーン幅と選択したフィールドの順序によっては、 ソートフィールドは表示されないかもしれない。
この(CIは、カラムのハイライトをFにして top を実行しているときに、 現在のソートフィールドをとても簡単に確認できる便利な方法である。
R :ソートフィールドの逆順/正順のトグル
この(CIを使うと、「高い方から低い方」と「低い方から高い方」を 切り替えることができる。


注意: フィールドのソートには、カラムに表示されている値ではなく、 内部的な値を使っている。 よって、TTY と WCHAN フィールドは厳密な ASCII 照合順序 (collating sequence) には違反するかもしれない。

3d. カラーマッピング

(CI 'Z' を発行すると、別のスクリーンが表示される。 このスクリーンでは、top の表示に戻る前に、 (CWのみまたは 4 つのウィンドウ全ての色を変更できる。

利用可能な(CI 4 つの大文字で対象 を選択する。 8 つの数字で を選択する。 通常のトグルが利用可能である 'B' :太字の無効/有効 'b' :実行中のタスクを「太字」/反転 'z' :カラー/モノクロ その他のコマンドも利用可能である 'a'/'w' :適用し、次/前へ行く。 <Enter> :適用し、終了する。 'q' :現在の変更を破棄し、終了する。
a' または 'w' を使って対象となるウィンドウを順番に選択し、 そのウィンドウを抜けるときに表示されているカラー形式を適用できる。 もちろん、任意のウィンドウに戻って別な色を再適用したり、 z' トグルで色を完全に F にすることも簡単にできる。
カラーマッピングスクリーンは、(FMまたは(AMにおける (CW/フィールドグループを変更するのにも使える。 q' または <Enter> が押されたときに対象とされていたフィールドは、 top の表示に戻ったときにカレントフィールドにされる。

4. 別形式の表示モード

4a. ウィンドウの概要

フィールドグループ/ウィンドウ :

(FMでは、スクリーン全体で表される単一のウィンドウがある。 この単一のウィンドウは、 4 つの異なるフィールドグループ (以下で繰り返し出てくる(CI 'G' (Xc) のうち 1 つのフィールドグループの表示に変更することもできる。 4 つのフィールドグループの各々には、 個別に設定可能な(SA とフィールドグループ毎の(TA がある。
(AMでは、これら 4 つのフィールドグループは同時に表示することもできるし、 コマンドで個別に F にすることもできる。
(SAは、たとえそのメッセージ行だけであっても、常に存在する。 どの時点でも1 つの (SAだけを表示することができる。 しかし、コマンドによっては、0 から 4 個までの 別々の(TDがスクリーンに表示されているかもしれない。
カレントウィンドウ :

(CWとは、(SAに関連づけられたウィンドウと、 タスクに関連するコマンドが常に送られるウィンドウである。 (AMでは、(TD のトグルを F できるので、 いくつかのコマンドは(CWでは制限されるかもしれない。
(SAの先頭行のトグルを F にすると、更に複雑になる。 ウィンドウ名 ('l' でトグルされる行) がないと、 どのウィンドウが(CWなのか簡単に分からなくなる。

4b. ウィンドウにおけるコマンド

-_ :ウィンドウの表示/非表示のトグル
-' キーは(CWの(TDを O または F にする。 O の場合、この(TAは 'f' と 'o' コマンドで確定した 最小限のカラムヘッダしか表示しない。 またこの(TAは、ユーザーが 0 個以上のタスクに対して適用した 他の(TAのオプション/トグルも反映する。
_' キーは同じことを全ての(TDに対して行う。 一方、このキーは現在表示されている(TDと ユーザーがトグルを F にした(TDを切り替える。 4 つの(TDが現在全て表示されている場合、 この(CIは(SAのみを表示される要素として残す。
*=+ :ウィンドウの均等化 (バランスの取り直し)
=' キーは(CWの(TDを表示させる。 このキーは有効になっている 'i' (アイドルタスク) と n' (最大タスク数) コマンドを無効にする。
+' キーは同じことを全てのウィンドウに対して行う。 4 つの(TDは再度表示され、均等にバランスがとられる。 (TDには、ユーザーが以前に適用したカスタマイズも保持される。 ただし、i' (アイドルタスク) と 'n' (最大タスク数) コマンドは除く。
*A :別形式の表示モードのトグル
このコマンドは(FMと(AMを切り替える。
このコマンドを初めて発行すると、4 つの(TDが全て表示される。 その後、モードを切り替えると、表示対象として選んだ(TDのみが表示される。
*aw :次のウィンドウを前方/後方へ進める
これらのキーは(CWを変更する。 コマンドが送られるウィンドウを順番に変更する。 これらのキーは巡回する形式で動作するので、 どちらのキーを使っても希望する (CW へ辿り着ける。
ウインドウ名が表示されている ('l' のトグルを F にしていない) 場合に、 (CWの名前が強調/色付き表示されていないときは、 (TD が F で多くのコマンドが制限されていることを知らせている。
*G :他のウィンドウ/フィールドグループの選択
1 から 4 まで数字を入力するプロンプトが出される。 この数字は(CWに設定するウィンドウ/フィールドグループを表す。
(FMでは、このコマンドは(CWを変更するのに必須である。 (AMでは、'a' と 'w' コマンドに比べてあまり便利ではない、 単なる代替コマンドである。
g :ウィンドウ/フィールドグループ名の変更
(CWに適用する新しい名前を入力するプロンプトが出される。 ウィンドウ名が表示されている ('l' のトグルが O になっている) 必要はない。

(ASが付いた(CIは、(AM以外でも使われる。 =', 'A', 'G' 常に利用可能である。 a', 'w' カラーマッピングのときと同じ動作をする。

5. ファイル

5a. システムの設定ファイル

このファイルが存在すると、どのバージョンの「ヘルプ」スクリーンが 通常のユーザーに表示されるかに影響を与える。 より重要なのは、top の実行中に通常のユーザーに許可されることを、 このファイルで制限できることである。 通常のユーザーは以下のコマンドを発行できる。 k タスクを kill する。 r タスクを renice する。 d または s 遅延時間/スリープの間隔を変更する。
システムの設定ファイルはtopによって作成されない 。 逆に、ユーザーがこのファイルを手動で作成し、/etc ディレクトリに置く。 このファイル名は 'toprc' でなければならず、 先頭に '.' (ピリオド) が付いてはならない。 このファイルには 2 行だけしか書かれていてはならない。
以下に /etc/toprc の内容の例を示す: s # 1 行目: 「セキュア」モードのスイッチ 5.0 # 2 行目: 「遅延」間隔 (秒単位)

5b. 個人の設定ファイル

このファイルは '$HOME/.top に付けた名前' + 'rc' として書き出される。 (CI 'W' で、このファイルを作成または更新できる。
以下に一般的なレイアウトを示す: グローバル # 1 行目: プログラム名/エイリアス、メモ " # 2 行目: id,altscr,irixps,delay,curwin ウィンドウ毎 # 行 a : ウィンドウ名,fieldscur " # 行 b : winflags,sortindx,maxtasks " # 行 c : summclr,msgsclr,headclr,taskclr
環境変数 $HOME が存在しない場合、 top は個人の設定ファイルをカレントディレクトリに書き込もうとする。 ただしカレントディレクトリの権限に従う。

6. くだらないトリックのサンプル

これらの「トリック」の多くは、ユーザーが top の スケジューリングを向上させた場合に、最もうまく動作する。 ここでは top を nice 値 -10 で開始するため、 ユーザーが権限を持っていると仮定している。

6a. カーネルのマジック

これらのくだらないトリックでは、top が(FMになっている必要がある。
ユーザーインタフェース (プロンプトからヘルプまで) では、 意図的に遅延間隔が 1/10 秒までに制限されている。 しかしユーザーは希望する遅延時間を自由に設定できる。 Linux が top に対して最も良いスケジューリングを行うのを見たいなら、 遅延時間を 0.09 秒以下にすればよい。
この実験では、X Window System で xterm をオープンして最大化する。 その後、以下を実行する: . スケジューリングを向上させ、遅延時間を短くする: nice -n -10 top -d.09 . ソートされるカラムのハイライトを F にし、 パスの長さを最小化する。 . 行の反転によるハイライトを O にして、強調する。 . いろいろなソートカラム (TIME/MEM がうまく動作する) と 正順・逆順のソートを試し、最もアクティブなプロセスが ビューに入るようにする。
Linux がユーザーのために常に動作し、 とても忙しくしているのが分かるだろう。 しかしこれを説明できるプログラムはなかった。
xterm で「黒地に白」を使い、top のタスクの色を黒に設定し、 タスクのハイライトを反転でなく太字になっていることを確認して欲しい。 そして遅延間隔を 0.3 秒程度に設定する。
最もアクティブなプロセスがビューに入った後で、 現在実行中のタスクがゴーストのようなイメージとして見えるだろう。
既存のリソースファイルを削除するか、新しいシンボリックリンクを作成する。 この新しいバージョンを起動し、'T' (隠しキー 3c. タスクエリアコマンド、 ソート(Xt) を入力し、続いて 'W' と 'q' を入力する。 最後に、プログラムを -d0 (遅延時間 0) で再度起動する。
この表示は前の top より 3 倍の割合で更新され、300% スピードアップする。 top は TIME で上位に上がってくるので、 top が最上位に到達するのに投資している間は、忍耐強く待って欲しい。

6b. バウンドするウィンドウ

これらのくだらないトリックでは、top が(AMになっている必要がある。
3 個または 4 個の(TDで表示されているときに、 最後のウィンドウ以外を選択し、アイドルプロセスを F にする。 i' を適用しているかによって、いくつかの(TDがときどきバウンドし、 アコーディオンのようになる。 これは top がスペースを確保するのに最善を尽くしているためである。
各ウィンドウのサマリー行を別々に設定する: メモリ使用量の表示なし・状態表示なし・何も表示しない・メッセージ行のみ。 そして 'a' または 'w' を押し続けると、バウンドするウィンドウの別バージョン (EM 跳ね上がるウインドウが見られる。
4 つのウィンドウ全てを表示し、 各ウィンドウでアイドルプロセスの表示を F にする。 そうすると「非常にバウンドする」ゾーンに入るだろう。

6c. 大きな雛鳥のようなウィンドウ

このくだらないトリックでも(AMが必要である。
4 つのウィンドウ全てを表示し、1:Def が(CWになっているのを確認する。 そして他の全ての(TDが「巣から押し出される」まで、 ウィンドウサイズを大きくし続ける。
他のウィンドウがすべて置き換えられたら、 全ての表示/非表示ウィンドウをトグルする。 そして以下の言葉について良く考えてみよう:
top は嘘をついているのか、ユーザーが強要した 真実を正直に言っているのか?

7. バグ

バグ報告は以下に送って欲しい: Albert D Cahalan, <albert@users.sf.net>

8. 以前の top の履歴

オリジナルの top は、Branko Lankester <lankeste@fwi.uva.nl> の ps プログラムを元にして Roger Binns が書いた。
Robert Nation <nation@rocket.sanders.lockheed.com> は これを proc ファイルシステムに適合させた。
Helmut Geyer <Helmut.Geyer@iwr.uni-heidelberg.de> は 設定可能フィールドのサポートを追加した。
その他にも多くの人々が長年に渡って貢献してきた。

9. 著者

この全く新しく拡張された top の置き換え版は Jim / James C. Warner, <warnerjc@worldnet.att.net> によって書かれた。 ( as a means to learn Linux, can you believe it? ) ( & he accidentally learned a little groff, too! )
以下の方々からは、計り知れない助けをしてもらった: Albert D Cahalan, <albert@users.sf.net> Craig Small, <csmall@small.dropbear.id.au>
-*- few though they are, some yet believe -*- -*- in-the-art -of-programming-*-

10. 関連項目

  free (1),   ps (1),   uptime (1),  atop (1),  slabtop (1),   vmstat (8),   w (1). 

-*-
Copyright (c) 2002 (EM JC Warner & Associates, Ltd.
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with no Front-Cover Texts, no Back-Cover Texts, and with the following Invariant Sections and any sub-sections therein:
STUPIDTRICKSSampler;
AUTHOR
A copy of the license is included in the section entitled \(dqGNU Free Documentation License\(dq.

GNU Free Documentation License

Version 1.1, March 2000
Copyright (C) 2000 Free Software Foundation, Inc. 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.

0. PREAMBLE

The purpose of this License is to make a manual, textbook, or other written document "free" in the sense of freedom: to assure everyone the effective freedom to copy and redistribute it, with or without modifying it, either commercially or noncommercially. Secondarily, this License preserves for the author and publisher a way to get credit for their work, while not being considered responsible for modifications made by others.
This License is a kind of "copyleft", which means that derivative works of the document must themselves be free in the same sense. It complements the GNU General Public License, which is a copyleft license designed for free software.
We have designed this License in order to use it for manuals for free software, because free software needs free documentation: a free program should come with manuals providing the same freedoms that the software does. But this License is not limited to software manuals; it can be used for any textual work, regardless of subject matter or whether it is published as a printed book. We recommend this License principally for works whose purpose is instruction or reference.

1. APPLICABILITY AND DEFINITIONS

This License applies to any manual or other work that contains a notice placed by the copyright holder saying it can be distributed under the terms of this License. The "Document", below, refers to any such manual or work. Any member of the public is a licensee, and is addressed as "you".
A "Modified Version" of the Document means any work containing the Document or a portion of it, either copied verbatim, or with modifications and/or translated into another language.
A "Secondary Section" is a named appendix or a front-matter section of the Document that deals exclusively with the relationship of the publishers or authors of the Document to the Document's overall subject (or to related matters) and contains nothing that could fall directly within that overall subject. (For example, if the Document is in part a textbook of mathematics, a Secondary Section may not explain any mathematics.) The relationship could be a matter of historical connection with the subject or with related matters, or of legal, commercial, philosophical, ethical or political position regarding them.
The "Invariant Sections" are certain Secondary Sections whose titles are designated, as being those of Invariant Sections, in the notice that says that the Document is released under this License.
The "Cover Texts" are certain short passages of text that are listed, as Front-Cover Texts or Back-Cover Texts, in the notice that says that the Document is released under this License.
A "Transparent" copy of the Document means a machine-readable copy, represented in a format whose specification is available to the general public, whose contents can be viewed and edited directly and straightforwardly with generic text editors or (for images composed of pixels) generic paint programs or (for drawings) some widely available drawing editor, and that is suitable for input to text formatters or for automatic translation to a variety of formats suitable for input to text formatters. A copy made in an otherwise Transparent file format whose markup has been designed to thwart or discourage subsequent modification by readers is not Transparent. A copy that is not "Transparent" is called "Opaque".
Examples of suitable formats for Transparent copies include plain ASCII without markup, Texinfo input format, LaTeX input format, SGML or XML using a publicly available DTD, and standard-conforming simple HTML designed for human modification. Opaque formats include PostScript, PDF, proprietary formats that can be read and edited only by proprietary word processors, SGML or XML for which the DTD and/or processing tools are not generally available, and the machine-generated HTML produced by some word processors for output purposes only.
The "Title Page" means, for a printed book, the title page itself, plus such following pages as are needed to hold, legibly, the material this License requires to appear in the title page. For works in formats which do not have any title page as such, "Title Page" means the text near the most prominent appearance of the work's title, preceding the beginning of the body of the text.

2. VERBATIM COPYING

You may copy and distribute the Document in any medium, either commercially or noncommercially, provided that this License, the copyright notices, and the license notice saying this License applies to the Document are reproduced in all copies, and that you add no other conditions whatsoever to those of this License. You may not use technical measures to obstruct or control the reading or further copying of the copies you make or distribute. However, you may accept compensation in exchange for copies. If you distribute a large enough number of copies you must also follow the conditions in section 3.
You may also lend copies, under the same conditions stated above, and you may publicly display copies.

3. COPYING IN QUANTITY

If you publish printed copies of the Document numbering more than 100, and the Document's license notice requires Cover Texts, you must enclose the copies in covers that carry, clearly and legibly, all these Cover Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on the back cover. Both covers must also clearly and legibly identify you as the publisher of these copies. The front cover must present the full title with all words of the title equally prominent and visible. You may add other material on the covers in addition. Copying with changes limited to the covers, as long as they preserve the title of the Document and satisfy these conditions, can be treated as verbatim copying in other respects.
If the required texts for either cover are too voluminous to fit legibly, you should put the first ones listed (as many as fit reasonably) on the actual cover, and continue the rest onto adjacent pages.
If you publish or distribute Opaque copies of the Document numbering more than 100, you must either include a machine-readable Transparent copy along with each Opaque copy, or state in or with each Opaque copy a publicly-accessible computer-network location containing a complete Transparent copy of the Document, free of added material, which the general network-using public has access to download anonymously at no charge using public-standard network protocols. If you use the latter option, you must take reasonably prudent steps, when you begin distribution of Opaque copies in quantity, to ensure that this Transparent copy will remain thus accessible at the stated location until at least one year after the last time you distribute an Opaque copy (directly or through your agents or retailers) of that edition to the public.
It is requested, but not required, that you contact the authors of the Document well before redistributing any large number of copies, to give them a chance to provide you with an updated version of the Document.

4. MODIFICATIONS

You may copy and distribute a Modified Version of the Document under the conditions of sections 2 and 3 above, provided that you release the Modified Version under precisely this License, with the Modified Version filling the role of the Document, thus licensing distribution and modification of the Modified Version to whoever possesses a copy of it. In addition, you must do these things in the Modified Version:
A .Use in the Title Page (and on the covers, if any) a title distinctfrom that of the Document, and from those of previous versions (which should, if there were any, be listed in the History section of the Document). You may use the same title as a previous version if the original publisher of that version gives permission. B .List on the Title Page, as authors, one or more persons or entitiesresponsible for authorship of the modifications in the Modified Version, together with at least five of the principal authors of the Document (all of its principal authors, if it has less than five). C .State on the Title page the name of the publisher of the ModifiedVersion, as the publisher. D .Preserve all the copyright notices of the Document. E .Add an appropriate copyright notice for your modifications adjacentto the other copyright notices. F .Include, immediately after the copyright notices, a license noticegiving the public permission to use the Modified Version under the terms of this License, in the form shown in the Addendum below. G .Preserve in that license notice the full lists of Invariant Sectionsand required Cover Texts given in the Document's license notice. H .Include an unaltered copy of this License. I .Preserve the section entitled "History", and its title, and add to itan item stating at least the title, year, new authors, and publisher of the Modified Version as given on the Title Page. If there is no section entitled "History" in the Document, create one stating the title, year, authors, and publisher of the Document as given on its Title Page, then add an item describing the Modified Version as stated in the previous sentence. J .Preserve the network location, if any, given in the Document forpublic access to a Transparent copy of the Document, and likewise the network locations given in the Document for previous versions it was based on. These may be placed in the "History" section. You may omit a network location for a work that was published at least four years before the Document itself, or if the original publisher of the version it refers to gives permission. K .In any section entitled "Acknowledgements" or "Dedications", preservethe section's title, and preserve in the section all the substance and tone of each of the contributor acknowledgements and/or dedications given therein. L .Preserve all the Invariant Sections of the Document, unaltered in theirtext and in their titles. Section numbers or the equivalent are not considered part of the section titles. M .Delete any section entitled "Endorsements".Such a section may not be included in the Modified Version. N .Do not retitle any existing section as "Endorsements" or to conflictin title with any Invariant Section.

If the Modified Version includes new front-matter sections or appendices that qualify as Secondary Sections and contain no material copied from the Document, you may at your option designate some or all of these sections as invariant. To do this, add their titles to the list of Invariant Sections in the Modified Version's license notice. These titles must be distinct from any other section titles.
You may add a section entitled "Endorsements", provided it contains nothing but endorsements of your Modified Version by various parties--for example, statements of peer review or that the text has been approved by an organization as the authoritative definition of a standard.
You may add a passage of up to five words as a Front-Cover Text, and a passage of up to 25 words as a Back-Cover Text, to the end of the list of Cover Texts in the Modified Version. Only one passage of Front-Cover Text and one of Back-Cover Text may be added by (or through arrangements made by) any one entity. If the Document already includes a cover text for the same cover, previously added by you or by arrangement made by the same entity you are acting on behalf of, you may not add another; but you may replace the old one, on explicit permission from the previous publisher that added the old one.
The author(s) and publisher(s) of the Document do not by this License give permission to use their names for publicity for or to assert or imply endorsement of any Modified Version.

5. COMBINING DOCUMENTS

You may combine the Document with other documents released under this License, under the terms defined in section 4 above for modified versions, provided that you include in the combination all of the Invariant Sections of all of the original documents, unmodified, and list them all as Invariant Sections of your combined work in its license notice.
The combined work need only contain one copy of this License, and multiple identical Invariant Sections may be replaced with a single copy. If there are multiple Invariant Sections with the same name but different contents, make the title of each such section unique by adding at the end of it, in parentheses, the name of the original author or publisher of that section if known, or else a unique number. Make the same adjustment to the section titles in the list of Invariant Sections in the license notice of the combined work.
In the combination, you must combine any sections entitled "History" in the various original documents, forming one section entitled "History"; likewise combine any sections entitled "Acknowledgements", and any sections entitled "Dedications". You must delete all sections entitled "Endorsements."

6. COLLECTIONS OF DOCUMENTS

You may make a collection consisting of the Document and other documents released under this License, and replace the individual copies of this License in the various documents with a single copy that is included in the collection, provided that you follow the rules of this License for verbatim copying of each of the documents in all other respects.
You may extract a single document from such a collection, and distribute it individually under this License, provided you insert a copy of this License into the extracted document, and follow this License in all other respects regarding verbatim copying of that document.

7. AGGREGATION WITH INDEPENDENT WORKS

A compilation of the Document or its derivatives with other separate and independent documents or works, in or on a volume of a storage or distribution medium, does not as a whole count as a Modified Version of the Document, provided no compilation copyright is claimed for the compilation. Such a compilation is called an "aggregate", and this License does not apply to the other self-contained works thus compiled with the Document, on account of their being thus compiled, if they are not themselves derivative works of the Document.
If the Cover Text requirement of section 3 is applicable to these copies of the Document, then if the Document is less than one quarter of the entire aggregate, the Document's Cover Texts may be placed on covers that surround only the Document within the aggregate. Otherwise they must appear on covers around the whole aggregate.

8. TRANSLATION

Translation is considered a kind of modification, so you may distribute translations of the Document under the terms of section 4. Replacing Invariant Sections with translations requires special permission from their copyright holders, but you may include translations of some or all Invariant Sections in addition to the original versions of these Invariant Sections. You may include a translation of this License provided that you also include the original English version of this License. In case of a disagreement between the translation and the original English version of this License, the original English version will prevail.

9. TERMINATION

You may not copy, modify, sublicense, or distribute the Document except as expressly provided for under this License. Any other attempt to copy, modify, sublicense or distribute the Document is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance.

10. FUTURE REVISIONS OF THIS LICENSE

The Free Software Foundation may publish new, revised versions of the GNU Free Documentation License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns. See http://www.gnu.org/copyleft/.
Each version of the License is given a distinguishing version number. If the Document specifies that a particular numbered version of this License "or any later version" applies to it, you have the option of following the terms and conditions either of that specified version or of any later version that has been published (not as a draft) by the Free Software Foundation. If the Document does not specify a version number of this License, you may choose any version ever published (not as a draft) by the Free Software Foundation.

ADDENDUM: How to use this License for your documents

To use this License in a document you have written, include a copy of the License in the document and put the following copyright and license notices just after the title page:

Copyright (c) YEAR YOUR NAME.
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation;with the Invariant Sections being LIST THEIR TITLES, with the Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST. A copy of the license is included in the section entitled "GNU Free Documentation License".
If you have no Invariant Sections, write "with no Invariant Sections" instead of saying which ones are invariant. If you have no Front-Cover Texts, write "no Front-Cover Texts" instead of "Front-Cover Texts being LIST"; likewise for Back-Cover Texts.
If your document contains nontrivial examples of program code, we recommend releasing these examples in parallel under your choice of free software license, such as the GNU General Public License, to permit their use in free software.

end of GNU Free Documentation License