zookeeper 한 기계가 세 대의 zookeeper를 가동하는 동시에 유사한 조작kafka

0. 시스템 환경 구성

0.1
 hosts, ip hostname , :
vi /etc/hosts
192.168.68.1 b1
0.2
 limits
vi /etc/security/limits.conf
 

# End of file
#
   * soft nofile 500000
   * hard nofile 500000
   * soft nproc 65535
   * hard nproc 65535

1. 목표

 Linux zookeeper , kafka, 。

2.linux 시스템 구성

Red Hat Enterprise Linux Server release 6.4 (Santiago)

cpu :
  processor : 0
vendor_id   : GenuineIntel
cpu family  : 6
model       : 58
model name  : Intel(R) Core(TM) i5-3230M CPU @ 2.60GHz
stepping    : 9
cpu MHz     : 2594.121
cache size  : 3072 KB
fpu     : yes
fpu_exception   : yes
cpuid level : 13
wp      : yes
flags       : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts mmx fxsr sse sse2 ss syscall nx rdtscp lm constant_tsc up arch_perfmon pebs bts xtopology tsc_reliable nonstop_tsc aperfmperf unfair_spinlock pni pclmulqdq ssse3 cx16 pcid sse4_1 sse4_2 x2apic popcnt tsc_deadline_timer aes xsave avx f16c rdrand hypervisor lahf_lm ida arat epb pln pts dts fsgsbase smep
bogomips    : 5188.24
clflush size    : 64
cache_alignment : 64
address sizes   : 42 bits physical, 48 bits virtual
power management:

MemTotal:        1004608 kB

3. 단계

[root@mbankpush01 zookeeper-3.4.6]# ll conf
total 24
-rw-r--r-- 1 root root  535 Nov 26 17:38 configuration.xsl
-rw-r--r-- 1 root root 2161 Nov 26 17:38 log4j.properties
-rw-r--r-- 1 root root 1127 Nov 26 17:59 zoo2.cfg
-rw-r--r-- 1 root root 1127 Nov 26 18:01 zoo3.cfg
-rw-r--r-- 1 root root 1125 Nov 26 17:54 zoo.cfg
-rw-r--r-- 1 root root 1089 Nov 26 17:44 zoo.cfg.bak
[root@mbankpush01 zookeeper]# pwd
/opt/zookeeper
[root@mbankpush01 zookeeper]# ll
total 28
drwxr-xr-x  3 root root 4096 Nov 26 18:14 zkdata
drwxr-xr-x  2 root root 4096 Nov 26 17:59 zkdata2
drwxr-xr-x  2 root root 4096 Nov 26 18:00 zkdata3
drwxr-xr-x  3 root root 4096 Nov 26 18:14 zkdatalog
drwxr-xr-x  2 root root 4096 Nov 26 17:59 zkdatalog2
drwxr-xr-x  2 root root 4096 Nov 26 18:00 zkdatalog3
drwxr-xr-x 10 root root 4096 Nov 26 17:38 zookeeper-3.4.6
[root@mbankpush01 bin]# ./zkServer.sh start 
JMX enabled by default
Using config: /opt/zookeeper/zookeeper-3.4.6/bin/../conf/zoo.cfg
Starting zookeeper ... STARTED
[root@mbankpush01 bin]# ./zkServer.sh status
JMX enabled by default
Using config: /opt/zookeeper/zookeeper-3.4.6/bin/../conf/zoo.cfg
Error contacting service. It is probably not running.
 
 :
[root@mbankpush01 bin]# ./zkServer.sh status
JMX enabled by default
Using config: /opt/zookeeper/zookeeper-3.4.6/bin/../conf/zoo.cfg
Error contacting service. It is probably not running.
 :
[root@mbankpush01 bin]# ./zkServer.sh status ../conf/zoo3.cfg 
JMX enabled by default
Using config: ../conf/zoo3.cfg
Mode: follower
[root@mbankpush01 bin]# ./zkServer.sh status ../conf/zoo2.cfg 
JMX enabled by default
Using config: ../conf/zoo2.cfg
Mode: leader
[root@mbankpush01 bin]# ./zkServer.sh status ../conf/zoo.cfg 
JMX enabled by default
Using config: ../conf/zoo.cfg
Mode: follower

 zookeeper 。

kafka zookeeper 。 , 。

4. 설명

 , 。

좋은 웹페이지 즐겨찾기