LinuxQuestions.org
Visit Jeremy's Blog.
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 07-10-2016, 01:21 PM   #1
abefroman
Senior Member
 
Registered: Feb 2004
Location: lost+found
Distribution: CentOS
Posts: 1,430

Rep: Reputation: 55
Is it advisable to run yum -y daily via a cronjob on a critical production server?


Is it advisable to run yum -y daily via a cronjob on a critical production server?

To get and install daily all the last updates, new features, bug fixes, and security fixes.

Is there any "industry standard" regarding this?
 
Old 07-10-2016, 01:58 PM   #2
Emerson
LQ Sage
 
Registered: Nov 2004
Location: Saint Amant, Acadiana
Distribution: Gentoo ~amd64
Posts: 7,661

Rep: Reputation: Disabled
Certainly not.
 
1 members found this post helpful.
Old 07-10-2016, 02:58 PM   #3
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Abingdon, VA
Distribution: Catalina
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
Unattended upgrades on a working production server?

Turn in your Linux toaster.
 
2 members found this post helpful.
Old 07-11-2016, 04:50 AM   #4
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Rocky 9.2
Posts: 18,359

Rep: Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751Reputation: 2751
What they said ...
Get yourself a test machine & do it on there first....
 
Old 07-11-2016, 11:44 AM   #5
lazydog
Senior Member
 
Registered: Dec 2003
Location: The Key Stone State
Distribution: CentOS Sabayon and now Gentoo
Posts: 1,249
Blog Entries: 3

Rep: Reputation: 194Reputation: 194
Always test updates before you apply them to production. Linux Admin 101.
 
1 members found this post helpful.
Old 07-11-2016, 02:36 PM   #6
John VV
LQ Muse
 
Registered: Aug 2005
Location: A2 area Mi.
Posts: 17,624

Rep: Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651Reputation: 2651
and "-y" is very very very dangerous
use that with EXTREME CAUTION

it is "yes to EVERYTHING and do not inform me as to changes -- just DO IT "
and it will do what ever "it" is
 
Old 07-13-2016, 10:34 AM   #7
youngstorm
Member
 
Registered: May 2003
Location: USA
Distribution: Fedora 21, RHEL 5,6&7, Windoze 7
Posts: 235

Rep: Reputation: 31
You can help minimize your risk of an update causing issues by only installing security updates on productions servers. This mean NOT installing bug/feature updates.
Only install bug fixes if needed.

To make yum only install security patches do the following:
1. Install the yum security plugin by running 'yum install yum-plugin-security'
2. Add the security option to yum update command like this 'yum --security update'

So, if you do NEED to automate your updates (THIS IS NOT ADVISABLE), installing security only patches will help minimize your risks.
BTW, I only install security patches on all my production servers as a rule, even tho I run them manually.

Hope this helps.
 
Old 07-15-2016, 06:07 PM   #8
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,659
Blog Entries: 4

Rep: Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941
... but, even then, you might be "relying too much" upon what some distro-vendor considers to be "a 'security' update."

The single most-important attribute of any production server is: "absolute continuity of service." It is not okay(!) to update the software that performs that service, "any ol' time a distro-provider wants to." You must plan(!) for these things.
 
Old 07-15-2016, 06:34 PM   #9
youngstorm
Member
 
Registered: May 2003
Location: USA
Distribution: Fedora 21, RHEL 5,6&7, Windoze 7
Posts: 235

Rep: Reputation: 31
While I agree with you, that's not the whole story. I did not go into how I deal with the issue of continuity. In my environment, I take snapshots of anything I'm going to run update's on. This is beyond our normal backups, test environments, etc. that we have in place. Having said that, I must, at some point, either trust the updates, exhaustively scan thru every line of source code (windows source code??? ..... anyone???) or not run the updates. I have found that even running updates in a test env. doesnt always catch all the issues one can run into. Fortunately, Redhat is very good concerning its security updates (I dont think I've ever had a RH security update brake something) and snapshots allows me to run updates then hit the rewind button if something brakes. ...... usually :}

But, again, you make a very good point... thanks!
 
Old 07-15-2016, 07:55 PM   #10
jefro
Moderator
 
Registered: Mar 2008
Posts: 21,981

Rep: Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625Reputation: 3625
I think the clue to answer is this "a critical production server".

You are really in a tough boat on this. You NEED to keep it current for threats but you also don't need to bork it with a faulty update of some junk program.

Best practice is to look at updates and decide or get management to issue a rule.
 
Old 07-17-2016, 10:33 AM   #11
sundialsvcs
LQ Guru
 
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 10,659
Blog Entries: 4

Rep: Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941Reputation: 3941
One clever "shop" that I know of puts all "system-related" files onto a single volume (image). Every part of any of their "standard server-configurations" which is not "malleable user data" is stored on that volume.

There are three virtual-disks associated with each (virtual ...) production server: "previous," "current," and "next." All of them are read-only to the server in question.

Regularly, they apply system updates using an offline master machine, then run a series of production-readiness tests which gruelingly examine everything that is of operational importance to them.

If everything is well, the changes are replicated via rsync onto the "next" images.

A server can then be shut-down, the three disk-images are "rotated," and the server is restarted. The previous "last" image becomes the "next" one.

And, in the case of "extreme unction" , they have one, if not two, "fall-back positions" to drop to.
 
Old 07-17-2016, 02:06 PM   #12
lazydog
Senior Member
 
Registered: Dec 2003
Location: The Key Stone State
Distribution: CentOS Sabayon and now Gentoo
Posts: 1,249
Blog Entries: 3

Rep: Reputation: 194Reputation: 194
Quote:
Originally Posted by sundialsvcs View Post
One clever "shop" that I know of puts all "system-related" files onto a single volume (image). Every part of any of their "standard server-configurations" which is not "malleable user data" is stored on that volume.

There are three virtual-disks associated with each (virtual ...) production server: "previous," "current," and "next." All of them are read-only to the server in question.

Regularly, they apply system updates using an offline master machine, then run a series of production-readiness tests which gruelingly examine everything that is of operational importance to them.

If everything is well, the changes are replicated via rsync onto the "next" images.

A server can then be shut-down, the three disk-images are "rotated," and the server is restarted. The previous "last" image becomes the "next" one.

And, in the case of "extreme unction" , they have one, if not two, "fall-back positions" to drop to.
I like this idea a lot. Would like to know more about this procedure.
 
Old 07-17-2016, 06:59 PM   #13
youngstorm
Member
 
Registered: May 2003
Location: USA
Distribution: Fedora 21, RHEL 5,6&7, Windoze 7
Posts: 235

Rep: Reputation: 31
I would like to know more too.
 
  


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
[SOLVED] Cronjob doesn't run daily as expected PatrickDickey Linux - Newbie 7 12-23-2011 03:59 AM
cronjob schedule to run php script on lighttpd server internally? ted_chou12 Linux - Software 2 03-29-2011 09:43 PM
A cronjob to run yum -y update daily, good idea? abefroman Linux - Server 2 09-16-2009 10:38 PM
Advisable to Let Laptop Run 24/7? Ian Linux - Laptop and Netbook 1 05-02-2004 09:49 PM
Daily cronjob failure Soubi Linux - Newbie 3 07-22-2003 02:59 AM

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

All times are GMT -5. The time now is 04:08 PM.

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