貝貝爸爸的程序人生

          關注Seam、BPM
          posts - 23, comments - 10, trackbacks - 0, articles - 32
            BlogJava :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理

          FastDFS安裝筆記

          Posted on 2012-03-17 16:38 貝貝爸爸 閱讀(773) 評論(0)  編輯  收藏 所屬分類: 程序人生
          系統環境
          CentOS6.2
          #step 1. download libevent https://github.com/downloads/libevent/libevent/libevent-2.0.17-stable.tar.gz
          $ ./configure
          $ make
          $ make verify   # (optional)
          $ sudo make install
          $ln -s /usr/local/lib/libevent-2.0.so.5 /usr/lib64/libevent-2.0.so.5
          #step 2. download FastDFS source package and unpack it,
          $ ./make.sh
          $ ./make.sh install
          #step 3. edit/modify the config file of tracker and storage
          #step 3.1.
          $ vim /etc/fdfs/tracker.conf
          ## base_path=??
          ## reserved_storage_space = 1GB
          #step 3.2
          $ vim /etc/fdfs/storage.conf
          ## base_path=/home/yuan/fastdfs/storage
          ## path(disk or mount point) count, default value is 1
          ## store_path_count=1
          ## store_path#, based 0, if store_path0 not exists, it's value is base_path
          ## the paths must be exist
          ## store_path0=/home/yuan/fastdfs0
          ## tracker_server=host:port
          #step 4 cp the start shell into /etc/init.d
          $ cd FastDFS
          $ cp init.d/fdfs_trackerd /etc/init.d
          $ cp init.d/fdfs_storaged /etc/init.d
          #step 5 mkdir the trackerd base path and storaged base path
          $ mkdir /home/yuan/fastdfs
          $ mkdir /home/yuan/fastdfs0
          #step 6 start trackerd service
          $/sbin/service fdfs_trackerd start
          ###$/sbin/service fdfs_trackerd status
          ###$fdfs_trackerd (pid 11441) is running...
          #step 7 start storaged service
          $/sbin/service fdfs_storaged start
          ###$/sbin/service fdfs_storaged status
          ###$fdfs_storaged (pid 11553) is running...
          #step 8. run test program
          #step 8.1. vim /etc/fdfs/client.conf
          ###base_path=/home/yuan/fastdfs
          ###tracker_server=192.168.0.197:22122
          #step 8.2 run test program
          $/usr/local/bin/fdfs_test /etc/fdfs/client.conf upload /usr/include/stdlib.h
          #step 9 monitor fdfs
          $/usr/local/bin/fdfs_monitor /etc/fdfs/client.conf
          主站蜘蛛池模板: 岳阳县| 邳州市| 黄大仙区| 岑巩县| 卢龙县| 建德市| 乐安县| 合川市| 西乌| 邯郸市| 济阳县| 广东省| 彝良县| 西安市| 玛多县| 左权县| 阿巴嘎旗| 延庆县| 蓝田县| 兴安县| 天长市| 高淳县| 福海县| 黔江区| 江山市| 漾濞| 博罗县| 车致| 苍梧县| 大港区| 日照市| 庆阳市| 新乡县| 乳源| 调兵山市| 吉首市| 岗巴县| 太保市| 诸暨市| 屏南县| 盐城市|