This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
GB_LOCAL_REPO=/var/gitbucket/data/repositories | |
MIRROR_BASE=/var/gitbucket/mirrors | |
SRC_BASE=${GB_LOCAL_REPO}/ | |
[email protected]: | |
DST_USER=bitbucketuser | |
function repo_put() { | |
curl -X POST \ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## System configurations | |
get following informations by root | |
### files: | |
/etc/security/limits.conf | |
/proc/cpuinfo | |
### commands: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
abs_dirname() { | |
local cwd="$(pwd)" | |
local path="$1" | |
while [ -n "$path" ]; do | |
cd "${path%/*}" | |
local name="${path##*/}" | |
path="$(readlink "$name" || true)" | |
done |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
LD_LIBRARY_PATH=${HOME}/lib:$LD_LIBRARY_PATH | |
INCLUDE=${HOME}/include:$INCLUDE | |
[ -z "$ld_library_path" ] && typeset -T LD_LIBRARY_PATH ld_library_path | |
[ -z "$include" ] && typeset -T INCLUDE include | |
typeset -U path cdpath fpath manpath ld_library_path include |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
zcat 20150325*_log/elmsto20*/mss.elmsto*stat.gz | grep StatMssCassandraGetSliceWithSliceRange | sed -e 's#[/]# #g' | awk '{print $2,$3,$7,$9,$16,$17}' | sed -e 's/\(..\)\(..\)\(..\)\(...\)+\(....\) /\1:\2:\3.\4 /' | sed 's/\(..:..:\)\([012].....\) /\100 /' | sed 's/\(..:..:\)\([345].....\) /\130 /' > ~/work/aminamid/cmpare/slicerange.txt | |
for s in 1 2 3 4 5 6 7 8 9 ; do sar -f ../elcdto20${s}_sar.201503250500 -n ETCP -s 12:30:00 -e 14:10:00 | awk "{print \""'elcdto20'${s}"\",\$0; fflush() }"; done | |
zcat elms*/mss*stat.gz | grep -e StatMssCassandraGetSliceWithSliceRange -e StatMssRmeImapSelectTime -e StatMssSLRmeCreateMessageTime | sed 's# [^ ;]*;\(.*\)(.*\/[^)]*) # \1 #' | sed -e 's#[/]# #g' | awk '{print $2,$3,$5,$6,$8,$15,$16}' | sed -e 's/\(..\)\(..\)\(..\)\(...\)+\(....\) /\1:\2:\3.\4 /' | sed 's/\(..:..:\)\([012].....\) /\100 /' | sed 's/\(..:..:\)\([345].....\) /\130 /' | |
cat xxx | while read line ; do echo ${line} | sed -e "s/.*\(172.25.105.9.\).\(....\) \(172.25.105.9.\).\(.....\): .*$/tcpdump -nn -r e |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
use strict; | |
use warnings; | |
use Crypt::CBC; | |
use Crypt::Rijndael; | |
use Digest::SHA1 qw(sha1); | |
sub main() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## multisessions | |
http://tech.naviplus.co.jp/2014/01/09/tmux%E3%81%A7%E8%A4%87%E6%95%B0%E3%82%B5%E3%83%BC%E3%83%90%E3%81%AE%E5%90%8C%E6%99%82%E3%82%AA%E3%83%9A%E3%83%AC%E3%83%BC%E3%82%B7%E3%83%A7%E3%83%B3/ | |
switch sync/async | |
``` | |
set-window-option synchronize-panes on | |
set-window-option synchronize-panes off | |
``` |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo 'stout to stderr' 1>&2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cd ~/ssh | |
ssh-keygen -t rsa -C [email protected] -f id_peko | |
~/.ssh/config | |
Host bitbucket.org | |
HostName bitbucket.org | |
IdentityFile ~/.ssh/id_rsa | |
User git |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import sys | |
import datetime | |
import itertools | |
def concat( ll ): | |
return list(itertools.chain(*ll)) |