当前位置: 首页 > news >正文

企语企业管理系iFair(F23.2_a0)在Debian操作系统中的安装

起因:在安装了F24.8版本后,发现生产用环境和测试、开发用环境还是分开的好。 旧版的用来实验、测试,新版的一步一步小心的配置、使用是比较稳妥的操作。因此,决定在KVM虚拟机上搭建一个F23.2版本的企语系统。

一、 存在的问题

而在安装过程中,发现原来的方法用在Debian12系统中无法成功了。主要原因在于数据库的限制。 特别是 导入最后一个 proc.sql 数据库文件的时候,提醒 无法找到 mysql.proc 。这个东西只有Mysql-5.X系列支持,从8.0版本开始已经不再存在了。

尝试了从源码编译安装mysql到debian12系统中,但总有各种小问题无法顺利运行。 最终方案: Debian9 + Mysql5.6.51(*.deb安装) 。

具体过程参考: 服务社-企语系统-F_air21.8的Debian11安装方法,也叫协同管理系统_企语ifair-CSDN博客

注意,要使用 服务社官方给的 jdk1.7,  如果用jdk1.8 会造成部分项目无法显示等问题

二、Debian9 的安装

需要替换源。 该版本已经没有官方的支持了。

cat /etc/apt/sources.list## 下面是内容deb http://archive.debian.org/debian/ stretch main contrib non-free 
deb-src http://archive.debian.org/debian/ stretch main contrib non-free 
deb http://archive.debian.org/debian-security/ stretch/updates main contrib non-free 
deb-src http://archive.debian.org/debian-security/ stretch/updates main contrib non-free deb http://archive.debian.org/debian/ stretch-backports main contrib non-free

三、 Mysql-5.6.51 安装后的配置

注意: 在安装Mysql过程中设置的 root 密码 是 A123456!  ,后面两个脚本中的该部分文字,请根据你的设定,加以修改!!!

配置文件1: /etc/mysql/mysql.cnf

cat /etc/mysql/my.cnf###  主要配置内容如下:# * IMPORTANT: Additional settings that can override those from this file!
#   The files must end with '.cnf', otherwise they'll be ignored.
#
!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mysql.conf.d/
[client]
default-character-set = utf8mb4[mysql]
default-character-set = utf8mb4
no-auto-rehsah
[mysqld]
character-set-server = utf8mb4
collation-server = utf8mb4_unicode_ci[mysqldump]
quick
max_allowed_packet = 16M[mchk]
key_buffer = 20M
sort_buffer_size = 20M
read_buffer = 2M
write_buffer = 2M[myisamchk]
key_buffer = 20M
sort_buffer_size = 20M
read_buffer = 2M
write_buffer = 2M[mysqlhotcopy]
interactive-timeout[client]
#password   = your_password
port        = 3306
socket      = /var/run/mysqld/mysqld.sock

配置文件2:/etc/mysql/mysql.conf.d/mysqld.cnf

cat /etc/mysql/mysql.conf.d/mysqld.cnf### 主要配置内容如下:# The MySQL  Server configuration file.
#
# For explanations see
# http://dev.mysql.com/doc/mysql/en/server-system-variables.html[mysqld]
pid-file	= /var/run/mysqld/mysqld.pid
socket		= /var/run/mysqld/mysqld.sock
datadir		= /var/lib/mysql
log-error	= /var/log/mysql/error.log
# Disabling symbolic-links is recommended to prevent assorted security risks
symbolic-links=0
myisam_sort_buffer_size = 8M
read_rnd_buffer_size = 512K
read_buffer_size = 256K
net_buffer_length = 8K
sort_buffer_size = 512K
max_allowed_packet = 1M
key_buffer = 16M

四、数据库文件的导入

这一点非顺利,没有波折.  将下列代码保存为 input-mysql.sh 加x权限,运行即可.

#!/bin/bash
mysql -uroot -pA123456! </usr/local/fuwushe/db/stfoa.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_ccb.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_dl.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_dl_dc.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_dl_so.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_dl_so_sale.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_dl_so_stocktake.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_dl_so_sum.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_fcb.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_frm.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/amb.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_scb.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_dl_so_orderproduct.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/biz_dl_so_sale_task.sql
mysql -uroot -pA123456! </usr/local/fuwushe/db/hrm.sql
mysql -uroot -pA123456! mysql </usr/local/fuwushe/db/proc.sql

五、 Tomcat app的配置文件的信息修改

将下列代码保存为 Change-yomcat.sh 加x权限,运行即可

#!/bin/bashsed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/cc/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/cc/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/oa/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/oa/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/hr/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/hr/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/tc/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/tc/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa#' /usr/local/fuwushe/tomcat/webapps/pb/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/pb/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/fm/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/fm/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/crm/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/crm/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/dlm/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/dlm/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/dls/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/dls/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/dlmpda/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/dlmpda/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/dlspda/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/dlspda/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/ccb/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/ccb/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/scb/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/scb/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.url=jdbc:mysql://localhost:13306/stfoa#hibernate.connection.url=jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/frm/WEB-INF/classes/hibernate.propertiessed -i 's#hibernate.connection.password=3.1415926#hibernate.connection.password=A123456!\n#' /usr/local/fuwushe/tomcat/webapps/frm/WEB-INF/classes/hibernate.propertiessed -i 's#sum.url = jdbc:mysql://localhost:13306/biz_dl_so_sum#sum.url = jdbc:mysql://localhost:3306/biz_dl_so_sum\n#' /usr/local/fuwushe/tomcat/webapps/dls/WEB-INF/classes/conf/sum.propertiessed -i 's#sum.password = 3.1415926#sum.password = A123456!\n#' /usr/local/fuwushe/tomcat/webapps/dls/WEB-INF/classes/conf/sum.propertiessed -i 's#slave.url = jdbc:mysql://localhost:13306/stfoa#slave.url = jdbc:mysql://localhost:3306/stfoa\n#' /usr/local/fuwushe/tomcat/webapps/dlm/WEB-INF/classes/conf/slave.propertiessed -i 's#slave.password = 3.1415926#slave.password = A123456!\n#' /usr/local/fuwushe/tomcat/webapps/dlm/WEB-INF/classes/conf/slave.properties

六、 启动Tomcat 中的app

cd /usr/local/fuwushe/tomcat/bin
chmod + ./*.sh
./startup.sh

默认使用的是 8080 端口。 可用frp 映射到公网ip 的vps上,用域名访问。

相关教程: Nginx与frp结合实现局域网和公网的双重https服务_nginx frp-CSDN博客


http://www.mrgr.cn/news/90526.html

相关文章:

  • C++基础知识学习记录—补充
  • QSPI总线设备驱动开发详解
  • tenda路由器WriteFacMac存在远程命令执行漏洞(CVE-2024-10697)
  • DeepSeek提问技巧总结
  • 23、深度学习-自学之路-激活函数relu、tanh、sigmoid、softmax函数的正向传播和反向梯度。
  • 关于“i18n“在vue中的使用
  • C++基础学习记录—this指针和const关键字
  • mysql8.0使用MGR实现高可用
  • Linux内核 - 非仿生机器人之感知主控系统(协议栈)
  • android studio下载安装汉化-Flutter安装
  • 并发编程---多线程不安全示例以及解决,多线程创建方式
  • 【嵌入式Linux应用开发基础】read函数与write函数
  • 【工业安全】-CVE-2019-17621-D-Link Dir-859L 路由器远程代码执行漏洞
  • 自然语言处理NLP入门 -- 第三节词袋模型与 TF-IDF
  • haproxy+nginx负载均衡实验
  • 解锁大语言模型潜能:KITE 提示词框架全解析
  • DeepSeek-V3 技术报告
  • 设计模式全解(含代码实例)
  • 【科技革命】颠覆性力量与社会伦理的再平衡
  • web前端布局--使用element中的Container布局容器
  • C++基础学习记录—this指针
  • c#中“事件-event”的经典示例与理解
  • c++ 多线程知识汇总
  • 开发一个类似小红书的社交电商平台需要综合技术、产品和运营能力
  • 自然语言处理NLP入门 -- 第一节基础概念
  • 黑马Mistral Le chat逆转deepseek