Skip to content

Instantly share code, notes, and snippets.

View richardplas's full-sized avatar
🏠
Working from home

ganbei richardplas

🏠
Working from home
View GitHub Profile
@richardplas
richardplas / linux-http-tcp.md
Created April 23, 2020 05:13 — forked from v5tech/linux-http-tcp.md
linux下查看http 并发和 tcp连接数

linux查看httpd进程数

ps -ef | grep httpd | wc -l

查看Apache的并发请求数及其TCP连接状态

netstat -n | awk '/^tcp/ {++S[$NF]} END {for(a in S) print a, S[a]}'
@richardplas
richardplas / db_backup.sh
Created March 21, 2019 08:21 — forked from NARKOZ/db_backup.sh
MySQL backup shell script
#!/bin/bash
# Shell script to backup MySQL database
# Set these variables
MyUSER="" # DB_USERNAME
MyPASS="" # DB_PASSWORD
MyHOST="" # DB_HOSTNAME
# Backup Dest directory
DEST="" # /home/username/backups/DB
@richardplas
richardplas / brew-java-and-jenv.md
Created April 19, 2018 06:46 — forked from alChaCC/brew-java-and-jenv.md
How To Install Java 8 on Mac

Install HomeBrew first

brew update
brew tap caskroom/cask
brew install brew-cask

If you get the error "already installed", follow the instructions to unlink it, then install again: