Jump to content

Memcached feature breaks product update.


Recommended Posts

Hi,

First, I'm not fully sure if I set this up the right way, which might be the source of my problems. It's kind of hard to set the preformance settings without any guides.. yaknow?

Anyways, I installed memcached on my server, which removed the initial warning message. I then "Add a server" and gave it the following settings: IP: 127.0.0.1 / Port: 11211 / Weight: 1

Now it seemed like it was working... FO and BO loaded fine without any errors which is always a good sign. But today back in the office, I was trying to update product details, specifically the attribute quantities. So if Product A has 0 and I increase the stock movement by 1, after saving the new quantity should be 1, right?

Well it remained 0, no matter how many times. So I turned off the cache feature. And reloaded that same products combination page. Everything updated fine. Actually the 10 times I tried saving with the feature on at the time only showed 0, but with it off it showed all 10 increases I had added.

It seems like the cache isn't being refreshed for quantity updates or something.

I don't know if I set something up wrong (like should the ip be that of my server and not localhost?) or if any body else is having the same issues, and this is a bug that I should report. Any feedback is greatly appreciated!!

Thanks!

Link to comment
Share on other sites

Hi mytheory

I had the same problem and I disabled the cache I also enabled force compile (this is normally enabled if you edit your .tpl files, themes and stuff) - but you need to disable that once your web site goes live. I've read in another post that the newest version 1.4.3 has sorted the cache problem. I had to close everything and exit my browser and start all over again!

I also found a cache clearing module called Clear Smarty - it's free and you can get it from www.catalogo-onlinersi.com.ar - one of many Prestashop module makers! I've loaded it into my BO and every now and then I go and "ClearSmarty" !!

Good luck!

Link to comment
Share on other sites

Hi,

Thanks for your response!

Yea when our site went live I had to disable the force compile... it was working fine with it enabled when we were still updating the site; however, when it went live we kept getting a 500 error (90% of the time). So I disabled this since it should be with a live site anyways, and do use the clear smarty module (or manually clear it via ftp). It's an extra step, but our site works flawlessly so I can't complain.

However, my question was regarding the memcache feature at the end of that same performance page. Is this what you are talking about when you say it was fixed in the new version?? If so, than it must be a bug with the 1.4.2.5 version..?

There is no documenation regarding these settings and features, which is a shame.

Again, thanks!

Link to comment
Share on other sites

Obtw... I haven't had much time to mess with this feature. I had to disable it as soon as the problem occurred... I have employees updating product information at the moment so I could have it cause any problems. Hopefully I will have time later tonight to test a few different scenarios to see if any other settings solves this issue.

I will report back.

Link to comment
Share on other sites

Hi again Mytheory

Sorry - missed replying about that one! I asked my hosting company about Memcached - my type of hosting doesn't support it as it's shared.

Although it's disable at the moment I use Filesystem with Directory Depth set to 1 as recommended by my hosting company.

Link to comment
Share on other sites

Hi,

Yea I'm considering trying that out too... if memcached doesn't work.

How is that working for you? Do you notice any differences (ie. speed, performance gains, etc.) on your FO (homepage)?

Also, with it enabled can you update your product quantities (esp. attribute quantities) without any problems?

Thanks so much!

Link to comment
Share on other sites

Ok...

So to give a little of an update...

I re-enabled the cache feature via the BO, and added a server using the outside IP address of my server (I deleted the original localhost IP server). I saved and a few tests on the FO and BO. Everything seems to work fine. It seems faster too. However, I also briefly tested it without any servers... just memcached enabled with NO servers below it. The speeds seem to be almost the same.

So now I am wondering if I even need to "add a server"... or would this feature work with it just being "enabled" without any servers or does it not work (even when its enabled) unless a server is listed??

I'm not too familiar with the memcached feature, but my thought process is... if the Memcached extension is enabled on my server the same one where my PS is installed do I really need to declare a server? Seems like it would be redundant, it seems like it is just rerouting back to the same server. I could understand if Memcache was installed on a separate server and you need to link to it to utilize the feature, but if the extension and the site are on the same server do I need to add a server, or would just enabling work fine??

Thanks!!

Link to comment
Share on other sites

  • 4 weeks later...

hi, i'm interested in memcache too... already installed and let it working but also for me is not clear what ip address to add... i'm on vps, i need the localhost or the wan ip address? Maybe the ip field must be kept blank?

Link to comment
Share on other sites

Hi,

Yea, I am not positive about this yet (the add a server feature) either... but here is what I do know.

When we added a server with 127.0.0.1 (localhost) as the ip... some of the product data (ie. attribute quantities) did not update immediately. We found out it actually does update but the new quantity for example does not show up until you log out and log back in. At first we thought there were no changes being made after few tries, but after logging out and then back in we found all the updates had been made.

We haven't found a way to actually verify if Memcached works or not which makes it difficult to determine whether an ip address is needed if the memcached is on the same server. When we first enabled this feature we did not add an ip address... it seemed like it worked fine. However, currently we have a server added using our actual IP address. This also seems to work, but then again we don't know if there is an actual way to verify this claim.

HTH!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...