Troubleshooting Windows File Write Access Issues using Cloudbase-Init
search cancel

Troubleshooting Windows File Write Access Issues using Cloudbase-Init

book

Article ID: 390256

calendar_today

Updated On: 04-02-2025

Products

VMware Aria Suite

Issue/Introduction

Customers may encounter difficulties writing text files to the C drive on newly deployed Windows machines.

Environment

VMware Aria Automation 8.x

Cause

The inability to write files to the C drive on a newly provisioned Windows machine can be caused by various factors, including:

  • Insufficient permissions: The user account may lack write permissions to the C drive.
  • File system restrictions: The file system may be read-only or have strict access controls.
  • Cloudbase-Init configuration: The Cloudbase-Init configuration may not be correctly set up to perform the desired file write operations.

Resolution

This solution uses Cloudbase-Init commands within Automation Assembler to ensure the desired file is written to the C drive during the deployment process.

Procedure:

  • Create a Cloudbase-Init Template:
    Go to the "Design" tab in Automation Assembler and create a new cloud template.
  • Add a "cloudConfig" section with the following Cloudbase-Init commands:
resources:
  Cloud_Machine_1:
    type: Cloud.Machine
    properties:
      image: cloudbase-init-win-2016
      flavor: small
      remoteAccess:
        authentication: usernamePassword
        username: Administrator
        password: Password1234@$
      cloudConfig: |
        #cloud-config
        write_files:
          - path: C:\hello.txt
            content: |
              Hello
          - permissions: '0644'

 

  • Deploy the cloud template from Automation Assembler.
  • Connect to the newly deployed Windows machine using Remote Desktop Protocol (RDP) and the credentials specified in the template.
  • Verify that the "C:\test.txt" file exists and contains the expected text.

Additional Information