###Single hop tunelling:
ssh -f -N -L 9906:127.0.0.1:3306 user@dev.example.com
where,
-f
puts ssh in background-N
makes it not execute a remote command
###Single hop tunelling:
ssh -f -N -L 9906:127.0.0.1:3306 user@dev.example.com
where,
-f
puts ssh in background-N
makes it not execute a remote commandThis installation is going to require 2 servers one acts as kerberos KDC server
and the other machine is going to be client. Lets assume the FQDN's are (here
cw.com
is the domain name, make a note of the domain name here):
Important: Make sure that both systems have their hostnames properly set and both systems have the hostnames and IP addresses of both systems in
Kafka acts as a kind of write-ahead log (WAL) that records messages to a persistent store (disk) and allows subscribers to read and apply these changes to their own stores in a system appropriate time-frame.
Terminology:
#!/usr/bin/env ruby | |
require 'socket' | |
require 'timeout' | |
unless ARGV.length == 2 | |
abort "Usage: ruby #{__FILE__} HOST PORT" | |
end | |
def port_open?(ip, port, seconds=1) | |
# => checks if a port is open or not on a remote host | |
Timeout::timeout(seconds) do |
#!/bin/bash | |
# Detects which OS and | |
# if it is Linux then it will detect which Linux Distribution, | |
# if Mac(Darwin) will detect mac os x version, build number | |
OS=`uname -s` | |
REV=`uname -r` | |
MACH=`uname -m` | |
GetVersionFromFile() |
###Create a project from Maven Template:
To start a new maven project, use the maven archetype plugin from the command line using the archetype:generate
goal.
The following command will tell maven to create a java project from maven-archetype-quickstart
template, if you ignore the archetypeArtifactId
argument, then a list of the templates will be listed for you to choose.
#!/bin/sh | |
exec scala -savecompiled "$0" "$@" | |
!# | |
import scala.collection.mutable.Map | |
import scala.util.Random | |
import scala.collection.mutable.ArrayBuffer | |
import java.io._ | |
class IPGenerator(var sessionCount: Int, var sessionLength: Int) { |
package com.cloudwick.mapreduce.FileSystemAPI; | |
import java.io.BufferedInputStream; | |
import java.io.BufferedOutputStream; | |
import java.io.File; | |
import java.io.FileInputStream; | |
import java.io.FileOutputStream; | |
import java.io.IOException; | |
import java.io.InputStream; | |
import java.io.OutputStream; |
#!/bin/bash | |
function usage () { | |
script=$0 | |
cat <<USAGE | |
Creates scala project structure to be used with sbt | |
Syntax | |
`basename $script` project_name artifact_id |