# Data Loss MySQL Ignition History

**URL:** <https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402>\
**Category:** Ignition\
**Tags:** ignition80\
**Created:** [August 5, 2020, 2:09pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402 "2020-08-05T14:09:00Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![albetro.15](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/albetro.15/32/3922_2.png) [@albetro.15](https://forum.inductiveautomation.com/u/albetro.15)\
**Post date:** [August 5, 2020, 2:09pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/1 "2020-08-05T14:09:00Z")

</div>

Hi,

Today I discovered that when I try to access the data from some tags in July the data is missing. The configuration has been kept the same all along but all the sabed data using ignition native history mode is missing. I can access the data from August but everything since the 16 July is missing. I’m guessing there is a corruption in the database given that in MySQL there is a database named ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/c/d/cd7d0858c7c8ee6442614be259853ee755454a65.png) just where the problem starts.

How can i see which data /lines are causing the problem ?

I think the problem started when i clicked retry on a Quarantined file in Store and Forward, but i’m not sure and I don’ have the quarantined file.

---

<div class="post-metadata">

**Author:** ![accyroy](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/accyroy/32/3386_2.png) [@accyroy](https://forum.inductiveautomation.com/u/accyroy)\
**Post date:** [August 5, 2020, 2:23pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/2 "2020-08-05T14:23:51Z")

</div>

Go to Config - Tags - History and click on your tag history data provider and check what the settings are for Data Pruning, it may have been purged by this.

 ![Screenshot 2020-08-05 at 15.22.06](https://us1.discourse-cdn.com/inductiveautomation/original/3X/2/9/2938d21a7f0b2100ed8d07c376130a69d806ddab.png)

---

<div class="post-metadata">

**Author:** ![albetro.15](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/albetro.15/32/3922_2.png) [@albetro.15](https://forum.inductiveautomation.com/u/albetro.15)\
**Post date:** [August 5, 2020, 2:25pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/3 "2020-08-05T14:25:37Z")

</div>

It double checked that. Data pruning is not activated and I have data from before the 16th July. It is really from july 16th tup unto August 1st that I can’t recover/see the data.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [August 5, 2020, 2:27pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/4 "2020-08-05T14:27:42Z")

</div>

Is there any chance your database is simply full and couldn’t store that data?

---

<div class="post-metadata">

**Author:** ![albetro.15](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/albetro.15/32/3922_2.png) [@albetro.15](https://forum.inductiveautomation.com/u/albetro.15)\
**Post date:** [August 5, 2020, 2:29pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/5 "2020-08-05T14:29:36Z")

</div>

Not really. I could see the data just before. It was really after that retry in Store And Forward that now I cant’ see it. It seems really weird to me.

---

<div class="post-metadata">

**Author:** ![albetro.15](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/albetro.15/32/3922_2.png) [@albetro.15](https://forum.inductiveautomation.com/u/albetro.15)\
**Post date:** [August 5, 2020, 2:31pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/6 "2020-08-05T14:31:08Z")

</div>

I changed recently from month to weekd in the ways to store data. I don’t know if that store and forward changed the structure somewhere and it tinks it is by week instead of mont (or viseversa ?)

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [August 5, 2020, 2:31pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/7 "2020-08-05T14:31:53Z")

</div>

You probably want to look at both your gateway logs and your DB logs to see what is being rejected.

---

<div class="post-metadata">

**Author:** ![albetro.15](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/albetro.15/32/3922_2.png) [@albetro.15](https://forum.inductiveautomation.com/u/albetro.15)\
**Post date:** [August 5, 2020, 2:33pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/8 "2020-08-05T14:33:58Z")

</div>

Ignition returns zero as values. I think it doesnt reject anything it justs returns zero given that it doesnt find the history of the data, although I’m confident it is in the database somewhere. I checked the logs but no error message is shown anywhere

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [August 5, 2020, 2:39pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/9 "2020-08-05T14:39:53Z")

</div>

You might want to have support look over your shoulder.

---

<div class="post-metadata">

**Author:** ![albetro.15](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/albetro.15/32/3922_2.png) [@albetro.15](https://forum.inductiveautomation.com/u/albetro.15)\
**Post date:** [August 5, 2020, 2:42pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/10 "2020-08-05T14:42:55Z")

</div>

Thanks. I’m guessing the next line is the one causing the issue, but I’m not sure.

SELECT @@datadir datadir,sd.path FROM information\_schema.INNODB\_TABLES st JOIN information\_schema.innodb\_datafiles sd USING(space) WHERE st.name = ‘cnc/sqlt\_data\_1\_20200716’;

---

<div class="post-metadata">

**Author:** ![albetro.15](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/albetro.15/32/3922_2.png) [@albetro.15](https://forum.inductiveautomation.com/u/albetro.15)\
**Post date:** [August 5, 2020, 3:50pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/11 "2020-08-05T15:50:10Z")

</div>

Nevermind. Thought i had some more new information but that is not the case. All the information from july is missing, so I think somewhere the change from month to week changed an ID or a key and now it is unable to see the table. Just grasping at straws here.

I however, have no idea how I can solve it…

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [August 5, 2020, 3:52pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/12 "2020-08-05T15:52:46Z")

</div>

> [@albetro.15](#):
>
> have no idea how I can solve it…

Didn't wait for support to look over your shoulder, huh? You really should have IA help you unscramble this.

---

<div class="post-metadata">

**Author:** ![albetro.15](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/albetro.15/32/3922_2.png) [@albetro.15](https://forum.inductiveautomation.com/u/albetro.15)\
**Post date:** [August 5, 2020, 4:17pm UTC](https://forum.inductiveautomation.com/t/data-loss-mysql-ignition-history/37402/13 "2020-08-05T16:17:49Z")

</div>

I wanted to make sure the system is stable and we continue to function as before. I’m defnitely not going to modfiy anything but jus tryng to learn more about the situation ^^’
