Microsoft SQL Server 2022 (Oracle Linux 8) by metabloc

Welcome to your Microsoft SQL Server 2022 deployment solution by metabloc. This stack was designed to be as streamlined as possible, with the least number of steps required to get you up and running quickly. Please follow the directions closely to ensure success. It is recommended to get the product you purchased running per this documentation first. Then you have the option to customize your solution to your requirements.

These instructions for our stack assume the following:

·        Basic understanding of the AWS console

·        Intermediate skill level and/or experience with Oracle Linux and Microsoft SQL Server

·        Remote access SSH client, such as Putty, and how to create a ppk file from an AWS PEM file. These credentials will allow you to connect to your new EC2 instance in your AWS availability zone

Preinstalled Software

·        Oracle Linux 8.10

·        Microsoft SQL Server 2022

Getting Started

Connect to your EC2 Instance using an SSH Client such as putty, as the cloud-user. More information about how to do this is here:

https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/connect-linux-inst-from-windows.html

Changing your SQL Server Edition

This AMI is preconfigured with SQL Server Express Edition. To change this to a different edition, run the following a select the appropriate option:

 

 
sudo systemctl stop mssql-server
sudo /opt/mssql/bin/mssql-conf setup
 
Choose an edition of SQL Server:
  1) Evaluation (free, no production use rights, 180-day limit)
  2) Enterprise Developer (free, no production use rights)
  3) Standard Developer (free, no production use rights)
  4) Express (free)
  5) Web (PAID)
  6) Standard (PAID)
  7) Enterprise (PAID) - CPU core utilization restricted to 20 physical/40 hyperthreaded
  8) Enterprise Core (PAID) - CPU core utilization up to Operating System Maximum
  9) I bought a license through a retail sales channel and have a product key to enter.
 10) Standard (Billed through Azure) - Use pay-as-you-go billing through Azure.
 11) Enterprise Core (Billed through Azure) - Use pay-as-you-go billing through Azure

 

Resetting the sa password

 

sudo systemctl stop mssql-server
sudo /opt/mssql/bin/mssql-conf set-sa-password
sudo systemctl start mssql-server

 

 

Database Access

To connect locally to the SQL Instance using the sqlcmd client:

sqlcmd -S localhost -U sa -P '[password]' -N -C
1> SELECT Name FROM sys.databases;
2> go
Name                                                                            
--------------------------------------
master                                                                          
tempdb                                                                          
model                                                                           
msdb                                                                            
 
(4 rows affected)
1> quit

AWS Elastic IP Address Allocation

 

It is strongly recommended that you create an AWS elastic IP address associated to this new EC2 build instance. This will allow you to start and stop without having to update the public IP address connection information.

 

AWS Security Group Configuration

Enable SSH, MSSQL from your client IP to the EC2 Instance IP

  
  SSH          : 22:22
  MSSQL        : 1433:1433