Easy-to-follow video tutorials help you learn software, creative, and business skills.Become a member

Migrating to Drupal 7

From: Drupal 7 Advanced Training

Video: Migrating to Drupal 7

When we last left our migration project, we'd finished all that we were going to do with Drupal 6 site. Now we are going to replace the Drupal core with Drupal 7, and as I mentioned before, at this point, you'll no longer be able to use your Drupal 6 site, because we're going to delete the entire set of software and then we're going to run a database update. We made a backup when we first started. If you didn't, do so now, here we go. We then click Replace Drupal core in the Upgrade status module. This gives some fairly complicated instructions, so I'll go through them step by step.

Migrating to Drupal 7

When we last left our migration project, we'd finished all that we were going to do with Drupal 6 site. Now we are going to replace the Drupal core with Drupal 7, and as I mentioned before, at this point, you'll no longer be able to use your Drupal 6 site, because we're going to delete the entire set of software and then we're going to run a database update. We made a backup when we first started. If you didn't, do so now, here we go. We then click Replace Drupal core in the Upgrade status module. This gives some fairly complicated instructions, so I'll go through them step by step.

First, Create a new virtual host, and it suggests one to create. I've already done so at d7.tomgeller.com, and as you can see there's nothing there. We just have to remember to use that URL; instead of the one it suggests whenever it mentions it. Then I download the new Drupal core into that directory and it conveniently gives me a link to that page. Go down, copy the link, and then go over to my site, where I'll go back up to my Drupal 7 site and download there.

Right now I am in the middle of my Drupal 6 site, so I have to go up a few levels. Yup, I am in the right place. Because I have Drush installed, I can use it to download Drupal. By default, it will grab the latest version of the most current integer versions, so in this case 7 point whatever, yup 7.12. Then as I've done elsewhere in this course, I bring it up one level to put it at the root level of where my web host is looking for this site.

You might not have to do this. We go back to our instructions, and it says to Copy all of the existing modules from the old version of Drupal core, into the same location of the new version. Here it really helps for you to know exactly how your web host is set up; fortunately, I do. Remember, when you're doing this in UNIX, it's cp -R for recursive; otherwise, the command will fail. And just to be sure, let's take a look in that directory. Aha! We made a mistake, you see, we copied modules into modules. That's okay; this sort of thing happens all the time.

Just go into it and move everything up. Now I can remove that modules directory that's inside the other one. Very good! Now remember, we have a Drupal 7 site with Drupal 6 modules, but don't worry the upgrade process will take care of that. Next, it says to copy settings.php and the files directory to their identical locations.

Now I am going to go back into my Drupal 6 site and do it from there, just to make sure that I'm copying the right files directory. If you're running a multisite installation, or if you move things over from Acquia Dev Desktop, you might find the files directory isn't quite where you expected it to be. So now I am in my lyndad6; that is the Drupal 6 directory, and good, since I'm not running a multisite installation, files is probably in default.

And that's also where my settings file is. From here I'll copy over the settings file. First, I'll clear my screen and then do copy settings (cp settings) and then from here I have to figure out where I'm copying it to. One nice thing in UNIX is that you can find out where you are while traversing directories, by simply hitting the Tab key twice. That's the top level of this Drupal directory, so I'll go up one more and then into lyndad7/sites/default. Good! That made that copy.

Now we also need to copy the files. So same thing, but this time remember the -R. All right! That takes care of our next step. Now we go back and run the update program and remember, we changed the domain, so we'll do it from the domain that we named. At this point we're completely converting the database over. So here we go. Go to my site and update.php.

But we do get an error. At another point in this course, I talk about all of the things that are in the settings.php file. One of them allows you to update the site if you're not their super user. Now remember, we didn't actually install the Drupal 7 site yet, so there is no super user. We have to go into that settings file and then change it, so that we can update it, then change it back. So we go back to our Terminal, go to our lynda7/site, and edit that settings.php.

The thing we're looking for is this update_free_access. I'll change that to True and write it out, then go back and reload and Continue. Notice, there's lots and lots of updates. This process will take a few minutes. Now notice, we get a few informational messages here. I am going to Command+Click those links just so I have them in the background and can take care of them later.

This one is just informational, so we can ignore it, but then we have a warning here to reset that value. So I'll go back to my Terminal and do exactly that. Change it to False and exit, saving as we go. Now we can go back to our front page. Now remember in our previous video we put the site in maintenance mode. But we were logged out during the process so we're no longer the administrator. If we were, we would see the full administration screen here, so we have to log in again.

We do that by going to /user. And in fact, we want to stay in maintenance mode because we haven't completed the process yet. Now we are on to Download new project versions. There are a few ways of doing this. We could do it manually and here it helpfully lists all of the modules we'd have to update, along with links to their projects. But it also provides this drush command here.

Now notice, it says the delete option may not be supported yet. Let's just give it a try. I'll copy it, clear my screen; make sure I am in the right place. Yup, I want to be in the Drupal 7 site where we just downloaded that software and I'll try that command. Nope, it's not implemented as I make this video. It may be by the time you watch it however. So instead, I'll go back and manually delete them. But notice, only those that are going to be replaced. That is, everything except for upgrade assist.

And of course, those are in our modules folder. Now I'll reissue that drush command, clear the screen and remove that dash, dash, delete. Now you'll notice that the process gave us a few warnings.

You want to take note of which things it's giving warnings about. There's upgrade assist, image assist, and upgrade status. So we saw an upgrade status, but it's probably the old one. Once we've finished that, I'll reload the page. Scroll down, it tells us once again to run update.php, and we have more updates to do, these are of course on the modules.

And we get some warnings, which we should take note of and take care of later. But for now, I am just going to go back to my front page and see what the next step is. We are almost done. The next step is to re-enable modules. We get a warning, but we can re-enable some modules, so we'll do so here and Re-enable. Then I'll reload the page. Now this is the tricky point.

We can check on which modules were re-enabled, by going to be d7.tomgeller.com/admin and then following the path. Normally of course, we'd use the toolbar, but remember we disabled all of those modules in Drupal 6, and toolbar wasn't even in it. So we have a very bare kind of site right now, administratively speaking. But let's see what the modules are. There is CCK, we might want to start re- enabling things here, the Image module, Pathauto, Token, but there is a problem with Upgrade status.

That is of course because this is the module that we carried over from Drupal 6. Then we find additional errors such as Ctools, which is necessary for Views and so forth. This is where things get tricky. You're going to run into some modules that simply don't exist for the new version. There are a few things you can do for that. First, the functionality might not be necessary. That is, it might be done in a different way in Drupal 7. One example here was the Image module. That's actually part of Drupal 7 now, and so we didn't really need it.

Take a good look at all of the modules that you were trying to bring over, and talk to an experienced Drupal 7 consultant if necessary to figure out if that's the case for the ones that you have. The second option is you might be able to replicate the functionality using a non-Drupal solution, such as the free apps from Google and the like. Third, perhaps you could help produce the Drupal 7 version. This helps not only you, but the whole Drupal community. Finally, if none of these are possible, you might just have to adjust your site to do without the features that you had in your previous version.

In any case, you can often figure out the best path by looking through the modules image queue. For example, let's take a look at that Image Assist module. Go into the issue queue and do a search for Drupal 7 let's say. Ah! And it says right here, the issue having to do with the Drupal 7 port. One thing that we didn't do is to take care of those pages that we opened after we had installed Drupal 7. Now that we are logged in as user1, we can reload those pages and make whatever changes are necessary.

And then finally, after we've got all our modules together, we check our status report, and finally go online. So that was a long process, wasn't it? And you can see that it's tricky. But the update status module makes it much easier than it used to be. The problem is also somewhat ameliorated, because the Drupal community hugely maintains both the current version and previous one of any given module.

That is Drupal 7 and Drupal 6 in our case. So you have plenty of time to make the change. And as long as the modules you need are available, the procedure really isn't so hard.

Show transcript

This video is part of

Image for Drupal 7 Advanced Training
Drupal 7 Advanced Training

72 video lessons · 11554 viewers

Tom Geller
Author

 
Expand all | Collapse all
  1. 4m 51s
    1. Welcome
      1m 7s
    2. Planning your Drupal career
      3m 44s
  2. 25m 46s
    1. Comparing development and production environments
      6m 22s
    2. Configuring your settings.php file
      7m 10s
    3. Running multiple sites from one Drupal installation
      7m 32s
    4. Troubleshooting common issues
      4m 42s
  3. 51m 20s
    1. Understanding your Drupal site's place on the web
      2m 44s
    2. Selecting a web host
      7m 20s
    3. Using Unix's command-line interface
      8m 23s
    4. Working with your web host's access restrictions
      4m 51s
    5. Using cPanel and other graphical web host interfaces
      3m 40s
    6. Transferring files to and from your web host
      5m 49s
    7. Moving databases using phpMyAdmin
      6m 34s
    8. Moving databases using Unix commands
      6m 8s
    9. Modifying server configuration files
      5m 51s
  4. 27m 10s
    1. Learning from case studies
      3m 13s
    2. Planning your site
      4m 18s
    3. Populating your site with Devel Generate
      3m 42s
    4. Managing URL paths
      3m 20s
    5. Restricting access to downloadable files
      5m 55s
    6. Reusing site components with the Features module
      6m 42s
  5. 21m 53s
    1. Understanding and installing Drush
      5m 23s
    2. Installing Drupal using Drush
      7m 24s
    3. Building a site using Drush
      9m 6s
  6. 31m 59s
    1. Backing up with the Backup and Migrate module
      8m 17s
    2. Moderating comment spam
      6m 47s
    3. Migrating from Drupal 6
      4m 28s
    4. Migrating to Drupal 7
      12m 27s
  7. 22m 24s
    1. Letting users log in through OpenID
      5m 10s
    2. Letting users log in through Facebook, Twitter, and other services
      9m 43s
    3. Republishing posts on Facebook and Twitter
      7m 31s
  8. 1h 5m
    1. Understanding Drupal's base themes
      5m 55s
    2. Introducing base themes: Zen and subtheming
      11m 35s
    3. Introducing base themes: Fusion and extensibility
      10m 44s
    4. Introducing base themes: AdaptiveTheme and responsive design
      7m 25s
    5. Introducing base themes: Omega and mobile devices
      7m 9s
    6. Using Firebug and other theming tools
      7m 20s
    7. Modifying themes with Sweaver
      6m 59s
    8. Modifying themes with Livethemer
      8m 45s
  9. 49m 35s
    1. Understanding the Rules module
      6m 48s
    2. Demonstrating how Rules works in Drupal Commerce
      3m 53s
    3. Creating practical rules
      6m 37s
    4. Improving rules
      9m 10s
    5. Defining conditions with the Context module
      7m 51s
    6. Varying layout with the Context and Delta modules
      5m 0s
    7. Varying layout with the Panels module
      10m 16s
  10. 52m 46s
    1. Enabling social features
      9m 46s
    2. Implementing a voting system
      9m 15s
    3. Rewarding good behavior with the Userpoints module
      5m 57s
    4. Setting up Organic Groups
      6m 28s
    5. Adding content to groups
      2m 21s
    6. Seeing group activity better with views and panels
      10m 13s
    7. Making groups private
      4m 54s
    8. Letting each group have its own permissions
      3m 52s
  11. 25m 32s
    1. Understanding packaged Drupal distributions
      2m 8s
    2. Getting a head start with Acquia Drupal
      7m 28s
    3. Creating online storefronts with Drupal Commerce
      6m 53s
    4. Creating government web sites with OpenPublic
      9m 3s
  12. 1h 30m
    1. Taking the assignment
      3m 26s
    2. Planning the project
      3m 43s
    3. Preparing the infrastructure
      8m 42s
    4. Starting the design
      7m 35s
    5. Filling in the content
      7m 29s
    6. Developing the layout
      10m 27s
    7. Finishing the layout
      7m 8s
    8. Refining the CSS
      6m 32s
    9. Setting up sections for regional offices
      4m 53s
    10. Configuring regional offices
      7m 18s
    11. Connecting to social media
      5m 9s
    12. Cleaning up
      12m 32s
    13. Securing the site
      5m 56s
  13. 37s
    1. Next steps
      37s

Start learning today

Get unlimited access to all courses for just $25/month.

Become a member
Sometimes @lynda teaches me how to use a program and sometimes Lynda.com changes my life forever. @JosefShutter
@lynda lynda.com is an absolute life saver when it comes to learning todays software. Definitely recommend it! #higherlearning @Michael_Caraway
@lynda The best thing online! Your database of courses is great! To the mark and very helpful. Thanks! @ru22more
Got to create something yesterday I never thought I could do. #thanks @lynda @Ngventurella
I really do love @lynda as a learning platform. Never stop learning and developing, it’s probably our greatest gift as a species! @soundslikedavid
@lynda just subscribed to lynda.com all I can say its brilliant join now trust me @ButchSamurai
@lynda is an awesome resource. The membership is priceless if you take advantage of it. @diabetic_techie
One of the best decision I made this year. Buy a 1yr subscription to @lynda @cybercaptive
guys lynda.com (@lynda) is the best. So far I’ve learned Java, principles of OO programming, and now learning about MS project @lucasmitchell
Signed back up to @lynda dot com. I’ve missed it!! Proper geeking out right now! #timetolearn #geek @JayGodbold
Share a link to this course

What are exercise files?

Exercise files are the same files the author uses in the course. Save time by downloading the author's files instead of setting up your own files, and learn by following along with the instructor.

Can I take this course without the exercise files?

Yes! If you decide you would like the exercise files later, you can upgrade to a premium account any time.

Become a member Download sample files See plans and pricing

Please wait... please wait ...
Upgrade to get access to exercise files.

Exercise files video

How to use exercise files.

Learn by watching, listening, and doing, Exercise files are the same files the author uses in the course, so you can download them and follow along Premium memberships include access to all exercise files in the library.


Exercise files

Exercise files video

How to use exercise files.

For additional information on downloading and using exercise files, watch our instructional video or read the instructions in the FAQ .

This course includes free exercise files, so you can practice while you watch the course. To access all the exercise files in our library, become a Premium Member.

Are you sure you want to mark all the videos in this course as unwatched?

This will not affect your course history, your reports, or your certificates of completion for this course.


Mark all as unwatched Cancel

Congratulations

You have completed Drupal 7 Advanced Training.

Return to your organization's learning portal to continue training, or close this page.


OK
Become a member to add this course to a playlist

Join today and get unlimited access to the entire library of video courses—and create as many playlists as you like.

Get started

Already a member ?

Become a member to like this course.

Join today and get unlimited access to the entire library of video courses.

Get started

Already a member?

Exercise files

Learn by watching, listening, and doing! Exercise files are the same files the author uses in the course, so you can download them and follow along. Exercise files are available with all Premium memberships. Learn more

Get started

Already a Premium member?

Exercise files video

How to use exercise files.

Ask a question

Thanks for contacting us.
You’ll hear from our Customer Service team within 24 hours.

Please enter the text shown below:

The classic layout automatically defaults to the latest Flash Player.

To choose a different player, hold the cursor over your name at the top right of any lynda.com page and choose Site preferences from the dropdown menu.

Continue to classic layout Stay on new layout
Exercise files

Access exercise files from a button right under the course name.

Mark videos as unwatched

Remove icons showing you already watched videos if you want to start over.

Control your viewing experience

Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.

Interactive transcripts

Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.

Learn more, save more. Upgrade today!

Get our Annual Premium Membership at our best savings yet.

Upgrade to our Annual Premium Membership today and get even more value from your lynda.com subscription:

“In a way, I feel like you are rooting for me. Like you are really invested in my experience, and want me to get as much out of these courses as possible this is the best place to start on your journey to learning new material.”— Nadine H.

Thanks for signing up.

We’ll send you a confirmation email shortly.


Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

Keep up with news, tips, and latest courses with emails from lynda.com.

Sign up and receive emails about lynda.com and our online training library:

Here’s our privacy policy with more details about how we handle your information.

   
submit Lightbox submit clicked
Terms and conditions of use

We've updated our terms and conditions (now called terms of service).Go
Review and accept our updated terms of service.