Info Security Memo
  • Blog
  • Sitemap
    • Categories
  • Contact
  • About
  • Resources
  • Tools
  • 51sec.org

Build Confidence

Focusing on Information Security 

Info Security Notes

Azure Blob Storage Operation Notes

10/30/2021

0 Comments

 
Azure Blob Storage Operation Notes

This post is to show you the methods how to access your Azure Blob storages, especially under Windows. 

You will be able to use NFS 3.0 protocol to mount Blob storage container. 


Azure Storage Explorer

Azure Portal, from storage accounts page, you can click "Open in Explorer":

You can use Azure Storage Explorer (Free tool to easily manage your Azure cloud storage resources anywhere, from Windows, macOS, or Linux)

Download link:https://azure.microsoft.com/en-in/features/storage-explorer/

More details can be found from this link: Manage Azure Blob Storage resources with Storage Explorer

Connect to Blob container:


Anonymously access:


Enter your blob container URL: https://teststorage51sec.blob.core.windows.net/testcontainer2
teststorage51sec is storage account name
testcontainer2 is container name


Download an Archived file will be failed, but hot/cool will be ok. Cool download has no delay based on testing.


Change access layer for archive file. It is dehydrate process. 

You can choose to upload to a new folder to create a folder under Blob container when uploading files. You also can choose multiple files to upload at one time. 


Access Blob Storage Using Linux

References: Mount Blob storage by using the Network File System (NFS) 3.0 protocol
 


Mounting on Linux is simple, but you’ll need to have an NFS client install first. Some distros have this automatically installed, but others will need to install it.

Once it’s installed, create a mountpoint with mkdir. You may need sudo if you aren’t a root user or don’t have permissions.

mkdir /mnt/mystuff


After creating the mountpoint, mount the Storage Account with the mount command.

mount -o sec=sys,vers=3,nolock,proto=tcp testnfs3sec.blob.core.windows.net:/testnfs3sec/nfs3test /mnt/mystuff



Access Blob Storage in Windows


Mounting Blob Storage using NFS 3.0


Reference link: https://hovermind.com/azure-virtual-machine/mounting-blob-storage.html#points-to-be-noted

Enable cloud shell (https://shell.azure.com.) will cause a small charges since it will requires a storage account with a new resource group to store some information. 
Requesting a Cloud Shell.Succeeded.
Connecting terminal...

Welcome to Azure Cloud Shell

Type "az" to use Azure CLI
Type "help" to learn about Cloud Shell


MOTD: Save files to $home/clouddrive for persistence across sessions

VERBOSE: Authenticating to Azure ...
VERBOSE: Building your Azure drive ...
PS /home/netsec>
PS /home/netsec> Register-AzProviderFeature -FeatureName AllowNFSV3 -ProviderNamespace Microsoft.Storage

FeatureName ProviderName      RegistrationState
----------- ------------      -----------------
AllowNFSV3  Microsoft.Storage Registering

PS /home/netsec>
PS /home/netsec> Register-AzResourceProvider -ProviderNamespace Microsoft.Storage

ProviderNamespace : Microsoft.Storage
RegistrationState : Registered
ResourceTypes     : {storageAccounts/encryptionScopes, deletedAccounts, locations/deletedAccounts, storageAccounts…}
Locations         : {East US, East US 2, West US, West Europe…}


PS /home/netsec>

Verify that NFS is registered
PS /home/netsec> Get-AzProviderFeature -ProviderNamespace Microsoft.Storage -FeatureName AllowNFSV3

FeatureName ProviderName      RegistrationState
----------- ------------      -----------------
AllowNFSV3  Microsoft.Storage Registering


PS /home/netsec>







On your VM, install client for NFS.

You will need to enable write access to the NFS share by creating two registry settings. You can do this by launching PowerShell and running the following two commands. Once this is done, you need to reboot or restart the NFS service. Failed to do this step, you will only be able to mount the NFS container, but not able to access it. It will show you error to say no permission.

New-ItemProperty -Path HKLM:\SOFTWARE\Microsoft\ClientForNFS\CurrentVersion\Default -Name AnonymousUid -PropertyType DWord -Value 0

New-ItemProperty -Path HKLM:\SOFTWARE\Microsoft\ClientForNFS\CurrentVersion\Default -Name AnonymousGid -PropertyType DWord -Value 0



Restart client VM.


C:\Users\netsec>mount -o nolock testnfs3sec.blob.core.windows.net:/testnfs3sec/nfs3test *
Z: is now successfully connected to testnfs3sec.blob.core.windows.net:/testnfs3sec/nfs3test

The command completed successfully.

C:\Users\netsec>


Performance:



The uploading speed is about 120Mbps from local to mounted NFS share. 

But when using Azure Storage Explorer, it can reach around 430Mbps.








References

  • Mount Blob storage by using the Network File System (NFS) 3.0 protocol.
  • Tutorial: Use a Windows VM system-assigned managed identity to access Azure Storage
  • Learn to transfer data from the Azure VM (Linux) to Blob Storage





via Blogger http://blog.51sec.org/2021/10/azure-blob-storage-operation-notes.html
October 30, 2021 at 09:22PM Cloud
0 Comments



Leave a Reply.

    Categories

    All
    Architecture
    Blog
    Checkpoint
    Cisco
    Cloud
    CyberArk
    F5
    Fortigate
    Guardium
    Juniper
    Linux
    Network
    Others
    Palo Alto
    Qualys
    Raspberry Pi
    Security
    SIEM
    Software
    Vmware
    VPN
    Wireless

    Archives

    March 2024
    February 2024
    January 2024
    December 2023
    November 2023
    October 2023
    September 2023
    August 2023
    July 2023
    June 2023
    May 2023
    April 2023
    March 2023
    February 2023
    January 2023
    December 2022
    November 2022
    October 2022
    September 2022
    August 2022
    July 2022
    June 2022
    May 2022
    April 2022
    March 2022
    February 2022
    January 2022
    December 2021
    November 2021
    October 2021
    September 2021
    August 2021
    July 2021
    June 2021
    May 2021
    April 2021
    March 2021
    February 2021
    January 2021
    December 2020
    November 2020
    October 2020
    September 2020
    August 2020
    July 2020
    October 2019
    September 2019
    June 2019
    July 2018
    May 2018
    December 2017
    August 2017
    April 2017
    March 2017
    January 2017
    December 2016
    November 2016
    October 2016
    September 2016
    August 2016
    July 2016
    June 2016
    May 2016
    April 2016
    March 2016
    February 2016
    January 2016
    December 2015
    November 2015
    October 2015
    September 2015
    August 2015
    July 2015
    June 2015
    May 2015
    April 2015
    March 2015

    Print Page:

    RSS Feed

    Email Subscribe
Powered by Create your own unique website with customizable templates.
  • Blog
  • Sitemap
    • Categories
  • Contact
  • About
  • Resources
  • Tools
  • 51sec.org