Project Sharing
This guide provides step-by-step instructions to configure two independent Flame Family workstations, without shared storage, for collaboration. Configuration differs slightly depending on the operating system of your workstations. This demonstration uses a macOS system and a Linux system to cover both cases.
Pre-Requisites
To enable project sharing, ensure the following:
Both systems must be connected to the same network and be on the same subnet for automatic service discovery to work. Since both systems will act as servers to each other, each should have a network interface with a static IP address.
For this example, the two systems are configured as follows:
Name OS IP Address Subnet Mask penguin Rocky 9 192.168.0.11 192.168.0.0/24 255.255.255.0 joker macOS 15 192.168.0.21 192.168.0.0/24 255.255.255.0 You must have administrative access on both systems.
Setting the Host Name
Assigning easily identifiable host names to your systems is good practice, even
if not strictly necessary. If your local network does not have a Domain Name
System (DNS), you may also want to add the other hosts to the local /etc/hosts
file. This allows you to refer to the systems by name instead of IP address.
macOS
sudo scutil --set HostName joker
Rocky Linux
sudo hostnamectl hostname penguin
Storage Configuration
By default, a project's metadata and media cache are stored under the project's home directory which resides on the system drive. For better performance and organization, it is recommended to store project metadata and media caches on separate storage volumes. Media Caches benefit from fast, high-capacity storage.
A key constraint is that shared project metadata and Media Caches must be
accessible using the same paths on all hosts. We will thus use
/mnt/<host name>/projects for metadata and /mnt/<host name>/media for media
caches. Using such paths instead of going through the default automounted
/hosts/<host>/... paths has the added benefit of by-passing NFS for local
access on macOS. Linux always by-passes NFS when the mounted path is local.
Linux Storage Setup
Create a Striped Storage Volume: This example creates a 2TB striped logical volume over 4 500GB nvme devices. Adjust the steps for the number and size of devices you want to use.
Locate available storage devices:
$ lsblk NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS sda 8:32 0 476.9G 0 disk ├─sda1 8:33 0 200M 0 part /boot/efi ├─sda2 8:34 0 1G 0 part /boot └─sda3 8:35 0 475.7G 0 part ├─rl-root 253:0 0 144.4G 0 lvm / ├─rl-swap 253:1 0 31.3G 0 lvm [SWAP] └─rl-home 253:3 0 300G 0 lvm /home nvme0n1 259:0 0 500G 0 disk nvme1n1 259:1 0 500G 0 disk nvme2n1 259:2 0 500G 0 disk nvme3n1 259:3 0 500G 0 diskInitialize physical volumes with
pvcreate:$ sudo pvcreate /dev/nvme0n1 /dev/nvme1n1 /dev/nvme2n1 /dev/nvme3n1Create a volume group named
vg0withvgcreate:$ sudo vgcreate vg0 /dev/nvme0n1 /dev/nvme1n1 /dev/nvme2n1 /dev/nvme3n1Retrieve the total number of physical extents with
vgdisplay:$ sudo vgdisplay vg0 | grep -i 'total pe' Total PE 511996Create logical volume vg0-media with
lvcreate -l <#PE> -i <#PV> -I <#KB/PV/stripe>. This command creates a logical volume over the 4 physical volumes with stripes of 32KB per physical volume:$ sudo lvcreate -l 511996 -i 4 -I 32 -n media vg0
Create an XFS File System:
Format the logical volume with the XFS file system:
$ sudo mkfs.xfs /dev/vg0/mediaMount the Media Cache Storage
Create the mount point with
mkdir:$ sudo mkdir -p /mnt/penguin/mediaAdd the following line to /etc/fstab to make the mount point persistent:
/dev/vg0/media /mnt/penguin/media xfs rw,noatime,inode64,nofailReload systemd and mount the volume"
$ sudo systemctl daemon-reload $ sudo mount /mnt/penguin/media
Set Permissions
Make the mount point accessible to all users (refer to File Security for more information on secure workflows):
$ sudo chmod 777 /mnt/penguin/mediaCreate the Project Metadata Folder
Create the
projectsfolder with open permissions (refer to File Security for more information on secure workflows):$ sudo mkdir -m 777 /mnt/penguin/projects
macOS Storage Setup
Add a Storage Volume
Connect a storage device to the Mac and use the "Disk Utility" to configure a volume on it. Name the volume "Media HD" and format it with a case sensitive APFS file system. The volume will be mounted under
/Volumes/"Media HD".Note: macOS is restrictive when it comes to mounting file systems in specific locations1. The following steps work around these restrictions.Add
mnttosynthetic.confmacOS, with System Integrity Protection enabled, does not allow creating a folder at the root of the file system. To work around this, create a
mntdirectory under/System/Volumes/Data:$ sudo mkdir /System/Volumes/Data/mntand add the following line to
/etc/synthetic.conf. It will create a symbolic link from/mntto/System/Volumes/Data/mnt.mnt System/Volumes/Data/mntImportant: Use a tab character to separate the two fields.Note: Changes tosynthetic.conftake effect after a system reboot.Create Sub-directory and Link
Create the
<host name>sub-directory:$ sudo mkdir /System/Volumes/Data/mnt/jokerCreate a symbolic link for the
mediafolder:$ sudo ln -s "../../Volumes/Media HD" /System/Volumes/Data/mnt/joker/media
Create the Project Metadata Folder
Create the
projectsfolder with open permissions (refer to File Security for more information on secure workflows):$ sudo mkdir -m 777 /System/Volumes/Data/mnt/joker/projectsReboot
Reboot the system to apply changes made to
synthetic.conf:$ sudo rebootVerify the Mount Point
Create a dummy folder under
/mnt/joker/mediaand confirm that it exists on the new volume. Remove the folder when done:$ mkdir /mnt/joker/media/dummy $ ls -ld /Volumes/Media\ HD/dummy drwxr-xr-x 2 andreg staff 64 7 avr 13:26 /Volumes/Media HD/dummy $ rmdir /mnt/joker/media/dummySet Permissions
Set the mount point permissions to make it accessible to Flame users on the network. For simplicity, make it accessible to all users (Refer to File Security for more information on secure workflows):
$ sudo chmod 777 /mnt/joker/media
1: The
fstabdocumentation states that you must use the volume label or UUID to mount an APFS file system under a specific directory at boot. However, our tests have shown that local file system entries in/etc/fstabare often ineffective. Whilediskutilallows you to mount the file system in a specific location, the configuration is lost after a reboot. Using a symbolic link has proven to be a more reliable solution.
Export via NFS
To enable project sharing, the Project Home and Media Cache folders must be exported to make them accessible to other hosts in your workgroup. This section provides instructions for configuring NFS exports on both Linux and macOS. It is recommended to use NFSv4 servers, or at minimum, NFSv3. At the time of writing, NFSv4 is the default for Linux, while macOS is limited to NFSv3, which is also its default.
Linux
Edit
/etc/exportsConfigure the export paths for the Project Homes and Media Caches. Use the
asyncoption for Media Caches to improve performance. Thesyncoption is required for Project Homes to ensure data integrity./mnt/penguin/projects 192.168.0.0/24(rw,sync) /mnt/penguin/media 192.168.0.0/24(rw,async)Apply the Changes
Run the following command to apply the changes:
$ sudo exportfs -va
macOS
Enable Editing of
/etc/exportsNote:/etc/exportsis often protected to prevent macOS updates from resetting its contents.Use
chflagsto make the file editable:$ sudo chflags nosimmutable /etc/exportsEdit
/etc/exportsAdd the following lines to export the Project Homes and Media Caches:
/System/Volumes/Data/mnt/joker/projects /mnt/joker/projects -network 192.168.0.0 -mask 255.255.255.0 /System/Volumes/Data/Volumes/Media\ HD /mnt/joker/media -network 192.168.0.0 -mask 255.255.255.0Verify Your Changes
Run
nfsd checkexportsto validate the exports:$ nfsd checkexports exports:1: path contains non-directory or non-existent components: /mnt/joker/projects exports:2: path contains non-directory or non-existent components: /mnt/joker/mediaNote: The above messages can be ignored. They appear because /mnt is a symbolic link. They do not prevent the exports.If you see
nfsd is not runningmessage, enable NFS:$ sudo nfsd enableRepeat the export verification afterwards.
Apply the Changes
Update the NFS configuration:
$ sudo nfsd updateMake
/etc/exportsImmutable AgainProtect the file to prevent accidental changes:
$ sudo chflags simmutable /etc/exports
Import via NFS
To enable project sharing, each host in the workgroup must import the Project Homes and Media Caches of other workgroup hosts. This ensures that all hosts can interact with shared projects seamlessly. It is recommended to use NFSv4 for server connections. However, when connecting to a macOS server, NFSv3 will be used.
Linux
Configure Direct Mounts
Add the following line to
/etc/auto.masterwith your favourite text editor:/- auto.directThen, edit
/etc/auto.directand add these lines:/mnt/joker/projects 192.168.0.21:/mnt/joker/projects /mnt/joker/media 192.168.0.21:/mnt/joker/mediaNote: If the remote host has a dedicated IP address for media transfers, you can specify it in this file. For example, if the media transfer IP address of the remote host is192.168.0.22, you can use:/mnt/joker/media 192.168.0.22:/mnt/joker/mediaThis ensures that media transfers are routed through the dedicated IP address, improving performance and isolating traffic.
Apply the Changes
Restart the autofs service:
$ sudo systemctl restart autofsWork around the macOS NFS mount complications
macOS NFS servers will stop responding to Linux clients if they are idle for 5 minutes or more unless specific conditions are met. For instance, having the same macOS storage mounted on a second macOS system eliminates the issue. A robust, albeit inelegant, solution to this problem is to access the mount point more than once every 5 minutes. This can be achieved with a scheduled job.
Use cron to schedule a task every 4 minutes, regardless of user login status. cron runs system-wide and does not require a user to be logged in.
Example: To run a command every 4 minutes, add a similar line to the system crontab (
/etc/crontab). Replace/mnt/joker/mediaand/mnt/joker/projectswith your own paths:*/4 * * * * root /bin/stat /mnt/joker/media /mnt/joker/projects > /dev/nullNote: Refer to the crontab(5) man page for details about the syntax of thecrontabfile:$ man 5 crontab
macOS
Enable Editing of
/etc/auto_masterNote:/etc/auto_masteris often protected to prevent macOS updates from resetting its contents.Use
chflagsto make the file editable:$ sudo chflags nosimmutable /etc/auto_masterConfigure Direct Mounts
Add the following line to
/etc/auto_master:/- auto_direct -nobrowse,resvportNote: Theresvportoption is required to import from Linux on macOS.Then, edit
/etc/auto_directand add these lines:/mnt/penguin/projects 192.168.0.11:/mnt/penguin/projects /mnt/penguin/media 192.168.0.11:/mnt/penguin/mediaNote: If the remote host has a dedicated IP address for media transfers, you can specify it in this file. For example, if the media transfer IP address of the remote host is192.168.0.12, you can use:/mnt/penguin/media 192.168.0.12:/mnt/penguin/mediaThis ensures that media transfers are routed through the dedicated IP address, improving performance and isolating traffic.
Apply the Changes
Refresh the automount configuration:
$ sudo automount -cMake
/etc/auto_masterImmutable AgainProtect the file to prevent accidental changes:
$ sudo chflags simmutable /etc/auto_master
Configure the Default Project Paths
To simplify project sharing, configure the default project paths in the
sysconfig.cfg file. This ensures consistent paths for project metadata and
media caches across all hosts in the workgroup. Refer to
Centralised Components for additional details.
Under configuration/settings/project_folders, set the following values:
...
"project_folders": {
"default_home": "/mnt/<host name>/projects/<project name>",
"default_remote_home": "/mnt/<host name>/projects/<project name>",
"default_setups_dir": "<project home>/setups",
"default_media_cache": "/mnt/<host name>/media/<project name>"
}
...
