破損した .history ファイルが原因で、システムが遅くなります
Issue
- ".history" ファイルのデータの形式が不正になり、ファイルサイズが大きくなります。
- 各コマンドの履歴がファイルに記録されます。その際、タイムスタンプ行と、EOL (End Of Line) で終了するコマンドエントリ行が一緒に記録されます。
- 通常、.history ファイルは以下のようになります。
$ cat -n .history
\#+1289787344
set
- タイムスタンプと run コマンドエントリは順番通りに記録されません。run コマンドエントリではなく、タイムスタンプが予想通りに記録されません (下記 4 行目を参照)。また、いくつかのエントリが予想外に結合されます (下記 6 および 7 行目を参照)。
- 不正の形式の .history ファイルは以下のようになります。
$ cat -n .history
\#+1289787344
test
\#+1289787367
1289787366
\#+1289787367
128978\#+12897\#+1289\#+12897test
\#+1289\#+12897testls\#\#+1289787401l12\#+1289787402
st
- csh が大きな .history ファイルなどを読み込むためにメモリを大量に使用するため、システムが遅くなります。
Environment
- Red Hat Enterprise Linux 2.1
- Red Hat Enterprise Linux 3
- Red Hat Enterprise Linux 4
- Red Hat Enterprise Linux 5
- Red Hat Enterprise Linux 6
- RHEL5: tcsh-6.14-14.el5-x86_64
- RHEL6: tcsh-6.17-8.el6.x86_64
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
