Zen Cart Logo
Forums / Basic Configuration / Admin Log In Screen (and Cart) VERY slow to display

Admin Log In Screen (and Cart) VERY slow to display

Views: 2,704

Results 1 to 16 of 16
15 Jun 2012, 12:23 PM
#1
ts232 avatar

ts232

Zen Follower

Join Date:
May 2006
Posts:
167
Plugin Contributions:
0

Admin Log In Screen (and Cart) VERY slow to display

This has been going on for quite awhile.

Just pulling up the admin log in screen on my cart can sometimes take 10-20 seconds. Entering credentials and logging in then goes fairly quickly, and the admin system itself seems responsive enough (not great, but better). It doesn't seem to matter whether I have http or https active on the admin.

Possibly related, there are similar delays when the customer uses the Add To Cart button to add an item and go to the Shopping Cart page.

I am thinking this could be related to session generation? I've tried fiddling with different session settings in the config files, and haven't been able to get things any better. Any suggestions for things to try?

Thanks.

15 Jun 2012, 1:17 PM
#2
skrillnet avatar

skrillnet

New Zenner

Join Date:
May 2010
Location:
Arkansas
Posts:
33
Plugin Contributions:
0

Re: Admin Log In Screen (and Cart) VERY slow to display

Can you give some details of your hosting environment? Are you mysql databases on a different server? Do you use shared hosting?

15 Jun 2012, 1:27 PM
#3
ts232 avatar

ts232

Zen Follower

Join Date:
May 2006
Posts:
167
Plugin Contributions:
0

Re: Admin Log In Screen (and Cart) VERY slow to display

This is running on Dreamhost VPS with 1GB of reserved memory and a separate Dreamhost VPS SQL server with 300MB of reserved memory. On both systems I am running well within the amount of reserved memory, and CPU loads are low. Page load times for product pages are pretty snappy, it's just when I get into the admin or front end shopping cart/login/payment pages that things slow down.

15 Jun 2012, 5:33 PM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Admin Log In Screen (and Cart) VERY slow to display

So, are you saying that whenever you click from a non-SSL page to go to an SSL page that it's suddenly slow?

15 Jun 2012, 5:35 PM
#5
ts232 avatar

ts232

Zen Follower

Join Date:
May 2006
Posts:
167
Plugin Contributions:
0

Re: Admin Log In Screen (and Cart) VERY slow to display

DrByte:

So, are you saying that whenever you click from a non-SSL page to go to an SSL page that it's suddenly slow?

Not quite. Even when I run the admin via plain http I have the delay. Similar with the initial shopping cart page, which is non-SSL, but slow to load.

Not sure these two items are related, just putting it out there in the interest of full disclosure.

16 Jun 2012, 1:09 PM
#7
ts232 avatar

ts232

Zen Follower

Join Date:
May 2006
Posts:
167
Plugin Contributions:
0

Re: Admin Log In Screen (and Cart) VERY slow to display

Thanks. I'd already done most of those but rechecked the list just in case. For the admin log in, the delay occurs even before I attempt the login (i.e. just bringing up the initial empty login form). The delay seems to happen only when I access the admin after a time away from it (~24 hours?). Subsequent accesses are pretty snappy.

I am using OpenDNS for my local network DNS so I don't think it's a problem with slow nameserver resolution.

I am beginning to suspect that it could be a problem with my VPS SQL Server having the related admin/customer tables swapped out of memory when they have been inactive for awhile (despite the reserved memory) and it taking a long time to load them. Not sure how I could prove that however. I am checking with my host, but I expect their answer is to upgrade to a $100/month dedicated server which I would rather avoid.

Another possibility seems to be something in my PHP/Zen configurationthat is causing slow session creation. I have turned off all of the ip-to-hostname lookups, so it is not that.

Any other suggestions for things to check on the zen-cart side?

16 Jun 2012, 5:59 PM
#8
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Admin Log In Screen (and Cart) VERY slow to display

I'd be curious if a fresh clean uncustomized install of a new separate ZC shop in another folder and another database, using just the demo products, exhibits the same symptoms or not.

Plus, please list all your addons and every way that you've changed your store from original code.

18 Jun 2012, 3:45 AM
#9
ts232 avatar

ts232

Zen Follower

Join Date:
May 2006
Posts:
167
Plugin Contributions:
0

Re: Admin Log In Screen (and Cart) VERY slow to display

DrByte:

I'd be curious if a fresh clean uncustomized install of a new separate ZC shop in another folder and another database, using just the demo products, exhibits the same symptoms or not.

Plus, please list all your addons and every way that you've changed your store from original code.

I've got a fresh install of a zencart 1.5.0 with just the catalog DB carried over on the same server that loads the admin login page much faster. Unfortunately that 1.5.0 is not a pristine copy, I was working on installing the FEC mod and it has broken the shopping cart link so I cannot check the load time there.

On my production 1.3.9h there are quite a few mods, main ones are:

-Fast and Easy Checkout 1.9.3
-Multi Cross Sell
-Stock by Attributes 1.4.14
-Super Orders 2.0
-Zen Lightbox
-Testimonial Manager
-CSS Flyout Header

I thought the stock by attributes might be the culprit for the slow shopping cart load times, but I disabled "check for stock" and it did not reduce the load times.

Website is http://hardbrakes.com/

18 Jun 2012, 4:05 AM
#10
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Admin Log In Screen (and Cart) VERY slow to display

When two stores in the same account exhibit different performance, I am struck by the need to investigate all the differences between those two stores, in order to identify what's causing the bottleneck.

Sometimes that means creating a new store and slowly building it up to match the behavior of the ill-performing store, until suddenly it breaks ... or nothing is found.

Sometimes it means working the other direction: http://www.zen-cart.com/wiki/index.php/Troubleshoot_-_Diagnosing_Obscure_Issues

19 Jun 2012, 6:23 PM
#11
ts232 avatar

ts232

Zen Follower

Join Date:
May 2006
Posts:
167
Plugin Contributions:
0

Re: Admin Log In Screen (and Cart) VERY slow to display

I will keep digging. Quick question though: when is a php session created for admin and shopping cart? For the former, is it at the blank admin login page or after the first log in attempt? For the shopping cart, is it at the first "add to cart" button press? Knowing this will help me diagnose with my VPS host for possible PHP/apache issues that could be slowing down the session creation. Thanks.

19 Jun 2012, 10:25 PM
#12
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: Admin Log In Screen (and Cart) VERY slow to display

A session is created, or updated, or recreated, on each click/hit to your site.

First visit: session created
Next click: session updated, since already exists.
Start SSL page: session recreated (unless you've turned that off for some peculiar reason) to prevent hijacking

So, the simple answer is: a session is created/updated EVERY time you click (including the first visit).

But I'm somewhat doubtful about your idea that the situation is session-related.

30 Jun 2012, 4:08 PM
#13
prestontmitch avatar

prestontmitch

New Zenner

Join Date:
Mar 2007
Location:
Hatch, NM
Posts:
23
Plugin Contributions:
0

Re: Admin Log In Screen (and Cart) VERY slow to display

I have the exact same thing going on with my install. The login page takes 25-40 seconds to load but once it loads everything loads at normal speeds.

30 Jun 2012, 4:14 PM
#14
ts232 avatar

ts232

Zen Follower

Join Date:
May 2006
Posts:
167
Plugin Contributions:
0

Re: Admin Log In Screen (and Cart) VERY slow to display

I spent a lot of time optimizing my site, and improved the performance significantly. Pingdom.com is a useful tool for this. I experimented with different cache settings in zencart and on the server. The google pagespeed optimization also helped out.

At the end of the day however, the initial admin page was still loading slowly, as were the shopping cart pages. Overall performance was still highly variable. I decided to bite the bullet and switch to a dedicated server and the pages are all loading very quickly now. A HUGE improvement. It is a lot more expensive, but if I just get one or two extra sales a month then it will be worth it.

In general, I would recommend doing all the optimizations you can before switching to dedicated. It is possible to speed the site up significantly with some minor tweaks and images resizes etc.

10 Jul 2012, 6:43 PM
#15
camaro avatar

camaro

New Zenner

Join Date:
Jul 2012
Posts:
10
Plugin Contributions:
0

Re: Admin Log In Screen (and Cart) VERY slow to display

It happens to me sometimes too, but it's very rare and i don't mind that. Try to clean cache maybe?

10 Jul 2012, 9:18 PM
#16
athena avatar

athena

Totally Zenned

Join Date:
Jan 2006
Location:
NM
Posts:
740
Plugin Contributions:
0

Re: Admin Log In Screen (and Cart) VERY slow to display

Just commenting that what resolved this issue for us (THANK YOU THANK YOU!) was to follow the advice in the article below mentioned by DrByte - specifically Admin>Tools>Store Manger>Cleanup Debug Log Files>Confirm

DrByte:

Related FAQ articles to consider:

http://www.zen-cart.com/content.php?63-how-do-i-speed-up-my-site