Linux CentOS 7 安装 微软SQL数据库 Microsoft SQL Server
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 |
yum clean all yum -y update wget https://packages.microsoft.com/config/rhel/7/mssql-server.repo wget https://packages.microsoft.com/config/rhel/7/prod.repo mv *.repo /etc/yum.repos.d/mssql.repo # 安装 yum install -y mssql-server mssql-tools # 配置 /opt/mssql/bin/sqlservr-setup Microsoft(R) SQL Server(R) Setup You can abort setup at anytime by pressing Ctrl-C. Start this program with the --help option for information about running it in unattended mode. The license terms for this product can be downloaded from http://go.microsoft.com/fwlink/?LinkId=746388 and found in /usr/share/doc/mssql-server/LICENSE.TXT. Do you accept the license terms? If so, please type "YES": YES Please enter a password for the system administrator (SA) account: Enter Admin Password Please confirm the password for the system administrator (SA) account: Re Enter Admin Password Setting system administrator (SA) account password... Do you wish to start the SQL Server service now? [y/n]: n You can use sqlservr-setup --start-service to start SQL Server, and sqlservr-setup --enable-service to enable SQL Server to start at boot. Setup completed successfully. Finally, Start the MS SQL Service: # 启动数据库 systemctl start mssql-server systemctl enable mssql-server # 开启防火墙 firewall-cmd --permanent --zone=public --add-port=1433/tcp firewall-cmd --reload # 安装完成 连接数据库 sqlcmd -H 127.0.0.1 -U sa Password: 1> |
求教,以前安装了sqlserver,卸载后,在此安装,启动失败,是不是卸载的不彻底。