debian6(32bit)でrailsを動かしてみる(2)-- mysqlのインストール
root@debian6-i386-gen123:~/test/config# apt-cache search mysql-server auth2db - Powerful and eye-candy IDS logger, log viewer and alert generator cacti - Frontend to rrdtool for monitoring systems and services mysql-server - MySQL データベースサーバ (最新版に依存するメタパッケージ) mysql-server-5.1 - MySQL データベースサーババイナリおよびシステムデータベースの設定 mysql-server-core-5.1 - MySQL データベースサーババイナリ torrentflux - ウェブベースで多機能な BitTorrent ダウンロードマネージャ root@debian6-i386-gen123:~/test/config#
mysql-serverをインストール
root@debian6-i386-gen123:~/test/config# ps -ef | grep mysql root 2993 1 0 23:02 ? 00:00:00 /bin/sh /usr/bin/mysqld_safe mysql 3104 2993 0 23:02 ? 00:00:00 /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --user=mysql --pid-file=/var/run/mysqld/mysqld.pid --socket=/var/run/mysqld/mysqld.sock --port=3306 root 3105 2993 0 23:02 ? 00:00:00 logger -t mysqld -p daemon.error root 3213 1938 0 23:03 pts/1 00:00:00 grep mysql root@debian6-i386-gen123:~/test/config#
debianの場合は、インストールの途中で、mysql用のrootのパスワードを聞いてくれる。
また、インストール終了後、サービスは勝手に走ってくれるんだよね。
root@debian6-i386-gen123:~/test/config# mysql -u root -p Enter password: Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 40 Server version: 5.1.49-3 (Debian) Copyright (c) 2000, 2010, Oracle and/or its affiliates. All rights reserved. This software comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to modify and redistribute it under the GPL v2 license Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. mysql> use mysql Reading table information for completion of table and column names You can turn off this feature to get a quicker startup with -A Database changed mysql> mysql> select user,password from user;
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- +
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
user | password |
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- +
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
root | *05B752D57A30918CEE0xxxxxxxxxxxxxxxxxxxxx |
root | *05B752D57A30918CEE0xxxxxxxxxxxxxxxxxxxxx |
root | *05B752D57A30918CEE0xxxxxxxxxxxxxxxxxxxxx |
debian-sys-maint | *56F737D29E7C1C0190Axxxxxxxxxxxxxxxxxxxxx |
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- +
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
なぜ、rootのエントリが3つもあるんだ? ま、いっか。