Skip to content

Instantly share code, notes, and snippets.

View seeker815's full-sized avatar

Sai Kothapalle seeker815

  • self
  • Bangalore, India
View GitHub Profile
@seeker815
seeker815 / app.py
Last active April 20, 2018 13:21
python code for hadoop metrics
import requests
import json
import boto
import socket
HOSTNAME = socket.gethostbyaddr(socket.gethostname())[0]
JOB_TRACKER_URL = "http://" + HOSTNAME + ":8088/ws/v1/cluster/metrics/"
config = json.load(open("config.json"))
METRIC_NAMESPACE = config['namespace']
@seeker815
seeker815 / app.json
Created December 28, 2017 04:58
production.docker-registry-v2
{
"id": "/production.docker-registry-v2",
"cmd": null,
"cpus": 1,
"mem": 2048,
"disk": 2048,
"instances": 1,
"constraints": [
[
"lifecycle",
package checks
import (
"fmt"
"time"
"strings"
maps "github.com/ashwanthkumar/golang-utils/maps"
"github.com/gambol99/go-marathon"
)
@seeker815
seeker815 / scala_dep.md
Created December 4, 2017 09:22
Install Java,Scala and SBT

Install Java,Scala and SBT on Ubuntu 16.04

  • Install Java 8 (default jdk)

    sudo apt-get update

    sudo apt-get install default-jdk

    java -version

Command Cheatsheet

RAID

  • How do I know if an instance EBS volumes are RAID'd or not/ lvm or not?

lsblk

  • Get RAID details
@seeker815
seeker815 / Kafka_cheatsheet.md
Created September 15, 2017 12:30
Kafka Cheatsheet

Kafka Cheatsheet

Kafka Operations

  • Run the commands on any of the kafka brokers (APIs in v0.10)

List all Kafka Topics

#!/bin/bash
# Ensure we're not running as root
if [ $EUID -eq 0 ] ; then
echo "Do not run as root!" 1>&2
exit 1
fi
#!/bin/bash
# Ensure we're not running as root
if [ $EUID -eq 0 ] ; then
echo "Do not run as root!" 1>&2
exit 1
fi
@seeker815
seeker815 / knife cheat
Created August 24, 2016 08:08 — forked from ipedrazas/knife cheat
Hello!
# knife cheat
## Search Examples
knife search "name:ip*"
knife search "platform:ubuntu*"
knife search "platform:*" -a macaddress
knife search "platform:ubuntu*" -a uptime
knife search "platform:ubuntu*" -a virtualization.system
knife search "platform:ubuntu*" -a network.default_gateway
repo = '%s-tools' % node['lsb']['codename']
apt_repository 'scalyr-agent-2' do
uri 'http://10.100.0.xx/repo/snapshots'
arch 'amd64'
distribution repo
components [repo]
key 'http://10.100.0.xx/repo/bjn.gpg'
end
package 'scalyr-agent-2' do