Is the Raspberry Pi suitable for running continuously, 24/7?

  • I would like to run a headless machine to perform some basic automation and statistical generation (e.g. generating netstats, uploading to pvoutput.org), as well as any other trivial batch jobs that may spring up.

    As the RaspPi has been designed primarily as a learning device, is it still a good candidate for 100% up-time? I'm not sure if the unit's classroom-friendly design lends itself to such operational parameters (i.e. 'childproof' design = more robust; is the device built to run for the length of a school lesson etc).

    For the purposes of this question, I am assuming the RaspPi is housed in a case and located in a 'safe' operating environment (i.e. indoors).

    -

    21 Oct 2012: There is a useful related thread here re: SD card life: How can I extend the life of my SD card?

    I've been running mine as a webserver for nearly seven weeks with no reboots, so the hardware is capable of running stable. How long it will last is another matter, I suppose.

    I got an uptime of 20 days, before i shutdown to replace the power source.

    @SimonMandy what exactly was your power source, and what function did the Pi perform?

    We have deployed hundreds of Pi's for the last 2+ years for digital signage purposes. They mostly run 24/7, with regular (unscheduled) power cuts though. We had about 5 units returning dead, not quite sure why they broke down, could well be because of external damaging factors. Overall it's a very stable platform. Granted, our units don't write that often to SD.

    Been running the 3 for a couple of months now, one information radiator and another as combined BT, Airplay and Squeezebox wireless speaker :-(missing google cast)-: No issues so far, as with the 2 it appears that as long the power is stable the board is solid.

    I have an uptime of 451 days today.

  • berry120

    berry120 Correct answer

    8 years ago

    Yes, absolutely.

    • Draws very little power
    • Can be used for a number of server tasks that imply continuous uptime, eg. DHCP server
    • Few people seem to have had issues through running them this way (and the passage of time is now definitely at a point where this is worth noting)

    Historically, there were a few negatives I could think of, I'll leave them here for reference:

    • SD card has limited lifespan
    • You could potentially find stability issues with some drivers
    • Limited resources mean if there is a memory leak somewhere, or a process that suddenly eats lots of RAM, it won't be long before performance drops and / or a reboot is required.

    All of these points are now (June 2018) somewhat moot, though. A decent SD card in practice these days won't have a problem unless it's under very heavy use, almost all the early stability issues with drivers have been ironed out, and 1GB of RAM is heaps more than the original (original boards had 256MB, and up to half of that was eaten by the GPU.)

    I still wouldn't use it as a device that needed to be up 24/7 for some form of critical operation, but then again that's the same with any consumer grade PC.

    If you use the SD card just to boot it up, and the run from another media like an HDD you eliminate the SD card problem almost completely.

    @Reonarudo Yes, this is true but by doing that you sacrifice other aspects - the system will likely be noisier and draw more power for instance, as well as being more expensive in hardware. May or may not matter to each use case, but I agree it's worth noting there's other options to be had.

    SD wear is probably a greatly exaggerated issue in this kind of use. People have no problem writing gigabytes of data to a card weekly for years on end in a camera, for example. The question also hints that data is sent to a network service, which means there may be no need for volatile storage other than RAM and the whole card could spend its normal life read-only. Keeping a backup and replacing the card with a fresh one every n years is also cheap.

    Typical server software is also routinely run 24/7 all around the world and unless you create memory/storage leaks yourself, they practically never happen.

    @XTL I agree - though on cheaper SD cards that don't spread the writes properly they generally will die relatively quickly (in cameras or anywhere else!) I don't think the disadvantages outweigh the advantages at all (at least for the majority of the time), just wanted to put them there to provide a balanced viewpoint.

    I'm running a DreamPlug on a good-quality SanDisk microSD with an external RAID1 enclosure mounted under /var (plus a swap partition), so the mSD is basically read-only. I've had this setup running 24/7 for two years. One HD failed last week; the microSD is still going strong. Just offload write-intensive operations elsewhere, and your SD cards will last ages.

    I am running a chess playing software on a Pi, it has been on for 2 weeks non stop and so far no problem at all. Granted most of the time it sits idle, and the program is loaded into memory since boot so the SD card shouldn't have been used in the last 2 weeks. I have not noticed any heating issues and it has not failed in any discernible way.

    A proper SD card like this: http://www.bhphotovideo.com/c/product/1082349-REG/sandisk_sdsdxp_128g_a46_128gb_extreme_pro_uhs_i.html wears out after 100TB of writing. This is not an issue, only if you use something very cheap. Every sandisk sd card uses wear leveling since 2008 (if I remember well), and I guess other top manufacturers use it too.

    @LeonardoMarques except HDDs have a much shorter lifespan thanSD cards.

  • I'm finding that the Pi makes a very good microserver, as long as you understand its limitations. While flash memory in theory has a limited life, in practice you'll get several years out of it. I've been running a similar ARM-based board as a home server for over three years with / and /home on an SD card, and it hasn't complained.

    The biggest issue I have with the Pi is the power supply. Running off a phone charger, it doesn't have the capacity to ride through minor power glitches. I've found it reboots at the slightest flicker. Sure, it comes back up quickly, but you'll either have to address this with a better regulated power supply, or design your tasks that they can restart from where they were interrupted on reboot.

    Update, 2013-12-23: The card on the the ARM-based board home server may have finally crapped out after the 24+ hour blackout we had here due to an ice storm. This is a single anecdotal report, and should be taken as-is.

    The power glitches might be less of a problem if you plug it in a UPS. That's my solution for network switch and router running on a similar board.

    Yes, mine has been running off a UPS since about the day after I wrote that comment, and has uptimes to match ...

    Just to clarify (to make sure I'm reading it correctly), by "uptimes to match" you mean uptimes of months, yes?

    Yes. I have noticed that my long-running machine is slowly filling up the card. I'm suspecting logging.

    Your flickering issues might be because the phone charger can't provide the 1.2 A that the Raspberry Pi needs.

    Nope, it's fine if it has a stable grid connection. With the crappy overhead wiring we have in Toronto, that's a problem that only a UPS can solve. My Raspberry Pi draws about 850 mA; 1.2 A is a bit heavy.

    For a Pi, a battery pack that is commonly used to give your phone some extra juice acts as a perfect UPS for your Pi, and it can run on it for hours.

    +1 for USB battery pack acting as a UPS, witnessed working for 18 months. I recently found one with solar panels for bonus trickle charging.

    @MaxthonChan I experience restarts when electricity drops with my battery pack. Can you tell us which battery do you use and if it has similar problem or not? thanks

    @Davita I used a ghetto solution, assembled one myself.

  • I have been running mine for about 3 months non-stop as a web server for www.sm0vpo.com where there are about 10,000 electronic PDF files and about 250 electronic projects that i have fully documented with PCB poil patters in ZIP and GIF form.

    I have about 3,000,000 hits per year so my little RPi will have seen about 700,000 hits as well as experiencig both heavy and light traffic.

    I have the RPi running "barefoot" (no keyboard, monitor or mouse) with no external USB connections. The only connections are SD-card (SanDisk EXTREME 8GB @33Mb/s). I reasoned that the keyboard, mouse and memory stick could burn as much as the RPi itself.

    The RPi has never once crashed, is slightly warm and I consider it to be 100% reliable. An MS Windoze-XP machine running the same traffic had to be restarted about every second month on average, with a lower traffic density. The RPI is also faster than the 2.66GHz HP computer but I believe this to be a function of the different operating system (my RPi is running LINUX - debian).

    If you want more information I can send you pictures, but at the moment and as a newbie, I cannot access net logs in the lighthttpd server. If you have any command sequences I can enter into my SSH terminal then you are more than welcome to share all information (and softare) I have.

    FYI - My RPi is hidden behind an IP-Cop (LINUX) hardware-dedicated firewall, but I hope one day to change that ATX card for a dedicated RPi server/firewall. I am only missing one component - time.

    "barefoot" ... headless maybe?

    "barefoot" ... commando maybe?

    How is it going after three more years? (posted 3/2013, now it's 4/2016) Since you are exercising storage and IO, was there ever a failure since your original post?

    @Harry Is your machine still "kicking"?

  • Since most computers are not suited for 24/7 operations due to their moving parts the RPi shouldn't have any problems.

    If a machine fails it's most of the time due to a hard drive failing or some fans failing as those are prone to wear.

    The only thing that can experience wear like that on a RPi is the SD Card so you might want your setup to get as much of the write operations into RAM or onto another device that can handle writes a little bit longer. Something like an usb attached server grade hard drive that's designed to operate 24/7.

    `not suited for 24/7 operations due to their moving parts` - You mean hard disk(fan failure is not a show stopper!)- the only moving part in a PC- You can run a HDD for 5 years without turning it off and it will beg for another 5 years! Computers can run 24/7 no problem- That is what they are designed for. Servers are made to run at 100% CPU in hot conditions-if needed. That is why servers are more expensive. SD cards are not moving and they are worse than HDD's - So your answer is rubbish. Cant believe you got upvotes. -1 from me (misleading and non-factual answer) Server grade hard drive???

    i'd like to see that desktop machine without a running fan going on while you're using it. True most of the newer machines will just freeze down and crash as the cpu themal sensor kicks in, but some older machines actually just went smokey once this happens. So thats a show stopper for sure. And an consumer HDD is not necessarily suited for 24/7 operation as well (e.g. green series from western digital) while some are (e.g. the new red series)

    I have a NAS with two Seagate consumer drives which is on 24/7 as well as my laptop which is also on 24/7. My two PCs at work are also on 24/7. Computers do not need to rest, it is a myth. Disk drives do gradually wear out and some fail prematurely as with all manufacturing some are better than others (i.e. everything is made to a tolerance and not identical). That is all there is to say really.

  • For my own experience, I have had my RaspPi running since June 24/7 logging data from my solar system and haven't had any problems. Im using a DC-DC converter for power via the 12V solar system and fitted a cooling fan on the box but it hasn't got hot enough to turn on yet.

    I am not writing to the SD card so that will hopefully not be a point of failure, it is only uploading to a remote server every 60 seconds.

    The board seems to run very cool and uses very little power.

    That was 4 months of continuous operation 24/7, and (smartly) without writing to the SD card. Now it's been almost 4 years since you originally posted this answer, did it run considerably longer after your posting? (I want to ask "which solar system are you living in" but sometimes humor backfires)

    @BrianDorey Look up https://en.wikipedia.org/wiki/Solar_System :) I think we all share the same solar system. I got a chuckle after reading that.

    According to https://spaceplace.nasa.gov/other-solar-systems/en/ there is just one called "our solar system". Not sure why it's not "The Solar System" then.

  • I was also eager to know more about the 24/7 capabilities of the Raspberry Pi. Therefore, I installed the app "stress" (sudo apt-get install stress), which is capable of loading the CPU for the full 100% all the time.
    The best thing about "stress" is that it gives priority to other running processes, it only "fills" the gap till the CPU is loaded for the full 100%.

    I ran the test a while ago for 275 (!!!) days, without any issues. No reboots, no crashes, no overheating, no... nothing (I didn't tweak the Raspberry Pi, I used it as-is, so no overclocking and so on...).

    Based upon what I've experienced, I'm quite sure the Raspberry Pi is more than robust enough to survive 24/7 situations for a very, very long time. I'm even considering to use it for my home automation system...

    Great 1st-hand info, thanks for sharing! What happened day 276? :)

    It blew apart... :P Nope, seriousely, we had an electricity cut-of (due to maintenance on the electicity net) and because of this, I had to interrupt my test. But rest assured, it's still up and running! :-)

    Either way, awesome. :)

  • If you want your SD card to last for longer I have got two pieces of advice for you:

    • Make sure you don't have too many write cycles, ie. turn off logging, don't run a Bitcoin node, etc.
    • Buy a good brand (ocz/kingston/a-data and other popular ones are fine, just not chinese no-names)

    When I did not follow those two mentioned above my memory cards on headless Debian machines died within weeks

    Various SD card techniques are also mentioned here.

  • I can only offer a view based on my experience. I use 2 raspberry pi's as mini servers and never turn them off. My first Pi is now well over 4 months old and has probably been 'off' for less than a few hours during all that time. I use it pretty heavily as an iPlayer download and podcast host, which does a reasonable amount of reads and writes of the SD card.

    It sits behind my tv in the cardboard box it came in (with a couple of holes cut for the cables), never gets warm and seems to work continuously.

    I have had to rebuild it twice, once because I wanted to move from Squeeze to Raspbian and once because I buggered up the OS messing about.

  • A few things to consider when designing your project:

    • Depending on your usage of the RaspberryPi spiking it's SoC to near 100% usage can make it quite hot, and I recommend adding a heatsink, as I have done, with perhaps a little 5volt fan to keep things a little cool (I've gotten my heatsink from a old Security DVR)
    • SD Card performance and wear, I know this has been touched on already but I would highly recommend not cheaping out on this part of the setup. E.g. going with a high class card for fast read & write speeds and longer period of time before it will become necessary to replace the card; this of course also increases your RaspberryPi's speed and could be useful if you plan to do a lot with data. More details Here ;D
    • Another point to note would be power consumption and supply. As you probably know quite well the RaspberryPi should be operated at 5v and at least 700mAs, and you this another area where cheaping out can lead to some unpleasant results... So perhaps going with a rather strictly regulated 5v power supply (to prevent brownouts which could cause your Pi to restart) delivering about 1 amp.
    • My fourth point is that you should also make sure you have a sturdy place to secure the Pi away from anything that might cause damage ;) (they are quite hard to get a hold of haha)

    Hope that helps mate!

  • Just to chime in with a datapoint:

    I've used my raspberry as a datalogger for my solarpanels. It was writing to a logfile on the SDcard every minute. I've now had a hard failure of the SD card for the second time. Each time the card lasted about a month. The cards were both Kingston SDC4/4GB cards. So SDcard wear is real!

    Oh wow, this is exactly what I hope to use my Pi for! I might have to look at saving the log files somewhere else (dropbox maybe?). I hope to use sma-bluetooth but haven't had *any* luck so far with bluetooth dongles. Thanks for the update.

    I've been shuffling around a few GB of data daily for the past several months now. Are you sure your overclock/power supply didn't screw anything up? (Sandisk ultra 16GB Class 10 microSDHC)

License under CC-BY-SA with attribution


Content dated before 6/26/2020 9:53 AM