SSH修改端口和密码
修改端口
执行命令,编辑配置文件sshd_config
vi /etc/ssh/sshd_config
修改完之后保存:w
,退出:q
,重启即可。
修改密码
执行命令
passwd
执行命令,编辑配置文件sshd_config
vi /etc/ssh/sshd_config
修改完之后保存:w
,退出:q
,重启即可。
执行命令
passwd
环境是LAMP,网站根目录新建.htaccess
文件:
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>
Nginx的话,看这篇《Typecho Nginx Rewrite规则》。