The Naked Scientists

The Naked Scientists Forum

Author Topic: Why Does Rebooting A Device Often Solve Issues ?  (Read 2523 times)

Offline neilep

  • Withdrawnmist
  • Naked Science Forum GOD!
  • *******
  • Posts: 20602
  • Thanked: 8 times
    • View Profile
Why Does Rebooting A Device Often Solve Issues ?
« on: 30/07/2015 12:45:50 »
Wocha peeps,

how are ewe today ?..I'm fine.. Thanks for asking !!

As a sheepy i of course keep up to date with all the latest gadgets and tech. Ewe won't catch me with an out of date piece of kit (well...there is wifey i guess !!)

Look, here i am with my latest computer !!..I know !!..impressive innit ?




I know ewe are jealous !!

Even my super computer occasionally misbehaves and thus a reboot is called for. Fortunately it only takes an hour to reboot such is the awesome puissance of the abacus chip inside !  Once done computer works again...voila !!

Why do things like phones and computers with issues benefit from a reboot which can often fix them ?

whys that then ?

hugs and shmishes

mwah mwah !!


neil

« Last Edit: 30/07/2015 19:41:51 by neilep »


 

Offline David Cooper

  • Neilep Level Member
  • ******
  • Posts: 1505
    • View Profile
Re: Why Does Rebooting A Device Often Solve Issues ?
« Reply #1 on: 30/07/2015 17:36:15 »
Diminishing returns for the programmers is the issue - they could spend years trying to find the hard-to-find bugs that creep in over time to make operating systems and other programs go wrong, but if they don't occur so soon that you can't get a reasonable amount of work done first, you can just fix them by rebooting, so the programmers just leave you to do that while they go off to write new code to do something more productive. The questions they ask are, is it good enough to sell, and is it worth trying to inprove it a little rather than getting on with writing more important code which will make the old stuff redundant anyway. In most cases there will be many rare bugs which gradually disable a system, so hunting down one and fixing it won't even show up as there will be lots of other bugs which will still force you to reboot every now and then. These bugs will also be the fault of different people, and while some of these programmers may feel the need to put in the effort to eliminate the bugs they've caused, the rest can't be bothered, and that means that some who might have bothered won't bother because they don't see the point if the rest aren't going to put in the work. If the operating system and programs that run on it are intended to operate equipment that must not go wrong, more work will be done to check code and eliminate bugs for that, but the costs will go through the roof.
 

Offline chris

  • Neilep Level Member
  • ******
  • Posts: 5339
  • Thanked: 65 times
  • The Naked Scientist
    • View Profile
    • The Naked Scientists
Re: Why Does Rebooting A Device Often Solve Issues ?
« Reply #2 on: 30/07/2015 19:05:40 »
I laughed so much at this thread that I nearly cried; that computer is fabulous. Actually, at the BBC's Make it Digital show in Cambridge a few weeks ago they had one of the original consoles for PONG, sitting alongside an original Atari; we played bat n ball for about half an hour; ridiculously addictive...
 

Offline neilep

  • Withdrawnmist
  • Naked Science Forum GOD!
  • *******
  • Posts: 20602
  • Thanked: 8 times
    • View Profile
Re: Why Does Rebooting A Device Often Solve Issues ?
« Reply #3 on: 30/07/2015 19:44:29 »
Diminishing returns for the programmers is the issue - they could spend years trying to find the hard-to-find bugs that creep in over time to make operating systems and other programs go wrong, but if they don't occur so soon that you can't get a reasonable amount of work done first, you can just fix them by rebooting, so the programmers just leave you to do that while they go off to write new code to do something more productive. The questions they ask are, is it good enough to sell, and is it worth trying to inprove it a little rather than getting on with writing more important code which will make the old stuff redundant anyway. In most cases there will be many rare bugs which gradually disable a system, so hunting down one and fixing it won't even show up as there will be lots of other bugs which will still force you to reboot every now and then. These bugs will also be the fault of different people, and while some of these programmers may feel the need to put in the effort to eliminate the bugs they've caused, the rest can't be bothered, and that means that some who might have bothered won't bother because they don't see the point if the rest aren't going to put in the work. If the operating system and programs that run on it are intended to operate equipment that must not go wrong, more work will be done to check code and eliminate bugs for that, but the costs will go through the roof.

Thanks David. So bugs are really there from the offset due to bad programming, either by a fault in the operating system which causes good software to glitch or a glitch in a third party software eh ? so, it's all down to programming in the end. Or possibly a hardware issue too ?
 

Offline neilep

  • Withdrawnmist
  • Naked Science Forum GOD!
  • *******
  • Posts: 20602
  • Thanked: 8 times
    • View Profile
Re: Why Does Rebooting A Device Often Solve Issues ?
« Reply #4 on: 30/07/2015 19:46:05 »
I laughed so much at this thread that I nearly cried; that computer is fabulous. Actually, at the BBC's Make it Digital show in Cambridge a few weeks ago they had one of the original consoles for PONG, sitting alongside an original Atari; we played bat n ball for about half an hour; ridiculously addictive...

lol !...I remember how incredible and mind blowing bat n ball was. How refreshing that it's still so addictive. awwwww.. glad ewe had such fun Chris.
 

Offline syhprum

  • Neilep Level Member
  • ******
  • Posts: 3823
  • Thanked: 19 times
    • View Profile
Re: Why Does Rebooting A Device Often Solve Issues ?
« Reply #5 on: 30/07/2015 19:55:01 »
I think we are putting too much blame on programmers surely many crashes are due to transient hardware glitches otherwise things would not run after the reboot if you attempted the same operation again.
 

Offline chris

  • Neilep Level Member
  • ******
  • Posts: 5339
  • Thanked: 65 times
  • The Naked Scientist
    • View Profile
    • The Naked Scientists
Re: Why Does Rebooting A Device Often Solve Issues ?
« Reply #6 on: 30/07/2015 20:31:23 »
Not necessarily; a bit of bad programming might, for example, cause a memory leak where a process fails to release agin some memory that was used transiently for an operation. Until the computer runs out of free memory, the program runs fine. A reboot resets the memory registrations and so everything is junky dory again, until you run out of memory again...
 

Offline David Cooper

  • Neilep Level Member
  • ******
  • Posts: 1505
    • View Profile
Re: Why Does Rebooting A Device Often Solve Issues ?
« Reply #7 on: 30/07/2015 20:56:07 »
Hardware errors can happen (sometimes caused by radiation), but this is rare - some operating systems and their apps can run for weeks, months or even years without going wrong, but if you boot the same machine with a commercial operating system you might have to reboot every few days because it gets tied up in knots.

If a bug always prevents some operation from functioning, the programmer will notice and debug it until it works, but if it only fails occasionally, the programmer may be unable to work out why it sometimes fails and is likely to give up and just say "it'll do". Often a routine will run many times without failing but will gradually change variables until it reaches a point where the value of one of these variables causes the routine to malfunction, so a reboot will restore it to initial conditions and fix things (for a while). I find that Windows XP slows my machine down the longer it runs, and if I don't reboot soon enough, it starts thrashing the hard drive and I have to power it off to reboot (which can damage data on the hard drive). It shouldn't get it's knickers in such a twist, but it does, and I assume it's because it isn't cleaning things up properly as memory is freed and reallocated, so it runs out of working space.
 

Offline evan_au

  • Neilep Level Member
  • ******
  • Posts: 4130
  • Thanked: 249 times
    • View Profile
Re: Why Does Rebooting A Device Often Solve Issues ?
« Reply #8 on: 30/07/2015 22:35:25 »
Writing software is very complex - I heard an estimate that even experienced programmers produce about 1 error in every 10 lines. In millions of lines of code, that is a huge number of bugs to find and correct. And the worst part is that you can stare at software you wrote, and simply not see the error. That's why cooperative teams are needed for large software projects*.

There is software that can check software for risky programming practices - an early one for the "C" programming language was called "lint", which helped clean up your software.

There are more sophisticated tools available now, which attempt to analyse every path through the software, but as Alan Turning showed, it is effectively impossible to analyse an arbitrary piece of software.

There are other tools that check that every path in the code has been tested at least once - but in any piece of software, there are parts of the code that seem impossible to reach by using test data.

Some of the more recent programming languages have actually taken steps to prevent some classes of errors, by banning access to arbitrary regions of memory (the infamous "C" pointer), by declaring how to interpret certain regions of memory, and by limiting the user to certain software structures that simplify analysis of the software.

Some systems are able to add extra code that checks for out-of-range variables or accessing memory past the end of a data structure, but this slows down execution time, so programmers often turn these off in the delivered system.

You can also access public libraries of pre-written software. Software available under Open-Source agreements has had many people look it over, and use it in many different ways, so it is better tested than software you write yourself.

Everyone should take advantage of the simple tools that detect things like uninitialized variables. The advanced tools take a lot of effort, and are usually only justified for life-critical applications.

Even so, a frequent security hole in computer systems is still one of the oldest in the book - array overflow. Software reads in some string of characters from the internet which is longer than the space used to store it. A clever hacker can insert characters in here which make software do things it was never intended to do...

*How Bill Gates managed to write a BASIC interpreter in machine language in a couple of days astonishes me. I guess that is why he has billions of dollars, and I don't.
 

Offline David Cooper

  • Neilep Level Member
  • ******
  • Posts: 1505
    • View Profile
Re: Why Does Rebooting A Device Often Solve Issues ?
« Reply #9 on: 31/07/2015 19:27:07 »
*How Bill Gates managed to write a BASIC interpreter in machine language in a couple of days astonishes me. I guess that is why he has billions of dollars, and I don't.

I don't know how much of it he wrote in a couple of days, but he appears to have shared out the work with Paul Allen and Monte Davidoff (who was hired to do "some" of the floating-point maths stuff). In reality, they had a few weeks to do the job, and while Paul Allen was working on adapting a simulator to run their code on (because they didn't have a machine with the same kind of processor on it as would be in the machine they were writing BASIC to run on), Gates was designing their version of BASIC on paper (which indicates that he did most of the actual work on producing the interpreter). BASIC already existed as a programming language, so they were not breaking new ground, but they did have to compress it into half the space that it would ordinarily have been available to it, and that takes good hackers. What really made Gates successful though was the luck of timing, being in the right place at the right time with the right skills and making the right calls. The key move was buying QDOS from Tim Patterson and doing IBM over with a deal that gave him the right to print money.
 

The Naked Scientists Forum

Re: Why Does Rebooting A Device Often Solve Issues ?
« Reply #9 on: 31/07/2015 19:27:07 »

 

SMF 2.0.10 | SMF © 2015, Simple Machines
SMFAds for Free Forums