Skip to content

Instantly share code, notes, and snippets.

View build-git-together-on-ubuntu-18.04.bash
# package dependences
sudo apt install pkg-config
sudo apt install libssl-dev
# build toolchain
sudo apt-get install curl
curl https://sh.rustup.rs -sSf | sh
source $HOME/.cargo/env
rustup default nightly
View test_io_perf_using_parallel_dd.bash
#!/usr/bin/env bash
set -x
# need to specify where to put the test file (on the target device)
if [ $# -eq 0 ] ; then
echo "usage: $0 <target file on device>"
exit 1
fi
@xinzweb
xinzweb / docker-build-gcloud-auth.md
Last active Aug 17, 2018
`docker build` paused 10 seconds before `Sending build context`
View docker-build-gcloud-auth.md

I recently experienced slow down with docker build, after I ran gcloud auth configure-docker.

The 10 seconds slow down is caused by the extra step of gcloud authentication, even though you are not using the gcr.io registry in your current build.

To solve this problem, just rename the file under ~/.docker/config.json to something else, like:

mv ~/.docker/config.json ~/.docker/config.json.gcloud
@xinzweb
xinzweb / pg_regress.md
Last active Jun 25, 2018
To just run one test in `pg_regress` under Greenplum
View pg_regress.md

Usually, you only got one test failed, and you tried to rerun that failed test, and there are tables missing, or data didn't load right.

It's a tedious process to find all the dependencies, and I tried that to produce a known list of tests should run before you even try your repro.

This is the list of tests you need to run before your repro of failed tests based on 5.7.0 release:

@xinzweb
xinzweb / tmate-slave-ubuntu-1604.md
Last active Jan 18, 2019 — forked from mego22/tmate-slave-ubuntu-1604.md
Tmate-slave on Ubuntu 16.04
View tmate-slave-ubuntu-1604.md

Install dependincies

apt-get install  git-core build-essential pkg-config libtool libevent-dev libncurses-dev zlib1g-dev automake libssh-dev cmake ruby

Install msgpack >= 1.2.0

git clone https://github.com/msgpack/msgpack-c.git
cd msgpack-c
cmake .
@xinzweb
xinzweb / tmux-cheatsheet.markdown
Last active Dec 12, 2017 — forked from MohamedAlaa/tmux-cheatsheet.markdown
tmux shortcuts & cheatsheet
View tmux-cheatsheet.markdown

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname