tencent cloud

Cloud File Storage

Releases Notes and Announcements
Release Notes
Announcements
Product Introduction
Overview
Strengths
Storage Classes and Performance
Use Cases
Recommended Regions
Use Limits
Service Regions and Service Providers
Purchase Guide
Billing Overview
Pricing Overview
General Series Billing
Turbo Series Billing
High-Throughput CFS Billing
Billing Mode
IA ‍Storage Billing
Storage Resource Units
Resource Purchase
Viewing Bills
Arrears Reminder
Getting Started
Creating File Systems and Mount Targets
Using CFS File Systems on Linux Clients
Using CFS File Systems on Windows Clients
Using CFS Turbo on Linux Clients
Using the CFS Client Assistant to Mount File Systems
Operation Guide
Access Management
Managing File Systems
Permission Management
Using Tags
Snapshot Management
Guide for Cross-AZ and Cross-Network Access
Automatically Mounting File Systems
Data Migration Service
User Permission Management
User Quotas
Data Encryption
Data Lifecycle Management
Upgrading Standard File Systems
Practical Tutorial
Selecting Kernels for NFS Clients
Managing Turbo CFS Directories
Terminating Compute Instances
Using CFS on TKE
Using CFS on SCF
Using CFS Turbo on TKE
Using CFS Turbo on TKE Serverless Cluster
Selecting a Network for Turbo CFS
Copying Data
CFS Storage Performance Testing
API Documentation
History
Introduction
API Category
Snapshot APIs
File system APIs
Lifecycle APIs
Other APIs
Data Flow APIs
Making API Requests
Permission Group APIs
Service APIs
Scaling APIs
Data Migration APIs
Data Types
Error Codes
Troubleshooting
Client Use Bottleneck due to Large Number of Small Files or Parallel Requests
FAQs
CFS Service Level Agreement
Contact Us
Glossary
문서Cloud File StoragePractical TutorialManaging Turbo CFS Directories

Managing Turbo CFS Directories

PDF
포커스 모드
폰트 크기
마지막 업데이트 시간: 2024-01-22 22:15:48

Overview

This practice aims to achieve higher performance and lower latency of a Turbo file system by better allocating directories and files.

Background

When clients access a file system, operations are performed based on the virtual file system (VFS) layer. The VFS layer serially grants and ‍recalls locks when processing multiple processes reading and writing the same file. If a client's I/O is under an extremely large directory at a certain level, the serial lock operations of VFS may cause increased I/O latency.
As a strongly consistent file system, a Turbo file system maintains consistency for any client to read and write at any time. However, this also means that all clients' I/O operations will involve the granting or recall of backend distributed locks. The Turbo backend can handle lock requests concurrently based on distributed metadata services. However, to ensure good performance in terms of latency, we recommend you manage the number of directories and files according to the suggestions in this document.

Suggestions

If your business mainly involves reading with no frequent delete/update/create operations, we recommend that a single directory contain 10 to1 million subdirectories and files.
If your business involves frequent delete/update/create operations, we recommend that a single directory contain 10 to 10,000 subdirectories and files.

Common directory structures

Sort by hash code: A 64-character hash code is used, where the first two characters form a first-level subdirectory, the next two characters form a second-level subdirectory, and files are stored under the second-level subdirectory. When the statistics feature of hash functions works properly, files can be evenly distributed in these 65,536 directories. When the file system has 600 million files, each directory has an average of 10,000 files. When the file system has 1.2 billion files, each directory has an average of 20,000 files.
Sort by time: The year, month, and day form the first-level subdirectory, the hour forms the second-level subdirectory, and the minute forms the third-level subdirectory (which can be omitted).


도움말 및 지원

문제 해결에 도움이 되었나요?

피드백