# Influx not saving data?

**URL:** <https://community.influxdata.com/t/influx-not-saving-data/34784>\
**Category:** InfluxDB 2\
**Tags:** influxdb\
**Created:** [July 1, 2024, 7:34am UTC](https://community.influxdata.com/t/influx-not-saving-data/34784 "2024-07-01T07:34:54Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kristoffer\_Milligan](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/kristoffer_milligan/32/15870_2.png) [@Kristoffer\_Milligan](https://community.influxdata.com/u/Kristoffer_Milligan)\
**Post date:** [July 1, 2024, 7:34am UTC](https://community.influxdata.com/t/influx-not-saving-data/34784/1 "2024-07-01T07:34:54Z")

</div>

Hi group,

I have a influxdb2 running in a docker container on GCP. The container has a google provisioned persistent volume mounted in the data folder so that my records persist any container restart/version bumps, etc.

The container has been running since december last year and I would have expected data to be coming in rather frequently since then. I took a look in one my primary bucket now, and I saw this:

```auto
influx query "from(bucket: \"my-bucket\") |> range(start: 0) |> filter(fn: (r) => r._field == \"pressure\")"

```

And to my dismay the oldest record I had was:

```auto
Table: keys: [_start, _stop, _field, _measurement, device_id, device_identifier, gateway_id_0, gateway_id_1, hardware_serial]
                   _start:time _stop:time _field:string _measurement:string device_id:string device_identifier:string gateway_id_0:string gateway_id_1:string hardware_serial:string _time:time _value:float
------------------------------ ------------------------------ ---------------------- ---------------------- ---------------------- ------------------------ ---------------------- ---------------------- ---------------------- ------------------------------ ----------------------------
1970-01-01T00:00:00.000000000Z 2024-07-01T07:09:08.917346310Z pressure OBFUSCATED 1 OBFUSCATED2 OBFUSCATED3 OBFUSCATED3 OBFUSCATED4 2024-06-26T22:52:13.163000000Z 1008

```

I further queryed the bucket configuration which looks like this:

```auto
ID Name Retention	Shard group duration	Organization ID Schema Type
hidden1 my-bucket	infinite	168h0m0s hidden2 implicit

```

I have no scripts or cron jobs running that should clear out data. The container is based on the image **influxdb:latest**

What else could I check ?

---

<div class="post-metadata">

**Author:** ![Ravikant\_Gautam](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/ravikant_gautam/32/5700_2.png) [@Ravikant\_Gautam](https://community.influxdata.com/u/Ravikant_Gautam)\
**Post date:** [July 1, 2024, 10:30am UTC](https://community.influxdata.com/t/influx-not-saving-data/34784/2 "2024-07-01T10:30:16Z")

</div>

> [@Kristoffer\_Milligan](#):
>
> `influx query "from(bucket: \"my-bucket\") |> range(start: 0) |> filter(fn: (r) => r._field == \"pressure\")"`

influx query “from(bucket: "my-bucket") |\> range(start: -30d) |\> filter(fn: (r) =\> r.\_field == "pressure")”  
could you run this query and check your data?

---

<div class="post-metadata">

**Author:** ![Kristoffer\_Milligan](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/kristoffer_milligan/32/15870_2.png) [@Kristoffer\_Milligan](https://community.influxdata.com/u/Kristoffer_Milligan)\
**Post date:** [July 1, 2024, 10:43am UTC](https://community.influxdata.com/t/influx-not-saving-data/34784/3 "2024-07-01T10:43:00Z")

</div>

Thank you for your reply,

Running that query yielded the same output as the original query I was using. The first record I get is the same one as pasted in the original post

---

<div class="post-metadata">

**Author:** ![Kristoffer\_Milligan](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/kristoffer_milligan/32/15870_2.png) [@Kristoffer\_Milligan](https://community.influxdata.com/u/Kristoffer_Milligan)\
**Post date:** [July 1, 2024, 12:19pm UTC](https://community.influxdata.com/t/influx-not-saving-data/34784/4 "2024-07-01T12:19:36Z")

</div>

I believe I have solved the problem. A classic PEBCAK.

I was mounting my persistent volume in /var/lib/influxdb instead of /var/lib/influxdb2. I have changed my kubernetes deployment descriptor now, modifying the mount path. Hopefully this was an easy fix to a silly mistake. I will leave this running for a few hours and verify this was in fact the cause of my headaches.

---

<div class="post-metadata">

**Author:** ![suyash](https://sea1.discourse-cdn.com/flex023/user_avatar/community.influxdata.com/suyash/32/15791_2.png) [@suyash](https://community.influxdata.com/u/suyash)\
**Post date:** [July 1, 2024, 3:25pm UTC](https://community.influxdata.com/t/influx-not-saving-data/34784/5 "2024-07-01T15:25:53Z")

</div>

nice that you were able to fix it!
