Posts

Showing posts from January, 2013

Failing to start MySQL

Sometimes you get the following error while starting the MySQL service or when upgrading to mysql5. Error MySQL Couldn't find MySQL manager or server Solution Comment this line from /etc/my.cnf Basedir =/ var / lib / mysql Thank you.

Move Tmp To Ramfs/Tmpfs

This article will show you how to create a ramfs/tmpfs partition and how to change the tmpdir variable to quicken copy to tmp queries. Keep in mind this only speeds up the IO portion of maintaining multiple indexed result sets due to query structure, the best performance increase would be gained from query analysis. ramfs vs tmpfs RamFS will use up all of your memory regardless of the size you set and it also never uses swap. TmpFS will use up only what you have assigned to it and it will use swap for idle ram. Typically you will want to use tmpfs, but its important to know the differences. Creating a ram partition You need to create a new mount to go about doing this. The below will create a 100mb tmpfs ( ram based ) partition and mount it. # mkdir /tmpfs # mount -t tmpfs -o size=100m tmpfs /tmpfs/ Thank you.

Repair a database

To repair a database using the default MyISAM  storage engine use: # mysqlcheck  -r  databasename If the above command fails to repair a myisam table, you can attempt to use the following repair command for rebuilding table structures from .frm files in the event .MYI headers are missing or corrupt: # mysqlcheck  -r  --use-frm  databasename To repair all databases on a server: # mysqlcheck  --repair  --all-databases

Hacking: how to prevent

Hacking can be done in many different ways. Two commonly used methods are explained below. (i) Account passwords harvesting ====================== In this method, hackers will try to collect website account passwords in large scale. We will call this process "account passwords harvesting". Details on how they do that are fuzzy. Use of password like 123456 or use of a spyware infected PCs at home are the main reasons. Actually the complexity of the password should be beefed up to at least 8 characters. But this does not help if the user computer is infected with a keylogger. (ii) PHP vulnerabilities ====================== PHP has got of lot of very vulnerable and potentially exploitable functions. Hackers have been enjoying these security lapses for a long time. Most of the PHP applications like Joomla, PhpBB, PhpNuke etc. are community developed. These application may have potential security vulnerabilities and hackers may exploit them. Most of the website hacki