This command can be used to start mysql service when it is stopped due to drive full
From command line issue the below command
tune2fs -m 0 /dev/sda5
This can save a little space enough to start mysql.
Now find out the reason to become the drive full. The below command can be used to list biggest 10 files:
du -a / | sort -n -r | head -n 10
If it is because any log file, delete it. If it is because of ibdata, the mysql file, follow the below steps to shrink it.
Also, check the possibility of reducing size by deleting old data from tables like STOCKDIARY, TAXLINES, etc.,
To shrink ibdata file, follow the below steps:
1. Connect a usb drive and mount it.
2. From command line issue below commands
mysqldump -u root -p SALECULATOR > /flash/fullbak.sql (enter password) mysql -u root -p (enter password) DROP DATABASE SALECULATOR; exit; service mysql stop rm /data/db/ibdata1 rm /data/db/ib_log* service mysql start mysql -u root -p (enter password) CREATE DATABASE SALECULATOR; USE SALECULATOR; source /flash/fullbak.sql; exit; exit
Leave a Reply