The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

[Resolved] [Case 95621] Optimize Website - No longer working

Discussion in 'EasyApache' started by lukapaunovic, Apr 3, 2014.

  1. lukapaunovic

    lukapaunovic Active Member

    Joined:
    Jul 29, 2012
    Messages:
    34
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Užice, Serbia
    cPanel Access Level:
    Root Administrator
    When client tries to enable or disable "Optimize Website" in cPanel, this error is shown:

    Code:
    OptimizeWS::optimizews(,) failed: Modification of non-creatable array value attempted, subscript -1 at /usr/local/cpanel/Cpanel/OptimizeWS.pm line 104, <HC> line 52. 
    I ran easyapache, didn't fix the issue.
    Any fix? :confused:

    Update:

    I tried to fix /usr/local/cpanel/Cpanel/OptimizeWS.pm with Check/Repair a Perl Script
    Didn't worked
    Here is output:

    Code:
    -- Missing Cpanel::Serverinfo. Starting installation -- 
    
    Checking C compiler....C compiler (/usr/bin/gcc) OK (cached Thu Apr  3 00:52:09 2014)
    Tuned C compiler not available because it is not enabled....Done
    Method: Using Perl Expect, Installer: cpanm
    cpanm (App::cpanminus) 1.6916 on perl 5.010001 built for x86_64-linux-thread-multi
    Work directory is /home/.cpanm/work/1396561300.819720
    You have make /usr/bin/make
    Falling back to HTTP::Tiny 0.029
    You have /bin/tar: tar (GNU tar) 1.23
    Copyright (C) 2010 Free Software Foundation, Inc.
    License GPLv3+: GNU GPL version 3 or later .
    This is free software: you are free to change and redistribute it.
    There is NO WARRANTY, to the extent permitted by law.
    
    Written by John Gilmore and Jay Fenlason.
    You have /usr/bin/unzip
    You have Cpanel::HttpRequest 2.1
    Removing corrupted/broken cpan file /home/.cpan/sources/modules/03modlist.data.gz
    Testing connection speed...(using fast method)....Done
    Ping:0 (ticks) Testing connection speed to cpan.makeperl.org using pureperl...(cached .. 61800.00 bytes/s)...Done
    Ping:0 (ticks) Testing connection speed to cpan.hexten.net using pureperl...(cached .. 56600.00 bytes/s)...Done
    Ping:0 (ticks) Testing connection speed to www.planet-elektronik.de using pureperl...(cached .. 35100.00 bytes/s)...Done
    Ping:0 (ticks) Testing connection speed to mirror.netcologne.de using pureperl...(cached .. 28200.00 bytes/s)...Done
    Ping:1 (ticks) Testing connection speed to cpan.panu.it using pureperl...(cached .. 11500.00 bytes/s)...Done
    Five usable mirrors located
    Ping:9 (ticks) Testing connection speed to 208.43.108.66 using pureperl...(5790.00 bytes/s)...Done
    Ping:10 (ticks) Testing connection speed to 216.38.56.98 using pureperl...(using cached speed)...Done
    Ping:11 (ticks) Testing connection speed to 67.205.110.4 using pureperl...(using cached speed)...Done
    Three usable fallback mirrors located
    Fetching http://cpan.makeperl.org/index.html (connected:0).......(request attempt 1/12)...Resolving cpan.makeperl.org...(resolve attempt 1/65)......connecting to 5.9.39.101...@5.9.39.101......connected......receiving...100%......request success......Done
    Mirror Check passed for cpan.makeperl.org (/index.html)
    Searching on cpanmetadb ...
    Fetching http://cpanmetadb.cpanel.net/v1.0/package/Cpanel::Serverinfo (connected:0).......(request attempt 1/12)...Resolving cpanmetadb.cpanel.net...(resolve attempt 1/65)......connecting to 208.74.124.130...@208.74.124.130......connected......receiving...Error 404 while fetching URL http://cpanmetadb.cpanel.net//v1.0/package/Cpanel::Serverinfo
    ...skipping 208.74.124.130......server closed connection...Searching Cpanel::Serverinfo on cpanmetadb (http://cpanmetadb.cpanel.net/v1.0/package/Cpanel::Serverinfo) ...
    Fetching http://cpanmetadb.cpanel.net/v1.0/package/Cpanel::Serverinfo (connected:0).......(request attempt 1/12)......connecting to 208.74.124.130...@208.74.124.130......connected......receiving...Error 404 while fetching URL http://cpanmetadb.cpanel.net//v1.0/package/Cpanel::Serverinfo
    ...skipping 208.74.124.130......server closed connection...Source: fastest CPAN mirror ... ! Couldn't find module or a distribution Cpanel::Serverinfo ()
    Perl Expect failed with non-zero exit status: 256
    
    CPAN fallback mode is active!
    Method: Using Perl Expect, Installer: cpan
    Testing connection speed...(using fast method).....Done
    Ping:0 (ticks) Testing connection speed to cpan.makeperl.org using pureperl...(cached .. 61800.00 bytes/s)...Done
    Ping:0 (ticks) Testing connection speed to cpan.hexten.net using pureperl...(cached .. 56600.00 bytes/s)...Done
    Ping:0 (ticks) Testing connection speed to www.planet-elektronik.de using pureperl...(cached .. 35100.00 bytes/s)...Done
    Ping:0 (ticks) Testing connection speed to mirror.netcologne.de using pureperl...(cached .. 28200.00 bytes/s)...Done
    Ping:1 (ticks) Testing connection speed to cpan.panu.it using pureperl...(cached .. 11500.00 bytes/s)...Done
    Five usable mirrors located
    Ping:10 (ticks) Testing connection speed to 216.38.56.98 using pureperl...(using cached speed)...Done
    Ping:11 (ticks) Testing connection speed to 67.205.110.4 using pureperl...(using cached speed)...Done
    Ping:9 (ticks) Testing connection speed to 208.74.125.42 using pureperl...(using cached speed)...Done
    Three usable fallback mirrors located
    Mirror Check passed for cpan.makeperl.org (/index.html)
    Disabling /bin/wget since LWP is available at /usr/local/cpanel/Cpanel/cPCPAN/Config.pm line 76.
    Disabling /bin/ftp since Net::FTP is available at /usr/local/cpanel/Cpanel/cPCPAN/Config.pm line 81.
    Unknown config variable 'gmake'
    commit: wrote '/usr/share/perl5/CPAN/Config.pm'
    Reading '/home/.cpan/Metadata'
      Database was generated on Thu, 03 Apr 2014 18:06:23 GMT
    Warning: Cannot install Cpanel::Serverinfo, don't know what it is.
    Try the command
    
        i /Cpanel::Serverinfo/
    
    to find objects with matching identifiers.
    CPAN: Time::HiRes loaded ok (v1.9721)
    perlmod--Install done
    
    The following modules were installed for /usr/local/cpanel/Cpanel/OptimizeWS.pm:
    	Cpanel::Serverinfo
    
    !! We have already tried to install Cpanel::Serverinfo. Please manually troubleshoot the installation of Cpanel::Serverinfo !!
    
    Check Complete
     
    #1 lukapaunovic, Apr 3, 2014
    Last edited: Apr 3, 2014
  2. vanessa

    vanessa Well-Known Member
    PartnerNOC

    Joined:
    Sep 26, 2006
    Messages:
    817
    Likes Received:
    22
    Trophy Points:
    18
    Location:
    Virginia Beach, VA
    cPanel Access Level:
    DataCenter Provider
    Based on what the code on that line is trying to do, it's possible that perhaps your .htaccess is not writeable. Check .htaccess in public_html and make sure it's owned by user:user and is at least 644. Then tell cPanel how cute they are.
     
  3. lukapaunovic

    lukapaunovic Active Member

    Joined:
    Jul 29, 2012
    Messages:
    34
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Užice, Serbia
    cPanel Access Level:
    Root Administrator
    .htaccess file in /home/user/.htaccess is owned by user:user and has 0644 premissions.
    What else could be the problem?
     
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,675
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    An internal case is open to address the issue you have reported. For reference, the case number is 95621. There is currently no time frame available on when a resolution might be released, but feel free to monitor the change log for that case number. One temporary workaround you could try is renaming the existing .htaccess file and then trying to enable/disable website optimization to see if it adds the correct entries. Remember to add back any additional entries to the .htaccess file (e.g. Mod_Rewrite rules).

    Thank you.
     
  5. cPanne

    cPanne Member
    Staff Member

    Joined:
    Oct 4, 2011
    Messages:
    7
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Cypress, Texas, United States
    cPanel Access Level:
    Website Owner
    If you see this issue, there is no /home/[cPanel user]/.htaccess file or the /home/[cPanel user]/.htaccess file is completely empty

    Here is a temporary solution:

    To be certain you are not over-writing any existing data:
    Code:
    # mv /home/[cPanel user]/.htaccess /home/[cPanel user]/.htaccess.bak
    
    To fix the issue with Optimize Website:
    Code:
    # echo  > /home/[cPanel user]/.htaccess; chown [cPanel user].[cPanel user] /home/[cPanel user]/.htaccess
    
    cPanel >> Software/Services >> Optimize Website should work as expected once there is an existing .htaccess file with some content in /home/[cPanel user]/.htaccess
     
  6. nunomigpe

    nunomigpe Registered

    Joined:
    Sep 12, 2013
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hi all

    I try this solutions but i have something like:

    .htaccess: Permission denied

    I delete with Fillezilla with root login, in the cpanel etc... but the fille keeps appearing

    Don´t know why

    Best Regards
     
  7. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,675
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    What permissions/ownership values is the file created with?

    Thank you.
     
  8. nunomigpe

    nunomigpe Registered

    Joined:
    Sep 12, 2013
    Messages:
    3
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    The permissions are 0644 I can change them but even then if i delete it appears again with 0644

    Best Regards
     
  9. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,675
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    The .htaccess file is required if you want to use the "Optimize Website" feature. Were you able to review this post to see if that helped?

    Thank you.
     
  10. egillette

    egillette Well-Known Member

    Joined:
    Jan 5, 2010
    Messages:
    68
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Orlando, FL
    cPanel Access Level:
    DataCenter Provider
    I have the same exact issue. . .

    Here is the contents of my .htaccess file:

    Code:
    # BEGIN WordPress
    <IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteRule ^index\.php$ - [L]
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule . /index.php [L]
    </IfModule>
    # END WordPress
    
    In addition:

    Code:
    -rw-r--r--. 1 money money 236 Apr 15 17:42 .htaccess
    
    And the public_html directory above it?

    Code:
    drwxr-xr-x.  8 money money  4.0K Apr 15 17:41 public_html/
    
    cPanel user is obviously "money" -- I'm running Apache 2.x with MOD_RUID2 (security) and PHP as a DSO (speed).

    This is actually the first server I've noticed this issue on. . .

    Here is the output from httpd / php:

    Code:
    root@tres [/home/money]# httpd -v
    Server version: Apache/2.2.27 (Unix)
    Server built:   Apr 10 2014 11:15:25
    Cpanel::Easy::Apache v3.24.15 rev9999
    
    root@tres [/home/money]# php -v
    PHP 5.3.28 (cli) (built: Apr 10 2014 11:21:59)
    Copyright (c) 1997-2013 The PHP Group
    Zend Engine v2.3.0, Copyright (c) 1998-2013 Zend Technologies
        with eAccelerator v0.9.6.1-ea, Copyright (c) 2004-2012 eAccelerator, by eAccelerator
        with the ionCube PHP Loader v4.4.1, Copyright (c) 2002-2013, by ionCube Ltd., and
        with Zend Guard Loader v3.3, Copyright (c) 1998-2010, by Zend Technologies
    root@tres [/home/money]#
    
    
    Please advise. . .
     
    #10 egillette, Apr 15, 2014
    Last edited: Apr 15, 2014
  11. WilliamIsted

    WilliamIsted Registered

    Joined:
    Apr 16, 2014
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    I too am having this problem with a newly created account and .htaccess file. Any progress?
     
  12. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,675
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Please keep in mind the .htaccess file at the root of the problem is not in the public_html directory. It's the .htaccess file within the /home/username directory. A resolution is scheduled for inclusion with a future build of cPanel, but in the meantime, I have verified that Anne's workaround in the post above works as intended.

    Temporary Workaround for Case 95621

    Thank you.
     
  13. egillette

    egillette Well-Known Member

    Joined:
    Jan 5, 2010
    Messages:
    68
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Orlando, FL
    cPanel Access Level:
    DataCenter Provider
    Michael,

    Thanks -- you know honestly I completely overlooked that.

    I thought the issue was with the public_html/.htaccess file and not the one above the public_html directory.

    I'll implement this fix on my machines -- thanks so much!
     
  14. pueblosnet

    pueblosnet Active Member

    Joined:
    Dec 23, 2003
    Messages:
    36
    Likes Received:
    0
    Trophy Points:
    6
    Where can I subscribe to get a notification when this case will be finally fixed?
     
  15. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,675
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    We do not send out notifications for specific cases, but you are welcome to monitor our change log:

    cPanel - Change Log

    Thank you.
     
  16. Serra

    Serra Well-Known Member

    Joined:
    Oct 27, 2005
    Messages:
    213
    Likes Received:
    4
    Trophy Points:
    18
    Location:
    Florida
    I too am seeing this problem. cPanel creates a lock file, but then can't do anything. I've tried creating an empty file and also tried deleting it turning it on without a file there.

    Anyway, a work around is to take the code from another .htaccess and put it in the one you want to turn this on for and that will turn it on.
     
  17. cPanelPeter

    cPanelPeter Technical Analyst III
    Staff Member

    Joined:
    Sep 23, 2013
    Messages:
    569
    Likes Received:
    15
    Trophy Points:
    18
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hello,

    Please don't just create an empty file (0 bytes). The file must be greater than 0.
    So something like this:

    Code:
    # echo "" > /home/CPUSERNAME/.htaccess
    
    should fix the issue. if your .htaccess file is NOT 0 bytes, then don't run the command above. It will erase everything within the file.
     
  18. cPanelJared

    cPanelJared Technical Analyst
    Staff Member

    Joined:
    Feb 25, 2010
    Messages:
    1,842
    Likes Received:
    18
    Trophy Points:
    38
    Location:
    Houston, TX
    cPanel Access Level:
    Root Administrator
    This problem is fixed in cPanel 11.42.1.15. To fix this problem, all you need to do is update cPanel. You can update at any time by running this command:

    Code:
    # /usr/local/cpanel/scripts/upcp --force
    You can see that 95621 is one of the cases that was fixed in 11.42.1.15, by viewing our changelog:

    http://documentation.cpanel.net/display/ALD/11.42+Change+Log
     
Loading...
Similar Threads - [Resolved] [Case 95621]
  1. guldvog
    Replies:
    10
    Views:
    1,672

Share This Page