FashDFS development environment and configuration


Advertisements


Reference resources (after the regular meeting to write)

0 \ in windows eclipse compiled under the first project to build a hello, and to compile, then FastDfs file directory to the src directory copy
a: set the environment variable CYGWIN_HOME
b: the properties of the c / c + + build the build command to set $ (CYGWIN_HOME) / bin / sh.exe / cygdrive / u / programe / testproject / test / src / FastDFS / make.sh
1 \ install basic configuration see
Mainly emphasized the path, port number, etc.
2 \ If you want to support the http Server
Configuration
tracker.conf, the # # include http.conf into # include http.conf
storage.conf, the # # include http.conf into # include http.conf
Modify mash.sh the # WITH_HTTPD = 1 into WITH_HTTPD = 1 (important)
Installation libEvent Library
1. # Tar xzvf libevent-2.0.4-alpha.tar.gz
2. # Cd libevent-2.0.4
3. #. / Configure - prefix = / home / super / installLIB
4. # Make
5. # Make install
3 \ Executive
. / Make.sh
. / Make.sh install (if you want to uninstall,. / Make.sh clean)

May occur
error while loading shared libraries: libevent_core.so.3: cannot open shared object file: No such file or directory

Execution
ln-s / home/super/installLIB/lib/libevent_core.so.3 / lib/libevent_core.so.3

4 \ Note operation see the log file
trackerd.log
storaged.log
The specific content they are
trackerd.log
[2010-05-03 06:47:26] INFO - FastDFS v1.27, base_path = / fastdfs / FastDFS, network_timeout = 60s, port = 22122, bind_addr =, max_connections = 256, store_lookup = 2, store_group =, store_server = 0, store_path = 0, reserved_storage_space = 1024MB, download_server = 0, allow_ip_count =- 1, sync_log_buff_interval = 10s, check_active_interval = 120s, thread_stack_size = 64 KB, storage_ip_changed_auto_adjust = 1
[2010-05-03 06:47:26] INFO - HTTP supported: server_port = 8080, default_content_type = application / octet-stream, anti_steal_token = 0, token_ttl = 0s, anti_steal_secret_key length = 0, token_check_fail content_type =, token_check_fail buff length = 0, check_active_interval = 30, check_active_type = tcp, check_active_uri = / status.html
storaged.log
[2010-05-03 06:47:29] INFO - FastDFS v1.27, base_path = / fastdfs / FastDFS, store_path_count = 1, subdir_count_per_path = 256, group_name = group1, network_timeout = 60s, port = 23000, bind_addr =, client_bind = 1, max_connections = 256, heart_beat_interval = 30s, stat_report_interval = 60s, tracker_server_count = 1, sync_wait_msec = 200ms, sync_interval = 0ms, sync_start_time = 00:00, sync_end_time: 23:59, allow_ip_count =- 1, file_distribute_path_mode = 0, file_distribute_rotate_count = 100, fsync_after_written_bytes = 0, sync_log_buff_interval = 10s, sync_binlog_buff_interval = 60s, thread_stack_size = 512 KB, upload_priority = 10, if_alias_prefix =, check_file_duplicate = 0, FDHT group count = 0, FDHT server count = 0, FDHT key_namespace =, FDHT keep_alive = 0 , HTTP server port = 8888, domain name =
[2010-05-03 06:47:29] INFO - HTTP supported: server_port = 8888, http_trunk_size = 262144, default_content_type = application / octet-stream, anti_steal_token = 0, token_ttl = 0s, anti_steal_secret_key length = 0, token_check_fail content_type =, token_check_fail buff length = 0
[2010-05-03 06:47:30] INFO - file: storage_param_getter.c, line: 225, storage_ip_changed_auto_adjust = 1
[2010-05-03 06:47:31] INFO - file: tracker_client_thread.c, line: 257, successfully connect to tracker server 192.168.247.128:22122, as a tracker client, my ip is 192.168.247.128

5 \ upload pictures later (see install file)
Return http://192.168.247.128:8080/group1/M00/00/00/wKj3gEvd84oAAAAAAABdrVV-uEs424_big.jpg
Ie to see in this picture to perform the normal operation http://192.168.247.128:8080/group1/M00/00/00/wKj3gEvd84oAAAAAAABdrVV-uEs424_big.jpg

6
View port
lsof-i: port
lsof-i: 8080
Show Results
[Root @ linux2 bin] # lsof-i: 8080
COMMAND PID USER FD TYPE DEVICE SIZE NODE NAME
fdfs_trac 4742 root 10u IPv4 14679 TCP *: webcache (LISTEN)

[Root @ call root] # netstat-anp
Show Results
Proto Recv-Q Send-Q Local Address Foreign Address State PID / Program name
tcp 0 0 127.0.0.1:2208 0.0.0.0: * LISTEN 2129/hpiod
tcp 0 0 0.0.0.0:835 0.0.0.0: * LISTEN 1925/rpc.statd
tcp 0 0 0.0.0.0:22122 0.0.0.0: * LISTEN 4742/fdfs_trackerd
tcp 0 0 0.0.0.0:111 0.0.0.0: * LISTEN 1891/portmap
tcp 0 0 0.0.0.0:8080 0.0.0.0: * LISTEN 4742/fdfs_trackerd
tcp 0 0 127.0.0.1:631 0.0.0.0: * LISTEN 2146/cupsd
tcp 0 0 0.0.0.0:8888 0.0.0.0: * LISTEN 5006/fdfs_storaged
tcp 0 0 0.0.0.0:23000 0.0.0.0: * LISTEN 5006/fdfs_storaged
tcp 0 0 127.0.0.1:25 0.0.0.0: * LISTEN 2192/sendmail: acce
tcp 0 0 127.0.0.1:2207 0.0.0.0: * LISTEN 2134/python
tcp 0 0 192.168.247.128:22122 192.168.247.128:48836 ESTABLISHED 4742/fdfs_trackerd
tcp 0 0 192.168.247.128:48836 192.168.247.128:22122 ESTABLISHED 5006/fdfs_storaged
tcp 0 0 192.168.247.128:57448 192.168.247.128:8888 TIME_WAIT -
tcp 0 0 192.168.247.128:57447 192.168.247.128:8888 TIME_WAIT -
tcp 0 0::: 22::: * LISTEN 2160/sshd
tcp 0 0:: ffff: 192.168.247.128:22:: ffff: 192.168.247.1:1038 ESTABLISHED 2754 / 0
tcp 0 0:: ffff: 192.168.247.128:22:: ffff: 192.168.247.1:1051 ESTABLISHED 3358 / 1
tcp 0 48:: ffff: 192.168.247.128:22:: ffff: 192.168.247.1:1101 ESTABLISHED 4149 / 2
udp 0 0 0.0.0.0:32768 0.0.0.0: * 2317/avahi-daemon:
udp 0 0 0.0.0.0:829 0.0.0.0: * 1925/rpc.statd
udp 0 0 0.0.0.0:832 0.0.0.0: * 1925/rpc.statd
udp 0 0 0.0.0.0:68 0.0.0.0: * 1748/dhclient
udp 0 0 0.0.0.0:5353 0.0.0.0: * 2317/avahi-daemon:
udp 0 0 0.0.0.0:111 0.0.0.0: * 1891/portmap
udp 0 0 0.0.0.0:631 0.0.0.0: * 2146/cupsd
udp 0 0::: 32769::: * 2317/avahi-daemon:
udp 0 0::: 5353::: * 2317/avahi-daemon:
Active UNIX domain sockets (servers and established)
Proto RefCnt Flags Type State I-Node PID / Program name Path
unix 2 [ACC] STREAM LISTENING 11230 2723/gam_server @ / tmp/fam-root-
unix 25 [] DGRAM 6411 1847/syslogd / dev / log
unix 2 [ACC] STREAM LISTENING 10819 2679/scim-launcher / tmp / scim-socket-frontend-root
unix 2 [ACC] STREAM LISTENING 11363 2741/mapping-daemon / tmp / mapping-root

7 \
wget-S file_url
wget-S http://192.168.247.128:8888/group1/M00/00/00/wKj3gEvd84oAAAAAAABdrVV-uEs424_big.jpg available documents, and to save the file in the current path

8 \
>> 3.store_path the role of the parameters in the same GROUP store_path directory number to be the same size, but the directory name can be different.

>> 4. Can directly access it? My opinion can not?
Can be used with apache. Installed in the storage server apache, the configuration DocumentRoot to $ (base_path) / data directory.
Some people asked similar questions, see: http://linux.chinaunix.net/bbs/thread-1062825-1-1.html

2. Other The 10 computers. May be achieved using rsync. As if there is no need to use fast-dfs it!
  • del.icio.us
  • StumbleUpon
  • Digg
  • TwitThis
  • Mixx
  • Technorati
  • Facebook
  • NewsVine
  • Reddit
  • Google
  • LinkedIn
  • YahooMyWeb

Related Posts of FashDFS development environment and configuration

  • An essential reference resource list of Java

    Since the Java platform since 1995 as a whole began to introduce programming community, and its development has gone far beyond the early Java experts and those who promote the idea of "applet ubiquitous" of that vision. In contrast, Java emerge

  • Ajax Portal

    The first test procedure: <html> <title>Full use XMLHttpRequest to load the document example </title> <head> <script type='text/javascript'> var req=null; var console=null; var READY_STATE_UNINITIALIZED=0; var READY_STATE_LOA

  • ror development environment to build

    Ror about the development environment set up, records are as follows. 1. Netbeans6.5 installation download netbeans6.5 address http://zh-cn.netbeans.org/download/6.5/ml/ Ruby can download a separate version that only around 50M. II. Ruby set up the e ...

  • About rails install mysql driver error problem

    My local wamp server using one of the key package, only used mysql functions, today in the use of rake db: migrate when First reported a month can not be implemented, the next inquiry and found no mysql installed a gem, to install gem install mysql i ...

  • In the Linux platform to install and configure Ruby on Rails Detailed

    ruby on rails recommend the production environment is running Linux / FreeBSD / Unix, or Unix family of operating systems, using lighttpd + FCGI solution. The following will be my Linux operating system, lighttpd + FCGI, MySQL database as an example, comp

  • ActiveMQ practice the road (four) ActiveMQ 4.x + JBoss 4.x MDP actual articles

    Keyword: ActiveMQ ActiveMQ practice the road (four) ActiveMQ 4.x + JBoss 4.x MDP actual articles At <<ActiveMQ Practice ( Three ) ActiveMQ 4.x +JBoss 4.x Consolidating articles >> which we compare in detail the ActiveMQ with JBoss integration

  • extjs development environment set up and practice

    1, download and extract the extjs 2, download eclipse and Eclipse AJAX Toolkit Framework (ATF) I have been accustomed to using eclipse as a development environment, a variety of open-source plugin so that eclipse has all-around performance, operating effi

  • log4j easy application in java

    JAVA development, frequently used the log output, in a so-called most of the software company will have its own set of configuration style, re-read the configuration file to initialize property of the log, it will be good, but sometimes may not need to fu

  • In the Spring to configure Service

    JTA in Spring Development Environment: JDK1.5 (sun) + Myeclipse6.0 + Tomcat5.5 + ant 1.7.1 + MySql5.0.4 Framework version: JSF1.2 (sun) + hibernate3.3.1.GA + spring2.5.6 JTA (Java Transaction API) Only supports the standard EJB Persistence (JTA) transacti

  • Hibernate secondary cache

    Hibernate cache: 2-bit cache, also known as process-level cache or SessionFactory level cache, secondary cache can be shared by all of the session Cache configuration and the use of: Will echcache.xml (the document code in hibernate package directory ...

blog comments powered by Disqus
Recent
Recent Entries
Tag Cloud
Random Entries