hello my name's Gary Simmons from
Android or authority now if you've ever
had a misbehaving app on your smart
phone
maybe you've looked around the internet
you've read some forums and somewhere on
the lines I'm going to say to you you
should do a full stop and a clear cache
that will help your problem so the
question before today what is a four
stop what is a cache and wise are the
four stop and clear cache actually help
fix misbehaving out well let me explain
okay at the very heart of anguish is the
Linux kernel and inside of Linux all
programs that run running a thing called
a process and the protein is a logical
container that allows the kernel to know
about which programs are running which
memory is allocated to them what
priority they have how much CPU time
they need and basically in Android every
app you run actually runs inside of a
limits process now I won't go into much
more now about the nuts prototype on a
whole video on proteases and thread that
you can find here on the and realtor
cheat channel if you go to the front
page of the Android 40 channel you'll
see a playlist for all of Garry explains
videos and you can easily find it in
there now when you start an application
it starts a Linux process and it can
basically go through some different
states now at the Linux level it can go
through running runnable and sleeping so
when a process is for example actually
on the CPU is running when it's ready to
run on the CPU it's run a ball and we're
waiting for something to happen like
network traffic it's known as sleeping
now Android also has some different
states for the activities which make up
your app and those activities include
running and pause and stopped and
basically what happens is is that Linux
or Android can say to an app you are now
in the poor state or you're going to be
stopped which tells it's going to kill
it off or it's going to have to need to
stays on this data creates about to be
killed and what's interesting is when
Android wants to stop an app it doesn't
actually stop the app it just has to
Linux kill that process
which means that the process get
obliterated out of memory or the
memories freed up is not given any more
CPU time all the files they had opened
are closed any locks that it had open
are free and so on basically by Linux
kills off the process everything just
disappears which is a great way to
ensure that the app have actually just
completely gone and just like Android
can tell Linux to kill a process you can
tell Android to tell Linux to kill a
process and that's what force stop does
basically you say - and what I want this
process to stop and it will obliterate
it from memory and it will be definitely
gone now the reason why that helps
because if you have a misbehaving app
it's going to helping - a funny loop
it's got yourself into a funny condition
and it's not recovering and by doing a
fourth stop you're actually killing off
the protein then when you restart it it
may very well start back up into a
better state and start functioning and
it needs be another good thing about
full stop is that once the process has
been deleted then all the open files
have been closed which means we know the
files inside the cache directory are now
no longer being used so what's the cache
directory basically the cache directory
is a place where an app can store
temporary files for example if when the
app starts up it needs to download
something from the internet maybe data
feed maybe some images it could just
download those things every time it
starts up or every time you refresh the
display but of course that will take a
long time and it will also use up your
bandwidth much better to get it
periodically and then stall the files in
the cache and then from time to time the
app can say hey should I update these
files that are in my cache or are they
ok at the moment it would also be true
for example if it was doing some
processing maybe it downloads some data
from the internet but it needs to be
uncompressed or decoded or decrypted or
something then actually those files also
go in the cache and again from time to
time you can say do I need to go and get
a newer version the latest version but
when you do refresh the app when you do
restart the app it can get a lot of its
data directly from the cache rather than
having to go out onto the Internet to go
and get it or using its processing time
to actually decode or decrypt the files
but what happens sometimes is those
cache files get them cell
in a muzzle mainly a card in the program
or it hasn't refreshed them when it
should have done theirs newer ones
available means that hasn't brought them
down and what you do by clear cache you
delete all those files now that's
perfectly okay because Android apps are
written in such a way but it knows that
files are in the cache early temporary
and if they're not there it doesn't
panic it just goes to the internet again
and goes and gets an or it does the
processing again to decrypt or decode or
whatever it needs to do to those files
so it knows that there is a situation
when a cache fault might not be there so
therefore by keying in the cache what
you're actually doing is saying to the
out hey you've got nothing here let's
start again so by doing a full stop and
a clear cache your restarting the
program with some new with an empty
cache which means it has to start again
with new data and hopefully that will
fix the program my name is Gary Sims
from Andrew authority I hope you enjoyed
this video if you did please do give it
a thumbs up I'd like to mention that
there is a playlist of all the gary
explains videos on the front page of the
android authority youtube channel also
don't forget to subscribe to the android
or throw to youtube channel it's also
going to be download the app because
that will give you access to all our
news and features directly on your
mobile phone and last but not least do
go over to Android or chicom because we
are your source for all things Android
We are a participant in the Amazon Services LLC Associates Program, an affiliate advertising program designed to provide a means for us to earn fees by linking to Amazon.com and affiliated sites.