Media Cache
The Media Cache stores managed media used internally by the application. Users should not access or delete files in this folder directly.
Unreferenced Media Clean Up
Unreferenced media will automatically be removed from the Media Cache on a regular basis with the auto-save process or on startup/exit of the application.
The clean up process can be done explicitly by using the option Flush Purgeable Media in the preferences.
Media Pre-Allocation
By default, disk space for video files is allocated on-the-fly as the files are rendered or written. However, concurrent I/O operations from multiple clients or background processes can lead to clip fragmentation and decreased playback performance, especially on spinning disk storage.
To address this issue, Stone and Wire, Flame's optimized I/O system, provides media file pre-allocation mechanisms. These mechanisms reserve the necessary disk space before writing the media files, ensuring better contiguity and improved playback performance. The available pre-allocation strategies are:
FALLOCATE: Files are pre-allocated and zeroed out during allocation. On most file systems, this operation is as expensive as writing the files.
RESERVE: Disk space is reserved but not written, leaving the apparent file size at 0. The apparent size of the frame will remain 0. This operation is typically much faster than
FALLOCATE
but is supported only on selected file systems, such as XFS.F_PREALLOCATE: Similar to
RESERVE
, but supported on different file systems such as HFS/HFS Plus.BEST: Automatically selects the best pre-allocation strategy for the current project's media folder file system.
NONE: No pre-allocation is performed. Disk space is allocated as frames are written.
By default, pre-allocation is disabled (NONE
). To enable it, modify the
Preallocation
parameter in
/opt/Autodesk/sw/cfg/stone+wire.cfg
under the [StandardFSMediaOptions]
section. Note that the Preallocation
parameter under the [Partition#]
sections only applies to storage volumes used by versions prior to 2026.
Measuring File System Performance with sw_io_perf_tool
Stone and Wire includes a command-line tool, sw_io_perf_tool
, to measure file
system performance. This tool simulates I/O requests (audio and/or video)
issued by Flame Family products and reports throughput and maximum
latency for the requested operations. Use this tool
to evaluate the read and write performance of your project's media cache.
Usage Example
To display a list of available options:
/opt/Autodesk/sw/tools/sw_io_perf_tool -h
To test the read performance of the media cache for project MyProject
at UHDTV
resolution (3840x2160) with 16-bit floating-point depth and no frame rate
throttling:
/opt/Autodesk/sw/tools/sw_io_perf_tool -m /var/opt/Autodesk/flame/projects/MyProject/media -v 3840,2160 -d 16fp -Z
Alternatively, allocate temporary test media in the project itself:
/opt/Autodesk/sw/tools/sw_io_perf_tool -u $(readlink /var/opt/Autodesk/flame/projects/MyProject/.uuid) -v 3840,2160 -d 16fp -Z
This tool can be run while other operations are ongoing to simulate real-world
conditions. The media used by sw_io_perf_tool
is allocated and freed
automatically.
Checking Disk Usage
To check if a project's media cache is full, use the df -h
command.
Linux:
$ df -h /var/opt/Autodesk/flame/projects/MyProject/media
Filesystem Size Used Avail Use% Mounted on
/dev/sdc 7.3T 4.4T 3.0T 60% /mnt/8TB_STORAGE
- Size: Total size of the file system.
- Used: Amount of space currently used.
- Avail: Available free space.
- Use%: Percentage of space used.
macOS:
$ df -h /var/opt/Autodesk/flame/projects/MyProject/media
Filesystem Size Used Avail Capacity iused ifree %iused Mounted on
/dev/disk1s2 3.6Ti 898Gi 2.7Ti 25% 3.7M 29G 0% /System/Volumes/Data
- Size: Total size of the file system.
- Used: Amount of space currently used.
- Avail: Available free space.
- Capacity: Percentage of space used.
- iused: Number of inodes used.
- ifree: Number of free inodes.
- %iused: Percentage of inodes used.
To see the storage consumed by your project's media cache, use the du -hs
command:
$ du -hs /var/opt/Autodesk/flame/projects/MyProject/media
219G /var/opt/Autodesk/flame/projects/MyProject/media
- The output shows the total size of the specified folder (219G in this example).
Moving the Media Cache
You may need to move the Media Cache for various reasons, such as insufficient storage capacity, hardware upgrades, or making room for another project. Follow these instructions to move the Media Cache for a single project or all projects under a common mount point.
Moving One Project Media Cache at a Time
These steps guide you through moving the Media Cache of a single project to a new location.
Ensure the project is not in use
Make sure the affected project is not in use by any application or background job.
Determine the current Media Cache location
Use the
realpath
command to find the current Media Cache location:$ realpath /var/opt/Autodesk/flame/projects/MyProject/media /mnt/SSD/MyProject/efa426b-3654-4e1a-9f9e-4e144e557ee4
Copy the Media Cache to the new location
Use the
cp -pR
command to copy the folder to the desired location. This command will preserve file attributes:$ cd /mnt/SSD/MyProject $ cp -pR efa426b-3654-4e1a-9f9e-4e144e557ee4 /mnt/NVME/MyProject/
Verify the folder exists in the new location:
$ ls -ld /mnt/NVME/MyProject/efa426b-3654-4e1a-9f9e-4e144e557ee4 drwxrwsrwx 3 flame artists 15 Mar 20 18:12 /mnt/NVME/MyProject/efa426b-3654-4e1a-9f9e-4e144e557ee4
Update the symbolic link
Modify the symbolic link in the project home folder to point to the new location:
$ cd /var/opt/Autodesk/flame/projects/MyProject $ ln -sfn /mnt/NVME/MyProject/efa426b-3654-4e1a-9f9e-4e144e557ee4 media
Validate the symbolic link points to the new location:
$ realpath /var/opt/Autodesk/flame/projects/MyProject/media /mnt/NVME/MyProject/efa426b-3654-4e1a-9f9e-4e144e557ee4
Verify the new location in the application
Start the application, enter the Manage window, and confirm the new Media Cache location.
Delete the original folder
After verifying the copy, delete the original folder:
$ cd /mnt/SSD/MyProject/ $ rm -Rf efa426b-3654-4e1a-9f9e-4e144e557ee4
Moving All Project Media Caches Under a Common Mount Point
These steps guide you through replacing a storage volume used exclusively for Media Caches. Note: The commands below are approximations and will need to be adapted to your platform and configuration.
Ensure no applications are using the Media Cache
Make sure no application or background task is using a project with its Media Cache on the volume to be moved.
Create a temporary mountpoint
Create a new temporary mount point for the original volume:
$ sudo mkdir -p /mnt/old_volume
Unmount the original volume and remount it
Unmount the original volume and remount it on the new mount point:
$ sudo umount /mnt/media_caches $ sudo mount /dev/nvme0n1 /mnt/old_volume
Mount the new volume
Mount the new volume on the original mount point:
$ sudo mount /dev/nvme1n1 /mnt/media_caches
Copy data to the new volume
Use the rsync command to copy the material from the original to the new volume. This command will preserve file attributes and hard links:
$ sudo rsync -aH --progress /mnt/old_volume/ /mnt/media_caches
Remove the temporary mount point
Unmount the original volume and eliminate the temporary mount point:
$ sudo umount /mnt/old_volume $ sudo rmdir /mnt/old_volume
Verify access and clean up
After verifying that each project has access to its Media Cache, you can safely delete the data on the old storage.
Relocating The Cache And Renders Database
Flame Family products use a PostgreSQL database to manage Cache and Renders metadata (see PostgreSQL Database for more details).
There might be a need to relocate the database of a given host, eg. for maintenance or upgrade. Administrator privilege is required.
Log on the host on which the database is located and type the following command to perform a snapshot of the database, replacing <snapshot location> with your desired location:
sudo -u flame_db -i /opt/Autodesk/pgsql-17/bin/pg_dumpall | zstdmt -o /<snapshot location>/flame.db.zst
When the snapshot is complete, log on to the host on which you want to restore the database snapshot and copy the database snapshot on that host. If you have created the database snapshot on a shared location, skip this step.
scp Source_Server:/<snaphot location>/flame.db.zst /<snapshot location>
Restore the database backup on the destination host:
zstdcat /<snapshot location>/flame.db.zst | sudo -u flame_db -i /opt/Autodesk/pgsql-17/bin/psql -X -d flame
Clean Up
Follow these steps to delete the source content:
Delete the database snapshot on the source host:
rm /<snapshot location>/flame.db.zst
Delete the database snapshot on the destination host
rm /<snapshot location>/flame.db.zst
Destroy the database on the source host
sudo -u flame_db -i /opt/Autodesk/bin/igniter --destroy
Restoring Project Media Cache Database Backups
When the application is started, a backup of the database subset for the currently selected project is done automatically, the same way as for the Catalog. In case of disaster recovery, it is possible to restore this backup of the project's cache metadata.
Administrators are able to restore backups using the following commands:
Rocky Linux / Trust Authentication mode
zstd -cd /<project home>/catalog_AUTO_BACKUP/<project name>/backup.000/<project name>.sql.zst | /opt/Autodesk/pgsql-17/bin/psql -d flame -U u:flame_user
Rocky Linux / Certificate Authentication mode
zstd -cd /<project home>/catalog_AUTO_BACKUP/<project name>/backup.000/<project name>.sql.zst | /opt/Autodesk/pgsql-17/bin/psql -d flame
macOS / Trust Authentication mode
/opt/Autodesk/lib64/zstd -cd /<project home>/catalog_AUTO_BACKUP/<project name>/backup.000/<project name>.sql.zst | /opt/Autodesk/pgsql-17/bin/psql -d flame -U u:flame_user
macOS / Certificate Authentication mode
/opt/Autodesk/lib64/zstd -cd /<project home>/catalog_AUTO_BACKUP/<project name>/backup.000/<project name>.sql.zst | /opt/Autodesk/pgsql-17/bin/psql -d flame