Magento An error occurred while saving the URL rewrite

Fix An error occurred while saving the URL rewrite, quick and easy fix for this problem.
We always recommend making FULL site backups before commencing.
This error normally shows up on a Magento 1.4x installation, the fix we found was to simply to re-index the site:
Admin -> System -> Index Management -> Select All and Reindex
Additional Steps
Added 21/09/2010.
—
If this doesn’t fix your problem, then try one (or all) of the following
1. Change the permissions of your media folder to 777.
2. Flush your cache, by deleting the /var/cache/ directory *
3. Delete your sessions, by removing your /var/sessions folder *
4. Try replacing your root .htaccess file with a default .htaccess file suitable for your Magento version
*Don’t worry about removing these two folders, they will be automatically recreated once you visit the site again.
—-
Additional, additional steps
Added 30/09/2010.
—
It would seem that this error message is cropping up more and more for people on 1.4x, whilst using different built in features of Magento, such as multiple stores.
Multiple Stores problem
Thanks to erikedhagen.com for pointing this latest problem out with multiple stores and 1.4x. More information on the fix for multiple stores can be found in the following Magento Forum Thread:
www.magentocommerce.com/boards/main.php/viewthread/198534/
—
If this didn’t fix your magento error, then please let us know with a message below.
Related Articles
- 14.02.11: Perl files download instead of executing / processing (fixed) (0)
- 08.04.11: Coupon Code in Order Confirmation Email - Magento (5)
- 17.05.11: Currency drop down selector in header, Magento (3)
- 23.06.11: Add logo to print popup in Joomla (0)
- 17.06.11: Sales order error in Magento Sage Pay (0)









Comments RSS Feed





we have this issue and reindexing all gives the same error.
Go to Top of the page
Sorry to hear your having problems Colin.
Is this a fresh 1.4* install?
Have you tried:
Clearing and turning off the cache?
Also deleting the cache and sessions via FTP.
Do you have mod-rewrite enabled on your server?
Are you using Magento URL rewrites from the admin? i.e. no index.php in the URL
Go to Top of the page
Thank you for advice. Your suggested did the trick. Running Magento ver. 1.4.1.1. Too bad errors like this are still frequent with the product.
Go to Top of the page
Hi!
Got the same problem. However, reindexing all data does not solve the problem for me..
I have no clue of what caused this or how to fix it.
Please email me if you have any ideas..
Would greatly appreciate your help on this.
Regards,
Erik
Go to Top of the page
Please try any / all of the addtional steps updated in the main post.
Go to Top of the page
Adam,
Thanks for your response!
I eventually managed to solve my problem through mostly the same steps you listed here. Setting correct permissions and clearing the cache solved this for me!
As far as I can tell, for me this problem had to do with setting a custom admin URL through the admin panel (which should be avoided since it messes up your admin, there is a better way to do this).
Anyway, everything is fine and working for the time being, but probably won’t be for long.
Well we wouldn’t be working with magento if we didn’t love problem-solving, am I right?
Cheers,
Erik
Go to Top of the page
Thanks for the update Erik, glad to hear you’ve solved your problem (for the time being at least).
Yes, Magento is not for the faint hearted! Lots of backups are a necessity.
Going to be looking at Prestashop soon, as it looks a lot more lightweight and has some really nice features out of the box.
Go to Top of the page
Hmm, it’s interesting you’re looking at Prestashop.
Most people I’ve heard are all about moving from other platforms to Magento.
Magento is the first and only ecommerce platform I’ve tried and that’s because of my impression beforehand.
But I might be revising the alternatives soon as well.
After all, Magento is pretty heavy for most smaller store needs.
Go to Top of the page
I’ts funny, I just came across this URL rewrite error again.
This time it seemingly had something to do with creating a new store view.
I created a new store view and then uploaded a new language pack (the language not being related to the created store view).
After this, I had the same URL rewrite error again.
However, this time, cache-clearing and permission-setting did not solve the issue.
Instead I found a workaround (and possibly root of the problem) in a forum thread here: http://www.magentocommerce.com/boards/main.php/viewthread/198534/#t255791
In short, Magento is throwing an exception without a preceding error.
Luckily the fix was really quick and easy, but has to be applied each time the error is shown.
Well, whatever works! Hope this can help other people stumbling upon this page in search for the solution to this problem.
Go to Top of the page
Im having this same issue, I did a transfer of all our products from CS-Cart to Magento and all I get is this error when trying to re-index.
Go to Top of the page
How did you transfer the products from CS?
Have you tried any / all of the additional steps in the post? Let us know how you get on.
Go to Top of the page
heelp guys, I tried everything here and my homepage is all broken now - My issue: I mistakenly changed in Config>Catalog>SEO the category suffix from .html to .hml (mouse must have landed there by mistake) and now all my backend is broken and I can’t refresh or flush anything - all buttons do nothing but I can still see everything in ugly broken html - any suggestions?
Go to Top of the page
@Coca: Via phpMyAdmin Locate: core_config_data
Easiest way to do that, is search for:
“Category URL Suffix”
Once you find it, EDIT the value (hml to html) and Save.
This is taking into consideration that your previous working version used html as a file extension… if your previous working version had no extension then remove the entry and save.
Failing that, do you have a backup of your database?
Go to Top of the page
The fix on the link worked perfectly to fix the url rewrite error, but editing the core is not the best solution but for now, seems like the only solution.
Go to Top of the page
Deleting the cache and session folders solved the problem. Thanks for this.
Go to Top of the page
I did Additional steps
and I still have “An error occurred while saving the URL rewrite.” when tried Index product and categories URL rewrites Reindex
pls help
Go to Top of the page
@fishco; sorry to hear your having probs, this does seem like a big pain in the Magento.
Could you let us know which version you are using?
And whether you have multiple stores?
Thanks.
Go to Top of the page