Migrating to XAMPP local install – Configure the temporary directory

I have copied a site I have on a VPS down to run from XAMPP on my local machine. When I restore the site using Backup and Migrate I get the error message on all pages of the site:

The specified file temporary://filemy1oSK could not be copied, because the destination directory is not properly configured.

I have clean installs of drupal running fine on XAMPP. On the File System configuration page (admin/config/media/file-system) they use ‘/Applications/XAMPP/xamppfiles/temp/’ so I have tried using this and ‘/Applications/XAMPP/xamppfiles/private/’ but this doesn’t fix the error.

There is a similar Drupal Answers Question, about moving a site from local up to a VPS I have tried to work through the suggestions there to no effect. The top answer recommends advice from this site. Following this to avoid starting the file paths with a forward slash I tried using ‘sites/default/files/private/’ and ‘sites/default/files/temp/’but this doesn’t fix the error either.

As this is a local install, security is less of an issue. I have been setting the above directories to 777 to ensure that there are enough permissions. I have also made ‘sites’, ‘sites/default’ and ‘sites/default/files/’ 777.

Possibly incidentally, clean URLS weren’t working on the the local install, even though they work fine on the fresh installs of Drupal. This stopped the links on the site working. I disabled them by going to http://localhost/sitename/?q=admin/config/search/clean-urls and the site links now work without clean URLS

Also possibly incidentally, I got an error message when I used the site files I downloaded to install with a clean database. I did this so I could install the backup migrate module and restore the site properly. At the end of the install I got the error:

Deprecated function: preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in _acquia_profile_create_node() (line 158 of /Applications/XAMPP/xamppfiles/htdocs/sitename/profiles/acquia/acquia.profile).

I don’t have any admin menu and the overlay admin screens aren’t working. I am assuming this is a result of the temporary files error.

Any advice?

This article was republished from its original source.
Call Us: 1(800)730-2416

Pixeldust is a 20-year-old web development agency specializing in Drupal and WordPress and working with clients all over the country. With our best in class capabilities, we work with small businesses and fortune 500 companies alike. Give us a call at 1(800)730-2416 and let’s talk about your project.

FREE Drupal SEO Audit

Test your site below to see which issues need to be fixed. We will fix them and optimize your Drupal site 100% for Google and Bing. (Allow 30-60 seconds to gather data.)

Powered by

Migrating to XAMPP local install – Configure the temporary directory

On-Site Drupal SEO Master Setup

We make sure your site is 100% optimized (and stays that way) for the best SEO results.

With Pixeldust On-site (or On-page) SEO we make changes to your site’s structure and performance to make it easier for search engines to see and understand your site’s content. Search engines use algorithms to rank sites by degrees of relevance. Our on-site optimization ensures your site is configured to provide information in a way that meets Google and Bing standards for optimal indexing.

This service includes:

  • Pathauto install and configuration for SEO-friendly URLs.
  • Meta Tags install and configuration with dynamic tokens for meta titles and descriptions for all content types.
  • Install and fix all issues on the SEO checklist module.
  • Install and configure XML sitemap module and submit sitemaps.
  • Install and configure Google Analytics Module.
  • Install and configure Yoast.
  • Install and configure the Advanced Aggregation module to improve performance by minifying and merging CSS and JS.
  • Install and configure Schema.org Metatag.
  • Configure robots.txt.
  • Google Search Console setup snd configuration.
  • Find & Fix H1 tags.
  • Find and fix duplicate/missing meta descriptions.
  • Find and fix duplicate title tags.
  • Improve title, meta tags, and site descriptions.
  • Optimize images for better search engine optimization. Automate where possible.
  • Find and fix the missing alt and title tag for all images. Automate where possible.
  • The project takes 1 week to complete.