Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | |||||
3 | 4 | 5 | 6 | 7 | 8 | 9 |
10 | 11 | 12 | 13 | 14 | 15 | 16 |
17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 | 25 | 26 | 27 | 28 | 29 | 30 |
31 |
Tags
- Web
- 자바
- centos
- Linux
- Security
- framework
- data
- Numpy
- db
- Pattern
- 함수
- mysql
- error
- ai
- LIST
- Python
- Analysis
- javascript
- Github
- mariaDB
- interface
- Spring
- learning
- Deep
- SSH
- Server
- git
- 인공지능
- java
- DeepLearning
Archives
- Today
- Total
PostIT
[MAC/MariaDB]Error: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) / mysql 설치 및 에러 없애기 본문
DB/MariaDB
[MAC/MariaDB]Error: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2) / mysql 설치 및 에러 없애기
shun10114 2016. 8. 10. 14:42# MariaDB 에러 해결 및 설치 후 해야할 것
만약, 맥에서 MySql 사용시 아와 같은 에러가 난다면,
혹은 brew로 설치한 바로 다음이라면,
1) Error: Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
-> 권한 문제인지 아니면 파일이 없어서 문제인지 확인해서 생성해주어야 한다.
만약 기존의 것을 다시 만들어 사용한다면, DB파일들만 옮기고 이 부분만 다시 만들면 문제없이 실행될것이다.
$ brew services restart mysql
를 꼭 입력해보길 바랍니다.
만약, Homebrew로 mysql을 설치한 것이라면요.
2) 비밀번호 설정 및 기본 옵션 설정
$ mysql_secure_installation
를 입력해서 비밀번호와 기본 옵션을 설정하시길 바랍니다.
3) DB 접속
$ mysql -uroot -p
비밀번호 입력
그러면 들어가실 수 있으실 것입니다.
일단 저는 이렇게 해결했습니다....몇일 걸렸는데 다른분은 쉽게 해결하길 응원합니다.
2016.09.12 업데이트
(터미널에서)
1. /usr/local/var/mysql 안에 폴더를 삭제 후
2. mysql_install_db
'DB > MariaDB' 카테고리의 다른 글
[DB/MariaDB] SQL 예제를 통한 JOIN의 종류 파악 (2) | 2017.04.13 |
---|---|
[MariaDB/Mysql] 분실한 Mysql root Password 재설정하기. (0) | 2017.01.19 |
[MySql] Mariadb, MYsql 사용자 권한주기 및 확인 (0) | 2016.12.02 |
[MariaDB] MariaDB에서 날짜에 맞는 값을 가져오기 위한 함수와 SQL (0) | 2016.11.16 |
[맥/MAC] MariaDB, The server quit without updating PID file 에러시 (0) | 2016.08.07 |
Comments