Lumerical Quick-Start Product AMI Configuration
Overview
Unlike the License Server AMI, the Product AMI requires that you create your own AMI with a few additions before it can be used in a cluster. These changes are:
- SSH configuration (for MPI job-launching and communication)
- License server configuration
- Any additional changes you wish to make
Prerequisites
- Access to Lumerical Quick-Start AMIs
- Create and configure your VPC and Security Group
- Create a key-pair and IAM Role
Product AMI Custom Configuration
- Launch an instance of the Lumerical product AMI in the same way as was done with license manager. Use a small instance like c5.large since we are not running and simulations yet.
- Login with SSH
- Edit the aws-fdtd-config.json file and specify your S3 bucket and bucket region
- Create a configuration file to set your license manager using this command and substituting the PRIVATE IP address of your license manager server.
mkdir -p ~/.config/Lumerical; printf "[license]\nflexserver\host=27011@<server_privat_ip>\n" > ~/.config/Lumerical/License.ini
OR for a system-wide configuration:
sudo su; mkdir -p /opt/lumerical/2019b/Lumerical; printf "[license]\nflexserver\host=27011@<server_privat_ip>\n" > /opt/lumerical/2019b/Lumerical/License.ini
- Setup an SSH key so all instances with this AMI can communicate with one another over MPI.
ssh-keygen -N "" -f ~/.ssh/cluster_key
cat .ssh/cluster_key.pub >> .ssh/authorized_keys
printf "Host *\n StrictHostKeyChecking no\nIdentityFile ~/.ssh/cluster_key\n" >.ssh/config
chmod 600 .ssh/config - Test your connection by starting an ssh session from the instance to itself, you should not be prompted for a password when you run the following command:
[ec2-user@ip-<Private IP> ~]$ ssh <Private IP>
- You are now ready to create your own snapshot/AMI (see below)
Creating your AMI
- From the EC2 management console dashboard, go to your Instances and select the compute node you have created.
TIP: Add a name tag to this instance for quick identification. - Ensure that the selected instance is in the STOPPED state.
- Otherwise, Stop the instance.
- Create Image from this instance.
- Provide a unique image name and short description of your AMI.
- Use the default or current settings.
- Create the image
- This might take some time to finish.
- Once created and available, you can use this AMI to launch more compute nodes.
- Take note of the AMI ID for your image. This will be used later for your Launch Template.
- This might take a few minutes to finish and get the AMI running and ready.