SQL Server on Linux也发布一段时间了,官方上支持Red Hat, SUSE, Ubuntu。手上没有以上Linux版本,选用了与Red Hat最接近的CentOS7.4来进行安装和测试。
1. 环境Linux: CentOS Linux release 7.4.1708 (Core)
Memory: 4 GB
SQL Server: SQL Server 2017 (RC2) - 14.0.900.75 (X64)
2. 安装mssql-server
2.1 下载rpm包
[root@linuxidc /opt]# mkdir -p /opt/sqlserver2017
[root@linuxidc /opt]# cd /opt/sqlserver2017/
[root@linuxidc /opt]# wget https://packages.microsoft.com/rhel/7/mssql-server/mssql-server-14.0.900.75-1.x86_64.rpm
[root@linuxidc /opt/sqlserver2017]# yum localinstall mssql-server-14.0.900.75-1.x86_64.rpm
Loaded plugins: fastestmirror, langpacks
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
Examining mssql-server-14.0.900.75-1.x86_64.rpm: mssql-server-14.0.900.75-1.x86_64
Marking mssql-server-14.0.900.75-1.x86_64.rpm to be installed
Resolving Dependencies
--> Running transaction check
---> Package mssql-server.x86_64 0:14.0.900.75-1 will be installed
--> Finished Dependency Resolution
Dependencies Resolved
===========================================================================================================================================================================
Package Arch Version Repository Size
===========================================================================================================================================================================
Installing:
mssql-server x86_64 14.0.900.75-1 /mssql-server-14.0.900.75-1.x86_64 870 M
Transaction Summary
===========================================================================================================================================================================
Install 1 Package
Total size: 870 M
Installed size: 870 M
Is this ok [y/d/N]: y
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
Installing : mssql-server-14.0.900.75-1.x86_64 1/1
+--------------------------------------------------------------+
Please run 'sudo /opt/mssql/bin/mssql-conf setup'
to complete the setup of Microsoft SQL Server
+--------------------------------------------------------------+
Verifying : mssql-server-14.0.900.75-1.x86_64 1/1
Installed:
mssql-server.x86_64 0:14.0.900.75-1
Complete!