Disk space usage of old Files API nodes
- Dominant language
- Go
- Stars
- 17.1k
- Forks
- 3.2k
- Avg merge
- 3d 18h
- Merged PRs (30d)
- 11
Description
#### Version information: Official 0.4.3 64 bit Linux binary
#### Type: Files API
#### Priority: P3
#### Description:
I've been adding a large amount of small files, using the files API, and on a cronjob using "ipfs name publish $(ipfs files stat / | head -n 1)" to publish to IPNS.
The disk is now full. The disk IPFS is using is 250GB of Digital Ocean Block storage:
`root@ipfs:~# df -h | grep ipfs`
`Filesystem Size Used Avail Use% Mounted on`
`/dev/sda 246G 246G 0 100% /root/.ipfs`
I tried to run "ipfs files stat /", but it failed due to no disk space being available (is this a bug?), so I instead did this to get the root object's stats:
`root@ipfs:~# ipfs resolve /ipns/QmekbrSJGBAJy6Yzbj5e2pJh61nxWsTwpx88FraUVHwq8x
/ipfs/QmTgJ1ZWcGDhyyAnvMn3ggrQntrR6eVrhMmuVxjcT7Ct3D`
`root@ipfs:~# ipfs object stat /ipfs/QmTgJ1ZWcGDhyyAnvMn3ggrQntrR6eVrhMmuVxjcT7Ct3D`
`NumLinks: 1`
`BlockSize: 55`
`LinksSize: 53`
`DataSize: 2`
`CumulativeSize: 124228002182`
The useful data is ~124GB, so almost twice the amount of storage is being used as there is added data. Is this because of old root objects hanging around?
Over 99% of disk usage is in .ipfs/blocks
Contributor guide
Assessment
This issue has not been assessed yet.