常用教程及脚本整理合集

https://blog.boalk.com/wp-content/uploads/2021/12/acg.gy_37-1024x571.jpg

curl
curl -fsSL http://ilemonra.in/LemonBenchIntl | bash -s fast
wget
wget -qO- http://ilemonra.in/LemonBenchIntl | bash -s fast

curl
curl -fsSL http://ilemonra.in/LemonBenchIntl | bash -s full
wget
wget -qO- http://ilemonra.in/LemonBenchIntl | bash -s full

1
bash <(curl -L -s https://raw.githubusercontent.com/lmc999/RegionRestrictionCheck/main/check.sh)
1
wget https://raw.githubusercontent.com/nanqinlang-script/testrace/master/testrace.sh && bash testrace.sh

yum install -y wget;wget -q kos.f2k.pub -O kos && sh kos 选择n

1
netstat -an |grep tcp
1
du -h --max-depth=1 /
1
python3 -m http.server 80

https://github.com/soulteary/certs-maker

1
docker run --rm -it -e CERT_DNS="samsung.com;*.samsung.com" -e CERT_CN="Yui Certs" -e CERT_O="Yui" -v `pwd`/certs:/ssl soulteary/certs-maker

一键安装最新内核并开启 BBR 脚本

1
2
3
wget --no-check-certificate -O /opt/bbr.sh https://github.com/teddysun/across/raw/master/bbr.sh
chmod 755 /opt/bbr.sh
/opt/bbr.sh
1
2
3
4
echo "net.core.default_qdisc=fq" >> /etc/sysctl.conf
echo "net.ipv4.tcp_congestion_control=bbr" >> /etc/sysctl.conf
sysctl -p
lsmod | grep bbr

https://hostloc.com/thread-645870-1-1.html

1
wget --no-check-certificate -O AutoReinstall.sh https://git.io/AutoReinstall.sh && bash AutoReinstall.sh

https://hostloc.com/thread-583956-1-2.html

1
2
3
4
5
##镜像文件在OneDrive
wget -N --no-check-certificate https://raw.githubusercontent.com/veip007/dd/master/dd-od.sh && chmod +x dd-od.sh && ./dd-od.sh
 
##镜像文件在GoogleDrive
wget -N --no-check-certificate https://raw.githubusercontent.com/veip007/dd/master/dd-gd.sh && chmod +x dd-gd.sh && ./dd-gd.sh

bash <(wget --no-check-certificate -qO- 'https://moeclub.org/attachment/LinuxShell/InstallNET.sh') -d 11 -v 64 -a -firmware
密码:MoeClub.org

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
Usage:
 
    bash InstallNET.sh   -d/--debian [dist-name]
 
                -u/--ubuntu [dist-name]
 
                -c/--centos [dist-version]
 
                -v/--ver [32/i386|64/amd64]
 
                -p
 
                --ip-addr/--ip-gate/--ip-mask
 
                -apt/-yum/--mirror
 
                -dd/--image
 
                -a/-m
 
 
 
# dist-name: 发行版本代号
 
# dist-version: 发行版本号
 
# -p: 自定义密码
 
# -apt/-yum/--mirror : 使用定义镜像
 
# -a/-m : 询问是否能进入VNC自行操作. -a 为不提示(一般用于全自动安装), -m 为提示.
1
2
3
4
5
6
sed -i "s|if (bind_user == 'True') {|if (bind_user == 'REMOVED') {|g" /www/server/panel/BTPanel/static/js/index.js && rm -rf /www/server/panel/data/bind.pl
wget http://download.bt.cn/install/update/LinuxPanel-7.7.0.zip
unzip LinuxPanel-*
cd panel
bash update.sh
cd .. && rm -f LinuxPanel-*.zip && rm -rf panel
1
sysctl -w net.ipv6.conf.eth0.disable_ipv6=1
1
bash <(curl -Lso- https://git.io/superspeed.sh)
1
wget http://sh.nekoneko.cloud/tools.sh -O tools.sh && bash tools.sh
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
bash <(curl -fsSL git.io/warp.sh) [SUBCOMMAND]
install         Install Cloudflare WARP Official Linux Client
uninstall       uninstall Cloudflare WARP Official Linux Client
proxy           Enable WARP Client Proxy Mode (default SOCKS5 port: 40000)
unproxy         Disable WARP Client Proxy Mode
wg4             Configuration WARP IPv4 Network interface (with WireGuard)
wg6             Configuration WARP IPv6 Network interface (with WireGuard)
wgd             Configuration WARP Dual Stack Network interface (with WireGuard)
rewg            Restart WARP WireGuard service
unwg            Disable WARP WireGuard service
status          Prints status information
version         Prints version information
help            Prints this message or the help of the given subcommand(s)
menu            Chinese special features menu
1
yum -y install wget;wget http://kangle.cccyun.cn/start;sh start

[http://wanganzhi.cn/2017/12/18/kengle%20%E4%BB%8B%E7%BB%8D%E5%8F%8A%E5%AE%89%E8%A3%85/](http://wanganzhi.cn/2017/12/18/kengle 介绍及安装/)

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
/vhs/kangle/bin/kangle
 
参数:  
  [-h --help]       可以看到详细的参数说明
  [-d level]         调试运行程序
  [-r --reload]     重新加载所有配置文件
  [--revh]           重新加载etc/vh.xml文件(etc/vh.xml)
  [--reboot]        平滑重起程序(原有程序会保证服务完客户),一般用来升级用的
  [-z [disk_dir]]   建立硬盘cache目录
  [-v --version]  查看程序版本
  [-a apache_config_file]  转换的Apache配置
  [-q]                 关闭程序
  [-n]            start program not in daemon
1
yum install -y wget;wget -q kos.f2k.pub -O kos && sh kos

把以下文件解压并覆盖到/vhs/kangle/nodewww/webftp/framework/api目录里,主节点和同步节点都要上传

Kangle Https下载

1
wget https://www.moerats.com/usr/shell/swap.sh && bash swap.sh
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
#安装
curl  https://get.acme.sh | sh -s email=my@example.com
alias acme.sh=~/.acme.sh/acme.sh
 
#申请ecc证书
acme.sh --issue --dns dns_gd -d *.xxx.com -d xxx.com --keylength ec-256 
#自动部署
acme.sh --installcert -d *.xxx.com -d xxx.com --ecc --key-file /home/ftp/c/x/ssl.key --fullchain-file /home/ftp/c/x/ssl.crt --reloadcmd "service kangle restart"
#手动更新证书
acme.sh --renew -d *.xxx.com -d xxx.com --force --ecc
#停止自动更新
acme.sh --remove -d example.com --ecc

https://github.com/acmesh-official/acme.sh/wiki/dnsapi

EMBY常规部署

EMBY Docker部署

1
2
docker pull emby/embyserver:latest
docker run -d --name=emby --restart=always -v /root/emby/config:/config -v /home/gdrive:/home/gdrive -p 8096:8096 -p 8920:8920 -e UID=1000 -e GID=100 -e GIDLIST=100 emby/embyserver:latest

基于宝塔Docker自建Bitwarden密码管理服务

AdGuardHome搭建教程

Linux网络占用分析教程