Enter password: ←MySQL 用root パスワード入力します(画面上は表示されません)
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 12
Server version: 8.0.30 Source distribution
Copyright(c)2000, 2022, Oracle and/or its affiliates.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h'for help. Type '\c' to clear the current input statement.
#WordPressが制御する専用のデータベースを作成
mysql> CREATE DATABASE ark_db DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
Query OK, 1 row affected(0.00 sec)
#データベースの確認
mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| mysql |
| performance_schema |
| sys
| ark_db |
+--------------------+
5 rows inset(0.00 sec)
#アカウントを作成し、パスワードを設定し、作成したデータベースへのアクセスを許可します
mysql>CREATE USER 'ark_user'@'localhost' IDENTIFIED WITH mysql_native_password BY 'pwd#@12345';
Query OK, 0 rows affected(0.04 sec)
ユーザーがセットアップ済データベースにフルアクセスできる必要があることをデータベースに知らせます
mysql> GRANT ALL ON ark_db.* TO 'ark_user'@'localhost';
Query OK, 0 rows affected(0.04 sec)
#権限をリロード
mysql> flush privileges;
#mysqlを終了する
mysql> exit;
Bye
# mysql -u root -p
Enter password: ←MySQL 用root パスワード入力します(画面上は表示されません)
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 12
Server version: 8.0.30 Source distribution
Copyright (c) 2000, 2022, Oracle and/or its affiliates.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
#WordPressが制御する専用のデータベースを作成
mysql> CREATE DATABASE ark_db DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
Query OK, 1 row affected (0.00 sec)
#データベースの確認
mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| mysql |
| performance_schema |
| sys
| ark_db |
+--------------------+
5 rows in set (0.00 sec)
#アカウントを作成し、パスワードを設定し、作成したデータベースへのアクセスを許可します
mysql>CREATE USER 'ark_user'@'localhost' IDENTIFIED WITH mysql_native_password BY 'pwd#@12345';
Query OK, 0 rows affected (0.04 sec)
ユーザーがセットアップ済データベースにフルアクセスできる必要があることをデータベースに知らせます
mysql> GRANT ALL ON ark_db.* TO 'ark_user'@'localhost';
Query OK, 0 rows affected (0.04 sec)
#権限をリロード
mysql> flush privileges;
#mysqlを終了する
mysql> exit;
Bye
# mysql -u root -p
Enter password: ←MySQL 用root パスワード入力します(画面上は表示されません)
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 12
Server version: 8.0.30 Source distribution
Copyright (c) 2000, 2022, Oracle and/or its affiliates.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
#WordPressが制御する専用のデータベースを作成
mysql> CREATE DATABASE ark_db DEFAULT CHARACTER SET utf8 COLLATE utf8_unicode_ci;
Query OK, 1 row affected (0.00 sec)
#データベースの確認
mysql> show databases;
+--------------------+
| Database |
+--------------------+
| information_schema |
| mysql |
| performance_schema |
| sys
| ark_db |
+--------------------+
5 rows in set (0.00 sec)
#アカウントを作成し、パスワードを設定し、作成したデータベースへのアクセスを許可します
mysql>CREATE USER 'ark_user'@'localhost' IDENTIFIED WITH mysql_native_password BY 'pwd#@12345';
Query OK, 0 rows affected (0.04 sec)
ユーザーがセットアップ済データベースにフルアクセスできる必要があることをデータベースに知らせます
mysql> GRANT ALL ON ark_db.* TO 'ark_user'@'localhost';
Query OK, 0 rows affected (0.04 sec)
#権限をリロード
mysql> flush privileges;
#mysqlを終了する
mysql> exit;
Bye
2.Wordpressインストール
Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
# cd /var/www/html/arkgame.com
# wget http://ja.wordpress.org/latest-ja.tar.gz
# tar xvf latest-ja.tar.gz
# cd /var/www/html/arkgame.com
# wget http://ja.wordpress.org/latest-ja.tar.gz
# tar xvf latest-ja.tar.gz
# cd /var/www/html/arkgame.com
# wget http://ja.wordpress.org/latest-ja.tar.gz
# tar xvf latest-ja.tar.gz
3.Wordpress設定ファイルを編集
# cd wordpress/
# cp wp-config-sample.php wp-config.php
# vi wp-config.php
Plain text
Copy to clipboard
Open code in new window
EnlighterJS 3 Syntax Highlighter
// ** Database settings - You can get this info from your web host ** //
/** The name of the database for WordPress */^
define('DB_NAME', 'ark_db');
/** Database username */
define('DB_USER', 'ark_user');
/** Database password */
define('DB_PASSWORD', 'pwd#@12345');
// ** Database settings - You can get this info from your web host ** //
/** The name of the database for WordPress */^
define('DB_NAME', 'ark_db');
/** Database username */
define('DB_USER', 'ark_user');
/** Database password */
define('DB_PASSWORD', 'pwd#@12345');
// ** Database settings - You can get this info from your web host ** //
/** The name of the database for WordPress */^
define('DB_NAME', 'ark_db');
/** Database username */
define('DB_USER', 'ark_user');
/** Database password */
define('DB_PASSWORD', 'pwd#@12345');