How to create File Shares and steps to restore text document to its original state using Microsoft Azure.
From the home page, type 'storage accounts' and click on 'storage accounts' from the drop down.
Once opened, click on the desired storage account if you have more than one storage account.
Storage account overview page opens, scroll down to 'File shares' under Data storage after containers.
Click '+ File share' at the top of the page.
Choose a name for your file share and click 'Next: Backup >'.
Click 'Next: Review >'
Click 'Create'
File share created.
Open Windows 11 virtual machine (click here for how to create a Windows 11 virtual machine) and type 'PowerShell' in the search tab on the task bar once opened. Then click the 'Windows PowerShell' on top. Once open, choose 'run as administrator'.
Go back to Azure File share and click connect on top of the page.
The 'Connect' page opens to the right, scroll down to 'show script' and click to open.
Once the script opens, copy script by clicking on the 'copy to clipboard' icon and go back to your virtual machine PowerShell terminal previously opened.
Paste the copied script and press enter.
You should have a screen that looks like below. "Credential added successfully".
Still on the virtual machine, open file explorer (the yellow folder on the task bar at the bottom of screen).
Once opened, click 'This PC' on the left. The file share should appear under 'Network locations'. Double click the file share to open.
Once it opens, click 'New' on the top left.
Navigate to 'Text document'.
Give your text document a name.
Once created, double click to open.
Once it opens, type a sentence of your choice in it.
Then go to 'File'.
Click on 'Save' and minimize.
Navigate back to Azure File share and click 'Browse' on the left pane. Your text document from your virtual machine should open there.
Once it opens, click on 'Snapshot' to the left.
Click 'Add snapshot' on top left of page.
And click 'OK'.
Snapshot content.
Navigate back to your virtual machine and double click your text document to open.
Once it opens, type some gibberish next to the previously typed text in the text document.
Save it.
And close it.
Go to 'This PC' on the bottom left (still on the virtual machine).
Right click on your File share name that opens.
Click on 'Show more options'
Click on 'Restore previous version'
Click on the File share and click 'Restore' on the bottom right
Click 'Restore'
Click 'OK'
Now navigate back to the text document to see the restored version. Click the file share to open.
Click the text document to open.
If the text document has been restored, it should revert back to the original text and look like below. If not, repeat previous steps above.
Hope this has been helpful in creating your File share and restoring text document back to its original state.