With the DataSync migration completed and the File Gateway mounted, activated, and validated, the NFS server can be shut down. File access can be achieved by using Storage Gateway. Finally, test files will be written through Storage Gateway, verifying they end up in the S3 bucket to be scanned.
From the CLI for the Application server, run the following command to unmount the NFS server:
sudo umount /mnt/data
Using the EC2 console connect to the Application Server.
From the CLI of the Application server, run the following command to write a new object to S3 through Storage Gateway:
sudo cp /mnt/fgw/images/00002.jpg /mnt/fgw/new-image2.jpg
sudo cp eicar.com.txt /mnt/fgw/new-data.txt
When initially configuring storage gateway, the cache refresh interval was set to none. This means files quarantined by File Storage Security will continue to appear in the application server mount path.
To verify this, run the following command on the Application Server:
ls /mnt/fgw
Using the EC2 console connect to the Application Server.
From the CLI of the Application server, run the following command:
ls /mnt/fgw
With the cache refreshed the file is no longer available to the Application Server to interact with.