0% found this document useful (0 votes)
121 views39 pages

Azure File Sync

Uploaded by

rohalvarez
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
121 views39 pages

Azure File Sync

Uploaded by

rohalvarez
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 39

Azure File Sync

and Azure Files


Cristóbal Zúñiga
Azure Files
What are Azure file shares?

Users SMB
REST
NFS Virtual Machines
Applications Port 443 SMB 2.1, 3.0
Azure File Sync NFS 4.1
REST

NFS 4.1
VPN
NFS Client

SMB 3.0
VPN
Azure file share
Clients \\<account>.file.core.windows.net\<share>
SMB 3.0
Port 445
On-premises Azure
Clients
Azure File Sync
Hybrid Azure file shares
Azure Backup

Multi-site Sync
Azure
File Share
Cloud Tiering

Cloud Backup

Disaster Recovery Rapid DR Cloud Tiering


SMB UsersFile 1 File 1
NFS File 2 File 2
Applications
File 3 File 3
Branch
HQ File Server
File Server
Azure file shares
Things to know

100 TiB share capacity

20k IOPS for standard shares

Premium file shares: up to 100k IOPS

AAD Domain Services / Active Directory integration


Azure File Sync: What a User Sees

Azure Files/Azure File Sync lets you migrate files to Azure - preserving
Shares
Share Permissions
File System ACLs

…all while (if you want) reducing storage requirements / cost

The #1 use case: doing what One Drive can’t easily do


in an O365 migration – departmental shares!

“Azure File Sync is One Drive for Servers!”


– Engineering Manager, Government Customer John Knows
Setting Up Azure Files / File Sync is Simple!
Great starter workload for Azure
No need for complex networking or security (typically)

Requires:
V2 Storage account with a “share”
Storage Sync Service (“File Sync”)
Windows Server VM
Windows Server 2012 R2 or newer
NTFS formatted Data volume

Can scheduled snapshots with Azure Backup


Daily / Weekly / Monthly / Yearly – up to 200 total snapshots
Rapid Cyber Attack Recovery using Azure Files / File Sync
Azure Files: Setup Storage Account

Name must be
unique in your Azure
Cloud (DNS)

V2 Storage Account
supports Azure File
Shares

Use LRS for


“large share support”
(up to 100 TB / share)
Types of Storage Accounts
Storage Account Supported Services Supported Supported Replication Options Deployment Encryption
Type Performance Tiers Access Tiers Model

General- Blob, File, Queue, Table, Standard, Premium Hot, Cool, Archive LRS, GRS, RA-GRS, ZRS, GZRS Resource Manager Encrypted
purpose V2 Disk, and Data Lake Gen2 RA-GZRS

General- Blob, File, Queue, Table, Standard, Premium N/A LRS, GRS, RA-GRS Resource Encrypted
purpose V1 and Disk Manager, Classic

BlockBlob Blob (block blobs and Premium N/A LRS, ZRS Resource Manager Encrypted
Storage append blobs only)

FileStorage File only Premium N/A LRS, ZRS Resource Manager Encrypted

BlobStorage Blob (block blobs and Standard Hot, Cool, Archive LRS, GRS, RA-GRS Resource Manager Encrypted
append blobs only)
Azure Files: Setup Storage Account

Public Endpoint is
easiest (DNS)

“Azure File Shares” can


be up to 100TB… and
you can sync multiple
shares to a server for
HUGE file systems
Azure Files: Setup Storage Account

Name

Max Size

Temperature
Azure File Sync: Setup Sync Service

There is no “Add” button!


Azure File Sync: Setup Sync Service

Name

Pick Storage Account

Now we just need a Windows Server connected!

Pick File Share


File Sync Agent Installation and Configuration

https://aka.ms/afs/agent - Windows Server version specific


File Sync Agent Installation and Configuration
File Sync Agent Installation and Configuration
Make Sure the service is running
File Sync Agent Installation and Configuration
Cloud tiering settings (adjusting)
Azure File Sync: What a User Sees (Cloud Tiering)
AFS with Server Endpoint multiple disks
1 Storage Sync Service (SSS)
- Sync Group (SG) 1 <--> Cloud Endpoint (CEP-x) <--> FS 1
- SEP 1 (serverA) d:\data1
- SEP 2 (serverB) f:\data2
- SEP n (serverN) x\mydata

- Sync Group (SG) 2 <--> Cloud Endpoint (CEP-y) <--> FS 2


- SEP 3 (serverA) d:\data3
- SEP 4 (serverB) f:\data100
- SEP M (serverN) x:\mydata100

serverA
d:\data1 --> SG 1 - CEP - SA\fs1
f:\data2 --> SG 2 - CEP - SA\fs2
(SA can be same or different)
Replicating from R volume
Replicating from S volume
Protect data with Snapshot Management from Azure Backup
Setting Up Azure Backup for Azure Files (Snapshots)
Assuming you’ve already created a recovery services vault…
Take Away: Azure File Sync
1. Reduces “Storage pressure”
on infrastructure
2. Simple setup on
modern Windows Servers
3. Tiers files to Azure – all appear local
(application compatibility!)
FAQ: If the same file is changed on two servers at approximately the same time, what happens?

• File conflicts are created when the file in the Azure file share doesn't match the file in the server endpoint location (size and/or last modified time is
different).
• The following scenarios can cause file conflicts:
• A file is created or modified in an endpoint (for example, Server A). If the same file is modified on a different endpoint before the change on Server A is
synced to that endpoint, a conflict file is created.
• The file existed in the Azure file share and server endpoint location prior to the server endpoint creation. If the file size and/or last modified time is
different between the file on the server and Azure file share when the server endpoint is created, a conflict file is created.
• Sync database was recreated due to corruption or knowledge limit reached. Once the database is recreated, sync enters a mode called reconciliation. If
the file size and/or last modified time is different between the file on the server and Azure file share when reconciliation occurs, a conflict file is
created.
• Azure File Sync uses a simple conflict-resolution strategy: we keep both changes to files that are changed in two endpoints at the same time. The most
recently written change keeps the original file name. The older file (determined by LastWriteTime) has the endpoint name and the conflict number
appended to the file name. For server endpoints, the endpoint name is the name of the server. For cloud endpoints, the endpoint name is Cloud. The
name follows this taxonomy:
• <FileNameWithoutExtension>-<endpointName>[-#].<ext>
• For example, the first conflict of CompanyReport.docx would become CompanyReport-CentralServer.docx if CentralServer is where the older write
occurred. The second conflict would be named CompanyReport-CentralServer-1.docx. Azure File Sync supports 100 conflict files per file. Once the
maximum number of conflict files is reached, the file will fail to sync until the number of conflict files is less than 100.
• Ref https://learn.microsoft.com/en-us/azure/storage/files/storage-files-faq
Azure File Sync scale targets

• Ref https://learn.microsoft.com/en-us/azure/storage/files/storage-files-scale-targets#azure-file-sync-scale-targets
Azure File Sync:
Bonus Material!
Cristóbal Zúñiga
Azure File Sync: Key Resources
• Azure Files Overview
https://azure.microsoft.com/en-us/services/storage/files/
• Common file sync scenarios and considerations
• Azure Files: Deploying
https://docs.microsoft.com/en-us/azure/storage/files/storage-files-deployment-
guide
• Azure File Sync: Deploying
https://docs.microsoft.com/en-us/azure/storage/files/storage-sync-files-
deployment-guide?tabs=portal

• Set Azure File Sync network Limits

• Immediate Sync

• Monitoring
* Not a quote

File Tiers
prices in USD, LRS, US West

Optimize cost and performance for your workload


Note: The premium tier is provisioned, and the standard tiers (transaction optimized, hot, and cool) are pay as you go

Tier GiB Price Transactions


Premium 16 cents $$$$ included 0

Transaction Write / List $ 0.015 per 10k


6 cents $$$ $
optimized Read/protocol $ 0.0015 per 10k

Write / List $ 0.065 per 10k


Hot 2.55 cents $$ Read/protocol $ 0.0065 per 10k $$
Metadata $ 0.0264 per GiB

Write $ 0.1 per 10k


List $ 0.065 per 10k
Read/protocol $ 0.013 per 10k
Cool 1.5 cents $ $$$
Metadata $ 0.0264 per GiB
Data retrieval $ 0.01 per GiB
Early deletion 1.5¢ 30-day prorated
Using DFS
with File Sync
• https://docs.microsoft.com/en-us/azure/storage/files/storage-sync-files-
planning#distributed-file-system-dfs
• Azure File Sync supports interop with DFS Namespaces (DFS-N) and DFS Replication
(DFS-R).

DFS Works
• DFS Namespaces (DFS-N): Azure File Sync is fully supported on DFS-N servers
Great • see DFS Namespaces overview
• DFS Namespaces with Azure NetApp Files
with Azure
Files / Azure • DFS Replication (DFS-R):
File Sync! • DFS-R and Azure File Sync are both replication solutions
• In most cases, we recommend replacing DFS-R with Azure File Sync
• There are scenarios where you would want to use DFS-R and Azure File Sync
together:

• Migrating from a DFS-R deployment to an Azure File Sync deployment. For


more information, see Migrate a DFS Replication (DFS-R) deployment to
Azure File Sync.
• Not every on-premises server that needs a copy of your file data can be
connected directly to the internet.
• Branch servers consolidate data onto a single hub server, for which you
would like to use Azure File Sync.
DFS-R to AFS
• Migrate DFS-R deployment to Azure File Sync (documented here):
• Create Azure File Share / sync group to represent the DFS-R
topology
Migrate DFS • Start on server with full set of data in DFS-R topology - Install Azure
Replication File
• Register server, create a server endpoint for the first server to be
(DFS-R) migrated - Do not enable cloud tiering
• Let all data sync to Azure file share (cloud endpoint)
to Azure • Install and register the Azure File Sync agent on each of the
remaining DFS-R server
File Sync • Disable DFS-R
• Create a server endpoint on each of the DFS-R servers. Do not
enable cloud tiering.
• Ensure sync completes and test your topology as desired.
• Retire DFS-R
• Cloud tiering may now be enabled on any server endpoint as
desired.
• DFS-R deployment coexisting with Azure File
Sync:
• Create Azure File Share / sync group to
Integrating represent the DFS-R topology
DFS-R with • Start on server with full set of data in DFS-R
topology - Install Azure File
Azure File • Register server, create a server endpoint for
Sync the first server to be migrated - Do not
enable cloud tiering on this Server
• Let all data sync to Azure file share (cloud
endpoint)
• Install and register the Azure File Sync agent
on new file servers – with or without tiering
enabled
Active Directory
Replace DFS-R (DFS Namespace)

DFS-N Points to All Endpoints


with Azure File
Sync (Example)
File Sync 2) Add new (smaller)

Simple as DFS Replica


DFS Replica
Cache VM
(with Tiering)
file server(s) with
agent and tiering
File Sync

1,2,3,4… 4) Decommission
AND
File Sync
(without Tiering)
Cache VM
(with Tiering)

old / large /expensive


DFS-R file server(s)
Azure
Files
DFS-R Replication
All Servers have full
copies (no tiering) File Sync Replication
Non-DFS-R Servers can
use tiering (saves storage)
Shrinking File Servers
with File Sync
File Sync inside VMs Leads to SAN Utilization “Shrinkage”
SAN upgrade not scheduled for another year …
any way to slow / stop / reverse growth avoids Azure

“early buy” Files

Installing Azure File Sync in larger VMs cut


space by tiering older files… allowing VMDK /
VHD files to be compressed / de-duplicated
SAN upgrade pushed out, Azure utilization
increased, no user impact
https://gbbblog.azurewebsites.us/index.php/2022/03/07/avoid-defer-costly-storage-
upgrades-with-azure-file-sync/
File Server File Server File Server
VM VM VM

Learning: You can reduce existing


storage with Azure Files without
replacing existing storage infrastructure
The Trick: Shrinking the VM Disk
Azure File Sync with Tiering reduced the file storage… but it didn’t
clean up the space
Space is just marked as available for use
Lots of the file “content” is still there – underlying storage doesn’t know it can
“deduplicate” / recover the space
Use Sdelete to “Zero” the free space in the VM
SDelete - Windows Sysinternals | Microsoft Docs
Example: Sdelete –z <drive letter>

You might also like