How can I remove jenkins completely from linux

LinuxJenkins

Linux Problem Overview


I have deleted jenkins all directories from different folders. But still when I access URL it is showing me jenkins login.

I want to uninstall jenkins completely. Have tried many commands from internet but still jenkins is there on server.

I have only command line access via putty so I tries whatever is possible via command to remove jenkins.

Linux Solutions


Solution 1 - Linux

If your jenkins is running as service instead of process you should stop it first using

sudo service jenkins stop

After stopping it you can follow the normal flow of removing it using commands respective to your linux flavour

For centos it will be

sudo yum remove jenkins

For ubuntu it will

sudo apt-get remove --purge jenkins

I hope this will solve your issue.

Solution 2 - Linux

if you are ubuntu user than try this:

sudo apt-get remove jenkins
sudo apt-get remove --auto-remove jenkins

'apt-get remove' command is use to remove package.

Solution 3 - Linux

On Centos7, It is important to note that while you remove jenkins using following command: sudo yum remove jenkins

it will not remove your users and other information. For that you will have to do following: sudo rm -r /var/lib/jenkins

Solution 4 - Linux

First - stop Jenkins service:

sudo service jenkins stop

Next - delete:

sudo apt-get remove --purge jenkins

If you used separate server for Jenkins, some GCP or AWS - just delete this server. Here is a video how to uninstall Jenkins from GCP Compute Engine https://youtu.be/D2HUFAc_Trw

Solution 5 - Linux

For sentOs, it's works for me At first stop service by sudo service jenkins stop

Than remove by sudo yum remove jenkins

Solution 6 - Linux

I had installed Jenkins using snap and I completely forgot. so if there is anyone out there who has tried all these steps and still gets Jenkins sign-in page try this thread.

https://stackoverflow.com/a/49695931/9854536

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionHelping HandsView Question on Stackoverflow
Solution 1 - LinuxmnpooniaView Answer on Stackoverflow
Solution 2 - LinuxMaulik PatelView Answer on Stackoverflow
Solution 3 - LinuxAnand DesaiView Answer on Stackoverflow
Solution 4 - LinuxMaksym RudnyiView Answer on Stackoverflow
Solution 5 - LinuxKhandaker Toihidul IslamView Answer on Stackoverflow
Solution 6 - LinuxMushira ShaikhView Answer on Stackoverflow