Wow, its been a while since I lasted posted.
Over the last year and a half I have been upgrading a lot of Drupal 6 sites to Drupal 7. I have found many times that different sites like to throw different errors (or sometimes now errors) after upgrading. I have been plagued by one specific error on a number of sites.
Notice: Undefined index: distribution_name in drupal_install_profile_distribution_name() (line 207 of /var/www/drupal/includes/install.inc).
Alas, after a year of searching, I finally found the solution at Drupal.org . Apparently what happens in the upgrade, sometimes, is that all of the installation profiles in Drupal are disabled. Why? I have no idea. If you were to look in install.inc, you would see the following code.
$profile = drupal_get_profile();
$info = system_get_info('module', $profile);
So with the profiles disabled, ‘distribution_name’ doesn’t exist. So what do you need to do? Well enable a profile of course! Only one problem, there is no way in Drupal to enable a profile without getting in to the database. To fix this, you will need access to mysql or phpmyadmin and you’ll want to run the following SQL command
UPDATE system SET status=1 WHERE name='standard';
This will reactivate the Standard profile in Drupal and your distribution_name error should disappear.
With the number of Drupal site upgrades I have been working on (using Drush site-upgrade), I thought it would be handly to compile a list of modules that should be disabled before attempting a site-upgrade. These are all modules that could cause issues in the upgrade process.
- While there is a D7 version of this module, there is no upgrade path from D6 to D7
- Node Hierarchy
- This module D7 version is just buggy and development has slowed dramatically. I recommend finding an alternative to this module.
- I had a site-upgrade process start shooting errors like crazy when I had this module enabled. So its probable a good idea to disable it.
I’ll continue to add more modules as a find them causing issues. Of course if you’re disabling these modules, it may be a good idea to delete them as well. Why save a module you can’t use?
Backups are one of the most important responsibilities that home users neglect. Most of the time this is because home users don’t realize how important their data is until either their hard drive crashes, their house starts on fire, or their computer is stolen.
Types of Data
There are many different types of data that home users should backup. A lot of home users don’t think backups are important because they don’t have financial or tax information on their system. This is a completely false assumption. Data such as music, home movies, and college papers should be backed up regularly. I have a friend whose laptop was stolen out of her boyfriend car and I’m sure see lost several papers that were due. Recently one of my family members had their computer stolen, and has probably lost all of their iTunes music.
What a backup isn’t…
There is a common misconception that moving (not copying) files to an external drive is a sufficient backup. Actually, its not a backup at all. As long as your have 1 copy of a file, you don’t have a backup. In order to have a real backup, you must have at least 2 copies of a file.
One thing I’ve seen posted all over the internet is the mention of the Backup 3-2-1 rule. This is probably the most useful rule you can remember when it comes to backups. The 3-2-1 rule states that you should keep three copies of any important files, that includes the primary copy and 2 backups. You should store your files on two different types of media, this could be hard drives and optical media such as blu-rays or dvd’s. Finally, 1 of your backups should be backed up offsite.
How do I set it up?
It’s always a good idea to keep a local and offsite backup. For a local backup, I’d recommend purchasing an external harddrive to keep plugged in to your computer. If you have Mac OS, you can use Time Machine to keep local backups of your system, otherwise you can download a free program called Crashplan that will let your perform backups without much configuration on your part. Just make sure its backing up to your usb drive. As for offsite there are multiple services that will take care of automatically backup such as Crashplan and Carbonite. I’ve only ever used Crashplan so I’ll speak to that. For $50 a year, you can backup all of your data to Crashplan’s server, or else if you have a friend that has a lot of extra storage space that they’d be willing to share, if they install crashplan, you can backup to their system securely. Carbonite will allow you to backup to their servers for around $60 a month I believe.
As usual, post any questions or comments below.
With the release of Mac OS 10.8 (Mountain Lion), Apple changed how you gain access to make and gcc. In previous version of Mac OS you could install xcode and everything would work fine. In 10.8 the installation of the command line tools as a separate package is required. To make things more frustrating, while Xcode is available in the Mac App store, the command line tools are not. In order to get the command line tools, you must sign up for an Apple Developer account (a free account works).
Once you download and install the command line tools package you can download the MacPorts packages form their website at http://www.macports.org.
If you upgraded from Lion to Mountain Lion and had MacPorts installed prior to the upgrade, you will need to reinstall Xcode from the App store, then install the command line tools, then reinstall MacPorts. Then you will need to run port upgrade outdated to update your packages from the Darwin 11 version to Darwin 12. You may receive an error in reference to a library package. If that happens trying running port clean “packagename”.
Here are a few lines for the vimrc file that will make vim a little more Python friendly by providing autoindent.
Update: After settings these, I found that copying text in to vim turned out to be a nightmare. So here is how you get around that.
before pasting, and then type
when you’re done to restore the vimrc settings.
Update: I am looking for ways to improve my vimrc even more, if you have any ideas, please let me know in the comments section. Thanks!