貝貝爸爸的程序人生

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

          FastDFS安裝筆記

          Posted on 2012-03-17 16:38 貝貝爸爸 閱讀(767) 評論(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
          主站蜘蛛池模板: 福安市| 上思县| 阿勒泰市| 康乐县| 连平县| 门源| 昆山市| 松滋市| 红安县| 泰和县| 和林格尔县| 南乐县| 乌兰浩特市| 苏州市| 台北县| 茌平县| 锡林浩特市| 横山县| 枞阳县| 防城港市| 康保县| 中江县| 秦安县| 合肥市| 普兰县| 陇西县| 兴安盟| 濉溪县| 新野县| 兴宁市| 花垣县| 虞城县| 郁南县| 四川省| 淮滨县| 鄂托克前旗| 富裕县| 明星| 太白县| 来凤县| 虹口区|