{"id":257,"date":"2015-02-12T15:20:29","date_gmt":"2015-02-12T08:20:29","guid":{"rendered":"http:\/\/www.st.ac.th\/krubuncha\/?p=257"},"modified":"2016-08-03T09:02:09","modified_gmt":"2016-08-03T02:02:09","slug":"%e0%b8%81%e0%b8%b2%e0%b8%a3%e0%b8%95%e0%b8%b4%e0%b8%94%e0%b8%95%e0%b8%b1%e0%b9%89%e0%b8%87-apache24mysql56php56","status":"publish","type":"post","link":"https:\/\/www.st.ac.th\/krubuncha\/%e0%b8%81%e0%b8%b2%e0%b8%a3%e0%b8%95%e0%b8%b4%e0%b8%94%e0%b8%95%e0%b8%b1%e0%b9%89%e0%b8%87-apache24mysql56php56\/","title":{"rendered":"\u0e01\u0e32\u0e23\u0e15\u0e34\u0e14\u0e15\u0e31\u0e49\u0e07 Apache24+Mysql56+Php56"},"content":{"rendered":"<h2>\u00a0<a title=\"Permanent Link to How to Install Apache, MySQL, PHP, and phpMyAdmin on FreeBSD\" href=\"https:\/\/www.iceflatline.com\/2011\/11\/how-to-install-apache-mysql-php-and-phpmyadmin-on-freebsd\/\" rel=\"bookmark\">How to Install Apache, MySQL, PHP, and phpMyAdmin on FreeBSD<\/a><\/h2>\n<p class=\"comment_edit\"><span class=\"comment_link\"><a href=\"https:\/\/www.iceflatline.com\/2011\/11\/how-to-install-apache-mysql-php-and-phpmyadmin-on-freebsd\/#comments\">127 Comments<\/a><\/span><\/p>\n<div class=\"time_link\">November 10th, 2011 by iceflatline<\/div>\n<div class=\"entry\">\n<p><strong>(20160616 \u2014 The steps in this post were amended to address changes in recent versions of software. Minor editorial corrections were also made \u2014 iceflatline)<\/strong><\/p>\n<p>This post will describe how to install and configure Apache, MySQL, PHP and phpMyAdmin on FreeBSD for basic local web development. Once set up, you\u2019ll be able to use your \u201cAMP\u201d server to do web development, code testing, maintain local copies of your web sites, etc.<\/p>\n<p>The software discussed in this post are available as free and open source under various licensing structures. The versions of software discussed in this post are as follows:<\/p>\n<ul>\n<li>FreeBSD 10.3-RELEASE-p4<\/li>\n<li>Virtual Box 5.0.20 r106931<\/li>\n<li>apache24-2.4.20_1<\/li>\n<li>mysql57-server-5.7.12_1<\/li>\n<li>mod_php70-7.0.7<\/li>\n<li>php70-7.0.7<\/li>\n<li>php70-extensions-1.1<\/li>\n<li>phpMyAdmin-4.6.2<\/li>\n<li>WordPress 4.5.2<\/li>\n<\/ul>\n<p>The following steps discussed in this post assume you have the FreeBSD Ports Collection installed. If not, you can install it using the following commands:<\/p>\n<div id=\"crayon-57a1501ac3ff2814195288\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac3ff2814195288-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac3ff2814195288-2\">2<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac3ff2814195288-1\" class=\"crayon-line\"><span class=\"crayon-e\">portsnap <\/span><span class=\"crayon-e\">fetch<\/span><\/div>\n<div id=\"crayon-57a1501ac3ff2814195288-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">portsnap <\/span><span class=\"crayon-v\">extract<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>If the Ports Collection is already installed, make sure to update it:<\/p>\n<div id=\"crayon-57a1501ac4009708330096\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4009708330096-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4009708330096-1\" class=\"crayon-line\"><span class=\"crayon-e\">portsnap <\/span><span class=\"crayon-e\">fetch <\/span><span class=\"crayon-v\">update<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Okay, let\u2019s get started. All commands are issued as the root user or by simulating the root user by using the command <em>su<\/em>. While building the various ports you should accept all default configuration options unless otherwise instructed.<\/p>\n<p><strong>Install Apache<\/strong><\/p>\n<p>Navigate to the Apache server port and build it:<\/p>\n<div id=\"crayon-57a1501ac4015459764952\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4015459764952-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac4015459764952-2\">2<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4015459764952-1\" class=\"crayon-line\"><span class=\"crayon-v\">cd<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">ports<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">www<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-e\">apache24<\/span><\/div>\n<div id=\"crayon-57a1501ac4015459764952-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">make <\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">recursive <\/span><span class=\"crayon-e\">install <\/span><span class=\"crayon-v\">distclean<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Once Apache has been successfully installed, add the following line to <em>\/etc\/rc.conf<\/em> so that the Apache server will start automatically at system boot.<\/p>\n<div id=\"crayon-57a1501ac4020202447075\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4020202447075-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4020202447075-1\" class=\"crayon-line\"><span class=\"crayon-e\">sysrc <\/span><span class=\"crayon-v\">apache24_enable<\/span><span class=\"crayon-o\">=<\/span><span class=\"crayon-v\">YES<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Now let\u2019s start Apache to make sure it works:<\/p>\n<div id=\"crayon-57a1501ac402a977779992\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac402a977779992-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac402a977779992-1\" class=\"crayon-line\"><span class=\"crayon-e\">service <\/span><span class=\"crayon-e\">apache24 <\/span><span class=\"crayon-v\">start<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Point your web browser to the host name or IP address of the FreeBSD host you\u2019ve installed Apache on and you should see the venerable \u201cIt works!\u201d<\/p>\n<p><strong>Install MySQL<\/strong>.<\/p>\n<p>Now let\u2019s build the MySQL server:<\/p>\n<div id=\"crayon-57a1501ac4034969578617\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4034969578617-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac4034969578617-2\">2<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4034969578617-1\" class=\"crayon-line\"><span class=\"crayon-v\">cd<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">ports<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">databases<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">mysql57<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">server<\/span><\/div>\n<div id=\"crayon-57a1501ac4034969578617-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">make <\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">recursive <\/span><span class=\"crayon-e\">install <\/span><span class=\"crayon-v\">distclean<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Add the following line to <em>\/etc\/rc.conf<\/em>:<\/p>\n<div id=\"crayon-57a1501ac403f756092718\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac403f756092718-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac403f756092718-1\" class=\"crayon-line\"><span class=\"crayon-e\">sysrc <\/span><span class=\"crayon-v\">mysql_enable<\/span><span class=\"crayon-o\">=<\/span><span class=\"crayon-v\">YES<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>And start the mysql server:<\/p>\n<div id=\"crayon-57a1501ac4048305323928\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4048305323928-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4048305323928-1\" class=\"crayon-line\"><span class=\"crayon-e\">service <\/span><span class=\"crayon-v\">mysql<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">server <\/span><span class=\"crayon-v\">start<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Then set a password for the MySQL root user:<\/p>\n<div id=\"crayon-57a1501ac4052702850209\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4052702850209-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4052702850209-1\" class=\"crayon-line\"><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">bin<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">mysql<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">u<\/span> <span class=\"crayon-v\">root<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">p<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>You\u2019ll be requested to enter a password. Enter the password contained in <em>\/root\/.mysql_secret<\/em>. You\u2019ll now be at the command prompt for the mysql server. Change your password using the following command:<\/p>\n<div id=\"crayon-57a1501ac405d701399183\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac405d701399183-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac405d701399183-1\" class=\"crayon-line\"><span class=\"crayon-e\">ALTER <\/span><span class=\"crayon-i\">USER<\/span> <span class=\"crayon-s\">&#8216;root&#8217;<\/span><span class=\"crayon-sy\">@<\/span><span class=\"crayon-s\">&#8216;localhost&#8217;<\/span> <span class=\"crayon-e\">IDENTIFIED <\/span><span class=\"crayon-i\">BY<\/span> <span class=\"crayon-s\">&#8216;your-new-password&#8217;<\/span><span class=\"crayon-sy\">;<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Enter \u2018quit\u2019 to exit the server. You may now delete <em>\/root\/.mysql_secret<\/em>.<\/p>\n<p><strong>Install PHP<\/strong><\/p>\n<p>Next, we\u2019ll build PHP:<\/p>\n<div id=\"crayon-57a1501ac4067443781567\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4067443781567-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac4067443781567-2\">2<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4067443781567-1\" class=\"crayon-line\"><span class=\"crayon-v\">cd<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">ports<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">lang<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-e\">php70<\/span><\/div>\n<div id=\"crayon-57a1501ac4067443781567-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">make <\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">recursive <\/span><span class=\"crayon-e\">install <\/span><span class=\"crayon-v\">distclean<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Then the module required to support PHP applications on Apache:<\/p>\n<div id=\"crayon-57a1501ac4071590471216\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4071590471216-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac4071590471216-2\">2<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4071590471216-1\" class=\"crayon-line\"><span class=\"crayon-v\">cd<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">ports<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">www<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-e\">mod_php70<\/span><\/div>\n<div id=\"crayon-57a1501ac4071590471216-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">make <\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">recursive <\/span><span class=\"crayon-e\">install <\/span><span class=\"crayon-v\">distclean<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Now let\u2019s add the extensions to PHP to round out its capabilities. Before we build this port though we\u2019ll want to add support for MySQLi (an improved interface to MySQL) in order to communicate with the MySQL server.<\/p>\n<div id=\"crayon-57a1501ac407c008358619\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac407c008358619-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac407c008358619-2\">2<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac407c008358619-1\" class=\"crayon-line\"><span class=\"crayon-v\">cd<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">ports<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">lang<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">php70<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">extensions<\/span><span class=\"crayon-o\">\/<\/span><\/div>\n<div id=\"crayon-57a1501ac407c008358619-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">make <\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-i\">recursive<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>In the corresponding menu you should select \u201cMYSQLI\u201d, then proceed with building the port:<\/p>\n<div id=\"crayon-57a1501ac4085658155329\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4085658155329-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4085658155329-1\" class=\"crayon-line\"><span class=\"crayon-e\">make <\/span><span class=\"crayon-e\">install <\/span><span class=\"crayon-v\">distclean<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p><strong>Install phpMyAdmin<\/strong><\/p>\n<p>phpMyAdmin is a free software tool written in PHP intended to handle the administration of MySQL from your web browser. phpMyAdmin supports a wide range of operations with MySQL, including managing databases, tables, fields, relations, indexes, users, permissions, etc., from an easy-to-use web page, while you still have the ability to directly execute any SQL statement from the command line if you prefer. Installing phpMyAdmin is optional but it\u2019s nice tool to have:<\/p>\n<div id=\"crayon-57a1501ac4091950146256\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4091950146256-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac4091950146256-2\">2<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4091950146256-1\" class=\"crayon-line\"><span class=\"crayon-v\">cd<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">ports<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">databases<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">phpmyadmin<\/span><span class=\"crayon-o\">\/<\/span><\/div>\n<div id=\"crayon-57a1501ac4091950146256-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">make <\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">recursive <\/span><span class=\"crayon-e\">install <\/span><span class=\"crayon-v\">distclean<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p><strong>Configuration<\/strong><\/p>\n<p>Now that we have the requisite ports built and installed it\u2019s time to configure them. First, let\u2019s create the file <em>\/usr\/local\/etc\/php.ini<\/em> to hold our PHP options. The simpliest way to do this is to copy the file <em>\/usr\/local\/etc\/php.ini-development<\/em> which will add the default settings for new PHP installations. This configuration is suitable for development purposes, but NOT necessarily for production purposes. If your plans include a production server, then among other things, and before going online with your site, you should consider copying <em>\/usr\/local\/etc\/php.ini-production<\/em>instead and consult the recommendations at <a title=\"PHP security recommendations at www.php.net\" href=\"http:\/\/php.net\/manual\/en\/security.php\" target=\"_blank\">http:\/\/php.net\/manual\/en\/security.php<\/a>.<\/p>\n<div id=\"crayon-57a1501ac409d986072334\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac409d986072334-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac409d986072334-1\" class=\"crayon-line\"><span class=\"crayon-v\">cp<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">etc<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">php<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">ini<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">development<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">etc<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">php<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">ini<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Now let\u2019s configure Apache. Open the file <em>\/usr\/local\/etc\/apache24\/httpd.conf<\/em> and look for the following line:<\/p>\n<div id=\"crayon-57a1501ac40a8685115103\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40a8685115103-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac40a8685115103-1\" class=\"crayon-line\"><span class=\"crayon-e\">DirectoryIndex <\/span><span class=\"crayon-v\">index<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">html<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>And change it so it reads as follows:<\/p>\n<div id=\"crayon-57a1501ac40b2823092829\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40b2823092829-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac40b2823092829-1\" class=\"crayon-line\"><span class=\"crayon-e\">DirectoryIndex <\/span><span class=\"crayon-v\">index<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-e\">html <\/span><span class=\"crayon-v\">index<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">php<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Then append the following lines to the end of the file in order to support PHP files as well as phpMyAdmin, which normally lives outside of the Apache document root. Note: if you elected not to install phpMyAdmin, then you need only add the FilesMatch directives.<\/p>\n<div id=\"crayon-57a1501ac40bd787861870\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40bd787861870-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac40bd787861870-2\">2<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40bd787861870-3\">3<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac40bd787861870-4\">4<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40bd787861870-5\">5<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac40bd787861870-6\">6<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40bd787861870-7\">7<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac40bd787861870-8\">8<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40bd787861870-9\">9<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac40bd787861870-10\">10<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40bd787861870-11\">11<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac40bd787861870-12\">12<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40bd787861870-13\">13<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac40bd787861870-14\">14<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac40bd787861870-1\" class=\"crayon-line\"><span class=\"crayon-o\">&lt;<\/span><span class=\"crayon-i\">FilesMatch<\/span> <span class=\"crayon-s\">&#8220;\\.php$&#8221;<\/span><span class=\"crayon-o\">&gt;<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-h\">\u00a0\u00a0\u00a0\u00a0<\/span><span class=\"crayon-e\">SetHandler <\/span><span class=\"crayon-v\">application<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">x<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">httpd<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">php<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-3\" class=\"crayon-line\"><span class=\"crayon-o\">&lt;<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">FilesMatch<\/span><span class=\"crayon-o\">&gt;<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-4\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-o\">&lt;<\/span><span class=\"crayon-i\">FilesMatch<\/span> <span class=\"crayon-s\">&#8220;\\.phps$&#8221;<\/span><span class=\"crayon-o\">&gt;<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-5\" class=\"crayon-line\"><span class=\"crayon-h\">\u00a0\u00a0\u00a0\u00a0<\/span><span class=\"crayon-e\">SetHandler <\/span><span class=\"crayon-v\">application<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">x<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">httpd<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">php<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">source<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-6\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-o\">&lt;<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">FilesMatch<\/span><span class=\"crayon-o\">&gt;<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-7\" class=\"crayon-line\"><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-8\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-v\">Alias<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-i\">phpmyadmin<\/span> <span class=\"crayon-s\">&#8220;\/usr\/local\/www\/phpMyAdmin&#8221;<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-9\" class=\"crayon-line\"><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-10\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-o\">&lt;<\/span><span class=\"crayon-i\">Directory<\/span> <span class=\"crayon-s\">&#8220;\/usr\/local\/www\/phpMyAdmin&#8221;<\/span><span class=\"crayon-o\">&gt;<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-11\" class=\"crayon-line\"><span class=\"crayon-e\">Options <\/span><span class=\"crayon-e\">None<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-12\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">AllowOverride <\/span><span class=\"crayon-e\">None<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-13\" class=\"crayon-line\"><span class=\"crayon-e\">Require <\/span><span class=\"crayon-e\">all <\/span><span class=\"crayon-v\">granted<\/span><\/div>\n<div id=\"crayon-57a1501ac40bd787861870-14\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-o\">&lt;<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">Directory<\/span><span class=\"crayon-o\">&gt;<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Now restart Apache:<\/p>\n<div id=\"crayon-57a1501ac40c7287826469\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40c7287826469-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac40c7287826469-1\" class=\"crayon-line\"><span class=\"crayon-e\">service <\/span><span class=\"crayon-e\">apache24 <\/span><span class=\"crayon-v\">restart<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>That\u2019s it for our Apache configuration. Now let\u2019s configure phpMyAdmin. We\u2019ll do this by creating the file <em>\/usr\/local\/www\/phpMyAdmin\/config.inc.php<\/em>, the basic configuration file for phpMyAdmin. Traditionally, users have manually created or modified <em>\/usr\/local\/www\/phpMyAdmin\/config.inc.php<\/em>, but now phpMyAdmin includes a nice setup script, making it much easier to create this file with the settings you want. Start by creating the directory <em>\/usr\/local\/www\/phpMyAdmin\/config<\/em> and make it writable by the phpMyAdmin setup script:<\/p>\n<div id=\"crayon-57a1501ac40d3018937260\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40d3018937260-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac40d3018937260-1\" class=\"crayon-line\"><span class=\"crayon-v\">mkdir<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">www<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">phpMyAdmin<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">config<\/span> <span class=\"crayon-o\">&amp;&amp;<\/span> <span class=\"crayon-i\">chmod<\/span> <span class=\"crayon-v\">o<\/span><span class=\"crayon-o\">+<\/span><span class=\"crayon-v\">w<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">www<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">phpMyAdmin<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">config<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Then make <em>\/usr\/local\/www\/phpMyAdmin\/config.inc.php<\/em> readable by the phpMyAdmin setup script:<\/p>\n<div id=\"crayon-57a1501ac40e0816988222\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40e0816988222-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac40e0816988222-1\" class=\"crayon-line\"><span class=\"crayon-i\">chmod<\/span> <span class=\"crayon-v\">o<\/span><span class=\"crayon-o\">+<\/span><span class=\"crayon-v\">r<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">www<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">phpMyAdmin<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">inc<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">php<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Now open your web browser and navigate to <em>http:\/\/your-hostname-or-IP-address\/phpmyadmin\/setup<\/em> where you will see the phpMyAdmin setup Overview page. Select \u201cNew server\u201d and then select the \u201cAuthentication\u201d tab. Under the \u201cAuthentication type\u201d choose \u201chttp\u201d from the drop-down list (using HTTP-Auth to sign-in into phpMyAdmin will avoid storing login\/password credentials directly in <em>config.inc.php<\/em>) and remove \u201croot\u201d from the \u201cUser for config auth\u201d(See Figure 1).<\/p>\n<p class=\"center\"><a href=\"https:\/\/i0.wp.com\/www.iceflatline.com\/wp-content\/images\/freebsd-amp-1.png?ssl=1\" target=\"_blank\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" title=\"Screenshot of the phpMyAdmin setup page\" src=\"https:\/\/i0.wp.com\/www.iceflatline.com\/wp-content\/images\/freebsd-amp-1-small.png?resize=320%2C225&#038;ssl=1\" alt=\"Screenshot of the phpMyAdmin setup page\" width=\"320\" height=\"225\" \/><\/a><\/p>\n<div class=\"caption\">Figure 1<\/div>\n<p>Now select \u201cApply\u201d and you will be returned you to the Overview page where you should see a new server listed. Select \u201cSave\u201d in the Overview page to save your configuration as<em>\/usr\/local\/www\/phpMyAdmin\/config\/config.inc.php<\/em>. Now let\u2019s move that file up one directory to<em>\/usr\/local\/www\/phpMyAdmin<\/em> where phpMyAdmin can make use of it.<\/p>\n<div id=\"crayon-57a1501ac40ed918962747\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40ed918962747-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac40ed918962747-1\" class=\"crayon-line\"><span class=\"crayon-v\">mv<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">www<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">phpMyAdmin<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">inc<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">php<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">www<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-i\">phpMyAdmin<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Now let\u2019s try out phpMyAdmin to make sure it works. Point your web browser to <em>http:\/\/your-hostname-or-IP-address\/phpmyadmin<\/em> where you will be presented with a pop-up box requesting you to log in. Use \u201croot\u201d and the MySQL password you set up previously, then you should be directed to the phpMyAdmin administration page. We no longer need the<em>\/usr\/local\/www\/phpMyAdmin\/config<\/em> directory so let\u2019s remove it, as well as the read permission we added previously to <em>\/usr\/local\/www\/phpMyAdmin\/config.inc.php<\/em>:<\/p>\n<div id=\"crayon-57a1501ac40f8315901886\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac40f8315901886-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac40f8315901886-2\">2<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac40f8315901886-1\" class=\"crayon-line\"><span class=\"crayon-v\">rm<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">r<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">www<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">phpMyAdmin<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-e\">config<\/span><\/div>\n<div id=\"crayon-57a1501ac40f8315901886-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-i\">chmod<\/span> <span class=\"crayon-v\">o<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">r<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">www<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">phpMyAdmin<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">inc<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">php<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>And wrap up by restarting the Apache and MySQL servers:<\/p>\n<div id=\"crayon-57a1501ac4102117230502\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4102117230502-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac4102117230502-2\">2<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4102117230502-1\" class=\"crayon-line\"><span class=\"crayon-e\">service <\/span><span class=\"crayon-e\">apache24 <\/span><span class=\"crayon-e\">restart<\/span><\/div>\n<div id=\"crayon-57a1501ac4102117230502-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">service <\/span><span class=\"crayon-v\">mysql<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">server <\/span><span class=\"crayon-v\">restart<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p><strong>Testing our installation using WordPress<\/strong><\/p>\n<p>WordPress is a full-featured website\/blog platform that makes heavy use of Apache, MySQL and PHP. We\u2019ll install it on our newly created implementation to ensure we have these packages installed and working correctly. Once again, all commands are issued as the root user or by simulating the root user using the command <em>su<\/em>. Let\u2019s start by downloading the latest WordPress directly from the developers site to your home directory and untarring the package:<\/p>\n<div id=\"crayon-57a1501ac410e099344957\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac410e099344957-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac410e099344957-2\">2<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac410e099344957-3\">3<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac410e099344957-1\" class=\"crayon-line\"><span class=\"crayon-v\">cd<\/span> <span class=\"crayon-o\">~<\/span><\/div>\n<div id=\"crayon-57a1501ac410e099344957-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">fetch <\/span><span class=\"crayon-v\">http<\/span><span class=\"crayon-o\">:<\/span><span class=\"crayon-c\">\/\/wordpress.org\/latest.tar.gz<\/span><\/div>\n<div id=\"crayon-57a1501ac410e099344957-3\" class=\"crayon-line\"><span class=\"crayon-v\">tar<\/span> <span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-e\">zxvf <\/span><span class=\"crayon-v\">latest<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">tar<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-i\">gz<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>You should now see the new directory <em>wordpress<\/em> in your home directory. Next we need to create the file <em>~\/wordpress\/wp-config.php<\/em> and make some changes to it so WordPress can access the MySQL server. First, let\u2019s copy the file <em>~\/wordpress\/wp-config-sample.php<\/em> to use as a template:<\/p>\n<div id=\"crayon-57a1501ac4118185197633\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4118185197633-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4118185197633-1\" class=\"crayon-line\"><span class=\"crayon-v\">cp<\/span> <span class=\"crayon-o\">~<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">wordpress<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">wp<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">sample<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">php<\/span> <span class=\"crayon-o\">~<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">wordpress<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">wp<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">config<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">php<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Open <em>~\/wordpress\/wp-config.php<\/em> in your favorite editor and enter the database name as well as your MySQL login and password in the appropriate lines. When complete, it should look like the following:<\/p>\n<div id=\"crayon-57a1501ac4124405478984\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4124405478984-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac4124405478984-2\">2<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4124405478984-3\">3<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac4124405478984-4\">4<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4124405478984-5\">5<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac4124405478984-6\">6<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4124405478984-7\">7<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac4124405478984-8\">8<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4124405478984-9\">9<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4124405478984-1\" class=\"crayon-line\"><span class=\"crayon-c\">\/\/ ** MySQL settings &#8211; You can get this info from your web host ** \/\/<\/span><\/div>\n<div id=\"crayon-57a1501ac4124405478984-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-c\">\/** The name of the database for WordPress *\/<\/span><\/div>\n<div id=\"crayon-57a1501ac4124405478984-3\" class=\"crayon-line\"><span class=\"crayon-e\">define<\/span><span class=\"crayon-sy\">(<\/span><span class=\"crayon-s\">&#8216;DB_NAME&#8217;<\/span><span class=\"crayon-sy\">,<\/span> <span class=\"crayon-s\">&#8216;wordpress&#8217;<\/span><span class=\"crayon-sy\">)<\/span><span class=\"crayon-sy\">;<\/span><\/div>\n<div id=\"crayon-57a1501ac4124405478984-4\" class=\"crayon-line crayon-striped-line\"><\/div>\n<div id=\"crayon-57a1501ac4124405478984-5\" class=\"crayon-line\"><span class=\"crayon-c\">\/** MySQL database username *\/<\/span><\/div>\n<div id=\"crayon-57a1501ac4124405478984-6\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-e\">define<\/span><span class=\"crayon-sy\">(<\/span><span class=\"crayon-s\">&#8216;DB_USER&#8217;<\/span><span class=\"crayon-sy\">,<\/span> <span class=\"crayon-s\">&#8216;root&#8217;<\/span><span class=\"crayon-sy\">)<\/span><span class=\"crayon-sy\">;<\/span><\/div>\n<div id=\"crayon-57a1501ac4124405478984-7\" class=\"crayon-line\"><\/div>\n<div id=\"crayon-57a1501ac4124405478984-8\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-c\">\/** MySQL database password *\/<\/span><\/div>\n<div id=\"crayon-57a1501ac4124405478984-9\" class=\"crayon-line\"><span class=\"crayon-e\">define<\/span><span class=\"crayon-sy\">(<\/span><span class=\"crayon-s\">&#8216;DB_PASSWORD&#8217;<\/span><span class=\"crayon-sy\">,<\/span> <span class=\"crayon-s\">&#8216;your-mysql-password&#8217;<\/span><span class=\"crayon-sy\">)<\/span><span class=\"crayon-sy\">;<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Now move the <em>wordpress<\/em> directory to Apache\u2019s document root:<\/p>\n<div id=\"crayon-57a1501ac412e245030041\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac412e245030041-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac412e245030041-1\" class=\"crayon-line\"><span class=\"crayon-v\">mv<\/span> <span class=\"crayon-o\">~<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">wordpress<\/span><span class=\"crayon-o\">\/<\/span> <span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">www<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">apache24<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">data<\/span><span class=\"crayon-o\">\/<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>Next, let\u2019s create an MySQL database for our WordPress installation. Open phpMyAdmin in your browser and create a database by selecting the \u201cDatabases\u201d tab at the top. Enter a name for it in the \u201cCreate database\u201d field. For purposes of our example, I\u2019ll use \u201cwordpress\u201d as the database name. You\u2019re free to use a different database name, just make sure to use the same name in the<em>define(\u2018DB_NAME\u2019, \u2018your-DB-name\u2019);<\/em> line in <em>~\/wordpress\/wp-config.php<\/em> as described above. Then select \u201cCreate.\u201d<\/p>\n<p>Now let\u2019s run the WordPress script that will populate its database with the requisite tables. Open your web browser and navigate to <em>http:\/\/your-hostname-or-IP-address\/wordpress\/wp-admin\/install.php<\/em>. If everything is configured correctly you should see the WordPress installation wizard page (See Figure 2). Enter a title for your site, username, password, and an e-mail, then select \u201cInstall WordPress.\u201d Then login with your newly created WordPress credentials and you should be presented with the default WordPress administration page.<\/p>\n<p class=\"center\"><a href=\"https:\/\/i0.wp.com\/www.iceflatline.com\/wp-content\/images\/freebsd-amp-2.png?ssl=1\" target=\"_blank\"><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" title=\"Screenshot of WordPress installation page\" src=\"https:\/\/i0.wp.com\/www.iceflatline.com\/wp-content\/images\/freebsd-amp-2-small.png?resize=320%2C225&#038;ssl=1\" alt=\"Screenshot of WordPress installation page\" width=\"320\" height=\"225\" \/><\/a><\/p>\n<div class=\"caption\">Figure 2<\/div>\n<p><strong>Common problems<\/strong><\/p>\n<p>An error that occasionally pops up when attempting to start the Apache server is the following:<\/p>\n<div id=\"crayon-57a1501ac413c721805594\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac413c721805594-1\">1<\/div>\n<div class=\"crayon-num crayon-striped-num\" data-line=\"crayon-57a1501ac413c721805594-2\">2<\/div>\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac413c721805594-3\">3<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac413c721805594-1\" class=\"crayon-line\"><span class=\"crayon-v\">httpd<\/span><span class=\"crayon-o\">:<\/span> <span class=\"crayon-e\">apr_sockaddr_info_get<\/span><span class=\"crayon-sy\">(<\/span><span class=\"crayon-sy\">)<\/span> <span class=\"crayon-e\">failed <\/span><span class=\"crayon-st\">for<\/span> <span class=\"crayon-o\">&lt;<\/span><span class=\"crayon-v\">some<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">host<\/span><span class=\"crayon-o\">&#8211;<\/span><span class=\"crayon-v\">name<\/span><span class=\"crayon-o\">&gt;<\/span><\/div>\n<div id=\"crayon-57a1501ac413c721805594-2\" class=\"crayon-line crayon-striped-line\"><span class=\"crayon-v\">httpd<\/span><span class=\"crayon-o\">:<\/span> <span class=\"crayon-e\">Could <\/span><span class=\"crayon-st\">not<\/span> <span class=\"crayon-e\">reliably <\/span><span class=\"crayon-e\">determine <\/span><span class=\"crayon-e\">the <\/span><span class=\"crayon-i\">server<\/span>&#8216;<span class=\"crayon-i\">s<\/span> <span class=\"crayon-e\">fully <\/span><span class=\"crayon-e\">qualified <\/span><span class=\"crayon-e\">domain <\/span><span class=\"crayon-v\">name<\/span><span class=\"crayon-sy\">,<\/span> <span class=\"crayon-i\">using<\/span> <span class=\"crayon-cn\">127.0.0.1<\/span> <span class=\"crayon-st\">for<\/span> <span class=\"crayon-v\">ServerName<\/span><\/div>\n<div id=\"crayon-57a1501ac413c721805594-3\" class=\"crayon-line\"><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">usr<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">local<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">etc<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">rc<\/span><span class=\"crayon-sy\">.<\/span><span class=\"crayon-v\">d<\/span><span class=\"crayon-o\">\/<\/span><span class=\"crayon-v\">apache24<\/span><span class=\"crayon-o\">:<\/span> <span class=\"crayon-v\">WARNING<\/span><span class=\"crayon-o\">:<\/span> <span class=\"crayon-e\">failed <\/span><span class=\"crayon-st\">to<\/span> <span class=\"crayon-e\">start <\/span><span class=\"crayon-v\">apache24<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>This can be fixed by adding the following line to <em>\/usr\/local\/etc\/apache24\/httpd.conf<\/em>:<\/p>\n<div id=\"crayon-57a1501ac4147901556732\" class=\"crayon-syntax crayon-theme-vs2012-black crayon-font-monospace crayon-os-pc print-yes notranslate crayon-wrapped\" data-settings=\" minimize scroll-mouseover wrap\">\n<div class=\"crayon-plain-wrap\"><\/div>\n<div class=\"crayon-main\">\n<table class=\"crayon-table\">\n<tbody>\n<tr class=\"crayon-row\">\n<td class=\"crayon-nums \" data-settings=\"show\">\n<div class=\"crayon-nums-content\">\n<div class=\"crayon-num\" data-line=\"crayon-57a1501ac4147901556732-1\">1<\/div>\n<\/div>\n<\/td>\n<td class=\"crayon-code\">\n<div class=\"crayon-pre\">\n<div id=\"crayon-57a1501ac4147901556732-1\" class=\"crayon-line\"><span class=\"crayon-e\">ServerName <\/span><span class=\"crayon-v\">localhost<\/span><span class=\"crayon-o\">:<\/span><span class=\"crayon-cn\">80<\/span><\/div>\n<\/div>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<\/div>\n<p>HTTP 403 permission problems when trying to access phpMyAdmin is another area that seems to sometimes trip people up. This is usually caused by errors in the way either the Alias or Directory Apache directives for phpMyAdmin have been written in <em>\/usr\/local\/etc\/apache24\/httpd.conf<\/em>. As an example, a missing \u201c\/\u201d in the Alias statement cost me two hours of troubleshooting time!<\/p>\n<p><strong>Conclusion<\/strong><\/p>\n<p>Well, that\u2019s it. A few hours of your time with the FreeBSD Ports Collection and you can a get a fully configured \u201cFAMP\u201d web development server up and running on your FreeBSD box.<\/p>\n<p><strong>References<\/strong><\/p>\n<p><a title=\"&quot;Apache\/MySQL\/PHP\/phpMyAdmin on FreeBSD&quot; at caffetine.org\" href=\"http:\/\/caffetine.org\/freebsd-amp.php\" target=\"_blank\">http:\/\/caffetine.org\/freebsd-amp.php<\/a><\/p>\n<p><a title=\"Upgrading from Apache 2.2 to 2.4 at apache.org\" href=\"https:\/\/httpd.apache.org\/docs\/2.4\/upgrading.html\" target=\"_blank\">https:\/\/httpd.apache.org\/docs\/2.4\/upgrading.html<\/a><\/p>\n<p><a title=\"Securing the Initial MySQL Accounts at dev.mysql.com\" href=\"http:\/\/dev.mysql.com\/doc\/refman\/5.7\/en\/default-privileges.html\" target=\"_blank\">http:\/\/dev.mysql.com\/doc\/refman\/5.7\/en\/default-privileges.html<\/a><\/p>\n<div class=\"related-posts\">\n<div id=\"related-posts-MRP_all\" class=\"related-posts-type\">\n<h4>Related Posts<\/h4>\n<ul>\n<li><a href=\"https:\/\/www.iceflatline.com\/2015\/08\/using-tarsnap-in-freebsd-to-improve-my-offsite-backups\/\">Using Tarsnap in FreeBSD to Improve My Offsite Backups<\/a><\/li>\n<li><a href=\"https:\/\/www.iceflatline.com\/2015\/07\/replacing-mysql-with-mariadb-in-freebsd\/\">Replacing MySQL with MariaDB in FreeBSD<\/a><\/li>\n<li><a href=\"https:\/\/www.iceflatline.com\/2015\/07\/using-zfs-replication-features-in-freebsd-to-improve-my-offsite-backups\/\">Using ZFS replication features in FreeBSD to improve my offsite backups<\/a><\/li>\n<li><a href=\"https:\/\/www.iceflatline.com\/2013\/12\/how-to-create-configure-and-connect-to-a-freebsd-instance-in-amazon-ec2\/\">How To Create, Configure And Connect To A FreeBSD Instance In Amazon EC2<\/a><\/li>\n<li><a href=\"https:\/\/www.iceflatline.com\/2013\/02\/how-to-use-portmaster-to-update-ports\/\">How to Use Portmaster to Update Ports<\/a><\/li>\n<li><a href=\"https:\/\/www.iceflatline.com\/2012\/09\/how-to-forward-roots-mail-to-a-another-user-in-freebsd\/\">How to Forward Root&#8217;s Mail to a Another User in FreeBSD<\/a><\/li>\n<\/ul>\n<\/div>\n<\/div>\n<p>Tags: <a href=\"https:\/\/www.iceflatline.com\/tag\/bsd\/\" rel=\"tag\">BSD<\/a>, <a href=\"https:\/\/www.iceflatline.com\/tag\/server\/\" rel=\"tag\">server<\/a>, <a href=\"https:\/\/www.iceflatline.com\/tag\/wordpress\/\" rel=\"tag\">wordpress<\/a><\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<div class=\"mh-excerpt\"><p>\u00a0How to Install Apache, MySQL, PHP, and phpMyAdmin on FreeBSD 127 Comments November 10th, 2011 by iceflatline (20160616 \u2014 The steps in this post were <a class=\"mh-excerpt-more\" href=\"https:\/\/www.st.ac.th\/krubuncha\/%e0%b8%81%e0%b8%b2%e0%b8%a3%e0%b8%95%e0%b8%b4%e0%b8%94%e0%b8%95%e0%b8%b1%e0%b9%89%e0%b8%87-apache24mysql56php56\/\" title=\"\u0e01\u0e32\u0e23\u0e15\u0e34\u0e14\u0e15\u0e31\u0e49\u0e07 Apache24+Mysql56+Php56\">[\u0e2d\u0e48\u0e32\u0e19\u0e15\u0e48\u0e2d]<\/a><\/p>\n<\/div>","protected":false},"author":1,"featured_media":311,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"footnotes":""},"categories":[1],"tags":[],"class_list":["post-257","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-1"],"jetpack_featured_media_url":"https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?fit=200%2C200&ssl=1","blog_post_layout_featured_media_urls":{"thumbnail":["https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?resize=150%2C150&ssl=1",150,150,true],"full":["https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?fit=200%2C200&ssl=1",200,200,false]},"categories_names":{"1":{"name":"\u0e1a\u0e17\u0e04\u0e27\u0e32\u0e21\u0e04\u0e2d\u0e21\u0e1e\u0e34\u0e27\u0e40\u0e15\u0e2d\u0e2d\u0e23\u0e4c","link":"https:\/\/www.st.ac.th\/krubuncha\/category\/%e0%b8%9a%e0%b8%97%e0%b8%84%e0%b8%a7%e0%b8%b2%e0%b8%a1%e0%b8%84%e0%b8%ad%e0%b8%a1%e0%b8%9e%e0%b8%b4%e0%b8%a7%e0%b9%80%e0%b8%95%e0%b8%ad%e0%b8%ad%e0%b8%a3%e0%b9%8c\/"}},"tags_names":[],"comments_number":0,"wpmagazine_modules_lite_featured_media_urls":{"thumbnail":["https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?resize=150%2C150&ssl=1",150,150,true],"cvmm-medium":["https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?resize=200%2C200&ssl=1",200,200,true],"cvmm-medium-plus":["https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?resize=200%2C200&ssl=1",200,200,true],"cvmm-portrait":["https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?resize=200%2C200&ssl=1",200,200,true],"cvmm-medium-square":["https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?resize=200%2C200&ssl=1",200,200,true],"cvmm-large":["https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?resize=200%2C200&ssl=1",200,200,true],"cvmm-small":["https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?resize=130%2C95&ssl=1",130,95,true],"full":["https:\/\/i0.wp.com\/www.st.ac.th\/krubuncha\/wp-content\/uploads\/sites\/19\/2015\/02\/freebsd-logo2-e1470190174543.jpg?fit=200%2C200&ssl=1",200,200,false]},"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p5Mvvj-49","jetpack-related-posts":[],"_links":{"self":[{"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/posts\/257","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/comments?post=257"}],"version-history":[{"count":2,"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/posts\/257\/revisions"}],"predecessor-version":[{"id":310,"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/posts\/257\/revisions\/310"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/media\/311"}],"wp:attachment":[{"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/media?parent=257"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/categories?post=257"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.st.ac.th\/krubuncha\/wp-json\/wp\/v2\/tags?post=257"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}