https://rancher.com/ logo
Title
f

flaky-coat-75909

06/10/2022, 1:15 PM
can any one explain why in my postgresql pod
$ df -h
Filesystem                                              Size  Used Avail Use% Mounted on
/dev/longhorn/pvc-c6b78d1e-109a-4c44-af17-ae2ad46e28b6   20G  1.5G   19G   8% /bitnami/postgresql
is
Used
1.5G
$ du -sh /bitnami/postgresql
1.5G	/bitnami/postgresql
Where on the frontend-longhorn I see
/dev/longhorn/pvc-c6b78d1e-109a-4c44-af17-ae2ad46e28b6
Size: 20 Gi
Actual Size:10.7 Gi
Which means it is almost 10times more displaying on frontend And it is probably because I'm doing snapshots On my node in that directory and I see files
[root@server22 pvc-c6b78d1e-109a-4c44-af17-ae2ad46e28b6-3277a500]# pwd
/var/lib/longhorn/replicas/pvc-c6b78d1e-109a-4c44-af17-ae2ad46e28b6-3277a500
[root@server22 pvc-c6b78d1e-109a-4c44-af17-ae2ad46e28b6-3277a500]# du -sh * 
4.0K	revision.counter
189M	volume-head-010.img
4.0K	volume-head-010.img.meta
4.0K	volume.meta
531M	volume-snap-035b7630-78a9-4299-af2f-ff3cc8be0f06.img
4.0K	volume-snap-035b7630-78a9-4299-af2f-ff3cc8be0f06.img.meta
2.1G	volume-snap-c-bi3bca-c-0dddc3f6.img
4.0K	volume-snap-c-bi3bca-c-0dddc3f6.img.meta
2.5G	volume-snap-c-bi3bca-c-1908b8fa.img
4.0K	volume-snap-c-bi3bca-c-1908b8fa.img.meta
1.6G	volume-snap-c-bi3bca-c-4b2590fb.img
4.0K	volume-snap-c-bi3bca-c-4b2590fb.img.meta
1.9G	volume-snap-c-bi3bca-c-d08a8ddd.img
4.0K	volume-snap-c-bi3bca-c-d08a8ddd.img.meta
2.2G	volume-snap-c-bi3bca-c-e827be1c.img
4.0K	volume-snap-c-bi3bca-c-e827be1c.img.meta
but why snapshots are taking so much memory while the whole my data is only
1.5G
What I'm doing wrong ?
f

famous-shampoo-18483

06/13/2022, 12:25 PM
Same. You can check the example and the explanation in this doc first: https://longhorn.io/docs/1.2.4/volumes-and-nodes/volume-size/#example