Jump to content



Photo

How to install MySQL on Ubuntu / Debian server in Haphost

MySQL

  • Please log in to reply
12 replies to this topic

#1 Cryo Kinesis

Cryo Kinesis

    Haphost Staff

  • Moderators
  • 128 posts
  • LocationGridania, Eorzea

Posted 05 August 2014 - 05:41 PM

Hi there,

 

Introduction
Recently we have discovered a small bug in the plop system that causes default MySQL installations on Ubuntu / Debian systems to not start. Issuing MySQL “start” causes it to go into infinite loop since it would always try to restart the service after it has crashed since the error is not marked as critical by MySQL standards. This guide will help you to avoid this nuisance and ensure that your MySQL operates properly.

Step 1
Firstly, you will need to update your APT by executing command “apt-get update” from command line. Live example can be seen in the picture below (Command is highlighted with red square): 
MySQL-Tutorial-1.png

Step 2
After updating your APT repository you can proceed with MySQL installation.
Important note: It is highly advised to install MySQL separately from all other pages due to the bug present in the plop system.
You can install MySQL by executing command “apt-get install mysql-server mysql-client” from command line.
Live example can be seen in the picture below (Command is highlighted with red square): 
MySQL-Tutorial-2.png

After executing the command you will receive a prompt window asking your confirmation. Type in “y” and press “ENTER” key to proceed with installation.
Once all packages will be loaded you will be requested to enter root password for your MySQL. Type in the password you desire and press “OK” to continue.
Live example can be seen in the picture below (Command is highlighted with red square): 
MySQL-Tutorial-3.png

Step 3 (IMPORTANT)
After you have entered your desired password the libraries will be loaded and the installation will proceed. After a certain period of time you will see a message telling you that system could not set the password. This is because of the bug in the system – MySQL was not able to start.

You can see the error example in the image below: 
MySQL-Tutorial-4.png

After seeing this message press “OK” and click “CTRL+Z” which will put the installation into the background! After using “CTRL+Z” you will see the following message: 
MySQL-Tutorial-5.png

Afterwards open the MySQL configuration file. In Ubuntu it is located in “/etc/mysql/my.cnf”. Find the line that contains “[mysqld]” and insert the line “innodb_use_native_aio = 0” after it. Everything is highlighted in the picture below: 
MySQL-Tutorial-6.png

Save the file and execute command “fg” in the command line which will pull back the installation from the background. You can see the example below: 
MySQL-Tutorial-7.png

NOTE: It can take some time for the installation to continue so don’t be alert.

Final notes
If you have followed all the steps described in this guide you should have the MySQL server installed on your Ubuntu / Debian server and it should be working without any errors. In case you have already installed the MySQL server and it can’t start check the log file (default location is “/var/log/mysql/error.log”) for information. If you will notice the error “InnoDB: Error: io_setup() failed with EAGAIN after 5 attempts.” Follow the guidelines in “Step 3” and modify the configuration file accordingly.


  • NINJA likes this

Cryo%20Kinesis%20Haphost%20Sig2.png


#2 LucSW

LucSW

    Member

  • Members
  • PipPip
  • 10 posts

Posted 20 September 2014 - 12:38 PM

Where are images ?


  • Deluxe likes this

#3 Deluxe

Deluxe

    Newbie

  • Members
  • Pip
  • 6 posts

Posted 21 September 2014 - 07:01 PM

Where are images ?

 

You are right, the images are not there...



#4 LucSW

LucSW

    Member

  • Members
  • PipPip
  • 10 posts

Posted 21 September 2014 - 08:16 PM

How to see images ?



#5 demotest

demotest

    Advanced Member

  • Members
  • PipPipPip
  • 73 posts

Posted 21 September 2014 - 11:22 PM

I already reported this couple of weeks ago, images are lost in transition to HapHost.

 

I don't think they'll be recovered.



#6 RoboCop

RoboCop

    Member

  • Members
  • PipPip
  • 28 posts

Posted 16 December 2014 - 02:55 AM

Can they be uploaded again please?



#7 Firas

Firas

    Member

  • Members
  • PipPip
  • 14 posts

Posted 10 January 2015 - 12:24 PM

no image :c



#8 Andreas

Andreas

    Haphost Staff

  • Moderators
  • 283 posts
  • LocationGermany

Posted 10 January 2015 - 09:46 PM

i have installed phpmyadmin and mysql but when i putmyip/phpmyadmin 404 error appears why?

The web server can't find the directory. Make sure the directory phpmyadmin exists and you typed in the URL correctly.



#9 Firas

Firas

    Member

  • Members
  • PipPip
  • 14 posts

Posted 22 January 2015 - 06:18 PM

 

-bash: apt-get: command not found

help here !



#10 Andreas

Andreas

    Haphost Staff

  • Moderators
  • 283 posts
  • LocationGermany

Posted 23 January 2015 - 02:22 PM

help here !

apt-get is a command provided by Debian and Ubuntu. I think you're using CentOS, so you should use yum as the packet manager instead.



#11 Firas

Firas

    Member

  • Members
  • PipPip
  • 14 posts

Posted 15 February 2015 - 11:32 AM

apt-get is a command provided by Debian and Ubuntu. I think you're using CentOS, so you should use yum as the packet manager instead.

yea i use CentOS so i use yum not apt-get ?



#12 Andreas

Andreas

    Haphost Staff

  • Moderators
  • 283 posts
  • LocationGermany

Posted 15 February 2015 - 01:06 PM

yea i use CentOS so i use yum not apt-get ?

 

That's correct.



#13 demotest

demotest

    Advanced Member

  • Members
  • PipPipPip
  • 73 posts

Posted 15 February 2015 - 01:07 PM

Btw, this bug does not exists anymore.







Also tagged with one or more of these keywords: MySQL

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users