Skip to content

Instantly share code, notes, and snippets.

@marcosgz
Created September 6, 2011 13:24
Show Gist options
  • Save marcosgz/1197519 to your computer and use it in GitHub Desktop.
Save marcosgz/1197519 to your computer and use it in GitHub Desktop.
Instalação do Mysql no ubuntu 11.04
# Install mysql
root@host:~# apt-get install mysql-server mysql-client libmysql-ruby libmysqlclient-dev mysql-admin mysql-query-browser
# Add "marcos" user with all privileges.
root@host:~# mysql -u root -p
mysql> CREATE USER 'marcos'@'localhost' IDENTIFIED BY 'secret';
mysql> GRANT ALL PRIVILEGES ON *.* TO 'marcos'@'localhost' WITH GRANT OPTION;
mysql> quit
# Mysql config
root@host:~# nano ~marcos/.my.cnf
[client]
user=marcos
password=secret
[mysql]
pager="less -Si"
root@host:~# chown marcos:marcos ~marcos/.my.cnf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment