$ mysql -u root -p
(provide your mysql root password to log in to mysql shell)
mysql> create database pnl
mysql> use pnl;
mysql> CREATE USER 'pnl'@'localhost' IDENTIFIED WITH mysql_native_password BY 'YourPassword';
mysql> grant all privileges on pnl.* to 'pnl'@'localhost';
The database name is pnl
.
$ mysql -u pnl -p pnl < pnlc7.sql
(provide YourPassword to log in to mysql shell)
(takes ~15 seconds)
$ mysql -u pnl -p pnl
mysql> use pnl;
mysql> show tables;
+------------------------+
| Tables_in_pnl |
+------------------------+
| pnl_commentmeta |
| pnl_comments |
| pnl_links |
| pnl_options |
...
...
My tar ball will unzip to /var/www/html/
. So I suggest backing up your html/
.
Feel free to work around it however way you prefer without backing up your html/
.
wget dropbox_link
cd /var/www/
mv html html.bak
tar -xzf pnl-local-website.tar.gz
php -c /path/to/your/config.ini -S 127.0.0.1:9000 -t /var/www/html/
http://127.0.0.1:9000/wp-admin/install.php
DB_HOST: 127.0.0.1
DB_NAME: pnl
DB_USER: pnl
DB_PASSWORD: YourPassword
table_prefix: pnl_
The above are the credentials you need to establish database connection.
If wp-admin/install.php
does not work for you, feel free to follow
any method from https://wordpress.org/support/article/how-to-install-wordpress/#setup-configuration-file .
Note: DB_HOST: localhost
did not work for me.
- Database connection troubleshooting (if needed)
Save MySQLi Procedural code as /var/www/html/test.php
and
see if you can load http://127.0.0.1:9000/test.php in your browser.