Neptune Process Introduction
Introduction to Configuration Parameters
Detailed process and configuration parameters
- Neptune Process Introduction
- Introduction to Configuration Parameters-system_conf
1 #system Configurations2*SYSTEM3 4MULTICASTADDR =239.255.0.4 5 6# State announcing/Listening multicast address7 8Multicastport =10002 9 Ten # State Multicast listening Port One AStateannounce =1.0 - -# State announcing Interval (inchseconds) the -Loadudpport =20014 - -Shmkey =747 + -Loadannounce =1.0 + A# Workload announcing interval (inchseconds) at -Stateexpire =5.0 - -# State Expiration period (inchSeconds
1 # Global Service Configurations 2 *SERVICE3 [Lookup]4 consistency = Readonly5 Initproc = lookup_init6 Finalproc = lookup_final7 reqresproc = lookup_lookup8 2
- Introduction to Configuration Parameters-server_conf
1 # Server Configurations2*SERVER3INTERFACE =eth14Listenport =83825 # Local Service configurations6*SERVICE7 [Lookup]8Process_mode =09Svc_dll =.. /bin/lookup.soTenLocal_partition =0 OneNum_worker = -
- Detailed process and configuration parameters
- Service Available SubSystem
Process 1/2: Each machine service availability publishing will provide its own services through multiple advertisements to other machines, each machine service availability Directory logs information from other machines to their service names and machine addresses that provide the service to map. Process 3: When a service request is available, the requesting service consumer sends a service request through a local service Access point. Process 4/5:service access point connects service Available SubSystem, obtaining map information for service availability directory configuration Parameters-system_conf:
1 #system Configurations2*SYSTEM3MULTICASTADDR =239.255.0.4#多播地址4Multicastport =10002#多播端口5 #Neptune服务机器之间要配置同一个多播地址和端口, it belongs to the same multicast group6Shmkey =747#共享内存, read-write space for multicast data7Stateannounce =1.0#每1秒钟向多播组发布状态信息 (services, partitions, etc.)8Stateexpire =5.0#每条状态信息5秒钟后过期
- Service load-balance SubSystem
Process 6-11: Each request, the Polling agent randomly picks 3 servers from a viable server and polls their load Index Servers. Returns the node information with the smallest payload to service Access point. Configuration Parameters-system_conf:
1 #system configurations23 *system45 1.0 #每1秒钟更新本机Load信息 67 20014 #主线程监听20014号UDP端口, When there is a load query request for the client, return the native load information
Process 12, 13:service Access Point sends a service request to the specified node for the services Runtime,server provider requests in the queue, the service processes the request, and returns the processing result. Configuration Parameters-system_conf:
1 # Global Service Configurations2 3*SERVICE4 5 #本机每添加一个服务, add a configuration block similar to the following6 7 [Lookup] #服务名8 9Consistency =Readonly #模式 (read only)Ten OneInitproc =lookup_init #初始化函数函数名 (load configuration, data, etc.) A -Finalproc =lookup_final #终结函数函数名 (free memory, etc.) - theReqresproc =lookup_lookup #服务函数函数名 - -Total_partition =2#该服务的数据分区个数
Configuration Parameters-server_conf:
1 # Server Configurations2 3*SERVER4 5INTERFACE =eth1 #网卡接口6 7Listenport =8382#监听服务请求的端口8 9 # Local Service configurationsTen One*SERVICE A - [Lookup] #服务名 - theProcess_mode =0#模式 (multithreaded0, Multi-process1) - -Svc_dll =.. /bin/lookup.so #服务程序所生成的动态链接库的地址 - +Local_partition =0#本地该服务的数据分区编号 - +Num_worker = -Number of #工作线程/processes
1#!/bin/Bash2 3node=$ (uname-n);4 5Root= 'pwd`/..6 7 Echo$root8 9Export neptune_load_port=20014#Load查询请求监听端口Ten OneExport neptune_shm_key=747#共享内存 A -Export neptune_max_qlen= -#队列最大长度 - theExport neptune_logfile= $root/logs/Server_log #日志文件地址 - -Export neptune_sysconffile= $root/conf/system_conf #系统配置文件地址 - +Export neptune_svrconffile= $root/conf/server_conf #服务器配置文件地址 - +Export Neptune_svcconfpath= $root/conf #配置文件夹地址 (used to build the service A at.. /bin/neptuneserver_g &#启动Neptune服务器 The address of a specific profile) - - Echo "$node Neptune started" - -
Neptune the process and parameters of distributed system