{"id":102,"date":"2009-05-30T20:50:59","date_gmt":"2009-05-31T00:50:59","guid":{"rendered":"http:\/\/www.compdigitec.com\/labs\/?p=102"},"modified":"2013-05-04T17:15:47","modified_gmt":"2013-05-04T22:15:47","slug":"solving-xampp-couldnt-start-mysql","status":"publish","type":"post","link":"http:\/\/www.compdigitec.com\/labs\/2009\/05\/30\/solving-xampp-couldnt-start-mysql\/","title":{"rendered":"Solving &#8220;XAMPP:  Couldn&#8217;t start MySQL!&#8221;"},"content":{"rendered":"<p><a href=\"http:\/\/www.apachefriends.org\/en\/xampp-linux.html\">XAMPP for Linux<\/a> is a convenient package for installing the AMPP stack (Apache, MySQL, PHP, Perl) of web server software, but it also has its own share of problems. One such error is the generic and uninformative error of &#8220;<strong>XAMPP: Couldn&#8217;t start MySQL!<\/strong>&#8220;. This is confusing because it does not say anything about the error. It is usually caused by permission errors because it is not able to write to a directory. Here is how to fix it:<\/p>\n<ol>\n<li>Open a terminal.<\/li>\n<li>Once the terminal has loaded, type &#8220;<strong>sudo chown -hR root <em>\/opt\/lampp<\/em><\/strong>&#8220;. (Note: replace <em>\/opt\/lampp<\/em> with the XAMPP install directory).<\/li>\n<li><strong>(Update from comment #7, untested)<\/strong> Type &#8220;<strong>sudo chmod -R 777 \/opt\/lampp<\/strong>&#8220;.<\/li>\n<li>Restart XAMPP with &#8220;<strong>sudo \/opt\/lampp\/lampp restart<\/strong>&#8220;.<\/li>\n<li>Exit the terminal (right-hand corner X or type <strong>exit<\/strong>).<\/li>\n<\/ol>\n<p><strong>Alternate solution for those who could not get the above working:<\/strong><\/p>\n<ol>\n<li>Re-download the LAMPP package from <a href=\"http:\/\/downloads.sourceforge.net\/sourceforge\/xampp\/xampp-linux-1.7.1.tar.gz\">http:\/\/www.apachefriends.org\/<\/a>. (<strong>wget http:\/\/downloads.sourceforge.net\/sourceforge\/xampp\/xampp-linux-1.7.1.tar.gz -O \/tmp\/xampp-linux-1.7.1.tar.gz<\/strong>)<\/li>\n<li>Navigate to <em>\/opt\/lampp<\/em>\/htdocs (or where-ever you store your documents) and back it up to another location. (<strong>mkdir \/tmp\/htdocs<\/strong> followed by <strong>cp -r \/opt\/lampp\/htdocs\/*\/tmp\/htdocs\/<\/strong><strong><\/strong>)<\/li>\n<li>(<em>optional<\/em>) Also back up the configuration directory and the phpmyadmin configuration (<strong>mkdir \/tmp\/etc<\/strong> followed by <strong>cp -r \/opt\/lampp\/etc\/*\/tmp\/etc\/<\/strong> followed by <strong><\/strong><strong>cp \/opt\/lampp\/phpmyadmin\/config.inc.php \/tmp\/<\/strong>)<\/li>\n<li>Delete the entire LAMPP tree (<strong>sudo rm -rf \/opt\/lampp<\/strong>)<\/li>\n<li>Re-extract the LAMPP tree from root (<strong>tar xvfz \/tmp\/xampp-linux-1.7.1.tar.gz -C \/opt<\/strong>)<\/li>\n<li>Restore htdocs folder to <em>\/opt\/lampp<\/em> (<strong>sudo cp -r \/tmp\/htdocs\/* \/opt\/lampp\/htdocs\/<\/strong>)<\/li>\n<li>(<em>optional<\/em>) Restore configuration folder and phpmyadmin config (<strong>sudo cp -r \/tmp\/etc\/* \/opt\/lampp\/etc\/<\/strong> followed by <strong>sudo cp \/tmp\/config.inc.php \/opt\/lampp\/phpmyadmin\/config.inc.php<\/strong>)<\/li>\n<\/ol>","protected":false},"excerpt":{"rendered":"<p>XAMPP for Linux is a convenient package for installing the AMPP stack (Apache, MySQL, PHP, Perl) of web server software, but it also has its own share of problems. One such error is the generic and uninformative error of &#8220;XAMPP: Couldn&#8217;t start MySQL!&#8220;. This is confusing because it does not say anything about the error. [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[14,3],"tags":[76,504,495,220,496,498,497,44,494],"_links":{"self":[{"href":"http:\/\/www.compdigitec.com\/labs\/wp-json\/wp\/v2\/posts\/102"}],"collection":[{"href":"http:\/\/www.compdigitec.com\/labs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.compdigitec.com\/labs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.compdigitec.com\/labs\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.compdigitec.com\/labs\/wp-json\/wp\/v2\/comments?post=102"}],"version-history":[{"count":0,"href":"http:\/\/www.compdigitec.com\/labs\/wp-json\/wp\/v2\/posts\/102\/revisions"}],"wp:attachment":[{"href":"http:\/\/www.compdigitec.com\/labs\/wp-json\/wp\/v2\/media?parent=102"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.compdigitec.com\/labs\/wp-json\/wp\/v2\/categories?post=102"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.compdigitec.com\/labs\/wp-json\/wp\/v2\/tags?post=102"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}