LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 06-28-2021, 10:40 AM   #1
keif
Member
 
Registered: Apr 2013
Posts: 107

Rep: Reputation: Disabled
Chef Handlers - add run_list on failed recipe run


Hello, I am encountering an issue running a chef role for a new install.

When I run the role, sometimes an Ubuntu service is running or some other issue and this causes the run to fail. When the run fails, the chef-client it ran on does not get the role and run_list from the role assigned to it when I check the node on the chef server (since the run failed, assigning the role to the node fails too).

I need to find a way to run the recipes in the role so that even if there is an error, the role and run_list gets assigned to the client.

Also, I need to find a way that if a fail occurs, the remaining recipes that were on the run_list continue. Right now if one recipe fails, the whole run_list stops.

I have been able to "trick" chef with deliberate exit code 0 so that it thinks the recipe succeeds and the recipes continue (aka a terrible solution :-)

If anyone has solved this sort of thing, especially with handlers of some sort, then any advice would be appreciated. Thanks, Keith
 
Old 07-07-2021, 01:24 PM   #2
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 16,493

Rep: Reputation: 2372Reputation: 2372Reputation: 2372Reputation: 2372Reputation: 2372Reputation: 2372Reputation: 2372Reputation: 2372Reputation: 2372Reputation: 2372Reputation: 2372
313 views, no replies, and for good reason. We haven't a clue wht you're talking about.

Apart from 'Ubuntu,' There's no versions, kernel, pc details, software, versions - nothing.
How_To_Ask_a_Question

Last edited by business_kid; 07-07-2021 at 01:26 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: How to install Chef Server, Workstation and Chef Client on Ubuntu 18.04 LXer Syndicated Linux News 0 06-18-2019 09:03 PM
[SOLVED] Changing Directories in Chef Recipe johnpedou Linux - Newbie 3 01-11-2017 01:41 PM
[SOLVED] otcl-1.14 make failed [recipe for target `libotcl.a' failed] for ns-allinone-2.35-RC8 pratikjoshi Linux - Newbie 4 08-23-2013 06:44 AM
run_list of rt_se hello13 Linux - Kernel 0 04-03-2013 10:45 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 10:16 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration