This document walks you through how to set up CORTX on an Amazon EC2 instance and how to perform IO operations using another EC2 instance on the same subnet.
- You will need an AWS account with right to create an EC2 instances.
- You will need to import to an AMI the CORTX OVA.
- Ideally you would have run and setup CORTX on a local VM and gone through the steps locally before doing it on AWS.
- To launch an instance in the EC2 dashboard look for the launch instance button.
- Select the AMI you created with the CORTX image.
When choosing the AMI go to My AMIs.
- Launch an AWS instance that can support 4 network interfaces. The recommended instance would be a c5 xlarge instance.
-
Create a new security group by following these instructions. Name this Security Group something recognizable like CORTX SG.
-
Once created follow these instructions to add the below inbound rules to the security group
Step 3: Create 2 network interfaces on different subnets with the security group and attach them to the EC2 instance
- Create 2 network interfaces with the security group that you created above.
- It will be helpful to name that network interface ens256 and ens224 so that it is easy to remember.
- [Attach that interface] (https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/using-eni.html#attach_eni) to the EC2 instance that you created in Step 2.
Step 4: Boot up the EC2 instance and edit net .rules file to create stable names for the network interfaces
- Log in to the EC2 instance using these credentials:
Username: CORTX
Password: opensource!
To create stable names for network interfaces on the EC2 instance we will need to edit the 70-persistent-net.rules
file located here /etc/udev/rules.d
- You can edit the file using
vi
by running this command:
vi /etc/udev/rules.d/70-persistent-net.rules
In the file you will add the value of each of the MAC addresses for the corresponding network interfaces to the right name.
Fill in the key for ATTR{address}==
with the MAC address you want for each network interface.
Example:
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="02:6d:62:4e:41:e3", NAME="ens192"
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="02:7c:de:ea:8a:8d", NAME="ens224"
SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="02:61:b7:69:e6:c9", NAME="ens256"
Do NOT just copy this example, fill in the MAC adddress of YOUR network interfaces
The naming of both drives in the bootstrap script are quite specific to do this we will need to rename the 2 drives to sdb
and sdc
.
- Run these 2 commands:
ln -s /dev/nvme2n1 /dev/sdb
ln -s /dev/nvme2n1 /dev/sdc
You can reboot the instance by selecting the machine and rebooting it in the EC2 dashboard.
- After the instance has been rebooted, login and run this command:
sh /opt/seagate/cortx/provisioner/cli/virtual_appliance/bootstrap.sh
- After this has been completed run the
s3-sanity-test
script to make sure that we can add and remoce s3 objects.
sh /opt/seagate/cortx/s3/scripts/s3-sanity-test.sh
- If the sanity test passes you can configure the CORTX server by using these instructions
Note: Your management IP address is the Elastic IP you created.
Because we can only expose one of the network interfaces publicly we will need another another EC2 instance to access the data network.
- Create another instance and instead of choosing the CORTX AMI select the Windows Server 2019 AMI instead
- For this instance you can use a T2 micro instance.
- Make sure the instance is on the same subnet as the network interface that is connected to ens256 which is the data interface. You will need to select this in the configuration.
Launch the instance and wait for it to complete booting before moving on to Step 7.
Once you have created the Windows Server you can remote desktop into the Windows Server instance to perform IO on the CORTX server.
-
Follow these instructions to remote desktop into your windows instance
-
Follow these instructions to upload files to the CORTX server.