fastdfs 合成jar包

fastdfs 合成jar包

1)用cmd进入项目 目录

E:\>cd fastdfs-client-java-1.27

E:\fastdfs-client-java-1.27>mvn clean install
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building fastdfs-client-java 1.27-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ fastdfs-client-java ---
[INFO]
[INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ fastdfs-client-java ---
[INFO] Using 'UTF-8' encoding to copy filtered resources.
[INFO] Copying 2 resources
[INFO]
[INFO] --- maven-compiler-plugin:3.5.1:compile (default-compile) @ fastdfs-client-java ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 22 source files to E:\fastdfs-client-java-1.27\target\classes
[INFO] /E:/fastdfs-client-java-1.27/src/main/java/org/csource/fastdfs/ClientGlobal.java: 某些输入文件使用了未经检查或不 安全的操作。
[INFO] /E:/fastdfs-client-java-1.27/src/main/java/org/csource/fastdfs/ClientGlobal.java: 有关详细信息, 请使用 -Xlint:unchecked 重新编译。
[INFO]
[INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ fastdfs-client-java ---
[INFO] Not copying test resources
[INFO]
[INFO] --- maven-compiler-plugin:3.5.1:testCompile (default-testCompile) @ fastdfs-client-java ---
[INFO] Not compiling test sources
[INFO]
[INFO] --- maven-surefire-plugin:2.12.4:test (default-test) @ fastdfs-client-java ---
[INFO] Tests are skipped.
[INFO]
[INFO] --- maven-jar-plugin:2.4:jar (default-jar) @ fastdfs-client-java ---
[INFO] Building jar: E:\fastdfs-client-java-1.27\target\fastdfs-client-java-1.27-SNAPSHOT.jar
[INFO]
[INFO] --- maven-install-plugin:2.4:install (default-install) @ fastdfs-client-java ---
[INFO] Installing E:\fastdfs-client-java-1.27\target\fastdfs-client-java-1.27-SNAPSHOT.jar to E:\maven_repo\org\csource\fastdfs-client-java\1.27-SNAPSHOT\fastdfs-client-java-1.27-SNAPSHOT.jar
[INFO] Installing E:\fastdfs-client-java-1.27\pom.xml to E:\maven_repo\org\csource\fastdfs-client-java\1.27-SNAPSHOT\fastdfs-client-java-1.27-SNAPSHOT.pom
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 32.520 s
[INFO] Finished at: 2020-12-19T18:52:15+08:00
[INFO] Final Memory: 17M/142M
[INFO] ------------------------------------------------------------------------

2)启动和停止

[root@localhost etc]# fdfs_trackerd /etc/fdfs/tracker.conf
[root@localhost etc]# fdfs_storaged /etc/fdfs/storage.conf
[root@localhost etc]# ps -ef | grep fdfs
root       3847      1  0 17:47 ?        00:00:00 fdfs_trackerd /etc/fdfs/tracker.conf
root       3864      1 26 17:48 ?        00:00:01 fdfs_storaged /etc/fdfs/storage.conf
root       3874   3603  0 17:48 pts/1    00:00:00 grep --color=auto fdfs
[root@localhost etc]# 

3)配置文件(tracker的ip和端口号)

tracker_server=192.168.179.129:22122

4)1.29版本的得不到trackerClient.getConnection();方法

​ 要换成1.27版本

5)connect to server 192.168.179.129:22122 fail

	### 解决方案

首先查看tracker和storage,nginx都开启了吗,开启之后还要关闭linux的防火墙

关闭防火墙:

[root@localhost ~]# systemctl status firewalld.service 
● firewalld.service - firewalld - dynamic firewall daemon
   Loaded: loaded (/usr/lib/systemd/system/firewalld.service; enabled; vendor preset: enabled)
   Active: active (running) since Sat 2020-12-19 17:03:25 CST; 3h 4min ago
     Docs: man:firewalld(1)
 Main PID: 836 (firewalld)
    Tasks: 2
   CGroup: /system.slice/firewalld.service
           └─836 /usr/bin/python2 -Es /usr/sbin/firewalld --nofork --nopid

Dec 19 17:03:22 localhost.localdomain systemd[1]: Starting firewalld - dynami...
Dec 19 17:03:25 localhost.localdomain systemd[1]: Started firewalld - dynamic...
Dec 19 17:03:26 localhost.localdomain firewalld[836]: WARNING: AllowZoneDrift...
Hint: Some lines were ellipsized, use -l to show in full.
[root@localhost ~]# systemctl stop firewalld.service 
[root@localhost ~]# systemctl status firewalld.service 
● firewalld.service - firewalld - dynamic firewall daemon
   Loaded: loaded (/usr/lib/systemd/system/firewalld.service; enabled; vendor preset: enabled)
   Active: inactive (dead) since Sat 2020-12-19 20:09:32 CST; 3s ago
     Docs: man:firewalld(1)
  Process: 836 ExecStart=/usr/sbin/firewalld --nofork --nopid $FIREWALLD_ARGS (code=exited, status=0/SUCCESS)
 Main PID: 836 (code=exited, status=0/SUCCESS)

Dec 19 17:03:22 localhost.localdomain systemd[1]: Starting firewalld - dynami...
Dec 19 17:03:25 localhost.localdomain systemd[1]: Started firewalld - dynamic...
Dec 19 17:03:26 localhost.localdomain firewalld[836]: WARNING: AllowZoneDrift...
Dec 19 20:09:28 localhost.localdomain systemd[1]: Stopping firewalld - dynami...
Dec 19 20:09:32 localhost

6)查看上传的位置 和文件(opt/fastdfs/storage/files/data/00/00)

7)文件下载,返回0就代表成功,其余一律失败

8)clear清屏

9)检查是否安装mysql

[root@localhost 00]# yum list installed | grep mysql

10)查看安装目录

which mysql

11)卸载mariadbmariadb

[root@localhost mysql]# rpm -e --nodeps mariadb-libs-5.5.68-1.el7.x86_64
[root@localhost mysql]# rpm -qa | grep mariadb
mariadb-5.5.68-1.el7.x86_64
mariadb-libs-5.5.68-1.el7.x86_64
[root@localhost mysql]# rpm -e nodeps mariadb-5.5.68-1.el7.x86_64
error: package nodeps is not installed
[root@localhost mysql]# rpm -e --nodeps mariadb-5.5.68-1.el7.x86_64
[root@localhost mysql]# rpm -qa | grep mariadb
mariadb-libs-5.5.68-1.el7.x86_64
[root@localhost mysql]# rpm -e --nodeps mariadb-libs-5.5.68-1.el7.x86_64
[root@localhost mysql]# 

12)命令

rpm -qa | grep mysql:查看是否安装了mysql
rpm -e --nodeps 文件名:卸载

13)解压缩

[root@localhost mysql]# tar -zxvf mysql-5.7.30-1.el7.x86_64.rpm-bundle.tar 
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值