ali aboos

Linux

VMware, Linux: scan your scsi host without rebooting

by on May.01, 2015, under Linux, VMware

echo "- - -" > /sys/class/scsi_host/host#/scan

Replace host# with number of your scsi adapter… sda would be host1, sdb host2 and so on.

Comments Off on VMware, Linux: scan your scsi host without rebooting :, , , more...

mySQL: repair and optimize all tables in all databases

by on Apr.28, 2015, under Linux

mysqlcheck -u root -p --auto-repair --optimize --all-databases

You will be asked for root password and command will run. If you want to do it through cron, put your password immediately after -p… like -ppassword.

Comments Off on mySQL: repair and optimize all tables in all databases more...

Linux: edit crontab with nano instead of vi

by on Apr.15, 2015, under Linux

Everyone hates vi… I sure do. If you can’t or don’t want to permanently change your crontab editor use this:
env EDITOR=nano crontab -e

Comments Off on Linux: edit crontab with nano instead of vi :, , , more...

Linux: VMware Tools on Red Hat or CentOS Prerequisites

by on Apr.06, 2015, under Linux

This should do it:
yum install perl gcc make kernel-headers kernel-devel audit binutils glibc-headers

If vmware tools install cannot find your linux headers, throw these in too and try again:
yum install kernel-headers-`uname -r` kernel-devel-`uname -r`

Comments Off on Linux: VMware Tools on Red Hat or CentOS Prerequisites :, , , more...

Debian: MySQL stops working after upgrade from Lenny to Squeeze

by on Jan.22, 2013, under Debian, Linux, SQL

MySQL installation gets upgraded during your OS upgrade as well… therefore a few different things could cause the server to not start. I’d start troubleshooting this way:

Incompatible configuration: simply backup your /etc/mysql/my.cnf and copy a new one from /etc/mysql/my.cnf.dpkg-dist and start the server.
cp /etc/mysql/my.cnf /etc/mysql/my.cnf.bak
cp /etc/mysql/my.cnf.dpkg-dist /etc/mysql/my.cnf
/etc/init.d/mysql restart

 

Missing loopback interface: MySQL binds to your loopback interface by default and would not start if it is missing. Check yours and add if necessary:
nano /etc/network/interfaces
and add “lo” to lines with “auto”. If your interface line is “auto eth0” change it to read “auto lo eth0”. Also add “iface lo inet loopback” to the file if it is missing. Save config and restart the server.

 

2nd last resort: install MySQL: Install it again, see what happens.
aptitude install mysql-server-5.1
 

Last resort: completely purge the install and install again:
aptitude remove --purge mysql-server
aptitude install mysql-server

and if none of the above worked keep googling… good luck!

Leave a Comment : more...

Search InsaneLabs.com

Can't find what you're looking for? Drop a comment on a post or email (ali aht insanelabs doht com)

Links

Links open in a new window