Skip to content

Instantly share code, notes, and snippets.

@rammanokar
rammanokar / ambari_start.sh
Created October 16, 2020 06:39
Ambari Start all the services
#!/bin/env bash
SERVER="xxxxxxxxxx:8080"
AMBARI_ADMIN_USER="admin"
AMBARI_ADMIN_PASSWORD="************"
CLUSTER_NAME="xxxxx"
STATE="STARTED"
generate_post_data()
{
cat <<EOF
@rammanokar
rammanokar / experthadoopadministration.md
Last active October 9, 2020 11:17
Expert Hadoop Administration.md

Expert Hadoop Administration

Checklist

  1. Increasing the File Limits
/etc/security/limits.conf
* - nofile 32768
* - nproc 65536
@rammanokar
rammanokar / sendOffmail.go
Created September 22, 2020 05:48
send office 365 mail using go
package main
import (
"fmt"
"net"
"errors"
mail "net/mail"
smtp "net/smtp"
)
@rammanokar
rammanokar / extend-trial-jetbrains-windows.bat
Created September 21, 2020 18:20 — forked from partho5/extend-trial-jetbrains-windows.bat
JetBrains IDE trial reset windows
REM Delete eval folder with licence key and options.xml which contains a reference to it
for %%I in ("WebStorm", "IntelliJ", "CLion", "Rider", "GoLand", "PhpStorm") do (
for /d %%a in ("%USERPROFILE%\.%%I*") do (
rd /s /q "%%a/config/eval"
del /q "%%a\config\options\other.xml"
)
)
REM Delete registry key and jetbrains folder (not sure if needet but however)
rmdir /s /q "%APPDATA%\JetBrains"
@rammanokar
rammanokar / add_cert.sh
Created September 11, 2020 08:21
Add cert form URL to JKS java keystore
HOST=google.com
PORT=443
KEYSTOREFILE="/etc/pki/java/cacerts"
KEYSTOREPASS=changeit
# get the SSL certificate
openssl s_client -connect ${HOST}:${PORT} </dev/null \
| sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' > ${HOST}.cert
# create a keystore and import certificate
@rammanokar
rammanokar / command.sh
Created September 10, 2020 08:28
nfs share issue in elasticsearch
#ERROR:
#"type": "repository_verification_exception",
# "reason": "[my_fs_backup] [[nQ6lBzfdQR6_Rkzv8x8mQA, 'RemoteTransportException[[qa2s1.c360i.com][10.73.40.91:9300][internal:admin/repository/verify]]; nested: RepositoryMissingException[[my_fs_backup] missing];']]"
# }
sudo setfacl -m d:u:elasticsearch:rwx /data/elk_back
@rammanokar
rammanokar / CKA_Curriculum_V1.18.yml
Last active August 26, 2020 13:27
Certified Kubernetes Administrator (CKA) Exam Curriculum
---
#ref: https://raw.githubusercontent.com/cncf/curriculum/master/CKA_Curriculum_V1.18.pdf
CKA Curriculum:
- Core Concepts: 19%
Topics:
- Understand the Kubernetes API primitives.
- Understand the Kubernetes cluster architecture.
- Understand Services and other network primitives.
- Scheduling: 6%
Topics:
#/usr/bin/env python3
'''
Author: Double Sine
License: GPLv3
'''
import os, sys, zipfile
VariantBase64Table = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/='
VariantBase64Dict = { i : VariantBase64Table[i] for i in range(len(VariantBase64Table)) }
VariantBase64ReverseDict = { VariantBase64Table[i] : i for i in range(len(VariantBase64Table)) }
@rammanokar
rammanokar / pedantically_commented_playbook.yml
Created May 20, 2020 05:29 — forked from marktheunissen/pedantically_commented_playbook.yml
Insanely complete Ansible playbook, showing off all the options
---
# ^^^ YAML documents must begin with the document separator "---"
#
#### Example docblock, I like to put a descriptive comment at the top of my
#### playbooks.
#
# Overview: Playbook to bootstrap a new host for configuration management.
# Applies to: production
# Description:
# Ensures that a host is configured for management with Ansible.
@rammanokar
rammanokar / KaliMirrorList.md
Last active May 1, 2020 10:50
KaliMirrorList.md

Kali Mirror List

deb https://mirror.karneval.cz/pub/linux/kali kali-rolling main non-free contrib
deb https://ftp.acc.umu.se/mirror/kali.org/kali kali-rolling main non-free contrib
deb https://mirrors.dotsrc.org/kali kali-rolling main non-free contrib
deb https://mirror.pyratelan.org/kali kali-rolling main non-free contrib
deb https://ftp.halifax.rwth-aachen.de/kali kali-rolling main non-free contrib
deb https://ftp2.nluug.nl/os/Linux/distr/kali kali-rolling main non-free contrib
deb https://ftp1.nluug.nl/os/Linux/distr/kali kali-rolling main non-free contrib
deb https://mirror.neostrada.nl/kali kali-rolling main non-free contrib