shoyebzz

Completely Uninstall LAMP Ubuntu

Aug 11th, 2022
144
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.97 KB | None | 0 0
  1. If your time does not permit the close supervision of your project then i am here for your help related with LAMP or LEMP Stack and others.
  2. Contact Me For Engaged Your Works:
  3. Telegram: https://t.me/LinuxGun
  4. WhatsApp: https://wa.link/5ow7oz
  5.  
  6.  
  7. #!/bin/bash
  8. # This will remove Apache
  9. sudo service apache2 stop
  10. sudo apt-get purge apache2 apache2-utils apache2.2-bin
  11. sudo apt remove apache2.*
  12. sudo apt-get autoremove
  13. whereis apache2
  14. sudo rm -rf /etc/apache2
  15.  
  16. # This will remove PHP version. Type your php version before run below command. I am using php7.4
  17. sudo apt-get purge `dpkg -l | grep php7.4| awk '{print $2}' |tr "\n" " "`
  18. sudo apt-get purge php7.*
  19. sudo apt-get autoremove --purge
  20. whereis php
  21. sudo rm -rf /etc/php
  22.  
  23. # This will remove MYSql
  24. sudo service mysql stop
  25. sudo apt-get remove --purge *mysql\*
  26. sudo apt-get remove --purge mysql-server mysql-client mysql-common -y
  27. sudo rm -rf /etc/mysql
  28. sudo apt-get autoremove
  29. sudo apt-get autoclean
  30.  
  31. sudo reboot
  32.  
Add Comment
Please, Sign In to add comment