Which directory can I write in an application in AWS AppStream 2?
- User
Which directory can I write in an application in AWS AppStream 2?
- Assistant
In AppStream 2.0 you don’t get write-access to Program Files or the Windows root – all of your application writes must go into “user‐writable” locations. By default you can write to:
-
The user’s profile folder (persistent if you enable Home folders)
• %USERPROFILE%
• e.g. C:\Users<STACK_USERNAME>\Documents
• e.g. C:\Users<STACK_USERNAME>\AppData\Local\Temp -
The local ephemeral scratch volume (D:\ drive)
• D:\ is fully writable during the session but is not persisted across instance rebuilds. -
Any network‐mounted file share you configure for persistence
• e.g. map an FSx or EFS share to, say, H:\
Here’s a quick comparison:
Location Path Examples Ephemeral? Persistent? Use Case User profile / Documents C:\Users<User>\Documents No* Yes, if Home folder enabled Saving user files/settings User temp folder C:\Users<User>\AppData\Local\Temp Yes (session) No Scratch/temp files Local scratch volume D:\ Yes (session) No Large temp data Network-mounted file share H:\ (or whatever drive you map) Depends Yes (FSx/EFS/SMB) Long‐term storage between sessions * Writes under your user profile only persist if you’ve turned on AppStream Home Folders (backed by FSx/EFS or an SMB share). Anything you write outside of a mapped share or the Home folder will vanish once the instance is stopped or rebuilt.
—
Recommendation
If you need true persistence:- Configure a Home Folder when you create your stack (point it at an FSx for Windows File Server or EFS-backed SMB share).
- Have your app write all user data to
%USERPROFILE%or a subfolder there.
If you only need scratch space during the session, write to
D:\or%TEMP%. -
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.