Want to subscribe to topics you're interested in?
Become a Member

Nginx PageSpeed ngx_pagespeed 1.10.33.5 and configuration setup

Discussion in 'Nginx, PHP-FPM & MariaDB MySQL' started by pamamolf, Feb 19, 2016.

  1. pamamolf

    pamamolf Well-Known Member

    2,498
    229
    63
    May 31, 2014
    Ratings:
    +390
    Local Time:
    12:02 PM
    Nginx-1.13.x
    MariaDB 10.1.x
    Ok i install it and and i am looking to check if it works :)

    Nginx -V shows the pagespeed module :)

    But where i can access the admin panel of pagespeed?

    Also i just notice here:
    Code:
    /usr/local/nginx/conf/pagespeed.conf
    /usr/local/nginx/conf/pagespeedadmin.conf
    
    this:
    Code:
    pagespeed off;
    Also on my domain conf file:
    Code:
    /usr/local/nginx/conf/conf.d/domain.com.conf
    I can see commented the:
    Code:
    #include /usr/local/nginx/conf/pagespeed.conf;
    #include /usr/local/nginx/conf/pagespeedhandler.conf;
    #include /usr/local/nginx/conf/pagespeedstatslog.conf;
    Are all the above values auto take care from the pagespeed setup?

    Thanks
     
    Last edited: Feb 19, 2016
  2. eva2000

    eva2000 Administrator Staff Member

    28,971
    6,575
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,759
    Local Time:
    7:02 PM
    Nginx 1.13.x
    MariaDB 5.5
  3. pamamolf

    pamamolf Well-Known Member

    2,498
    229
    63
    May 31, 2014
    Ratings:
    +390
    Local Time:
    12:02 PM
    Nginx-1.13.x
    MariaDB 10.1.x
    Ok thanks :)

    What about the :
    Code:
    pagespeed off;
    and
    Code:
    #include /usr/local/nginx/conf/pagespeed.conf;
    #include /usr/local/nginx/conf/pagespeedhandler.conf;
    #include /usr/local/nginx/conf/pagespeedstatslog.conf;
    ?
     
  4. eva2000

    eva2000 Administrator Staff Member

    28,971
    6,575
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,759
    Local Time:
    7:02 PM
    Nginx 1.13.x
    MariaDB 5.5
    also outlined at Nginx PageSpeed - CentminMod.com LEMP Nginx web stack for CentOS for pscontrol command etc
     
    • Informative Informative x 1
  5. pamamolf

    pamamolf Well-Known Member

    2,498
    229
    63
    May 31, 2014
    Ratings:
    +390
    Local Time:
    12:02 PM
    Nginx-1.13.x
    MariaDB 10.1.x
    Ok all working now :)

    But can't set two values that i need using the pscontrol edit :

    Code:
    Purging not enabled: please add
      pagespeed EnableCachePurge on;
    I add this:

    Code:
    pagespeed EnableCachePurge on;
    and for this:
    Code:
    No permission to rewrite http://s1.tinypic.com/files/image.jpg
    i add this:

    Code:
    pagespeed Domain *.tinypic.com;
    Restart Nginx and checking i can't purge cache files again :(
     
  6. eva2000

    eva2000 Administrator Staff Member

    28,971
    6,575
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,759
    Local Time:
    7:02 PM
    Nginx 1.13.x
    MariaDB 5.5
  7. pamamolf

    pamamolf Well-Known Member

    2,498
    229
    63
    May 31, 2014
    Ratings:
    +390
    Local Time:
    12:02 PM
    Nginx-1.13.x
    MariaDB 10.1.x
    Ok as i can see there is no /var/cache/pagespeed/cache.flush such file so i can use :

    Code:
    rm -rf /var/ngx_pagespeed_cache/*
    ngxrestart
    How can i increase the cache size i am getting this?

    Code:
    Increase cache size
    
    Unable to insert object of size: 299836, cache limit is: 35616
    Does pagespeed do on the fly all the optimizations without touching my files (like images) ?
     
  8. eva2000

    eva2000 Administrator Staff Member

    28,971
    6,575
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,759
    Local Time:
    7:02 PM
    Nginx 1.13.x
    MariaDB 5.5
    • Agree Agree x 1
  9. pamamolf

    pamamolf Well-Known Member

    2,498
    229
    63
    May 31, 2014
    Ratings:
    +390
    Local Time:
    12:02 PM
    Nginx-1.13.x
    MariaDB 10.1.x
    Thanks for the info :)

    I hope it will not change my original files with default settings in Centminmod installation :)
     
  10. eva2000

    eva2000 Administrator Staff Member

    28,971
    6,575
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,759
    Local Time:
    7:02 PM
    Nginx 1.13.x
    MariaDB 5.5
    or just setup ngx_pagespeed admin console and just use purge feature there

    upload_2016-2-19_18-49-53.png
     
  11. pamamolf

    pamamolf Well-Known Member

    2,498
    229
    63
    May 31, 2014
    Ratings:
    +390
    Local Time:
    12:02 PM
    Nginx-1.13.x
    MariaDB 10.1.x
    I got the error that i was post exactly there when i click Purge entire Cache :)

    Code:
    Purging not enabled: please add
      pagespeed EnableCachePurge on;
    and then i edit the config using pscontrol edit and i add it inside:
    Code:
    pagespeed EnableCachePurge on;
    Then restart Nginx but was not working (maybe a cache problem) ?
     
  12. pamamolf

    pamamolf Well-Known Member

    2,498
    229
    63
    May 31, 2014
    Ratings:
    +390
    Local Time:
    12:02 PM
    Nginx-1.13.x
    MariaDB 10.1.x
    Is there any file that hold all log data from:
    Code:
    http://hostname.domain.com/pagespeed_global_admin/message_history
    as i am getting a lot of entries there and i don't want to end up with a huge file on my disk ?
     
  13. eva2000

    eva2000 Administrator Staff Member

    28,971
    6,575
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,759
    Local Time:
    7:02 PM
    Nginx 1.13.x
    MariaDB 5.5
    read documentation the log is in memory not disk

    works for me
    Code:
    pagespeed on;
    
    pagespeed EnableCachePurge on;
    pagespeed PurgeMethod PURGE;
    Code:
    curl 'localhost/pagespeed_admin/cache?purge=*'                                
    Purge successful
    Code:
    curl --request PURGE 'localhost/*'
    Purge successful
     
    Last edited: Feb 19, 2016
  14. pamamolf

    pamamolf Well-Known Member

    2,498
    229
    63
    May 31, 2014
    Ratings:
    +390
    Local Time:
    12:02 PM
    Nginx-1.13.x
    MariaDB 10.1.x
    Thanks :)

    But inspecting with Chrome i can see that a few .js files are optimized by pagespeed.....

    Does the default installation is disabled for images like .jpg or .png ?
     
  15. eva2000

    eva2000 Administrator Staff Member

    28,971
    6,575
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +9,759
    Local Time:
    7:02 PM
    Nginx 1.13.x
    MariaDB 5.5
    yes some optimisations like images are disabled in pagespeed.conf (commented out etc), you have to configure and enable them yourself
     
    • Like Like x 1
  16. pamamolf

    pamamolf Well-Known Member

    2,498
    229
    63
    May 31, 2014
    Ratings:
    +390
    Local Time:
    12:02 PM
    Nginx-1.13.x
    MariaDB 10.1.x
    Ok thanks :)

    @RoldanLT

    Do you use pagespeed?

    What filters do you have enabled?

    Looking for some samples :)
     
    Last edited: Feb 20, 2016
  17. RoldanLT

    RoldanLT Well-Known Member

    3,829
    929
    113
    May 25, 2014
    Phillipines
    Ratings:
    +1,258
    Local Time:
    5:02 PM
    1.11
    10.2
    I am not anymore.