Showing posts with label nc. Show all posts
Showing posts with label nc. Show all posts

Monday, 30 September 2013

Monitoring Zookeeper

Option 1
  1. yum -y install git
  2. cd
  3. mkdir bin
  4. mkdir tools
  5. cd tools
  6. git clone https://github.com/phunt/zktop.git
  7. nice updatedb
  8. locate zoo.cfg
    1. jot this path down for step below
    2. let's call it "mypathtozoocfg"
    3. the name of your zk conf may vary, adjust if so
  9. cd
  10. cd bin
  11. ln -s /root/tools/zktop/zktop.py .
    1. make sure you put the '.' on the end of that command
  12. /root/bin/zktop.py --config /<mypathtozoocfg>/zoo.cfg
Option 2, by hand
  1. echo srvr | nc localhost 2181
  2. echo stat | nc localhost 2181
  3. echo cons | nc localhost 2181
  4. etc.
  5. Try: watch -d "echo stat | nc localhost 2181" 
    1. on all zk nodes 
    2. in separate terms
Break-out
  1. srvr
    1. version
    2. latencies
    3. received client requests
    4. sent client responses and notifications
    5. outstanding requests
    6. zxid, cluster id
    7. mode in cluster, leader or follower
    8. node count (?)
  2. stat
    1. similar to srvr
      1. but has actual connections listed by IP near top
Taken: http://phunt1.wordpress.com/2010/03/29/monitoring-zookeeper-3-3-even-more-cussin/

Monday, 17 June 2013

telnet vs netcat


  1. netcat
    1. prints only what is sent by the remote host
  2. telnet
    1. not suitable for arbitrary binary data 
      1. reserves some bytes as control characters 
    2. quits when its input runs out
      1. you may not see what the other end sends
    3. doesn't do UDP

Interview questions: 2020-12

Terraform provider vs provisioner Load balancing Network Load Balancer vs Application Load Balancer  Networking Layer 1 vs Layer 4 haproxy u...