Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to uninstall chef-client and the whole Chef package

Tags:

Is uninstalling Chef-Client just as easy as removing the directory, and making sure its not in the rc files? Is there a way to use knife to uninstall chef-client?

--2013-06-26_EDIT--

Updating this question to say, how to remove chef and all its other pieces from OS X, and Linux after using 1.) The Omnibus installer, and 2.) A bootstrapped node? Since I was trying to use Chef on my Mac, and had RVM installed, chef would not work, so now, I need to figure out how to remove chef.

--2015-03-08 EDIT --
Seems Opscode has put out their own instructions for uninstalling ChefDK. As far as the agent goes, it'd be the same method, using the package manager, or Add/Remove Programs.
http://docs.chef.io/install_dk.html#uninstall

like image 829
FilBot3 Avatar asked Jun 14 '13 18:06

FilBot3


People also ask

What is chef in Ubuntu?

Chef is a powerful platform for automation, simplifying how infrastructure is managed, deployed, or configured across a network. Chef operates by transforming the infrastructure into code.

What is chef workstation?

Chef Workstation is Chef's modern developer tool kit that includes Chef Infra, InSpec and Habitat plus a host of resources, helpers and testing tools that make automating infrastructure, application and security testing easier than ever.


2 Answers

To help answer my own question, I found that depending on how you install Chef, depends on how you uninstall it. You can do the:

Redhat/CentOS

rpm -qa *chef* yum remove <package> 

Or if you installed it with ruby gems:

gem uninstall chef-<version> 

However, for using an Omnibus installer, there wasn't an RPM package, and on my Mac OSX 10.6.8, I couldn't find anything about it. So, I realized that chef is self-contained, so I just deleted the directory in the /opt/ directory. Once I did that, I was able to use my RVM Ruby's.

--2015-03-08--
Opscode provides their own instructions for uninstalling ChefDK, and the Agent.
http://docs.chef.io/install_dk.html#uninstall

like image 65
FilBot3 Avatar answered Oct 06 '22 06:10

FilBot3


If you're on debian/ubuntu (or a system with dpkg) just check the status of the package:

dpkg --list | grep chef # or dpkg --status chef 

then purge (see man dpkg):

dpkg -P chef 
like image 32
DataDao Avatar answered Oct 06 '22 05:10

DataDao