Tools/README.md

110 lines
4.1 KiB
Markdown
Raw Normal View History

2018-10-22 22:45:40 +08:00
# Tools
Something about scripts
2018-10-10 16:22:16 +08:00
# Linux reinstall useage
## Notes:
If your VPS is base by Bandwagon and reinstalled OS which constructed by Bandwagon just now, you must reboot and then execute it.
2021-10-04 10:45:14 +08:00
## Features:
Support Debian 8+, Ubuntu 14.04+, CentOS 6+, you can modify architecture, mirror, firmware, ssh port, password etc for easily to reinstall a cleanly Linux system.
2018-10-10 16:22:16 +08:00
## Download:
<pre><code>wget --no-check-certificate -qO InstallNET.sh 'https://raw.githubusercontent.com/leitbogioro/WedTools/master/Linux_reinstall/InstallNET.sh' && chmod a+x InstallNET.sh</code></pre>
## Install
2018-10-10 16:30:57 +08:00
### Useage
2021-10-04 10:45:14 +08:00
<pre><code>bash InstallNET.sh -[OS name] [OS version] -v [Architecture x86 or x64] -a[Automatic, recommend]/m[Manually in VNC] --mirror '[a Debian/Ubuntu/Debian resource]' -firmware/-firmware --cdimage 'ustc' [these only for Debian, if you're living in China, you can prefer it to University of Science and Technology of China mirror for downloading quickly, default mirror is debian.org] -ssh [ssh port] -p [password]</pre></code>
2018-10-10 16:32:42 +08:00
### Parameters Describes
2021-10-04 10:53:47 +08:00
**-d** : Debian
2018-10-10 16:31:31 +08:00
<br />
2021-10-04 10:46:30 +08:00
<br />
2021-10-04 10:56:07 +08:00
2021-10-04 10:53:47 +08:00
**-u**: Ubuntu
2018-10-10 16:31:31 +08:00
<br />
2021-10-04 10:46:30 +08:00
<br />
2021-10-04 10:56:07 +08:00
2021-10-04 10:53:47 +08:00
**-c**: CentOS
2018-10-10 16:31:31 +08:00
<br />
2021-10-04 10:46:30 +08:00
<br />
2021-10-04 10:56:07 +08:00
2021-10-04 10:53:47 +08:00
**32/i386 64/amd64**: architecture
2018-10-10 16:31:31 +08:00
<br />
2021-10-04 10:46:30 +08:00
<br />
2021-10-04 10:56:07 +08:00
2021-10-04 10:53:47 +08:00
**--mirror**: Install files resource, you can select one which nearest for actual location of your server to upspeed the installation.
2021-10-04 10:45:49 +08:00
<br />
<br />
2021-10-04 10:56:07 +08:00
2021-10-04 10:58:24 +08:00
for Debian, mirror lists are here:
<br />
2021-10-04 10:47:48 +08:00
<pre><code>https://www.debian.org/mirror/list.zh-cn.html</code></pre>
2021-10-04 10:45:49 +08:00
<br />
2021-10-04 10:58:56 +08:00
2021-10-04 10:58:24 +08:00
for Ubuntu, mirror lists are here:
<br />
2021-10-04 10:53:47 +08:00
<pre><code>https://wiki.ubuntu.org.cn/%E6%BA%90%E5%88%97%E8%A1%A8</code></pre>
2021-10-04 10:47:48 +08:00
<br />
2021-10-04 10:58:56 +08:00
2021-10-04 10:58:24 +08:00
for CentOS, mirror lists are here:
<br />
2021-10-04 10:53:47 +08:00
<pre><code>https://www.centos.org/download/mirrors/</code></pre>
2021-10-04 10:45:14 +08:00
<br />
2021-10-04 10:55:28 +08:00
2021-10-04 10:53:47 +08:00
**-firmware/-firmware --cdimage 'ustc'**: specify hardware drivers for Debian.
<br />
<br />
2021-10-04 10:55:28 +08:00
2021-10-04 10:53:47 +08:00
**-ssh**: you can pre-specify ssh port of system, range is 1~65535.
<br />
<br />
2021-10-04 10:55:28 +08:00
2021-10-04 10:53:47 +08:00
**-p**: you can pre-specify ssh password of system, default is 'MoeClub.org'.
2021-10-04 10:45:14 +08:00
<br />
2021-10-04 10:56:54 +08:00
<br />
2021-10-04 10:45:14 +08:00
2021-10-04 10:57:10 +08:00
## for example:
2018-10-10 16:22:16 +08:00
### Debian 8
<pre><code>bash InstallNET.sh -d 8 -v 64 -a</code></pre>
### Debian 9
<pre><code>bash InstallNET.sh -d 9 -v 64 -a</code></pre>
2021-10-04 10:45:14 +08:00
### Debian 10 (Default)
<pre><code>bash InstallNET.sh -d 10 -v 64 -a</code></pre>
### Debian 10 (prefer mirror in China with firmware, recommend for Chinese users)
<pre><code>bash InstallNET.sh -d 10 -v 64 -a --mirror 'https://mirrors.tuna.tsinghua.edu.cn/debian/' -firmware --cdimage 'ustc'</code></pre>
<pre><code>bash InstallNET.sh -d 10 -v 64 -a --mirror 'http://mirrors.163.com/debian/' -firmware --cdimage 'ustc'</code></pre>
<pre><code>bash InstallNET.sh -d 10 -v 64 -a --mirror 'http://mirrors.cloud.tencent.com/debian/' -firmware --cdimage 'ustc'</code></pre>
### Debian 11
<pre><code>bash InstallNET.sh -d 11 -v 64 -a</code></pre>
2018-10-10 16:22:16 +08:00
### Ubuntu 16.04
<pre><code>bash InstallNET.sh -u 16.04 -v 64 -a</code></pre>
### Ubuntu 18.04
<pre><code>bash InstallNET.sh -u 18.04 -v 64 -a</code></pre>
2021-10-04 10:45:14 +08:00
### Ubuntu 20.04
<pre><code>bash InstallNET.sh -u 20.04 -v 64 -a</code></pre>
2018-10-10 16:22:16 +08:00
### Cent OS 6
<pre><code>bash InstallNET.sh -c 6.9 -v 64 -a</code></pre>
### Cent OS 7
<pre><code>bash InstallNET.sh -c 7.5 -v 64 -a</code></pre>
2018-10-10 16:24:37 +08:00
## Default Configurations
### Time zone
Shanghai Asia
### User name
root
### Password
2021-10-04 10:45:14 +08:00
MoeClub.org
2021-10-04 11:00:51 +08:00
### Port
22
2018-10-10 16:33:05 +08:00
<br />
2018-10-10 16:33:23 +08:00
<br />
2018-10-10 16:24:37 +08:00
<b>After installed system, you must change passwords immediately.</b>
2018-10-22 22:45:40 +08:00
<br />
2018-10-22 22:46:24 +08:00
<br />
2018-10-22 22:45:40 +08:00
# GroupPolicy import and export
This .bat script can only run in Windows. Although only one group-policy rule in Windows can be exported at a time and not support a global one and also have no GUI entrance to import another backuped group policy which exported from another computer. It can help you import or export GroupPolicy conveniently.
## Attentions
2018-10-22 22:57:50 +08:00
<ul>
<li>Compatible with all versions of Windows.</li>
<li>Only support the group-policy rules which exported by this script.</li>
<li>If you want to export group-policy rules. Folder which included group-policy files corresponds to current OS version strictly. Not support export rules which is different from current OS version.</li>
<li>Export operation is irreversible, be cautious to run it</li>
2018-10-22 22:58:22 +08:00
<li>I provided a suggested rules file about Windows Server 2016.</li>
<li>You should run it on desktop.</li>
2018-10-22 22:57:50 +08:00
</ul>