<s>
An	O
in-memory	B-General_Concept
database	I-General_Concept
(	O
IMDB	O
,	O
or	O
main	B-General_Concept
memory	I-General_Concept
database	I-General_Concept
system	I-General_Concept
(	O
MMDB	O
)	O
or	O
memory	O
resident	O
database	O
)	O
is	O
a	O
database	B-Application
management	I-Application
system	I-Application
that	O
primarily	O
relies	O
on	O
main	O
memory	O
for	O
computer	B-General_Concept
data	I-General_Concept
storage	I-General_Concept
.	O
</s>
<s>
It	O
is	O
contrasted	O
with	O
database	B-Application
management	I-Application
systems	I-Application
that	O
employ	O
a	O
disk	B-Device
storage	I-Device
mechanism	O
.	O
</s>
<s>
In-memory	B-General_Concept
databases	I-General_Concept
are	O
faster	O
than	O
disk-optimized	O
databases	B-Application
because	O
disk	B-Device
access	O
is	O
slower	O
than	O
memory	O
access	O
and	O
the	O
internal	O
optimization	O
algorithms	O
are	O
simpler	O
and	O
execute	O
fewer	O
CPU	O
instructions	O
.	O
</s>
<s>
Accessing	O
data	O
in	O
memory	O
eliminates	O
seek	O
time	O
when	O
querying	O
the	O
data	O
,	O
which	O
provides	O
faster	O
and	O
more	O
predictable	O
performance	O
than	O
disk	B-Device
.	O
</s>
<s>
Applications	O
where	O
response	O
time	O
is	O
critical	O
,	O
such	O
as	O
those	O
running	O
telecommunications	O
network	O
equipment	O
and	O
mobile	O
advertising	O
networks	O
,	O
often	O
use	O
main-memory	O
databases	B-Application
.	O
</s>
<s>
IMDBs	O
have	O
gained	O
much	O
traction	O
,	O
especially	O
in	O
the	O
data	B-General_Concept
analytics	I-General_Concept
space	O
,	O
starting	O
in	O
the	O
mid-2000s	O
–	O
mainly	O
due	O
to	O
multi-core	O
processors	O
that	O
can	O
address	O
large	O
memory	O
and	O
due	O
to	O
less	O
expensive	O
RAM	B-Architecture
.	O
</s>
<s>
A	O
potential	O
technical	O
hurdle	O
with	O
in-memory	B-General_Concept
data	O
storage	O
is	O
the	O
volatility	O
of	O
RAM	B-Architecture
.	O
</s>
<s>
Specifically	O
in	O
the	O
event	O
of	O
a	O
power	O
loss	O
,	O
intentional	O
or	O
otherwise	O
,	O
data	O
stored	O
in	O
volatile	B-General_Concept
RAM	I-General_Concept
is	O
lost	O
.	O
</s>
<s>
With	O
the	O
introduction	O
of	O
non-volatile	B-General_Concept
random-access	I-General_Concept
memory	I-General_Concept
technology	O
,	O
in-memory	B-General_Concept
databases	I-General_Concept
will	O
be	O
able	O
to	O
run	O
at	O
full	O
speed	O
and	O
maintain	O
data	O
in	O
the	O
event	O
of	O
power	O
failure	O
.	O
</s>
<s>
In	O
its	O
simplest	O
form	O
,	O
main	B-General_Concept
memory	I-General_Concept
databases	I-General_Concept
store	O
data	O
on	O
volatile	B-General_Concept
memory	I-General_Concept
devices	O
.	O
</s>
<s>
Snapshot	B-Application
files	O
,	O
or	O
,	O
checkpoint	O
images	O
,	O
which	O
record	O
the	O
state	O
of	O
the	O
database	O
at	O
a	O
given	O
moment	O
in	O
time	O
.	O
</s>
<s>
While	O
they	O
give	O
a	O
measure	O
of	O
persistence	B-Application
to	O
the	O
data	O
(	O
in	O
that	O
the	O
database	O
does	O
not	O
lose	O
everything	O
in	O
the	O
case	O
of	O
a	O
system	O
crash	O
)	O
they	O
only	O
offer	O
partial	O
durability	O
(	O
as	O
'	O
recent	O
"	O
changes	O
will	O
be	O
lost	O
)	O
.	O
</s>
<s>
Transaction	B-General_Concept
logging	I-General_Concept
,	O
which	O
records	O
changes	O
to	O
the	O
database	O
in	O
a	O
journal	O
file	O
and	O
facilitates	O
automatic	O
recovery	O
of	O
an	O
in-memory	B-General_Concept
database	I-General_Concept
.	O
</s>
<s>
Non-Volatile	O
DIMM	O
(	O
NVDIMM	B-Device
)	O
,	O
a	O
memory	O
module	O
that	O
has	O
a	O
DRAM	O
interface	O
,	O
often	O
combined	O
with	O
NAND	O
flash	O
for	O
the	O
Non-Volatile	O
data	O
security	O
.	O
</s>
<s>
The	O
first	O
NVDIMM	B-Device
solutions	O
were	O
designed	O
with	O
supercapacitors	O
instead	O
of	O
batteries	O
for	O
the	O
backup	O
power	O
source	O
.	O
</s>
<s>
Non-volatile	B-General_Concept
random-access	I-General_Concept
memory	I-General_Concept
(	O
NVRAM	B-General_Concept
)	O
,	O
usually	O
in	O
the	O
form	O
of	O
static	O
RAM	B-Architecture
backed	O
up	O
with	O
battery	O
power	O
(	O
battery	O
RAM	B-Architecture
)	O
,	O
or	O
an	O
electrically	B-General_Concept
erasable	I-General_Concept
programmable	I-General_Concept
ROM	I-General_Concept
(	O
EEPROM	B-General_Concept
)	O
.	O
</s>
<s>
High	O
availability	O
implementations	O
that	O
rely	O
on	O
database	O
replication	B-Architecture
,	O
with	O
automatic	O
failover	B-General_Concept
to	O
an	O
identical	O
standby	O
database	O
in	O
the	O
event	O
of	O
primary	O
database	O
failure	O
.	O
</s>
<s>
To	O
protect	O
against	O
loss	O
of	O
data	O
in	O
the	O
case	O
of	O
a	O
complete	O
system	O
crash	O
,	O
replication	B-Architecture
of	O
an	O
IMDB	O
is	O
normally	O
used	O
in	O
addition	O
to	O
one	O
or	O
more	O
of	O
the	O
mechanisms	O
listed	O
above	O
.	O
</s>
<s>
While	O
storing	O
data	O
in-memory	B-General_Concept
confers	O
performance	O
advantages	O
,	O
it	O
is	O
an	O
expensive	O
method	O
of	O
data	O
storage	O
.	O
</s>
<s>
An	O
approach	O
to	O
realising	O
the	O
benefits	O
of	O
in-memory	B-General_Concept
storage	O
while	O
limiting	O
its	O
costs	O
is	O
to	O
store	O
the	O
most	O
frequently	O
accessed	O
data	O
in-memory	B-General_Concept
and	O
the	O
rest	O
on	O
disk	B-Device
.	O
</s>
<s>
Since	O
there	O
is	O
no	O
hard	O
distinction	O
between	O
which	O
data	O
should	O
be	O
stored	O
in-memory	B-General_Concept
and	O
which	O
should	O
be	O
stored	O
on	O
disk	B-Device
,	O
some	O
systems	O
dynamically	O
update	O
where	O
data	O
is	O
stored	O
based	O
on	O
the	O
data	O
's	O
usage	O
.	O
</s>
<s>
This	O
approach	O
is	O
subtly	O
different	O
from	O
caching	O
,	O
in	O
which	O
the	O
most	O
recently	O
accessed	O
data	O
is	O
cached	O
,	O
as	O
opposed	O
to	O
the	O
most	O
frequently	O
accessed	O
data	O
being	O
stored	O
in-memory	B-General_Concept
.	O
</s>
<s>
In	B-Architecture
the	I-Architecture
cloud	I-Architecture
computing	O
industry	O
the	O
terms	O
"	O
data	O
temperature	O
"	O
,	O
or	O
"	O
hot	O
data	O
"	O
and	O
"	O
cold	O
data	O
"	O
have	O
emerged	O
to	O
describe	O
how	O
data	O
is	O
stored	O
in	O
this	O
respect	O
.	O
</s>
<s>
Hot	O
data	O
should	O
be	O
stored	O
in	O
ways	O
offering	O
fast	O
retrieval	O
and	O
modification	O
,	O
often	O
accomplished	O
by	O
in-memory	B-General_Concept
storage	O
but	O
not	O
always	O
.	O
</s>
<s>
Manufacturing	O
efficiency	O
provides	O
another	O
reason	O
for	O
selecting	O
a	O
combined	O
in-memory/on	O
-disk	O
database	B-Application
system	I-Application
.	O
</s>
<s>
If	O
such	O
devices	O
require	O
a	O
database	B-Application
system	I-Application
,	O
a	O
manufacturer	O
can	O
adopt	O
a	O
hybrid	O
database	B-Application
system	I-Application
at	O
lower	O
and	O
upper	O
cost	O
,	O
and	O
with	O
less	O
customization	O
of	O
code	O
,	O
rather	O
than	O
using	O
separate	O
in-memory	B-General_Concept
and	O
on-disk	O
databases	B-Application
,	O
respectively	O
,	O
for	O
its	O
disk-less	O
and	O
disk-based	O
products	O
.	O
</s>
<s>
The	O
first	O
database	B-General_Concept
engine	I-General_Concept
to	O
support	O
both	O
in-memory	B-General_Concept
and	O
on-disk	O
tables	O
in	O
a	O
single	O
database	O
,	O
WebDNA	B-Language
,	O
was	O
released	O
in	O
1995	O
.	O
</s>
<s>
Another	O
variation	O
involves	O
large	O
amounts	O
of	O
nonvolatile	O
memory	O
in	O
the	O
server	O
,	O
for	O
example	O
,	O
flash	O
memory	O
chips	O
as	O
addressable	O
memory	O
rather	O
than	O
structured	O
as	O
disk	B-Device
arrays	O
.	O
</s>
<s>
A	O
database	O
in	O
this	O
form	O
of	O
memory	O
combines	O
very	O
fast	O
access	O
speed	O
with	O
persistence	B-Application
over	O
reboots	O
and	O
power	O
losses	O
.	O
</s>
