「サーバとの接続」の編集履歴(バックアップ)一覧はこちら

サーバとの接続」(2012/06/27 (水) 19:07:43) の最新版変更点

追加された行は緑色になります。

削除された行は赤色になります。

&counter()人目 ( ̄ー ̄)/~~ アリガトネ [[MySQL5.5 リファレンス>トップページ]] :: 3. [[チュートリアル]] :: 3.1 [[サーバとの接続]] ORIGINAL : [[http://dev.mysql.com/doc/refman/5.5/en/tutorial.html]] ----
&counter()人目 ( ̄ー ̄)/~~ アリガトネ [[MySQL5.5 リファレンス>トップページ]] :: 3. [[チュートリアル]] :: 3.1 [[サーバとの接続]] ORIGINAL : [[http://dev.mysql.com/doc/refman/5.5/en/connecting-disconnecting.html]] ---- サーバーとの接続および接続切断 サーバーに接続する為には、MySQLのユーザー名が必要で、多くの場合はパスワードも必要でうs。ログインしているマシンと違うマシンにサーバーがある場合は、ホスト名も事前に知っておく必要があります。管理者に接続に必要なパラメータを聞いてください。(つまり、利用するホスト名、ユーザ名、パスワードです)これらのパラメータが分かれば、下記のようにして接続できます。 #highlight(){ shell> mysql -h host -u user -p Enter password: ********} ホストとユーザは、MySQLサーバーが稼働しているホスト名と、あなたのMySQLアカウントのユーザー名です。適切な値を置き換えてください。 ********はパスワードを示していて、"Enter password"プロンプトが現れた時にパスワードを入力してください If that works, you should see some introductory information followed by a mysql> prompt: shell> mysql -h host -u user -p Enter password: ******** Welcome to the MySQL monitor. Commands end with ; or \g. Your MySQL connection id is 25338 to server version: 5.5.27-standard Type 'help;' or '\h' for help. Type '\c' to clear the buffer. mysql> The mysql> prompt tells you that mysql is ready for you to enter commands. If you are logging in on the same machine that MySQL is running on, you can omit the host, and simply use the following: shell> mysql -u user -p If, when you attempt to log in, you get an error message such as ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2), it means that the MySQL server daemon (Unix) or service (Windows) is not running. Consult the administrator or see the section of Chapter 2, Installing and Upgrading MySQL that is appropriate to your operating system. For help with other problems often encountered when trying to log in, see Section C.5.2, “Common Errors When Using MySQL Programs”. Some MySQL installations permit users to connect as the anonymous (unnamed) user to the server running on the local host. If this is the case on your machine, you should be able to connect to that server by invoking mysql without any options: shell> mysql After you have connected successfully, you can disconnect any time by typing QUIT (or \q) at the mysql> prompt: mysql> QUIT Bye On Unix, you can also disconnect by pressing Control+D. Most examples in the following sections assume that you are connected to the server. They indicate this by the mysql> prompt.

表示オプション

横に並べて表示:
変化行の前後のみ表示: