比较穷,买不起独服 / 高端 VPS,只能拿 1GB 内存的破烂凑合一下建站。
众所周知,apache2 非常吃资源,经常内存就直接给吃满,所以这时候优化就显得十分重要。
(其实是懒得改成 nginx ///
比较穷,买不起独服 / 高端 VPS,只能拿 1GB 内存的破烂凑合一下建站。
众所周知,apache2 非常吃资源,经常内存就直接给吃满,所以这时候优化就显得十分重要。
(其实是懒得改成 nginx ///
日本 vps 也找了不少,一直在犹豫到底哪个比较好。
aws、sakura、kagoya、conoha、gmocloud、cloudgarage、idcf、webarena、阿里jp。。。。。。
不是太贵就是线路差,要不然就是对国人不大友好。
(有异想天开的同学,三色图上

日本回国直连线路主要有:BBTEC、NTT、IIJ、KDDI、163,这次的 Ablenet 就是双程 IIJ 路线。
测试
完整内容需要登录验证才能查看!… Read the rest
有一句话要说在前头:“Linux配置速成,从入门到跳楼一步走”
很绝望,我去Google了一圈,都没有找到解决方法,还是我自己乱**试出来的。
我不想说话,只是默默的贴上配置。
依次遇到的错误:“Mail content denied”,“dovecot: auth: Fatal: No passdbs specified in configuration file. PLAIN mechanism needs one”,“ dovecot: imap-login: Disconnected: Auth process broken (disconnected before auth was ready, waited 0 secs)”,“dovecot: imap(root): Error: Invalid settings in userdb: userdb returned 0 as uid”,“dovecot: imap(root): Error: Invalid user settings. Refer to server log for more information.”,“error: open database /etc/postfix/vmaps.txt.db: No such file or directory”,“postfix/trivial-rewrite[13636]: error: open file /etc/postfix/vhosts.txt: No such file or directory”,“Temporary lookup failure”
特别是下面这几个,弄了几百年才弄好:
“fatal: no SASL authentication mechanisms”,“ warning: SASL: Connect to private/auth failed: No such file or directory”,“Recipient address rejected: User unknown in local recipient table”,“Relay access denied”… Read the rest
默认的Wordpress文章页面上只会显示文章发布时间,不会显示文章的最后更新时间。

像这种效果
然后去Baidu(垃圾)和Google(厉害)了一圈竟然都没有找到既方便又正确的方法!
本来是想就此放弃的,直到我看到网页源代码中有这么几句… Read the rest
之前apache2的url重写一直开不起来,也搜了很多资料但都没有用。
最近终于找到了解决方法,其实很简单:
只需要
|
1 |
vim /etc/apache2/sites-available/000-default.conf |
|
1 |
然后修改 |
|
1 2 3 4 5 6 7 8 9 10 |
<VirtualHost *:80> <Directory /var/www/html/> Options FollowSymLinks #AllowOverride None 把None改为All使.htaccess作用在所有地方 AllowOverride All Require all granted </Directory> . . . </VirtualHost> |
最后,最关键的一步:
|
1 2 3 |
a2enmod rewrite //开启扩展,apache2专用 //或使用 ln -s /etc/apache2/mods-cuailable/rewrite.load /etc/apache2/mods-enabled/rewrite.load service apache2 restart |
然后就可以开心的使用啦!
(当时还搞了很久都没有弄出来… Read the rest