Skip to content

Instantly share code, notes, and snippets.

View mingderwang's full-sized avatar

Ming-der Wang mingderwang

View GitHub Profile
mkdir /etc/chef
cat << EOF > /etc/chef/solo.rb
file_cache_path "/tmp/chef-solo"
cookbook_path "/tmp/chef-solo/cookbooks"
node_name "app_server6"
EOF
cat << EOF > /etc/chef/chef.json
{
@mingderwang
mingderwang / README.md
Last active August 29, 2015 14:14 — forked from kfatehi/README.md

Logstash Performance Testing

Server Details

HP BL460

  • 48 Gb Memory
  • 2 x X5675 @ 3.07GHz
  • 2 x 10 gbps NIC
  • 2tb NetApp NFS volume for ES data
@mingderwang
mingderwang / Dockerfile
Last active August 29, 2015 14:16 — forked from ahromis/Dockerfile
FROM ubuntu:12.04
MAINTAINER Andrew Hromis "ahromis@gmail.com"
RUN apt-get update -q
RUN DEBIAN_FRONTEND=noninteractive apt-get install -qy build-essential curl git
RUN curl -s https://go.googlecode.com/files/go1.2.src.tar.gz | tar -v -C /usr/local -xz
RUN cd /usr/local/go/src && ./make.bash --no-clean 2>&1
ENV PATH /usr/local/go/bin:$PATH
RUN git clone git://github.com/elasticsearch/logstash-forwarder.git /opt/logstash-forwarder
  1. General Background and Overview
root@redmine:~/stress_test/gke# ../vegeta attack -rate=10000 -targets=targets.txt > results_23_101_1000_1.bin
root@redmine:~/stress_test/gke# ../vegeta report -inputs="results_23_101_1000_1.bin"
Requests [total, rate] 100000, 9954.37
Duration [total, attack, wait] 10.659396317s, 10.045843051s, 613.553266ms
Latencies [mean, 50, 95, 99, max] 131.628089ms, 22.243637ms, 677.705875ms, 6.066950532s, 6.066950532s
Bytes In [total, mean] 17340748, 173.41
Bytes Out [total, mean] 0, 0.00
Success [ratio] 15.10%
Status Codes [code:count] 200:15096 0:84904
Error Set:
@mingderwang
mingderwang / afile
Created October 22, 2015 14:43 — forked from josephfinlayson/afile
JSON
[
{
"code": "1001",
"category": "HOME",
"type": "SUBSCRIPTION",
"name": "Home emergency assistance and insurance",
"description": "We cover the typical mishaps you may encounter: If you lost your keys, a window or door gets broken and many more. Our assistance service is able to dispatch every type of craftsmen at no additional cost & at high quality and guaranteed low cost. 12 month subscription, coverage max. 1,500 per incident.",
"price": 119
},
@mingderwang
mingderwang / logstash.conf
Created December 28, 2015 11:44 — forked from oerd/logstash.conf
nxlog -> rsyslog -> logstash -> elasticsearch
input {
}
filter {
}
output {
@mingderwang
mingderwang / __readme.markdown
Created January 3, 2016 04:36 — forked from apai4/__readme.markdown
ElasticSearch bootstrap script and node configuration for Ubuntu [https://gist.github.com/2050769]

Installing ElasticSearch with Monit & nginx

This repository contains files tailored for bootstrapping, installing and configuring ElasticSearch with Chef Solo on the Ubuntu operating system, inspired by this article.

Launch and ssh into Ubuntu 12.04 instance (if on ec2, use ami from alestic.com and with a security group as detailed here)

Now, copy the files to the machine and execute the bootstrap script:

eth allows to create custom/private blockchain by using several options:
--private defines the name of the custom chain (optional).
--config <filename>
<filename> contains a JSON description of the network:
- sealEngine (engine use to mine block)
- params (general network information like minGasLimit, minimumDifficulty, blockReward, networkID)
- genesis (genesis block description)
- accounts (setup an original state that contains accounts/contracts)