ps -e -T
A specific pid
ps -Tp <pid>
""" | |
Returns result in the format: | |
{ | |
"B": { | |
2401: "1/6 = 2%", | |
3101: "1/6 = 2%" | |
}, | |
"C": { | |
"02": "3/6 = 50%" |
# If you come from bash you might have to change your $PATH. | |
# export PATH=$HOME/bin:/usr/local/bin:$PATH | |
# Path to your oh-my-zsh installation. | |
export ZSH=/Users/amittripathi/.oh-my-zsh | |
export EDITOR=vim | |
# Set name of the theme to load. Optionally, if you set this to "random" | |
# it'll load a random theme each time that oh-my-zsh is loaded. | |
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes |
package main | |
import ( | |
"sync" | |
"fmt" | |
"time" | |
"github.com/amitt001/moodb/client" | |
server "github.com/amitt001/moodb/mdbserver" | |
) |
#!/bin/bash | |
# file: ttfb.sh | |
# curl command to check the time to first byte | |
# ** usage ** | |
# 1. ./ttfb.sh "https://google.com" | |
# 2. seq 10 | xargs -Iz ./ttfb.sh "https://google.com" | |
curl -o /dev/null \ | |
-H 'Cache-Control: no-cache' \ | |
-s \ |
version: '2' | |
services: | |
zookeeper-1: | |
image: confluentinc/cp-zookeeper:latest | |
hostname: zookeeper-1 | |
ports: | |
- "12181:12181" | |
environment: | |
ZOOKEEPER_SERVER_ID: 1 | |
ZOOKEEPER_CLIENT_PORT: 12181 |
import sys | |
import time | |
from kubernetes import config, client | |
class KubeControl: | |
def __init__(self): | |
# config.load_kube_config(context='staging') | |
config.load_kube_config() |
# Initialize the scroll | |
page = es.search( | |
index = 'yourIndex', | |
doc_type = 'yourType', | |
scroll = '2m', | |
search_type = 'scan', | |
size = 1000, | |
body = { | |
# Your query's body | |
}) |
OpenSubtitles.org has apparently updated their servers. That uncovered latent bugs in the very dumb HTTP support of the VLSub extension. | |
To work around the problem (you might need administrator privileges): | |
Go to the VLC installation directory. | |
Look for the file named lua/extensions/VLSub.luac. | |
Open that file in a binary or hexadecimal editor. (DO NOT USE a text editor.) | |
Look for the character sequence "HTTP/1.1" (without quotes). | |
Replace the last one by a zero: "HTTP/1.0". | |
Repeat the procedure; there should be a second occurence in the file. | |
Save the file. |
VBox: http://linoxide.com/linux-how-to/setup-centos-7-vagrant-base-box-virtualbox/ | |
OR | |
Vagrant centos: https://atlas.hashicorp.com/relativkreativ/boxes/centos-7-minimal |