问题:

安装成功后,打开首页的文章页面、关于页面,或者在后台界面输入账号密码点击登录,都报404 Not Found错误。

解决办法:

在/usr/local/nginx/conf/vhost/下找到你的typecho站点配置文件(文件名类似xxxxx.conf),然后:

1、确保有“include typecho.conf;”这么一行,并且没有被“#”号注释;

2、用“#”号注释“try_files $uri =404;”这一行;

3、取消“#include pathinfo.conf;”这一行前面的的“#”号;

修改正确的话,typecho站点conf配置文件看起来如下:

include typecho.conf;  
#error_page   404   /404.html;  
location ~ [^/]\.php(/|$)  
    {  
        # comment try_files $uri =404; to enable pathinfo  
        #try_files $uri =404;  
        fastcgi_pass  unix:/tmp/php-cgi.sock;  
        fastcgi_index index.php;  
        include fastcgi.conf;  
        include pathinfo.conf;  
    }

4、重启nginx或lnmp:

# service nginx restart  

或者重启lnmp也行:

# /root/lnmp restart  

5、打开你的typecho站点文章页或者登录管理页面,验证问题是不是已经解决了!

非特殊说明,本博所有文章均为博主原创。

如若转载,请注明出处:http://www.notemi.cn/lnmp---solve-the-installation-of-typecho-background-landing-404-problems.html

添加新评论

icon_question.pngicon_razz.pngicon_sad.pngicon_evil.pngicon_exclaim.pngicon_smile.pngicon_redface.pngicon_biggrin.pngicon_surprised.pngicon_eek.pngicon_confused.pngicon_cool.pngicon_lol.pngicon_mad.pngicon_twisted.pngicon_rolleyes.pngicon_wink.pngicon_idea.pngicon_arrow.pngicon_neutral.pngicon_cry.pngicon_mrgreen.png

9 + 8 =