Join the community today
Register Now

Error in wordpress log

Discussion in 'Blogs & CMS usage' started by jdan1457, Apr 8, 2017.

  1. jdan1457

    jdan1457 New Member

    14
    2
    3
    Dec 20, 2016
    Ratings:
    +2
    Local Time:
    2:40 PM
    1.11.13
    mariadb10
    I'm trying to upload a zip file to a new website. I'm getting this error [error] 8537#8537: *2 client intended to send too large body: 186654604 bytes

    I've changed the php.ini file and the default_constant.php file in wordpress to have larger file sizes (1024MB) and longer execution time (3000). What else do I need to change to get this to work?
     
  2. jdan1457

    jdan1457 New Member

    14
    2
    3
    Dec 20, 2016
    Ratings:
    +2
    Local Time:
    2:40 PM
    1.11.13
    mariadb10
    Also when I go to upload media it shows the max file size as 1GB, so I'm not quite sure why the zip file won't import as its only 178MB
     
  3. eva2000

    eva2000 Administrator Staff Member

    30,156
    6,785
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,136
    Local Time:
    4:40 AM
    Nginx 1.13.x
    MariaDB 5.5
    Don't edit php.ini directly. For custom php settings read centminmod.com/phpfpm.html#customphpini. You might want to create /etc/centminmod/php.d/b_customphp.ini to override centmin mod defaults at /etc/centminmod/php.d/a_customphp.ini and restart PHP-FPM.

    Also outlined in Getting Started Guide Step 17
     
  4. jdan1457

    jdan1457 New Member

    14
    2
    3
    Dec 20, 2016
    Ratings:
    +2
    Local Time:
    2:40 PM
    1.11.13
    mariadb10
    Hi, I followed the steps and created the customphp.ini. I'm still having the same problem. Do I need to change any nginx or php-cli files maybe? Anywhere else that has affect on upload file size?
     
  5. eva2000

    eva2000 Administrator Staff Member

    30,156
    6,785
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,136
    Local Time:
    4:40 AM
    Nginx 1.13.x
    MariaDB 5.5
    output for
    Code (Text):
    php --ini

    and contents of your customphp.ini file ?
     
  6. jdan1457

    jdan1457 New Member

    14
    2
    3
    Dec 20, 2016
    Ratings:
    +2
    Local Time:
    2:40 PM
    1.11.13
    mariadb10
    php --ini
    Configuration File (php.ini) Path: /usr/local/lib
    Loaded Configuration File: /usr/local/lib/php.ini
    Scan for additional .ini files in: /etc/centminmod/php.d
    Additional .ini files parsed: /etc/centminmod/php.d/a_customphp.ini,
    /etc/centminmod/php.d/curlcainfo.ini,
    /etc/centminmod/php.d/geoip.ini,
    /etc/centminmod/php.d/igbinary.ini,
    /etc/centminmod/php.d/imagick.ini,
    /etc/centminmod/php.d/mailparse.ini,
    /etc/centminmod/php.d/memcache.ini,
    /etc/centminmod/php.d/memcached.ini,
    /etc/centminmod/php.d/redis.ini,
    /etc/centminmod/php.d/zendopcache.ini

    customphp.ini
    date.timezone = UTC
    max_execution_time = 1000
    short_open_tag = On
    realpath_cache_size = 384k
    realpath_cache_ttl = 28800
    upload_max_filesize = 1024M
    memory_limit = 1024M
    post_max_size = 1024M
    expose_php = Off
    mail.add_x_header = Off
    max_input_nesting_level = 128
    max_input_vars = 10000
    mysqlnd.net_cmd_buffer_size = 16384
    ;always_populate_raw_post_data=-1
    file_uploads = On

    Sorry I'm not sure how to properly format the code in posts
     
  7. eva2000

    eva2000 Administrator Staff Member

    30,156
    6,785
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,136
    Local Time:
    4:40 AM
    Nginx 1.13.x
    MariaDB 5.5
    for posting code you might want to use CODE tags for code How to use forum BBCODE code tags :)

    php --ini output doesn't list your customphp.ini file at /etc/centminmod/php.d/customphp.ini so it isn't loaded and as per centminmod.com/phpfpm.html#customphpini the name of the file matters as alpha-numeric order of files listed at php --ini determines which file's settings take priority/override previous files listed
     
  8. jdan1457

    jdan1457 New Member

    14
    2
    3
    Dec 20, 2016
    Ratings:
    +2
    Local Time:
    2:40 PM
    1.11.13
    mariadb10
    That contents that I showed come from /etc/centminmod/php.d/a_customphp.ini.
    Is it critical to create /etc/centminmod/php.d/b_customphp.ini?
     
  9. eva2000

    eva2000 Administrator Staff Member

    30,156
    6,785
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,136
    Local Time:
    4:40 AM
    Nginx 1.13.x
    MariaDB 5.5
    yes as outlined at centminmod.com/phpfpm.html#customphpini
     
  10. eva2000

    eva2000 Administrator Staff Member

    30,156
    6,785
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,136
    Local Time:
    4:40 AM
    Nginx 1.13.x
    MariaDB 5.5
    also make sure to restart php-fpm service for changes to take effect
     
  11. eva2000

    eva2000 Administrator Staff Member

    30,156
    6,785
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,136
    Local Time:
    4:40 AM
    Nginx 1.13.x
    MariaDB 5.5
    whoops should of re-read that, that is related to nginx setting not php hehe

    in /usr/local/nginx/conf/nginx.conf edit
    Code (Text):
    client_max_body_size 50m;
    


    see Module ngx_http_core_module
     
  12. jdan1457

    jdan1457 New Member

    14
    2
    3
    Dec 20, 2016
    Ratings:
    +2
    Local Time:
    2:40 PM
    1.11.13
    mariadb10

    Thank You!! That solved it.

    Another issue I'm having is with letsencrypt ssl https, my site shows the red not secure in my browser. I've done other sites with CMM using letsencrypt and never had this issue.
     
  13. eva2000

    eva2000 Administrator Staff Member

    30,156
    6,785
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,136
    Local Time:
    4:40 AM
    Nginx 1.13.x
    MariaDB 5.5
    You have mixed content issue so need to adjust your web app and/or web site style itself see What Is Mixed Content? - KeyCDN Support