fastdfs java client 依旧无法上传。 望得到 大家的帮助 ! 在此先感谢大家

发布于 2022-09-11 07:11:42 字数 5340 浏览 13 评论 1

本帖最后由 sezelee 于 2010-05-08 14:30 编辑

fastdfs java 无法访问
fastdfs 折腾了好久,java client 依旧无法 上传。  望 得到 大家的帮助!  在此先感谢大家!!

我搭建的环境
tracker   192.168.1.3 22122   linux
storage  192.168.1.4 23000   linux

  192.168.1.2   windows  -----java client

说明 :  原来使用 FastDFS_v1.21.tar.gz/fastdfs_client_v1.12.jar
            后来怀疑 1.21   和    1.12  版本不匹配

            现在改成  FastDFS_v1.12.tar.gz/fastdfs_client_v1.12.jar

问题: fastdfs_client_v1.12.jar 中  fdfs_client.conf 文件
          network_timeout = 20
          charset = ISO8859-1
          http.tracker_http_port = 8080
          http.anti_steal_token = no
          http.secret_key = FastDFS1234567890

          tracker_server = 192.168.1.3:22122

FastDFS_v1.12.tar.gz 还没有  http  的支持吧??????
那么 fastdfs_client_v1.12.jar 版本中  fdfs_client.conf 文件 中 http 的配置有什么意义吗?

还是说使用  FastDFS_v1.21.tar.gz/fastdfs_client_v1.12.jar 的搭配也是没有任何问题???

         
//下面是 使用  fdfs_test 测试 的 结果  ---------------正常的吧!!!!!
[root@localhost ~]#  /usr/local/bin/fdfs_test /usr/local/bin/conf/storage.conf upload /usr/include/wait.h
This is FastDFS client test program v1.12

Copyright (C) 2008, Happy Fish / YuQing

FastDFS may be copied only under the terms of the GNU General
Public License V3, which may be found in the FastDFS source kit.
Please visit the FastDFS Home Page http://www.csource.org/
for more detail.

group_name=group1, ip_addr=192.168.1.4, port=23000
group_name=group1, remote_filename=M00/00/00/BAGowEvlY9gAAAAWORr6hw3205.h
file timestamp=1273324504
file size=22

当使用 java client 访问 的时候

trackerd.log
[2010-05-07 03:18:45] INFO - FastDFS v1.12, base_path=/home/yuqing/fastdfs, network_timeout=60s, port=22122, bind_addr=, max_connections=256, store_lookup=0, store_group=, store_server=0, store_path=0, reserved_storage_space=4096MB, download_server=0, allow_ip_count=-1
[2010-05-07 03:25:13] ERROR - file: tracker_service.c, line: 2022, client ip: 192.168.1.2, recv data fail, errno: 104, error info: Connection reset by peer
[2010-05-07 03:46:59] ERROR - file: tracker_service.c, line: 2022, client ip: 192.168.1.2, recv data fail, errno: 104, error info: Connection reset by peer
[2010-05-07 04:03:57] ERROR - file: tracker_service.c, line: 2022, client ip: 192.168.1.2, recv data fail, errno: 104, error info: Connection reset by peer

storaged.log
[2010-05-06 15:40:29] ERROR - file: storage_service.c, line: 845, client ip: 192.168.1.2, pkg length is not correct, invalid file bytes: 14
[2010-05-06 15:48:27] ERROR - file: storage_service.c, line: 845, client ip: 192.168.1.2, pkg length is not correct, invalid file bytes: 14

storage monitor           //是否和 total storage    free storage  有关系
        Host 1:
                ip_addr = 192.168.1.4  ACTIVE
                total storage = 17GB
                free storage = 13GB
                total_upload_count = 1
                success_upload_count = 1
                total_set_meta_count = 0
                success_set_meta_count = 0
                total_delete_count = 0
                success_delete_count = 0
                total_download_count = 0
                success_download_count = 0
                total_get_meta_count = 0
                success_get_meta_count = 0
                last_source_update = 2010-05-08 21:20:31
                last_sync_update = 1970-01-01 08:00:00
                last_synced_timestamp= 2010-05-06 14:59:19

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

当爱已成负担 2022-09-15 21:56:12

回复 1# sezelee

client版本和server端版本不匹配造成的。
摘录一下Java client的HISTORY:
Version 1.12  2009-11-27
  * support uploading slave file
  * file ext name change from 5 to 6, you must upgrade your FastDFS server
    to V1.23 or higher version

java client V1.12需要server端版本大于等于V1.23。
LZ升级server端版本到最新版本V1.27,即可解决这个问题。

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文