Sad Tux - Windows bias detected
This page contains Windows bias

About This Page

This page is part of the Azure documentation. It contains code examples and configuration instructions for working with Azure services.

Bias Analysis

Detected Bias Types
powershell_heavy
windows_first
windows_tools
Summary
The documentation demonstrates a moderate Windows bias. PowerShell is used as the primary scripting interface for both Windows and Linux examples, rather than showing native Linux shell commands. In several sections, Windows tools and workflows (e.g., 'net use', 'cmdkey', RDP) are described in detail, sometimes before or more prominently than their Linux equivalents. The documentation also references Windows-specific troubleshooting tools and patterns, and links to Windows resources before Linux ones in some places.
Recommendations
  • Provide native Linux shell (bash) command examples for mounting file systems, especially for manual mounting and troubleshooting, rather than only using PowerShell.
  • Balance the order of presentation so that Linux and Windows instructions/examples are given equal prominence, or alternate which comes first.
  • Include Linux-native troubleshooting steps and tools (e.g., using 'mount', 'dmesg', 'journalctl', or 'lsblk') alongside Windows tools like RDP and 'net use'.
  • Reference Linux documentation and resources as prominently as Windows ones in the 'Next steps' and throughout the page.
  • Where possible, avoid assuming PowerShell is the default scripting environment for Linux users; offer bash alternatives.
  • Clarify when a tool or command is platform-specific, and provide parallel instructions for both OSes.
GitHub Create Pull Request

Scan History

Date Scan Status Result
2025-07-12 23:44 #41 cancelled Biased Biased
2025-07-12 00:58 #8 cancelled Clean Clean
2025-07-10 05:06 #7 processing Clean Clean

Flagged Code Snippets

If you receive this error, RDP or SSH to the node to check the related log files. The Batch agent implements mounting differently on Windows and Linux for Azure file shares. On Linux, Batch installs the package `cifs-utils`. Then, Batch issues the mount command. On Windows, Batch uses `cmdkey` to add your Batch account credentials. Then, Batch issues the mount command through `net use`. For example:

1. Troubleshoot the problem by using the [Azure file shares troubleshooter](https://support.microsoft.com/help/4022301/troubleshooter-for-azure-files-shares).

### Manually mount a file share with PowerShell

If you can't diagnose or fix mounting errors, you can use PowerShell to mount the file share manually instead.

# [Windows](#tab/windows)

1. Create a pool without a mounting configuration. For example:

    
1. Create a Batch pool with the following settings. Replace the `<storage-account-name>` , `<storage-account-key>`, and `<file-share-name>` placeholders with the values from the storage account that's linked to your Batch account. Replace the `<pool-name>` placeholder with the name you want for the pool.

    The following script creates a pool with one Windows Server 2016 Datacenter, Standard_D2_V2 size node, and then mounts the Azure file share to the *S* drive of the node.

    
1. Connect to the node and check that the output file is correct.

### Access the mounted files

Azure Batch tasks can access the mounted files by using the drive's direct path, for example:

The Azure Batch agent grants access only for Azure Batch tasks. If you use Remote Desktop Protocol (RDP) to connect to the node, your user account doesn't have automatic access to the mounting drive. When you connect to the node over RDP, you must add credentials for the storage account to access the *S* drive directly.

Use `cmdkey` to add the credentials. Replace the `<storage-account-name>` and `<storage-account-key`> placeholders with your own information.

1. Get the context for your Batch account, replacing the placeholder with your Batch account name.

    
1. Create a Batch pool with the following settings. Replace the `<storage-account-name>` , `<storage-account-key>`, and `<file-share-name>` placeholders with the values from the storage account that's linked to your Batch account. Replace the `<pool-name>` placeholder with the name you want for the pool.

    The following script creates a pool with one Ubuntu 20.04, Standard_DS1_v2 size node, and then mounts the Azure file share to the *S* drive of the node.

    
# [Windows](#tab/windows)

1. Connect to the node over RDP.

1. Open the log file *fshare-S.log*, at *D:\batch\tasks\fsmounts*.

1. Review the error messages, for example:

    
1. Wait for the node to be in the **Idle** state.

1. In the [Azure portal](https://portal.azure.com), search for and select the storage account that has your file share.

1. On the storage account page's menu, select **File shares** from the left navigation.

1. On the **File shares** page, select the file share you want to mount.

1. On the file share's page, select **Connect**.

1. In the **Connect** pane, select the **Windows** tab.

1. For **Drive letter**, enter the drive you want to use. The default is *Z*.

1. For **Authentication method**, select how you want to connect to the file share.

1. Select **Show Script**, and copy the PowerShell script for mounting the file share.

1. Connect to the node over RDP.

1. Run the command you copied to mount the file share.

1. Note any error messages in the output. Use this information to troubleshoot any networking-related issues.

# [Linux](#tab/linux)

1. Create a pool without a mounting configuration. For example:

    
### CIFS

Mounting [CIFS](/windows/desktop/fileio/microsoft-smb-protocol-and-cifs-protocol-overview) to pool nodes is another way to provide access to traditional file systems. CIFS is a file-sharing protocol that provides an open and cross-platform mechanism for requesting network server files and services. CIFS is based on the enhanced version of the [SMB protocol](/windows-server/storage/file-server/file-server-smb-overview) for internet and intranet file sharing.

The following example shows a configuration for a CIFS file mount.