Write errors with Google XML Sitemap Generator and WordPress
I’ve run into a problem where my Google Sitemap Generator plugin for WordPress keeps generating an error that there’s been a problem and it can’t write to either sitemap.xml or sitemap.xml.gz.
The error I get is:
"There was a problem writing your sitemap file. Make sure the file exists and is writable. Learn more
There was a problem writing your zipped sitemap file. Make sure the file exists and is writable. Learn more"
This seems to have started since I upgraded to Google XML Sitemaps 3.2.6. If I rebuild the sitemap manually, everything works fine, the file is written and I don’t get any errors. But left to it’s own devices, things don’t go so well.
I haven’t really solved the problem, but I believe I’ve managed to work around it. First, I downgraded back to Google XML Sitemaps 3.1.6. Since I have a blog running under IIS, there might be another change to make. If you go to Settings – XML Sitemap, Under the Location of your sitemap file:
I selected Custom Location and then put in the full pathname to the file such as C:\Inetpub\blog directory\wordpress\sitemap.xml
With those changes in place, the plugin seems to be working again. After a post, the sitemap.xml file is updated and I don’t get the write protection error. I’m not sure if it was one change or the other, but it’s fixed and I’m not messing with it.
Other articles of interest:
- Problems with WordPress 3.1 on IIS – Redirect Loop
- Search and Replace within WordPress
- Output status messages and test information by writing to the Log File Viewer in Katalon Studio
- The WordPress.com Desktop App
- How to Password Protect Part of a WordPress Post
- To markFailedAndStop or Not To markFailedAndStop?
- Checking for Page Load with a Custom Keyword
- Adding entries to an open Excel spreadsheet during runtime
- 5 episodes in
- Checking for the presence of an object without throwing an error
I’ve been trying to get Google sitemap XML plugin to work on my site for a while now.
Thanks to your tip, I got it working now. Here’s the line that help me:
I selected Custom Location and then put in the full pathname to the file such as C:\Inetpub\blog directory\wordpress\sitemap.xml
Once I change the file location, it works like a charm.