find /var/lib/mysql -type f -name “ib_logfile?” -exec mv {} {}_OLD \;
Monthly Archives: April 2014
mysql find ib_logfile location
lsof -c mysqld | grep ib_logfile
I/O are commonly in an “uninterruptible sleep” state or “D”
for x in `seq 1 1 10`; do ps -eo state,pid,cmd | grep “^D”; echo “—-“; sleep 5; done
CageFS jail error Skeleton directory is not mounted: /usr/share/cagefs-skeletor
If you found this error in your suexec_log, it means you should remount all your accounts:
cagefsctl –remount-all
service mysqld restart
mysql restore all databases from backup
Do a mysqldump of all databases (mysqldump –event -A), procedures, triggers etc except the mysql and performance_schema databases
Drop all databases except the above 2 databases
Stop mysql
Delete ibdata1 and ib_log files
Start mysql
Restore from dump
restore one mysql table
mysqldump -u root -p database0 > /tmp/database0.sql
mysql -u root -p -e ‘create database database0_bkp’
mysql -u root -p database0_bkp < /tmp/database0.sql
mysql -u root -p database0 -e 'insert into database0.table_you_want select * from database0_bkp.table_you_want'
generate a CSR SSL certificate request
openssl req -nodes -newkey rsa:2048 -keyout domain.key -out domain.csr
quick check if port is open
nmap linux4you.tk -PN -p ssh | egrep ‘open|closed|filtered’
ovirt – kvm disabled by bios
If you see this kind of error like “Disabling all-in-one plugin because hardware supporting virtualization could not be detected. Do you want to continue setup without AIO plugin
It mean you should check your BIOS settings if server virtualization is enabled, because wmx in /proc/cpuinfo shows just your CPU features.
/etc/init.d/network not works on Centos
It means you are missing some configurations like:
vi /etc/sysconfig/network
NETWORKING=yes
linux check CPU supports hardware virtualization (VT technology)
egrep ‘(vmx|svm)’ /proc/cpuinfo
bmc/ipmi shell, reboot ip kvm cold
ipmitool -H IP -U root shell
mc reset cold
or
ipmitool bmc reset cold
Sent cold reset command to MC
bash convert date to epoch
date --date="19-FEB-12" +%s
1329602400
centos check SSL heartbleed vulnerability
rpm -q –changelog openssl | grep -B 1 CVE-2014-0160
cPanel remove user command line
/scripts/killacct username