homebrewで入れたmysql, LauchAgentsで管理してたけど止めたいとき
>>> mysql.server stop
Shutting down MySQL
.. ERROR! The server quit without updating PID file (/usr/local/var/mysql/hoge.pid).
pidファイル updateできないのでエラーになったので
>>> open ~/Library/LaunchAgents/homebrew.mxcl.mysql.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>KeepAlive</key>
<true/>
<key>Label</key>
<string>homebrew.mxcl.mysql</string>
<key>ProgramArguments</key>
<array>
<string>/usr/local/opt/mysql/bin/mysqld_safe</string>
<string>--bind-address=127.0.0.1</string>
<string>--datadir=/usr/local/var/mysql</string>
</array>
<key>RunAtLoad</key>
<true/>
<key>WorkingDirectory</key>
<string>/usr/local/var/mysql</string>
<key>UserName</key>
<string>koichi.yanagimoto</string>
</dict>
</plist>
が出てくるので、
<key>KeepAlive</key>
<false/>
にします。
>>> launchctl unload ~/Library/LaunchAgents/homebrew.mxcl.mysql.plist
>>> launchctl load ~/Library/LaunchAgents/homebrew.mxcl.mysql.plist
して、
>>> mysql.server stop
で
Shutting down MySQL
.. SUCCESS!
SUCCESS!
Author And Source
この問題について(homebrewで入れたmysql, LauchAgentsで管理してたけど止めたいとき), 我々は、より多くの情報をここで見つけました https://qiita.com/kyanagimoto/items/415d24de13a11eb8c294著者帰属:元の著者の情報は、元のURLに含まれています。著作権は原作者に属する。
Content is automatically searched and collected through network algorithms . If there is a violation . Please contact us . We will adjust (correct author information ,or delete content ) as soon as possible .