What is the problem you are having with rclone?
rclone constantly increasing memory consumption over time when uploading millions files to the Azure blob storage.
Statistics about uploaded data: folders~36715; num files=10215623; size=4.47 TB
Run the command 'rclone version' and share the full output of the command.
rclone v1.60.0
- os/version: centos 8 (64 bit)
- os/kernel: 4.18.0-301.1.el8.x86_64 (x86_64)
- os/type: linux
- os/arch: amd64
- go/version: go1.19.2
- go/linking: static
- go/tags: none
Which cloud storage system are you using? (eg Google Drive)
Cloud storage - Azure blob
The command you were trying to run (eg rclone copy /tmp remote:tmp
)
Folder is mounted using fstab fuse
rclonefs#azure2:vna /mnt/azure fuse _netdev,config=/root/.config/rclone/rclone.conf,rc,allow-other,default-permissions,rw,max-read-ahead=4M,vfs-cache-mode=writes,vfs-cache-max-size=2G,azureblob-memory-pool-flush-time=10m0s,buffer-size=0,azureblob-memory-pool-use-mmap,use-mmap,dir-cache-time=2h,timeout=1h,cache-dir=/var/dcmsys/cache,uid=dcmsys,gid=dcmsys,cache-chunk-no-memory,size-only,allow-non-empty 0 0
The rclone config contents with secrets removed.
[azure2]
type = azureblob
account = vnatest3
key = secretkey==
Result of memory checking after 2 weeks of uploading:
Saved profile in /root/pprof/pprof.rclone.alloc_objects.alloc_space.inuse_objects.inuse_space.006.pb.gz
File: rclone
Type: inuse_space
Time: Dec 2, 2022 at 10:10am (PST)
Showing nodes accounting for 15060.62MB, 99.01% of 15211.03MB total
Dropped 122 nodes (cum <= 76.06MB)
flat flat% sum% cum cum%
3279.79MB 21.56% 21.56% 3441.29MB 22.62% github.com/Azure/azure-storage-blob-go/azblob.BlobGetPropertiesResponse.NewMetadata
2476.10MB 16.28% 37.84% 2476.10MB 16.28% github.com/rclone/rclone/vfs/vfscache.newItem
1916.35MB 12.60% 50.44% 1916.35MB 12.60% github.com/rclone/rclone/vfs.newFile
1297.24MB 8.53% 58.97% 1297.24MB 8.53% github.com/rclone/rclone/vfs.(*Dir).addObject
1250.65MB 8.22% 67.19% 1250.65MB 8.22% path.Join
1132.62MB 7.45% 74.64% 4815.47MB 31.66% github.com/rclone/rclone/backend/azureblob.(*Fs).Put
848.55MB 5.58% 80.21% 861.65MB 5.66% bazil.org/fuse.(*Conn).ReadRequest
842.03MB 5.54% 85.75% 842.03MB 5.54% net/textproto.(*Reader).ReadMIMEHeader
636.54MB 4.18% 89.93% 2292.81MB 15.07% github.com/rclone/rclone/vfs.newRWFileHandle
360.58MB 2.37% 92.30% 379.08MB 2.49% github.com/Azure/azure-storage-blob-go/azblob.(*Metadata).UnmarshalXML
262.51MB 1.73% 94.03% 262.51MB 1.73% encoding/base64.(*Encoding).EncodeToString
180MB 1.18% 95.21% 180MB 1.18% strings.(*Builder).grow (inline)
152MB 1% 96.21% 152MB 1% github.com/rclone/rclone/vfs.(*File).addWriter
151MB 0.99% 97.21% 7914.50MB 52.03% github.com/rclone/rclone/cmd/mount.(*Dir).Create
131.01MB 0.86% 98.07% 131.01MB 0.86% encoding/xml.copyValue
101.01MB 0.66% 98.73% 124.01MB 0.82% github.com/rclone/rclone/backend/azureblob.(*Fs).newObjectWithInfo
39.63MB 0.26% 98.99% 2515.73MB 16.54% github.com/rclone/rclone/vfs/vfscache.(*Cache)._get
3MB 0.02% 99.01% 527.09MB 3.47% encoding/xml.(*Decoder).unmarshal
0 0% 99.01% 861.65MB 5.66% bazil.org/fuse/fs.(*Server).Serve
0 0% 99.01% 8141.77MB 53.53% bazil.org/fuse/fs.(*Server).Serve.func1
0 0% 99.01% 8141.77MB 53.53% bazil.org/fuse/fs.(*Server).handleRequest
0 0% 99.01% 8141.77MB 53.53% bazil.org/fuse/fs.(*Server).serve
0 0% 99.01% 527.09MB 3.47% encoding/xml.(*Decoder).Decode (inline)
0 0% 99.01% 527.09MB 3.47% encoding/xml.(*Decoder).DecodeElement
0 0% 99.01% 413.58MB 2.72% encoding/xml.(*Decoder).unmarshalInterface
0 0% 99.01% 527.09MB 3.47% encoding/xml.(*Decoder).unmarshalPath
0 0% 99.01% 527.09MB 3.47% encoding/xml.Unmarshal
0 0% 99.01% 545.14MB 3.58% github.com/Azure/azure-pipeline-go/pipeline.(*pipeline).Do
0 0% 99.01% 545.14MB 3.58% github.com/Azure/azure-pipeline-go/pipeline.PolicyFunc.Do
0 0% 99.01% 535.59MB 3.52% github.com/Azure/azure-storage-blob-go/azblob.(*SharedKeyCredential).New.func1
0 0% 99.01% 526.59MB 3.46% github.com/Azure/azure-storage-blob-go/azblob.ContainerURL.ListBlobsHierarchySegment
0 0% 99.01% 545.14MB 3.58% github.com/Azure/azure-storage-blob-go/azblob.NewRetryPolicyFactory.func1.1
0 0% 99.01% 545.14MB 3.58% github.com/Azure/azure-storage-blob-go/azblob.NewTelemetryPolicyFactory.func1.1
0 0% 99.01% 545.14MB 3.58% github.com/Azure/azure-storage-blob-go/azblob.NewUniqueRequestIDPolicyFactory.func1.1
0 0% 99.01% 526.59MB 3.46% github.com/Azure/azure-storage-blob-go/azblob.containerClient.ListBlobHierarchySegment
0 0% 99.01% 527.09MB 3.47% github.com/Azure/azure-storage-blob-go/azblob.containerClient.listBlobHierarchySegmentResponder
0 0% 99.01% 535.59MB 3.52% github.com/Azure/azure-storage-blob-go/azblob.responderPolicy.Do
0 0% 99.01% 251.03MB 1.65% github.com/rclone/rclone/backend/azureblob.(*Fs).List
0 0% 99.01% 124.01MB 0.82% github.com/rclone/rclone/backend/azureblob.(*Fs).itemToDirEntry
0 0% 99.01% 611.60MB 4.02% github.com/rclone/rclone/backend/azureblob.(*Fs).list
0 0% 99.01% 526.59MB 3.46% github.com/rclone/rclone/backend/azureblob.(*Fs).list.func1
0 0% 99.01% 293.03MB 1.93% github.com/rclone/rclone/backend/azureblob.(*Fs).listDir
0 0% 99.01% 124.01MB 0.82% github.com/rclone/rclone/backend/azureblob.(*Fs).listDir.func1
0 0% 99.01% 3683.85MB 24.22% github.com/rclone/rclone/backend/azureblob.(*Object).Update
0 0% 99.01% 3680.80MB 24.20% github.com/rclone/rclone/backend/azureblob.(*Object).decodeMetaDataFromPropertiesResponse
0 0% 99.01% 3682.30MB 24.21% github.com/rclone/rclone/backend/azureblob.(*Object).readMetaData
0 0% 99.01% 124.01MB 0.82% github.com/rclone/rclone/cmd/mount.(*Dir).ReadDirAll
0 0% 99.01% 861.65MB 5.66% github.com/rclone/rclone/cmd/mount.mount.func2
0 0% 99.01% 512.14MB 3.37% github.com/rclone/rclone/fs.pacerInvoker
0 0% 99.01% 137.51MB 0.9% github.com/rclone/rclone/fs/list.DirSorted
0 0% 99.01% 4815.47MB 31.66% github.com/rclone/rclone/fs/operations.Copy
0 0% 99.01% 489.09MB 3.22% github.com/rclone/rclone/lib/pacer.(*Pacer).Call
0 0% 99.01% 509.14MB 3.35% github.com/rclone/rclone/lib/pacer.(*Pacer).call
0 0% 99.01% 1916.35MB 12.60% github.com/rclone/rclone/vfs.(*Dir).Create
0 0% 99.01% 124.01MB 0.82% github.com/rclone/rclone/vfs.(*Dir).ReadDirAll
0 0% 99.01% 131.01MB 0.86% github.com/rclone/rclone/vfs.(*Dir)._readDir
0 0% 99.01% 5847.15MB 38.44% github.com/rclone/rclone/vfs.(*File).Open
0 0% 99.01% 1248.15MB 8.21% github.com/rclone/rclone/vfs.(*File).Path
0 0% 99.01% 2292.81MB 15.07% github.com/rclone/rclone/vfs.(*File).openRW
0 0% 99.01% 1294.72MB 8.51% github.com/rclone/rclone/vfs.(*RWFileHandle).Truncate
0 0% 99.01% 1294.72MB 8.51% github.com/rclone/rclone/vfs.(*RWFileHandle).openPending
0 0% 99.01% 2370.20MB 15.58% github.com/rclone/rclone/vfs/vfscache.(*Cache).Exists
0 0% 99.01% 145.54MB 0.96% github.com/rclone/rclone/vfs/vfscache.(*Cache).Item (inline)
0 0% 99.01% 2515.73MB 16.54% github.com/rclone/rclone/vfs/vfscache.(*Cache).get
0 0% 99.01% 4815.97MB 31.66% github.com/rclone/rclone/vfs/vfscache.(*Item).Close.func2
0 0% 99.01% 4815.97MB 31.66% github.com/rclone/rclone/vfs/vfscache.(*Item)._store
0 0% 99.01% 4815.97MB 31.66% github.com/rclone/rclone/vfs/vfscache.(*Item).store
0 0% 99.01% 4815.97MB 31.66% github.com/rclone/rclone/vfs/vfscache/writeback.(*WriteBack).upload
0 0% 99.01% 842.03MB 5.54% net/http.(*persistConn).readLoop
0 0% 99.01% 842.03MB 5.54% net/http.(*persistConn).readResponse
0 0% 99.01% 842.03MB 5.54% net/http.ReadResponse
0 0% 99.01% 180MB 1.18% strings.(*Builder).Grow (inline)
0 0% 99.01% 180MB 1.18% strings.ToLower
Binary file is here: Data package from December 2nd. - FileTransfer.io
Rclone consumed ~19Gb RAM at this point
For comparison, on GCP the same workload but rclone ate ~2GB RAM.