IT Japan

Mac (Yosemite)에서 Homebrew 다시 설치. 본문

MySQL

Mac (Yosemite)에서 Homebrew 다시 설치.

swhwang 2016. 7. 29. 18:10
반응형



Mac에서 MySQL을 brew에서 넣으려고했지만, brew가 2013 년에 넣은 채로 방치로 움직이지 않게되어있다. 그리고, brew 업데이트거나 다시 설치 라든지하려고했지만 예와 같이 솔직하게 실행할 수 없습니다.

Mac에서 ruby​​ 경로는 / usr / bin / ruby​​하지만 / usr / local / bin / ruby​​가 없다고 불쾌하기 때문에 일단 링크 붙여 두거나과 다음 실행하면 또 혼났다.

$ sudo ln -s / usr / bin / ruby​​ / usr / local / bin / ruby
ln : / usr / local / bin / ruby​​ : File exists

이렇게되어있다.

$ ll / usr / local / bin / ruby
lrwxr-xr-x 1 myname mygroup 34 9 28 2013 / usr / local / bin / ruby​​ -> ../Cellar/ruby/2.0.0-p247/bin/ruby

일단 오래 끈다.

$ sudo rm -rf / usr / local / Cellar

다시 다음 실행.

$ sudo ln -s / usr / bin / ruby​​ / usr / local / bin / ruby

Xcode 라이선스에 합의 해 둔다. (brew 설치시 필요)

$ sudo xcodebuild -license

재차, brew 설치. URL은 2015 년 8 월 시점의 것.

$ ruby​​ -e "$ (curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

지금 다녔다. 는 MySQL을 넣는다.

$ brew install mysql


==> Installing mysql dependency: openssl
==> Downloading https://homebrew.bintray.com/bottles/openssl-1.0.2d_1.yosemite.bottle.tar.gz
######################################################################## 100.0%
==> Pouring openssl-1.0.2d_1.yosemite.bottle.tar.gz
==> Caveats
A CA file has been bootstrapped using certificates from the system
keychain. To add additional certificates, place .pem files in
  /usr/local/etc/openssl/certs
 
and run
  /usr/local/opt/openssl/bin/c_rehash
 
This formula is keg-only, which means it was not symlinked into /usr/local.
 
Apple has deprecated use of OpenSSL in favor of its own TLS and crypto libraries
 
Generally there are no consequences of this for you. If you build your
own software and it requires this formula, you'll need to add to your
build variables:
 
    LDFLAGS:  -L/usr/local/opt/openssl/lib
    CPPFLAGS: -I/usr/local/opt/openssl/include
 
==> Summary
<img src="https://s.w.org/images/core/emoji/72x72/1f37a.png" alt="🍺" class="emoji" draggable="false">  /usr/local/Cellar/openssl/1.0.2d_1: 464 files, 18M
==> Installing mysql
==> Downloading https://homebrew.bintray.com/bottles/mysql-5.6.26.yosemite.bottle.tar.gz
######################################################################## 100.0%
==> Pouring mysql-5.6.26.yosemite.bottle.tar.gz
==> Caveats
A "/etc/my.cnf" from another install may interfere with a Homebrew-built
server starting up correctly.
 
To connect:
    mysql -uroot
 
To have launchd start mysql at login:
  ln -sfv /usr/local/opt/mysql/*.plist ~/Library/LaunchAgents
Then to load mysql now:
  launchctl load ~/Library/LaunchAgents/homebrew.mxcl.mysql.plist
Or, if you don't want/need launchctl, you can just run:
  mysql.server start
==> /usr/local/Cellar/mysql/5.6.26/bin/mysql_install_db --verbose --user=user --basedir=/usr/local/Cellar/mysql/5.6.26 --datadir=/
==> Summary
<img src="https://s.w.org/images/core/emoji/72x72/1f37a.png" alt="🍺" class="emoji" draggable="false">  /usr/local/Cellar/mysql/5.6.26: 9854 files, 339M



역시 brew 없다고 곤란하네요 ...

추기
brew 삭제 재설치 이전 넣은 wget이 소멸 한! 그런 것인가. 재 빠르게 wget 다시 설치했지만. wget 없다고 곤란합니다.

추기 2
MySQL은 제거하고 MariaDB 넣었다. 사용자 데이터베이스 MySQL 시대 것이 그대로 남아있다.

$ brew uninstall mysql
$ brew install mariadb

반응형
Comments