# Test/Prod Patching Strategy

**URL:** https://forums.suse.com/t/test-prod-patching-strategy/25123
**Category:** SLES Updates
**Created:** [February 12, 2014, 5:35pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123 "2014-02-12T17:35:39Z")
**Posts on this page:** 13
**Page:** 1

<div class="post-metadata">

### Author: ![cmyslinsky](https://avatars.discourse-cdn.com/v4/letter/c/858c86/32.png) [@cmyslinsky](https://forums.suse.com/u/cmyslinsky)
#### Post date: [February 12, 2014, 5:35pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/1 "2014-02-12T17:35:39Z")

</div>

I have been tasked with implementing a patching strategy on our new SLES 11 SP3 boxes which starts patches in test then a month later installs those same patches in production. Rinse and repeat.

Being new to SuSE administration I’ve started investigating this effort with the Online Update tool. First glance it appears I can select the needed updates, export the list of updates to a text file then install. I’m guessing I can use the text file to ensure only the prior month’s patches are installed on production. In the end this solution feels kludgy and error prone so I’m looking for suggestions.

I’m curious how others are pushing patches through their environments and better implementation ideas for this particular scheme of patching test, waiting a month then patching production.

Cheers  
Chad

---

<div class="post-metadata">

### Author: ![Jens-U](https://avatars.discourse-cdn.com/v4/letter/j/d78d45/32.png) [@Jens-U](https://forums.suse.com/u/Jens-U)
#### Post date: [February 12, 2014, 5:58pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/2 "2014-02-12T17:58:30Z")

</div>

Hi Chad,

sounds like you’re running a modestly sized environment (read “no sneaker management”) - have you had a look at the “SUSE Manager” product?

Regards,  
Jens

---

<div class="post-metadata">

### Author: ![cmyslinsky](https://avatars.discourse-cdn.com/v4/letter/c/858c86/32.png) [@cmyslinsky](https://forums.suse.com/u/cmyslinsky)
#### Post date: [February 12, 2014, 6:11pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/3 "2014-02-12T18:11:31Z")

</div>

Thanks for the fast response Jens. I should have mentioned the size of the environment in the original message. Sorry about that.

We currently have 6 boxes with 2 being prod and the remaining 4 being dev/test so not too bad even if we had to do something manual. There are also 7 Red Hat boxes which could become SuSE at some point but I don’t expect the environment to grow beyond those.

Haven’t investigated SuSE Manager will look that up. Would you still recommend investigating that for a 15ish box environment?

Chad

---

<div class="post-metadata">

### Author: ![Jens-U](https://avatars.discourse-cdn.com/v4/letter/j/d78d45/32.png) [@Jens-U](https://forums.suse.com/u/Jens-U)
#### Post date: [February 12, 2014, 6:17pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/4 "2014-02-12T18:17:58Z")

</div>

Hi Chad,

> [@cmyslinsky;19272](#):
>
> Haven’t investigated SuSE Manager will look that up. Would you still recommend investigating that for a 15ish box environment?

let me admit that I have no idea of the licensing costs - but that environment size would in my eyes justify at least evaluating that tool. SUSE Manager will handle RedHat boxes as well, so you’d profit right from the start…

Regards,  
Jens

---

<div class="post-metadata">

### Author: ![malcolmlewis](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/malcolmlewis/32/11375_2.png) [@malcolmlewis](https://forums.suse.com/u/malcolmlewis)
#### Post date: [February 12, 2014, 6:21pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/5 "2014-02-12T18:21:07Z")

</div>

> [@](#):
>
> On Wed 12 Feb 2014 04:14:02 PM CST, cmyslinsky wrote:
> 
> Thanks for the fast response Jens. I should have mentioned the size of  
> the environment in the original message. Sorry about that.
> 
> We currently have 6 boxes with 2 being prod and the remaining 4 being  
> dev/test so not too bad even if we had to do something manual. There  
> are also 7 Red Hat boxes which could become SuSE at some point but I  
> don’t expect the environment to grow beyond those.
> 
> Haven’t investigated SuSE Manager will look that up. Would you still  
> recommend investigating that for a 15ish box environment?
> 
> Chad

Hi  
If you can spin up a virtual machine with 4-8GB of RAM and say 80GB of  
disk space, it would be worth running an eval version of SUSE Manager  
to test, it will also support the RHEL machines.

–  
Cheers Malcolm Â°Â¿Â° SUSE Knowledge Partner (Linux Counter #276890)  
openSUSE 13.1 (Bottle) (x86\_64) GNOME 3.10.2 Kernel 3.11.10-7-desktop  
If you find this post helpful and are logged into the web interface,  
please show your appreciation and click on the star below… Thanks!

---

<div class="post-metadata">

### Author: ![cmyslinsky](https://avatars.discourse-cdn.com/v4/letter/c/858c86/32.png) [@cmyslinsky](https://forums.suse.com/u/cmyslinsky)
#### Post date: [February 13, 2014, 9:37pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/6 "2014-02-13T21:37:21Z")

</div>

It looks like for the short-term the patching strategy will need to happen without the assistance of SuSE Manager. Since the original post I realized that what is selected under summary where it says “Security update for…” or “Recommended update for…” can actually be comprised of one or more packages. It’s the packages that I can export to the text file from the YaST2 Online Update. In other words, what is being selected to be installed doesn’t cleanly match up with the packages to be installed. I’m also concerned a month later when production is patched that a newer version of a package could become available and supersede the one installed in test the month prior. It appears an alternative version could be selected from the Versions tab but I’m not sure what caveats that could bring. So, I’m back to looking for additional suggestions on how to patch test, wait a month than apply those exact same patches in production. Additional thoughts?

Chad

---

<div class="post-metadata">

### Author: ![malcolmlewis](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/malcolmlewis/32/11375_2.png) [@malcolmlewis](https://forums.suse.com/u/malcolmlewis)
#### Post date: [February 13, 2014, 10:17pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/7 "2014-02-13T22:17:19Z")

</div>

> [@](#):
>
> On Thu 13 Feb 2014 07:44:01 PM CST, cmyslinsky wrote:
> 
> It looks like for the short-term the patching strategy will need to  
> happen without the assistance of SuSE Manager. Since the original post  
> I realized that what is selected under summary where it says “Security  
> update for…” or “Recommended update for…” can actually be comprised  
> of one or more packages. It’s the packages that I can export to the  
> text file from the YaST2 Online Update. In other words, what is being  
> selected to be installed doesn’t cleanly match up with the packages to  
> be installed. I’m also concerned a month later when production is  
> patched that a newer version of a package could become available and  
> supersede the one installed in test the month prior. It appears an  
> alternative version could be selected from the Versions tab but I’m not  
> sure what caveats that could bring. So, I’m back to looking for  
> additional suggestions on how to patch test, wait a month than apply  
> those exact same patches in production. Additional thoughts?
> 
> Chad

Hi  
Subscribing to the patch alert emails should provide info on what/why  
the updates are there. Some are critical, and depending on your  
situation may need to applied sooner than a month. Sounds like you need  
some vm’s and snapshots to test/check?

You can use zypper with a dry-run command to see what will be  
downloaded and installed, you can also just download only and not  
install…

–  
Cheers Malcolm Â°Â¿Â° SUSE Knowledge Partner (Linux Counter #276890)  
openSUSE 13.1 (Bottle) (x86\_64) GNOME 3.10.2 Kernel 3.11.10-7-desktop  
If you find this post helpful and are logged into the web interface,  
please show your appreciation and click on the star below… Thanks!

---

<div class="post-metadata">

### Author: ![Willem1](https://avatars.discourse-cdn.com/v4/letter/w/c57346/32.png) [@Willem1](https://forums.suse.com/u/Willem1)
#### Post date: [February 13, 2014, 11:16pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/8 "2014-02-13T23:16:29Z")

</div>

> [@cmyslinsky;19315](#):
>
> …I’m also concerned a month later when production is patched that a newer version of a package could become available and supersede the one installed in test the month prior. It appears an alternative version could be selected from the Versions tab but I’m not sure what caveats that could bring. So, I’m back to looking for additional suggestions on how to patch test, wait a month than apply those exact same patches in production. Additional thoughts?

What I’ve been doing is setup a SUSE SMT server and disable the daily smt-mirror (that command syncs the local SMT server repos with those in the outside world) and run the smt-mirror command when the patch cycle has completed. With our customer sites that can also take a month or so and this gives them the option to do a sync, start patching the less critical servers (SLES and OES) and move on to the more business critical ones using the same patch levels.

When they are ready for a new patch cycle, they first initiate a smt-mirror command.

That could be an option?

Cheers,  
Willem

---

<div class="post-metadata">

### Author: ![cmyslinsky](https://avatars.discourse-cdn.com/v4/letter/c/858c86/32.png) [@cmyslinsky](https://forums.suse.com/u/cmyslinsky)
#### Post date: [February 13, 2014, 11:40pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/9 "2014-02-13T23:40:07Z")

</div>

We have a VM for test and another for production. The goal is to apply a set of patches to test then a month later apply only that set of patches to production. Preferably using a semi automated method but I’m not ruling a totally manual process if it is foolproof and repeatable. The concerns I’m struggling with are two fold.

First is that the patches selected or deselected for install include one or more packages if I’m using the terminology correctly. The list of packages is what I’m able to export to a text file not the list of patches being installed.

The second area is how to address patches that have been updated to include a newer package than what was installed on test when it is time to patch production a month later. It appears different versions can be selected for install from the versions tab in YaST2 but I’m concerned about making a mess of dependencies.

Chad

---

<div class="post-metadata">

### Author: ![cmyslinsky](https://avatars.discourse-cdn.com/v4/letter/c/858c86/32.png) [@cmyslinsky](https://forums.suse.com/u/cmyslinsky)
#### Post date: [February 14, 2014, 3:27pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/10 "2014-02-14T15:27:38Z")

</div>

[QUOTE=Magic31;19318]What I’ve been doing is setup a SUSE SMT server and disable the daily smt-mirror (that command syncs the local SMT server repos with those in the outside world) and run the smt-mirror command when the patch cycle has completed. With our customer sites that can also take a month or so and this gives them the option to do a sync, start patching the less critical servers (SLES and OES) and move on to the more business critical ones using the same patch levels.  
[/QUOTE]

SMT appears to be free. Worth a look.

Thanks for the scoop.  
Chad

---

<div class="post-metadata">

### Author: ![clarkmike](https://avatars.discourse-cdn.com/v4/letter/c/57b2e6/32.png) [@clarkmike](https://forums.suse.com/u/clarkmike)
#### Post date: [February 26, 2014, 8:25pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/11 "2014-02-26T20:25:15Z")

</div>

I use a shell program to do updates via cron. It would be easy enough to run it at the beginning of the month on the test server then at the end of the month on the production server. This way I get a report of what was installed and can investigate if there are problems. Like when the SLES 11.3 update killed the BackupExec ralus agent.

#!/bin/bash  
MailTo=SomeOne #put names and addresses in /etc/aliases  
UpdatesOut=’/tmp/updates.out’  
rm $UpdatesOut

Running=`ps -ef|grep zypper|grep -v grep`  
if [-n “$Running”];then  
echo “$Running” |mail -s “ServerName Updates TROUBLE zypper is still running” $MailTo  
exit  
fi  
zypper ref  
UpDates=`zypper lu`  
if [[“$UpDates” =~ “No updates”]];then  
echo “$UpDates” \> $UpdatesOut  
cat $UpdatesOut | mail -s “ServerName Updates No Updates” $MailTo #\</dev/null  
exit  
fi  
/usr/bin/zypper -n up -l \> $UpdatesOut  
if [$? -eq 0] ;then  
mail -s “ServerName Updates” $MailTo \< $UpdatesOut  
/sbin/SuSEconfig  
else  
mail -s “ServerName Updates TROUBLE” $MailTo \< $UpdatesOut  
exit  
fi

if grep -i kernel $UpdatesOut \> /dev/null 2\>&1; then  
/sbin/init 6  
#reboot if kernel update was included  
fi  
PRun=`zypper ps`  
if [[“$PRun” =~ “No processes”]];then  
exit  
else  
echo $PRun|mail -s “ServerName Updates zypper ps” $MailTo  
fi  
exit

---

<div class="post-metadata">

### Author: ![clarkmike](https://avatars.discourse-cdn.com/v4/letter/c/57b2e6/32.png) [@clarkmike](https://forums.suse.com/u/clarkmike)
#### Post date: [February 26, 2014, 8:39pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/12 "2014-02-26T20:39:34Z")

</div>

I forgot to mention that with each SLES version update it’s most likely you will need to change the update program name. There have been 3 different programs used for SLES updates in the last three versions, 9- I forget, 10 -rug, 11- zypper. 12 - ???

---

<div class="post-metadata">

### Author: ![Willem1](https://avatars.discourse-cdn.com/v4/letter/w/c57346/32.png) [@Willem1](https://forums.suse.com/u/Willem1)
#### Post date: [February 27, 2014, 10:46pm UTC](https://forums.suse.com/t/test-prod-patching-strategy/25123/13 "2014-02-27T22:46:35Z")

</div>

> [@clarkmike;19562](#):
>
> I forgot to mention that with each SLES version update it’s most likely you will need to change the update program name. There have been 3 different programs used for SLES updates in the last three versions, 9- I forget, 10 -rug, 11- zypper. 12 - ???

SLES 9 was red-carpet I believe… but rug was also already in there. Long time for me too since I’ve used SLES 9.

From the looks of it, zypper will still be the mechanism used for SLES 12. Which is a good thing imo, as I like zypper 🙂

Cheers,  
Willem
