网站建设与管理常用,凡客诚品网站,wordpress是什么程序,福州企业如何建网站国产服务器安装软件简单记录(银河麒麟服务器版V10FT2000) 1、 远程工具#xff0c;向日葵安装包问麒麟软件客服要的#xff0c;todesk软件包是从官网下载的 1.1 向日葵 安装命令 rpm -ivh sunloginclient-10.0.2-24779.aarch64.rpm 安装输出信息#xff0c;表明是开机自启FT2000) 1、 远程工具向日葵安装包问麒麟软件客服要的todesk软件包是从官网下载的 1.1 向日葵 安装命令 rpm -ivh sunloginclient-10.0.2-24779.aarch64.rpm 安装输出信息表明是开机自启但是使用过程中并不会开机自启。应该有bug Created symlink /etc/systemd/system/multi-user.target.wants/runsunloginclient.service → /etc/systemd/system/runsunloginclient.service 1.2 todesk 官网地址 https://www.todesk.com/linux.html 安装命令 rpm -ivh todesk-v4.3.1.0-arm64.rpm 这个开机自启管用 Created symlink /etc/systemd/system/multi-user.target.wants/todeskd.service → /etc/systemd/system/todeskd.service 1.3 tigervnc 系统中自带tigervnc可以在局域网与windows系统之间的相互远程控制 软件下载地址 https://sourceforge.net/projects/tigervnc/files/stable/1.12.0/ 2、安装redis(4.0.11) yum install redis systemctl status redis systemctl start redis systemctl stop redis systemctl enable redis Created symlink /etc/systemd/system/multi-user.target.wants/redis.service → /usr/lib/systemd/system/redis.service. 配置文件 /etc/redis.conf 如果想让其他机器访问 protected-mode no # 由yes改为no bind 127.0.0.1 # 注释掉 requirepass foobared # 默认注释了可以设置密码 3、安装nginx(1.16.1) yum install nginx systemctl status nginx systemctl start nginx systemctl stop nginx systemctl enable nginx Created symlink /etc/systemd/system/multi-user.target.wants/nginx.service → /usr/lib/systemd/system/nginx.service. 配置文件 /etc/nginx/nginx.conf conf.d和default.d文件夹为空 主要编辑nginx.conf就可以了 4、安装tomcat(tomcat9.0.10) yum install tomcat systemctl status tomcat systemctl start tomcat systemctl stop tomcat systemctl enable tomcat Created symlink /etc/systemd/system/multi-user.target.wants/tomcat.service → /usr/lib/systemd/system/tomcat.service. 配置文件 /etc/tomcat/server.xml webapp路径 /var/lib/tomcat/webapps 运行报错加一个secretRequired““属性 Connector protocol“AJP/1.3” address”::1” port“8009” redirectPort“8443” secretRequired“”/ 5、卸载mariadb(卸载后系统出现了一些问题。激活的系统显示未激活、中文输入法消失可能依赖卸载多了。重装了系统使用了自带的maridb,参考9) 服务器中默认安装有mariadb10.3.9 ①systemctl disable mariadb ②yum remove mariadb 卸载mariadb ③yum list installed | grep mariadb 发现还有mariadb-connector-c.aarch64 yum remove mariadb-connector-c.aarch64 ④rm -rf /etc/my.cnf 已经没有了 ⑤rm -rf $(find / -name mysql) 删除所有包含mysql的文件夹 /var/lib/pcp/config/pmlogconf/mysql /var/lib/selinux/targeted/active/modules/100/mysql /var/lib/selinux/ukmcs/active/modules/100/mysql /usr/share/bash-completion/completions/mysql ⑥reboot 6、安装mysql8.0 wget https://repo.mysql.com//mysql80-community-release-el7-7.noarch.rpm rpm -Uvh mysql80-community-release-el7-2.noarch.rpm yum repolist all | grep mysql yum install mysql-community-server 配置文件 /etc/my.cnf /etc/my.cnf.d(里面没有文件) default-authentication-plugin port lower_case_table_names sql_mode 进行设置 systemctl status mysqld systemctl start mysqld 查找临时密码 cat /var/log/mysqld.log | grep password alter user ‘root’‘localhost’ identified by ‘1234’; flush privileges; update user set host‘%’ where user‘root’; 使用其他地方的客户端连接 7、关闭防火墙(测试连接redis、mysql时需要关闭防火墙) systemctl stop firewalld 开启防火墙 systemctl start firewalld 为了调试方便直接关掉了firewall,生产环境只需要开启特定几个端口即可 8、设置数据目录权限 777 chmode 777 /data 9、使用mariadb数据库 版本10.3.9 配置文件 /etc/my.cnf.d/mariadb-server.cnf # 只配置当前版本的mariadb # This group is only read by MariaDB-10.3 servers. # If you use the same .cnf file for MariaDB of different versions, # use this group for options that older servers don’t understand [mariadb-10.3] # 端口号 port 3376 #lower_case_table_names0 表名存储为给定的大小和比较是区分大小写的 #lower_case_table_names1 表名存储在磁盘是小写的但是比较的时候是不区分大小写 #lower_case_table_names2 表名存储为给定的大小写但是比较的时候是小写的 ## 默认值是0,为了与开发环境兼容这里修改成了1 lower_case_table_names1 #默认有更多的限制为了与开发环境兼容做了调整 sql_mode “STRICT_TRANS_TABLES,NO_ENGINE_SUBSTITUTION” 查看状态 systemctl status mariadb 启动 systemctl start mariadb 停止 systemctl stop mariadb 设置开机启动 systemctl enable mariadb 设置开机启动输出的信息 Created symlink /etc/systemd/system/mysql.service → /usr/lib/systemd/system/mariadb.service. Created symlink /etc/systemd/system/mysqld.service → /usr/lib/systemd/system/mariadb.service. Created symlink /etc/systemd/system/multi-user.target.wants/mariadb.service → /usr/lib/systemd/system/mariadb.service 禁止开机启动 systemctl disable mariadb 禁止开机启动输出的信息 Removed /etc/systemd/system/multi-user.target.wants/mariadb.service. Removed /etc/systemd/system/mysql.service. Removed /etc/systemd/system/mysqld.service. 10、项目中做的变更 !-- Mariadb驱动 --dependencygroupIdorg.mariadb.jdbc/groupIdartifactIdmariadb-java-client/artifactIdscoperuntime/scope/dependency配置文件 driverClassName: org.mariadb.jdbc.Driver url: jdbc:mysql://127.0.0.1:3376/file_system?serverTimezoneGMT%2B8useUnicodetruecharacterEncodingUTF-8 username: root password: 1234 11、 程序服务器部署后无法连接到数据库 程序部署到本机使用root用户连接不上mariadb数据库,发现user表中有好几个root用户其中Host为localhost的被我改成了%并设置了密码其他的密码为空。远程连接、服务器本地命令连接都可以就是运行程序无法连接。后采取了两个措施。 1、新建了一个其他用户名可以连接数据库了 2、因为url中使用的ip是127.0.0.1,把user表中host是127.0.0.1的root用户密码设置为配置文件对应的密码这样也可以连接了。 3、设置密码的时候甭管Host是什么统一用户名的设置一样的密码。这样它内部怎么匹配应该都能登录了吧。 小尾巴~~ 只要有积累就会有进步