banner
xingli

xingli

猫娘爱好者

2023常用脚本バックアップ

2023 常用脚本备份#

以下の大佬に感謝して、スクリプトを収集整理しました

https://hostloc.com/thread-921605-1-1.htmlhttps://blog.laoda.de/archives/useful-scripthttps://www.wrnxr.cn/163.html

DD ネットワーク再インストールスクリプト#

PS:カスタムパスワードは直接 -p あなたが望むパスワードを指定すれば大丈夫です!!!

一部のマシンではネットワークカードを設定する必要があります。そうしないと VNC は可能ですが、リモート SSH はできません。

 -firmware                追加のドライバーサポート
 -d                        Debianシステム 後ろにシステムバージョン番号
 -c                        Centosシステム 後ろにシステムバージョン番号
 -v                         後ろに64ビット 32ビットを記入
 -a                        auto、自動無人インストール
 --mirror                後ろにミラーソースのアドレス
 -p                        後ろにカスタムパスワードを記入
 –ip-addr                 ifconfig -a で取得した 例:194.87.xxx.xxx
 –ip-gate                 route -n   で取得した   194.87.xxx.xxx
 –ip-mask                 255.255.xxx.xx

甲骨文、三毛、Vir、RN などのほとんどの VPS に共通、三毛、甲骨文では -firmware を外すことを忘れないでください

bash <(wget --no-check-certificate -qO- 'https://moeclub.org/attachment/LinuxShell/InstallNET.sh') -d 11 -v 64 -a -firmware -p カスタムパスワード

#

bash <(wget --no-check-certificate -qO- 'https://raw.githubusercontent.com/MoeClub/Note/master/InstallNET.sh') -d 11 -v 64 -p パスワード -port ポート -a -firmware
bash <(wget --no-check-certificate -qO- 'https://raw.githubusercontent.com/MoeClub/Note/master/InstallNET.sh') -d 11 -v 64 -p 123456 -port 44 -a -firmware

PS: もしあなたが Tencent Cloud を使用している場合は、コンポーネントをアンインストールすることを忘れないでください。そうしないとエラーが発生し、DD が失敗します。#

 systemctl stop tat_agent
 systemctl disable tat_agent
 rm -rf /etc/systemd/system/tat_agent.service
 rm -fr /usr/local/qcloud
 
 ps -A | grep agent
 # Tencent Cloudのコンポーネントがまだあるか確認
 # このプロセスをkill

国内 VPS はミラーソースを変更する必要があります。そうしないと非常に遅くなります!私が使用しているのは Huawei のソースです。もしあなたが Tencent Cloud を使用している場合は、後で内部ネットワークのソースに変更できます。トラフィックを節約できます。以下に書いてあります!

bash <(wget --no-check-certificate -qO- 'https://moeclub.org/attachment/LinuxShell/InstallNET.sh') -d 11 -v 64 -a --mirror 'https://mirrors.huaweicloud.com/debian/' -p カスタムパスワード

ミラーサイトアドレス#

公式が提供するアドレスリスト:https://www.debian.org/mirror/list

 いくつかの国内の
 ftp.cn.debian.org
 mirror.bjtu.edu.cn
 mirror.lzu.edu.cn
 mirror.nju.edu.cn
 mirrors.163.com
 mirrors.bfsu.edu.cn
 mirrors.hit.edu.cn
 mirrors.huaweicloud.com
 mirror.sjtu.edu.cn
 mirrors.tuna.tsinghua.edu.cn
 mirrors.ustc.edu.cn
 
 使用方法:(大体は同じです)
 
 清華源
 --mirror 'https://mirrors.ustc.edu.cn/debian/'
 Tencent源
 --mirror 'http://mirrors.tencent.com/debian/'
 --mirror 'http://mirrors.cloud.tencent.com/debian/'
 Tencent源内部ネットワーク(dd完了後に変更可能、内部ネットワークを通ると速度が速くなります)
 http://mirrors.tencentyun.com/
 阿里源
 --mirror 'https://mirrors.aliyun.com/debian/'
 Huawei源
 --mirror 'https://mirrors.huaweicloud.com/debian/'

DD windows#

https://git.beta.gs/

 システム再インストールの前提コンポーネント:
 Debian/Ubuntu:
apt-get install -y xz-utils openssl gawk file wget screen && screen -S os
 
 RedHat/CentOS:
yum install -y xz openssl gawk file glibc-common wget screen && screen -S os
 
 異常が発生した場合は、ミラーキャッシュを更新するか、ミラーソースを変更してください。
 RedHat/CentOS:
 yum makecache && yum update -y
 Debian/Ubuntu:
 apt update -y && apt dist-upgrade -y
 
 
 使用:
wget --no-check-certificate -O NewReinstall.sh https://git.io/newbetags && chmod a+x NewReinstall.sh && bash NewReinstall.sh
 
 CNホストの場合(一部のホストプロバイダーでは使用できなくなっています)、エラーが発生したりスクリプトをダウンロードできない問題が発生する可能性があります。以下のコマンドを実行してインストールを開始できます。
wget --no-check-certificate -O NewReinstall.sh https://cdn.jsdelivr.net/gh/fcurrk/reinstall@master/NewReinstall.sh && chmod a+x NewReinstall.sh && bash NewReinstall.sh

41 合一システムパスワード:

1、CentOS 7.7 (ファイアウォールとSELinuxを無効にし、デフォルトパスワードはPwd@CentOS)
2、CentOS 7 (デフォルトパスワードcxthhhhh.com)
3、CentOS 7 (ARM64、UEFIをサポート、デフォルトパスワードcxthhhhh.com)
4、CentOS 8 (デフォルトパスワードcxthhhhh.com)
5、Rocky 8 (デフォルトパスワードcxthhhhh.com)
6、Rocky 8 (UEFIをサポート、デフォルトパスワードcxthhhhh.com)
7、Rocky 8 (ARM64、UEFIをサポート、デフォルトパスワードcxthhhhh.com)
8、CentOS 9 (デフォルトパスワードcxthhhhh.com)
9、CentOS 6 (公式ソースのオリジナル、デフォルトパスワードMinijer.com)
10、Debian 11 (公式ソースのオリジナル、デフォルトパスワードMinijer.com)
11、Debian 10 (公式ソースのオリジナル、デフォルトパスワードMinijer.com)
12、Debian 9 (公式ソースのオリジナル、デフォルトパスワードMinijer.com)
13、Debian 8 (公式ソースのオリジナル、デフォルトパスワードMinijer.com)
14、Ubuntu 20.04 (公式ソースのオリジナル、デフォルトパスワードMinijer.com)
15、Ubuntu 18.04 (公式ソースのオリジナル、デフォルトパスワードMinijer.com)
16、Ubuntu 16.04 (公式ソースのオリジナル、デフォルトパスワードMinijer.com)
17、Windows Server 2022 (デフォルトパスワードcxthhhhh.com)
18、Windows Server 2022 (UEFIをサポート、デフォルトパスワードcxthhhhh.com)
19、Windows Server 2019 (デフォルトパスワードcxthhhhh.com)
20、Windows Server 2016 (デフォルトパスワードcxthhhhh.com)
21、Windows Server 2012 (デフォルトパスワードcxthhhhh.com)
22、Windows Server 2008 (デフォルトパスワードcxthhhhh.com)
23、Windows Server 2003 (デフォルトパスワードcxthhhhh.com)
24、Windows 10 LTSC (デフォルトパスワードTeddysun.com)
25、Windows 10 LTSC (UEFIをサポート、デフォルトパスワードTeddysun.com)
26、Windows 7 x86 Lite (デフォルトパスワードnat.ee)
27、Windows 7 x86 Lite (阿里云専用、デフォルトパスワードnat.ee)
28、Windows 7 x64 Lite (デフォルトパスワードnat.ee)
29、Windows 7 x64 Lite (UEFIをサポート、デフォルトパスワードnat.ee)
30、Windows 10 LTSC Lite (デフォルトパスワードnat.ee)
31、Windows 10 LTSC Lite (阿里云専用、デフォルトパスワードnat.ee)
32、Windows 10 LTSC Lite (UEFIをサポート、デフォルトパスワードnat.ee)
33、Windows Server 2003 Lite (Cドライブデフォルト10G、デフォルトパスワードWinSrv2003x86-Chinese)
34、Windows Server 2008 Lite (デフォルトパスワードnat.ee)
35、Windows Server 2008 Lite (UEFIをサポート、デフォルトパスワードnat.ee)
36、Windows Server 2012 Lite (デフォルトパスワードnat.ee)
37、Windows Server 2012 Lite (UEFIをサポート、デフォルトパスワードnat.ee)
38、Windows Server 2016 Lite (デフォルトパスワードnat.ee)
39、Windows Server 2016 Lite (UEFIをサポート、デフォルトパスワードnat.ee)
40、Windows Server 2022 Lite (デフォルトパスワードnat.ee)
41、Windows Server 2022 Lite (UEFIをサポート、デフォルトパスワードnat.ee)
99、自分のイメージ

宝塔パネル 7.7.0#

curl -sSO https://raw.githubusercontent.com/8838/btpanel-v7.7.0/main/install/install_panel.sh && bash install_panel.sh
 
 1,携帯番号を遮断
sed -i "s|bind_user == 'True'|bind_user == 'XXXX'|" /www/server/panel/BTPanel/static/js/index.js
 2,強制的に携帯電話をバインドするjsファイルを削除
rm -f /www/server/panel/data/bind.pl
 3,宝塔のすべての有料プラグインを手動で永久にロック解除
 ファイルパス:/www/server/panel/data/plugin.json
 検索文字列:"endtime": -1をすべて"endtime": 999999999999に置き換え
 4,plugin.jsonファイルにロックをかけて自動修正を防ぐ
chattr +i /www/server/panel/data/plugin.json

常用スクリプト#

ワンクリックで BBR を有効にする(新しい Debian、Ubuntu に適しています)#

echo "net.core.default_qdisc=fq" >> /etc/sysctl.conf
echo "net.ipv4.tcp_congestion_control=bbr" >> /etc/sysctl.conf
sysctl -p
sysctl net.ipv4.tcp_available_congestion_control
lsmod | grep bbr

superbench#

wget -qO- git.io/superbench.sh | bash

Bench.sh#

wget -qO- bench.sh | bash

三網速度テスト#

bash <(curl -Lso- https://git.io/superspeed_uxh)
bash <(curl -Lso- https://git.io/J1SEh)

wget -O jcnf.sh https://raw.githubusercontent.com/Netflixxp/jcnfbesttrace/main/jcnf.sh
bash jcnf.sh

yabs マシンスコア#

curl -sL yabs.sh | bash

curl -sL yabs.sh | bash -s -- -flags
-bこのオプションは、ローカルパッケージではなく、repoからの事前コンパイルされたバイナリを強制的に使用します
-f/-dこのオプションはfio(ディスクパフォーマンス)テストを無効にします
-iこのオプションはiperf(ネットワークパフォーマンス)テストを無効にします
-gこのオプションはGeekbench(システムパフォーマンス)テストを無効にします
-hこのオプションは、使用法、検出されたフラグ、およびローカルパッケージ(fio/iperf)の状態を含むヘルプメッセージを印刷します
-rこのオプションは、iperfの場所の数を減らします(Online.net/Clouvider LON+NYC)、帯域幅の使用を減らします
-4このオプションはGeekbench 5パフォーマンステストをオーバーライドし、Geekbench4テストを実行します
-9このオプションはGeekbench 5テストを実行するだけでなく、Geekbench 4テストも実行します
-jこのオプションは、結果のJSON表現を画面に印刷します
-w<filename>このオプションは、提供されたファイル名を使用してJSON結果をファイルに書き込みます
-s<url>このオプションは、結果のJSON表現を指定されたurlに送信します(以下のセクションを参照)

ワンクリックで docker をインストール#

海外#

curl -sSL https://get.docker.com/ | sh

国内#

curl -sSL https://get.daocloud.io/docker | sh

docker をアンインストール#

sudo apt-get remove docker docker-engine
rm -fr /var/lib/docker/

ストリーミングメディアテスト#

全メディアテスト#

bash <(curl -L -s https://raw.githubusercontent.com/lmc999/RegionRestrictionCheck/main/check.sh)

Netflix テスト#

wget -O nf https://github.com/sjlleo/netflix-verify/releases/download/2.5/nf_2.5_linux_amd64 && chmod +x nf && clear && ./nf

#最初の
bash <(curl -L -s https://raw.githubusercontent.com/lmc999/RegionRestrictionCheck/main/check.sh)

# 2番目
bash <(curl -sSL "https://github.com/CoiaPrant/MediaUnlock_Test/raw/main/check.sh")

Glances:クロスプラットフォームのシステムパフォーマンスモニタリングツール#

curl -L https://bit.ly/glances | bash
wget -O- https://bit.ly/glances | bash

総合ツールボックス(強く推奨、たくさんのスクリプトを統合)#

wget -O box.sh https://raw.githubusercontent.com/BlueSkyXN/SKY-BOX/main/box.sh && chmod +x box.sh && clear && ./box.sh

あまり使わないスクリプト#

杜甫テスト#

wget -q https://github.com/Aniverse/A/raw/i/a && bash a

単スレッドテスト#

bash <(curl -Lso- https://bench.im/hyperspeed)

直接回線を表示#

curl https://raw.githubusercontent.com/zhucaidan/mtr_trace/main/mtr_trace.sh|bash

# 最初の
wget https://raw.githubusercontent.com/nanqinlang-script/testrace/master/testrace.sh
bash testrace.sh

# 2番目
wget -qO- git.io/besttrace | bash

25 ポートが開いているかテスト#

telnet smtp.aol.com 25

IPv4 優先か IPv6 優先かテスト#

curl ip.p3terx.com

WARP#

wget -N --no-check-certificate https://cdn.jsdelivr.net/gh/YG-tsj/CFWarp-Pro/multi.sh && chmod +x multi.sh && ./multi.sh

宝塔ワンクリックでハードディスクをマウントするスクリプト#

Centosシステムでは以下のコマンドを使用してください:
yum install wget -y && wget -O auto_disk.sh http://download.bt.cn/tools/auto_disk.sh && bash auto_disk.sh

Ubuntuシステムでは以下のコマンドを使用してください:
wget -O auto_disk.sh http://download.bt.cn/tools/auto_disk.sh && sudo bash auto_disk.sh

Debianシステムでは以下のコマンドを使用してください:
wget -O auto_disk.sh http://download.bt.cn/tools/auto_disk.sh && bash auto_disk.sh

FunctionClub のメモリ検出スクリプト#

CentOS

yum install wget -y
yum groupinstall "Development Tools" -y
wget https://raw.githubusercontent.com/FunctionClub/Memtester/master/memtester.cpp
gcc -l stdc++ memtester.cpp
./a.out

Ubuntu / Debian

apt-get update
apt-get install wget build-essential -y
wget https://raw.githubusercontent.com/FunctionClub/Memtester/master/memtester.cpp
gcc -l stdc++ memtester.cpp
./a.out

Aria2 ワンクリックインストールスクリプト#

wget -N git.io/aria2.sh && chmod +x aria2.sh && ./aria2.sh

qbittorrent インストール 4.3.9#

cd /root
wget https://github.com/userdocs/qbittorrent-nox-static/releases/download/release-4.3.9_v1.2.15/x86_64-qbittorrent-nox
chmod +x x86_64-qbittorrent-nox
./x86_64-qbittorrent-nox

y を入力してから ctrl+c で終了すれば大丈夫です

cat << "EOF" > /etc/systemd/system/qbittorrent.service
[Unit]
Description=qBittorrent Daemon Service
After=network.target

[Service]
LimitNOFILE=512000
User=root
ExecStart=/root/x86_64-qbittorrent-nox

[Install]
WantedBy=multi-user.target
EOF
# 設定を更新
systemctl daemon-reload
# サービスを開始
systemctl start qbittorrent
# ステータスを確認
systemctl status qbittorrent

プログラムを再起動 / 停止する必要がある場合は
kill コマンドを使用してプログラムを終了してください
ps -aux | grep qbittorrent
kill 対応する番号
例えば kill 11111
その後、プロセスデーモンを開いて使用できます

剣皇スクリプト#

wget https://github.com/maintell/webBenchmark/releases/download/0.6/webBenchmark_linux_x64
chmod +x webBenchmark_linux_x64
./webBenchmark_linux_x64 -c 32 -s https://target.url

その他のスクリプト#

swap 追加 / 削除スクリプト#

wget https://www.moerats.com/usr/shell/swap.sh && bash swap.sh

dd windows#

萌咖大佬のスクリプト、これを使うべきです。これの方が古いアドレスの成功率が高く、互換性も良好です

bash <(wget --no-check-certificate -qO- 'https://raw.githubusercontent.com/MoeClub/Note/master/InstallNET.sh') -d 11 -v 64 -p パスワード -port ポート -a -firmware

ワンクリックでデフォルト SSH ポートを変更、自分で 2222 に置き換えてください#

sed -i 's/#Port\ 22/Port\ 2222/' /etc/ssh/sshd_config && systemctl reload ssh

ワンクリックで /var/log/ ディレクトリ内の期限切れログをクリア#

find /var/log/ -name "*.1" -exec rm -rf {} \; && find /var/log/ -name "*.log.1" -exec rm -rf {} \; && find /var/log/ -name "*.gz" -exec rm -rf {} \;

ストリーミングメディア検出:#

bash <(curl -L -s check.unlock.media)

現在使用した中で最も使いやすく、機能が最も充実した warp スクリプト#

wget -N https://raw.githubusercontent.com/fscarmen/warp/main/warp-go.sh && bash warp-go.sh [option] [lisence]

楼主は主スレッドを更新し、ワンクリックで Linux システムを DD することができるように私のものを追加してください。Redhat 7 8 9 をサポートし、CentOS、AlmaLinux、RockyLinux、Fedora、Debian、Redhat、ARM64 AMD64 を自動的に識別して変換し、手動でハードウェアアーキテクチャパラメータを追加する必要がなく、grub1 と grub2 をスムーズに切り替え、Debian と Redhat を無限に相互インストールし、ゲストのタイムゾーンを自動設定し、国内ソースに接続して最適化し、さらにインテリジェントな動的、静的ネットワークパラメータ設定を行い、IPv4 IPv6 デュアルスタックマシン、IPv6 単一スタックマシン、甲骨文の最適化が良好です。Github アドレス:https://github.com/leitbogioro/Tools

ダウンロード:

wget --no-check-certificate -qO InstallNET.sh 'https://raw.githubusercontent.com/leitbogioro/Tools/master/Linux_reinstall/InstallNET.sh' && chmod a+x InstallNET.sh

依存関係のインストール:

wget をインストールすれば大丈夫です

Debian シリーズ:

apt update -y

apt install wget -y

Redhat シリーズ(CentOS / AlmaLinux / RockyLinux / OracleLinux / Fedora / VzLinux):

yum update --allowerasing -y

yum install wget -y

ddLinux の迅速なスタート:#

#debian
bash InstallNET.sh -debian
#centos
bash InstallNET.sh -centos
#RockyLinux
bash InstallNET.sh -rockylinux
#almalinux
bash InstallNET.sh -almalinux
#fedora
bash InstallNET.sh -fedora
#ubuntu
bash InstallNET.sh -ubuntu
パラメータの詳細:
-debian 9/10/11 : Debian 9+

-centos 7/8/9-stream: CentOS 7+

-almalinux/alma 8/9: AlmaLinux 8+

-rockylinux/rocky 8/9: RockyLinux 8+

-fedora 34/35/36/37: Fedora 34+

-ubuntu 16.04/18.04/20.04: Ubuntu 16.04~20.04

-mirror "有効なソースリンク"

-port "1~65535"

-pwd 'カスタムパスワード、あまり複雑でないことを推奨し、特殊記号を含まないことを推奨、デフォルト:LeitboGi0ro'

--network "dhcp/auto or static/manual" #動的または静的ネットワーク、オプションで追加可能、スクリプトが自動的に識別

#二つのハイフンが付いたパラメータはスクリプトの実行の最後に置くべきです。

vimsa#

wget -P /root -N --no-check-certificate "https://raw.githubusercontent.com/mack-a/v2ray-agent/master/install.sh" && chmod 700 /root/install.sh && /root/install.sh

より安定した翻訳ソフト

v2ray#

インストールコマンド#

source <(curl -sL https://multi.netlify.app/v2ray.sh) --zh

アップグレードコマンド(設定ファイルを保持して更新)#

source <(curl -sL https://multi.netlify.app/v2ray.sh) -k

アンインストールコマンド#

source <(curl -sL https://multi.netlify.app/v2ray.sh) --remove
v2ray/xray [-h|help] [options]
-h, help ヘルプを表示
-v, version バージョン番号を表示
start V2Rayを起動
stop V2Rayを停止
restart V2Rayを再起動
status V2Rayの実行状態を表示
new 新しいv2ray json設定ファイルを再構築
update V2Rayを最新のリリースバージョンに更新
update [version] 指定されたバージョンにV2Rayを更新
update.sh multi-v2rayを最新バージョンに更新
add ポートグループを追加
add [protocol] 新しいプロトコルのグループを追加し、ポートをランダムに設定します。例:v2ray add utp
del ポートグループを削除
info 設定を表示
port ポートを変更
tls tlsを変更
tfo tcpFastOpenを変更
stream 転送プロトコルを変更
cdn cdnを通す
stats v2rayトラフィック統計
iptables iptablesトラフィック統計
clean ログをクリア
log ログを表示
rm coreをアンインストール

ネットワーク再インストール alpine Linux ディストリビューションのスクリプト~**#

sh <(curl -k 'https://cdn.jsdelivr.net/gh/52fancy/NetInstallAlpine/alpine.sh')

【2023 スクリプト収集】常用スクリプトバックアップ

https://hostloc.com/thread-1097221-1-1.html
(出典:グローバルホスティング交流フォーラム)

読み込み中...
文章は、創作者によって署名され、ブロックチェーンに安全に保存されています。