# the base path to store data and log files
base_path=/home/wl/fastdfs/storage
# store_path#, based 0, if store_path0 not exists, it's value is base_path
# the paths must be exist
store_path0=/home/wl/fastdfs/storage
#store_path1=/home/yuqing/fastdfs2
# tracker_server can ocur more than once, and tracker_server format is
# "host:port", host can be hostname or ip address
tracker_server=192.168.10.229:22122
root@ubuntu:~# vi /etc/fdfs/client.conf
# the base path to store log files
base_path=/home/wl/fastdfs/client
# tracker_server can ocur more than once, and tracker_server format is
# "host:port", host can be hostname or ip address
tracker_server=192.168.10.229:22122
root@ubuntu:~# /usr/local/bin/fdfs_test /etc/fdfs/client.conf upload /usr/fastdfs/FastDFS/conf/anti-steal.jpg
This is FastDFS client test program v5.03
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.
[2016-10-30 21:29:59] DEBUG - base_path=/home/wl/fastdfs/client, connect_timeout=30, network_timeout=60, tracker_server_count=1, anti_steal_token=0, anti_steal_secret_key length=0, use_connection_pool=0, g_connection_pool_max_idle_time=3600s, use_storage_id=0, storage server id count: 0
tracker_query_storage_store_list_without_group:
server 1. group_name=, ip_addr=192.168.10.229, port=23000
group_name=group1, ip_addr=192.168.10.229, port=23000
storage_upload_by_filename
group_name=group1, remote_filename=M00/00/00/wKgK5VgV9deACTQtAABdrZgsqUU607.jpg
source ip address: 192.168.10.229
file timestamp=2016-10-30 21:29:59
file size=23981
file crc32=2553063749
example file url: http://192.168.10.229/group1/M00/00/00/wKgK5VgV9deACTQtAABdrZgsqUU607.jpg
storage_upload_slave_by_filename
group_name=group1, remote_filename=M00/00/00/wKgK5VgV9deACTQtAABdrZgsqUU607_big.jpg
source ip address: 192.168.10.229
file timestamp=2016-10-30 21:29:59
file size=23981
file crc32=2553063749
example file url: http://192.168.10.229/group1/M00/00/00/wKgK5VgV9deACTQtAABdrZgsqUU607_big.jpg
root@ubuntu:~#
图片目录
root@ubuntu:/home/wl/fastdfs/storage/data/00/00# ll
total 64
drwxr-xr-x 2 root root 4096 Oct 30 21:29 ./
drwxr-xr-x 258 root root 4096 Oct 30 15:58 ../
-rw-r--r-- 1 root root 23981 Oct 30 21:29 wKgK5VgV9deACTQtAABdrZgsqUU607.jpg
-rw-r--r-- 1 root root 49 Oct 30 21:29 wKgK5VgV9deACTQtAABdrZgsqUU607.jpg-m
-rw-r--r-- 1 root root 23981 Oct 30 21:29 wKgK5VgV9deACTQtAABdrZgsqUU607_big.jpg
-rw-r--r-- 1 root root 49 Oct 30 21:29 wKgK5VgV9deACTQtAABdrZgsqUU607_big.jpg-m
root@ubuntu:/home/wl/fastdfs/storage/data/00/00#
root@ubuntu:~# vi /etc/fdfs/mod_fastdfs.conf
# the base path to store log files
base_path=/tmp
# FastDFS tracker_server can ocur more than once, and tracker_server format is
# "host:port", host can be hostname or ip address
# valid only when load_fdfs_parameters_from_tracker is true
tracker_server=192.168.10.229:22122
# if the url / uri including the group name
# set to false when uri like /M00/00/00/xxx
# set to true when uri like ${group_name}/M00/00/00/xxx, such as group1/M00/xxx
# default value is false
url_have_group_name = true
# store_path#, based 0, if store_path0 not exists, it's value is base_path
# the paths must be exist
# must same as storage.conf
store_path0=/home/wl/fastdfs/storage
#store_path1=/home/yuqing/fastdfs1
root@ubuntu:~# /usr/local/bin/fdfs_test /etc/fdfs/client.conf upload /usr/fastdfs/FastDFS/conf/anti-steal.jpg
This is FastDFS client test program v5.03
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.
[2016-10-31 00:30:00] DEBUG - base_path=/home/wl/fastdfs/client, connect_timeout=30, network_timeout=60, tracker_server_count=1, anti_steal_token=0, anti_steal_secret_key length=0, use_connection_pool=0, g_connection_pool_max_idle_time=3600s, use_storage_id=0, storage server id count: 0
tracker_query_storage_store_list_without_group:
server 1. group_name=, ip_addr=192.168.10.229, port=23000
group_name=group1, ip_addr=192.168.10.229, port=23000
storage_upload_by_filename
group_name=group1, remote_filename=M00/00/00/wKgK5VgWIAiAEiODAABdrZgsqUU375.jpg
source ip address: 192.168.10.229
file timestamp=2016-10-31 00:30:00
file size=23981
file crc32=2553063749
example file url: http://192.168.10.229/group1/M00/00/00/wKgK5VgWIAiAEiODAABdrZgsqUU375.jpg
storage_upload_slave_by_filename
group_name=group1, remote_filename=M00/00/00/wKgK5VgWIAiAEiODAABdrZgsqUU375_big.jpg
source ip address: 192.168.10.229
file timestamp=2016-10-31 00:30:00
file size=23981
file crc32=2553063749
example file url: http://192.168.10.229/group1/M00/00/00/wKgK5VgWIAiAEiODAABdrZgsqUU375_big.jpg
root@ubuntu:~#