🚀RocManga.com

無料漫画、コミックのzip

40 views

yum update
yum install httpd -y
systemctl enable httpd.service
systemctl start httpd.service
systemctl status firewalld
systemctl stop firewalld
systemctl disable firewalld
sestatus
永久关闭
vi /etc/selinux/config
将SELINUX=enforcing改为SELINUX=disabled
设置后需要重启才能生效
wget http://repo.mysql.com/mysql57-community-release-el7-10.noarch.rpm
rpm -Uvh mysql57-community-release-el7-10.noarch.rpm
rpm –import https://repo.mysql.com/RPM-GPG-KEY-mysql-2022
yum install -y mysql-community-server
systemctl start mysqld.service
systemctl status mysqld.service
获取临时密码
grep ‘temporary password’ /var/log/mysqld.log
mysql -uroot -p
修改密码规则操作
mysql> set global validate_password_policy=0;
mysql> set global validate_password_length=1;
ALTER USER ‘root’@’localhost’ IDENTIFIED BY ‘yourpassword’;
授权其他机器远程登录
GRANT ALL PRIVILEGES ON *.* TO ‘root’@’%’ IDENTIFIED BY ‘yourpassword’ WITH GRANT OPTION;
FLUSH PRIVILEGES;
开机自启动
systemctl enable mysqld
systemctl daemon-reload
vi /etc/my.cnf
修改成这样
[mysql]
default-character-set=utf8
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
default-storage-engine=INNODB
character_set_server=utf8
symbolic-links=0
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid
测试登录
systemctl restart mysqld.service
mysql -uroot -h64.176.65.165 -p
yum install php php-mysql -y
enable mod_rewrite on Apache
grep -i AllowOverride /etc/httpd/conf/httpd.conf
修改所有AllowOverride None为AllowOverride All
sudo service httpd restart
查看mod_headers是否已经安装
apachectl -t -D DUMP_MODULES
yum install perl-CGI perl-libwww-perl.noarch perl-DBI perl-DBD-MySQL perl-GD perl-Cache-Memcached -y
LWP::Protocol::https 安装
yum install perl-Crypt-SSLeay -y
yum install perl-Digest-SHA -y
rsync -avP root@165.22.90.22:/home/wwwroot/rocfile/ /home/wwwroot/rocfile
cat db-rs01-2022021515.sql | mysql -u root -p rs01
yum install mod_ssl openssl -y
vi /etc/httpd/conf.d/ssl.conf
#找到以下部分并修改
DocumentRoot “/var/www/html” //去掉#号
ServerName www.example.com:443 //去掉#号,同时将www.example.com修改为你的域名或服务器ip
SSLHonorCipherOrder on //去掉#号
SSLCertificateFile /etc/letsencrypt/live/rocfile.com/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/rocfile.com/privkey.pem
vi /etc/httpd/conf/httpd.conf
DocumentRoot “/var/www/html”
ServerName rocfile.com
ServerAlias
<Directory “/var/www/html”>
Options Indexes FollowSymLinks MultiViews
AllowOverride All
Order allow,deny
Deny From all
Allow From 116.203.222.130
Allow From 127.0.0.1
Options All
ScriptAlias /cgi-bin/ /var/www/cgi-bin/
<Directory “/var/www/cgi-bin”>
AllowOverride All
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
# 开启SSLEngine及设置使用的证书,端口443
SSLEngine on
SSLCertificateFile /etc/letsencrypt/live/rocfile.com/fullchain.pem
SSLCertificateKeyFile /etc/letsencrypt/live/rocfile.com/privkey.pem
chmod 777 -R html cgi-bin
chmod 777 Templates/static logs temp uploads
chmod 666 XFSConfig.pm XFileConfig.pm ipn_log.txt logs.txt
chmod 755 api.cgi cron.pl cron_deleted_email.pl dl.cgi fs.cgi index.cgi index_box.cgi index_dl.cgi ipn.cgi transfer.pl up.cgi upload.cgi uu.cgi
删掉/var/www/cgi-bin .htaccess
yum install php-mbstring
yum install gcc make build-essential
yum install perl-CPAN
perl -MCPAN -e shell
install CPAN
reload cpan
perl -MCPAN -e shell
install MIME::Base64
install Authen::SASL
install XML::Simple
exit