SQL Server 2019 为所有数据工作负载带来了创新的安全性和合规性功能、业界领先的性能、任务关键型可用性和高级分析,现在还支持内置的大数据。 |
准备工作
关闭SELINUX
添加软件源并安装依赖包
[root@localhost ~]# curl https://packages.microsoft.com/config/rhel/7/prod.repo -o /etc/yum.repos.d/msprod.repo [root@localhost ~]# yum -y install mssql-tools unixODBC-devel bzip2 gdb libsss_nss_idmap cyrus-sasl cyrus-sasl-gssapi
安装SQL Server2019
下载文章上面提供的SQL Server2019,上传到服务器并安装
运行初始化配置
[root@localhost ~]# /opt/mssql/bin/mssql-conf setup usermod: no changes Choose an edition of SQL Server: 1) Evaluation (free, no production use rights, 180-day limit) 2) Developer (free, no production use rights) 3) Express (free) 4) Web (PAID) 5) Standard (PAID) 6) Enterprise (PAID) - CPU Core utilization restricted to 20 physical/40 hyperthreaded 7) Enterprise Core (PAID) - CPU Core utilization up to Operating System Maximum 8) I bought a license through a retail sales channel and have a product key to enter. Details about editions can be found at https://go.microsoft.com/fwlink/?LinkId=2109348&clcid=0x409 Use of PAID editions of this software requires separate licensing through a Microsoft Volume Licensing program. By choosing a PAID edition, you are verifying that you have the appropriate number of licenses in place to install and run this software. Enter your edition(1-8): 3 #这里选择了Express版本 The license terms for this product can be found in /usr/share/doc/mssql-server or downloaded from: https://go.microsoft.com/fwlink/?LinkId=2104294&clcid=0x409 The privacy statement can be viewed at: https://go.microsoft.com/fwlink/?LinkId=853010&clcid=0x409 Do you accept the license terms? [Yes/No]:Yes#输入Yes接受许可条目 Enter the SQL Server system administrator password: #设置SA管理员密码 Confirm the SQL Server system administrator password: Configuring SQL Server... The licensing PID was successfully processed. The new edition is [Express Edition]. ForceFlush is enabled for this instance. ForceFlush feature is enabled for log durability. Created symlink from /etc/systemd/system/multi-user.target.wants/mssql-server.service to /usr/lib/systemd/system/mssql-server.service. Setup has completed successfully. SQL Server is now starting.
添加环境变量
防火墙添加服务
[root@localhost ~]# firewall-cmd --permanent --add-service=mssql success [root@localhost ~]# firewall-cmd --reload success
在客户端连接数据库
安装上面提供的SSMS管理软件,安装完成之后搜索”ssms”,打开该管理软件
内存设置为2G的时候,安装SQL Server2019会出现安装失败,提示内存最少为2000M,所以设置不要低于2G内存,安装还是很简单的。
联系客服