Power Off Server Once In a While?

by on October 11, 2008 · 11 comments· LAST UPDATED October 11, 2008

in , ,

From my mailbag:

I turn off the PC at home or the office once in a while. Now, I've server at colocation center. Do we need to run server 24/7? I do reboot the server once a month. Is it advisable to completely power off a server once in a while instead of 24/7 running?


Short answer - no.

A UNIX / Windows server should be online 24/7 to serve http requests, sale product and services or simply collect emails. Most servers are build to operate 24/7 for years. There is no need to power it off once in a while. You need to powerdown server only if:

  1. Hardware replacement (replace NIC or hard disk or power supply)
  2. Hardware upgrade (upgrade CPU or RAM)
  3. Testing
TwitterFacebookGoogle+PDF versionFound an error/typo on this page? Help us!

{ 11 comments… read them below or add one }

1 Bilal October 12, 2008 at 10:22 am

Normally you don’t need to restart, only if you start to have some problems and same errors.

But if you don’t have production server you can restart it after 3 months with a force fsck.

Reply

2 Colin October 12, 2008 at 12:04 pm

While I agree with most of what is said above. There are circumstances where I have found through experience that a good power cycle will do wonders.
First things first. On a windows box a power cycle is almost mandated on a monthly basis. That is why I use Linux.

Even then I find in practise that if you are serving up applications that do memory leak or you just find you box getting cramped up with dead processes. I find no problem with adding a line to cron
0 0 * * 0 /sbin/shutdown -r now #(adjust to your system)

This naturally assumes that your server is not 24/7

Reply

3 Miker October 12, 2008 at 4:01 pm

I think this is really a matter of opinion and probably more determined by the application.

We have hosts running nameservers and standard web servers (all internal – not internet exposed) that have been up for 3+ years and show no need for a reboot, although the apps themselves have been restarted. We also have boxes that run incredibly memory intensive cgi scripts that don’t make it that long. To be honest, its usually because of some type of network event or hung mount while running near the limits of memory that ends up necessitating a reboot. Even memory leaking apps can often be cleaned up after – don’t forget to check orphaned shared memory segments and semaphores after the process is killed.

Personally, I would only reboot in the case of a kernel upgrade or patch cluster that required it. I would never power down a server that is truly depended upon unless required to do so. I’ve seen more than one instance of disks that hadn’t stopped spinning in 5 years, but power them down long enough to cool off and they won’t spin back up.

Reply

4 Akshay October 12, 2008 at 5:59 pm

As said it depends upon the applications..many severs all over the world are running continuously over years…

Reply

5 ashu October 13, 2008 at 1:47 am

most the production servers comes with the capblity of hot swapping like hot-swappable hard-drives power-supply etc. then u dont needto restart urs erver at all and what about planning man.. plan for future and u wont need hardware upgrade at all also u can use clusetring too

Reply

6 shawn October 13, 2008 at 3:22 pm

there was an interesting article online (can’t remember the reference) about powering down unneeded servers to “green” up your datacenter. the idea that an underutilized server sits, idle, consuming energy is troublesome.

a simple fact is it is fine to power down a server if you want; especially if a) you want to conserve power and b) that server is idle more than peak.

virtualization makes this even easier to accommodate. if you’re running a high availability environment (e.g. vmware with vmotion) then you can simply power off nodes in your cluster to save power and still provide all your services. if you begin peaking a lot, power up another node to provide additional resources.

personally, i think “24/7″ is nothing but sales/marketing rhetoric and has little to do with technical constraints. power up, power down, reboot, etc…the server will be fine (unless something is already wrong with it, in which case a power cycle can identify problems).

Reply

7 Bunty October 13, 2008 at 5:18 pm

this is the latest kernel which I want.

Reply

8 majickmann October 13, 2008 at 6:48 pm

The correct response is: “It depends…”

It depends on several factors, the most common being the application.

As a rule, we reboot Windows monthly. The Unix servers are rebooted from 90 days to annually, depending on the application and patch requirements.

If you know your server(s), then you know better than anyone else.

Just my nickels’ worth…
:-)

–majickmann

Reply

9 Tom October 16, 2008 at 9:05 pm

It depends. As a Unix admin, I will almost never power off my unix systems for the reasons above.

Usually, I will not reboot either. Except when dealing with:
– zombie processes (unkillable processes)
– memory leaks
– swapping (a reboot might be faster then waiting for the memory load to go down)

I’ve been at places that rebooted the firewalls once a week. That would drop all network connections which is not a bad thing.

Reply

10 Nahum October 23, 2008 at 4:48 am

Power off a server? what for?

I am running dozens of servers and rebooting them only when i install a new kernel.

One of my favorite servers is an IBM x330 machine (2xPIII, 2GB, 2x36GB) installed with Fedora Core 2 that gets no updates for at least 3-4 years. This server is on since 1999 (or 2000?) without being off for a single day. Now that it does not get any updates, i restarts it once a year…

Reply

11 Leslie Satenstein November 1, 2008 at 12:45 pm

I power the servers off monthly. Since the dust that accumulates affects cooling, Once off, I wash / change filters, and I use a vacuum and toothbrush together to clean the cooling fins on the Intel processors. I also clear the dust of the fan vanes. Otherwise there is no need to perform a poweroff or reboot.

Reply

Leave a Comment

Tagged as: , , , , , ,

Previous post:

Next post: