It seems that MySQL was created to be installed on RHEL/CentOS/Fedora...
But what if you are actually using Ubuntu?
Well, this is the purpose of the following tutorial
- Trace all old MySQL installations on the servers (yes, some vendors are delivering baseline images with some old MySQL versions)
sudo dpkg --get-selections | grep -v deinstall | grep -i mysql
sudo apt-get --purge remove libdbd-mysql-perl libmysqlclient18 mysql-client mysql-client-5.5 mysql-client-core-5.5 mysql-common mysql-server mysql-server-5.5 mysql-server-core-5.5 php5-mysql
- Get the MySQL repository
sudo wget -O mysql.deb http://dev.mysql.com/get/mysql-apt-config_0.2.1-1ubuntu14.04_all.deb
- Install the repository
sudo dpkg -i mysql.deb
sudo apt-get update
- Install the mysql package (you may need to select the right version and select a root password)
sudo apt-get -y install mysql-server mysql-client
- If you have a pre-configured my.cnf, get it and replace the current my.cnf file. Then you should restart the MySQL. I would recommend you to keep your my.cnf in a code repository like git to manage the versionssudo apt-get -y install git
sudo git clone wherever tmp && git mv tmp/.git . && rm -rf tmp
sudo service mysql restart
- Now it time to recover your database from your backup (if you have one) and back to business...
Keep Performing,
Little Security. Big Problems.
Redis is designed (as most early NoSQL products) as a product that should be used in secured environment (meaning little security measures are built in).
The only security measure Redis supports is authentication that is passed as clear text (definitely not a best security best practice).
UPDATE: Itamar Haber from RedisLabs referred me to an SSL communication encryption using stunnel or spiped.
Big Problems. Great Solutions
If you love Redis (and w/ 60K Set and Get Ops/Sec on commodity hardware there is no reason you won't love it), and if you must have an enterprise grade solution, you can take one of the following approaches:
- Implement a web layer in front of it (that can support SSL, encrypted authentication, logging and all other fancy stuff). A great example for this is Webdis with a built in solution. Off course, there is a performance penalty stick to the extra layer (and some issues as Redis still can be accessed directly).
- Save the data encrypted in Redis (encrypt data before the SET operation by the app servers, and decrypt it after the GET operation by consumers). This way, communication is not needed to be encrypted and hackers or malicious users can do little harm, even they are access the Redis directly as the Redis data store is encrypted.
Bottom Line
Even sensitive products that lack of basic security measurements, can be brought to enterprise level with the right design in mind.
Keep Performing,
Moshe Kaplan