Categories: Debian 7Debian 8Linux

Comment installer MySQL 5.5 automatiquement

Pour pouvoir utiliser le script suivant, vous devez avoir debconf d’installé sur votre serveur. Si ce n’est pas le cas, installez-le via la commande suivante:

apt-get install debconf

Pour installer MySQL automatiquement, copiez le texte ci-dessous dans un fichier .sh, remplacez VOTRE_MOT_DE_PASSE par le mot de pas que vous souhaitez mettre au super utilisateur root et lancez le script via la commande suivante: bash ./votre_fichier.sh

#Version de MySQL que vous souhaitez installer
mysqlVersion=5.5
#Variable contenant le mot de passe que vous voulez mettre pour l'utilisateur root
mysqlPassword='VOTRE_MOT_DE_PASSE'
#Préconfiguration des paramètres
echo "mysql-server-${mysqlVersion} mysql-server/root_password password ${mysqlPassword}" | debconf-set-selections
echo "mysql-server-${mysqlVersion} mysql-server/root_password_again password ${mysqlPassword}" | debconf-set-selections
#Installation de MySQL
apt-get -y install mysql-client mysql-server-${mysqlVersion}
The GrimmChester

Share
Published by
The GrimmChester
Tags: mysql

Recent Posts

How to set up a SIP trunk with FreePBX and Twilio

FreePBX Server Requirements FreePBX 14.0 Asterisk 13 1 Twilio Number Mine will be (579)123-1234 Notes:…

8 years ago

Automated Web Hosting Solution (AWHS)Panel

Requirements For now, AWHSPanel only supports Debian 8 but its architecture allows easy new implementations.…

9 years ago

How to install ioncube on Debian & Ubuntu

ionCube installation What is ionCube: ionCube helps you to protect your PHP code from being…

10 years ago

Comment rediriger un site HTTP vers HTTPS

RewriteEngine on RewriteCond %{HTTPS} !=on RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R]

10 years ago

How To Install Linux, Nginx, MySQL, PHP (LEMP) on Debian 8

Files Structure: /srv /mydomain.com /.socks /www /cgi-bin /logs /public_html /ssl /tmp /blog /cgi-bin /logs /public_html…

10 years ago

How To automate Horde Groupware Webmail installation

Prerequisites: - 1 database (mysql) - 1 user associated with the database - Follow this…

10 years ago