LoginSignup
1
0

More than 5 years have passed since last update.

Yosemiteでのcoreファイルの設定

Posted at

macでcoreファイルの設定を確認するときに以前は/etc/hostconfigを確認すれば良かった様であるが、yosemite以降はこのhostconfigというファイルがそもそもないらしい。

manコマンドでcore(5)を見ると
" Core dumps are disabled by default under Darwin/Mac OS X. To re-enable
core dumps, a privileged user must do one of the following

 * Edit /etc/launchd.conf or $HOME/.launchd.conf and add a line specifying
 the limit limit core unlimited

 * A privileged user can also enable cores with launchctl limit core
 unlimited

 * A privileged user can also enable core files by using ulimit(1) or
 limit(1) depending upon the shell. "

とあるのでやはりOSX以降はデフォルトでcoreファイルは生成されない模様。(まあそうですよね)

常時coreファイルを生成するようにするにはlaunchd.confを書き換えれば良いと思われるがこのファイルも元々はないファイルなので作らなければならないし、素人には危険なのでこの方法はやらない。

よってターミナルでulimit -c unlimited を実行すれば良い。

注意:coreファイルの生成は自己責任で。終わったら消しましょう。

1
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
0