Tips on downgrading applications

November 21, 2008, 02:05 PM —  Macworld.com — 

Recently, after swapping a couple of machines (I sent my first-generation Intel-based Mac mini back to the Macworld offices, and we bought an iMac for the kids and general use), I realized that I had inadvertently also disabled my locally-hosted Web sites: I used to use the mini as a local Web server, and it served out copies of the Mac OS X Hints site, as well as the various family sites I maintain. I didn't really want to keep the iMac running all the time just to have the Web server running, so I decided to move the server to my Mac Pro.

While OS X ships with a built-in Web server, it doesn't ship with MySQL, the database engine that enables sites such as macosxhints.com to work. Installing it is relatively straightforward--there are OS X installer versions available on the MySQL site. About the only trick comes in choosing which version of MySQL to install--some content management systems only work with certain versions. In my case, I wanted MySQL 4.1 for compatibility with the macosxhints.com site. Unfortunately, I managed to download and install version 5.0 without noticing. As soon as I noticed the problem, I downloaded the 4.1 package, and attempted to install it. The installer, however, refused to proceed, telling me there was already a newer version of MySQL installed.

Since the installer didn't want to install due to the presence of the newer version of MySQL, I thought I'd first get rid of that newer version. In the case of MySQL, all the code lives in the /usr/local/mysql directory, which is actually a symbolic link (like an alias in the Finder) to a directory with a much longer name. So in Terminal, I issued a sudo rm -r /usr/local/mysql-long-directory-name to remove all the MySQL code. Note that this command will delete all of your MySQL databases in addition to MySQL itself! In my case, I didn't care, because I hadn't yet migrated the databases over to the Mac Pro.

I then tried to run the installer again, but it still failed, saying a newer version was installed. After some thinking, I remembered the /Library/Receipts folder--this is where installers write out records of what they did. Perhaps, I thought, the MySQL installer is looking at the Receipts folder, seeing the MySQL 5.0 receipt, and using that as the basis for stopping the install.

In Terminal, I did cd /Library/Receipts, and then ls -d mysql* to see what was there. Sure enough, I found a receipt for the MySQL 5 installation, named something like mysql-standard-5.0.67-apple-darwin8.5.1-i686.pkg. I deleted that directory (sudo rm -r mysql-standard...), and then ran the 4.1 installer again. Success! The 4.1 install ran fine, I then moved over my databases, and had the internal web server up and running again a few minutes later. OK, so it was several hours later; it just seemed like a few minutes!

Generalizing from my experiences with MySQL, here's the process I would follow to downgrade a program that was installed with Apple's installer:

1.

Sign up for ITworld's Daily newsletter
Follow ITworld on Twitter @IT_world

I like it!
Close

On Twitter now

downgrading applications

Powered by Twitter
You are logged in | Sign out
Sign in and post to Twitter

What are you thinking?

Cancel Tweet sent
Post a comment
The content of this field is kept private and will not be shown publicly.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.
peer-to-peer

Esther Schindler
If the comments are ugly, the code is ugly

claird
SVG a graphics format for 21st century

pasmith
Take Chrome OS for a test spin

Sandra Henry-Stocker
Solaris Tip: Have Your Files Changed Since Installation?

sjvn
64-bits of protection?

jfruh
Android fragments vs. the iPhone monolith

mikelgan
What Gizmodo missed about the Pro WX Wireless USB disk drive

 

Sidekick: The Good News & the Bad News
Either way you look at it Microsoft Data Center management did not follow standards or best practices in this failure. In which case it makes me wonder more about the outsourcing of corporate data much less personal data.
- mburton325

Join the conversation here

The Daily Tip

The Daily TipQuick, practical advice for IT pros. Made fresh daily.

Hot tips:

Want to cash in on your IT savvy? Send your tip to tips@itworld.com. If we post it, we'll send you a $25 Amazon e-gift card.

Newsletters

Subscribe to ITWORLD TODAY and receive the latest IT news and analysis.

I would like to receive offers via email from ITworld partners.
By clicking submit you agree to the terms and conditions outlined in ITworld's privacy policy.
Featured Sponsor

AISO founders envisioned a Web hosting company that was environmentally friendly. While the company employed energy-efficient innovations like solar panels, its infrastructure produced unacceptable power and cooling requirements. Find out how AISO leveraged AMD technology to overcome their challenge in this case study white paper.

In this whitepaper, Scalar explores the opportunity to change the landscape with respect to mission critical databases built around Oracle. Leveraging technologies such as Linux, high-end commodity processing power and Oracle RAC technology to architect, design, build and maintain database infrastructure that delivers maximum availability, reliability and performance at a fraction of traditional cost.

On a typical day, weather.com, the Web site for The Weather Channel in Atlanta, serves up between 15 million and 20 million page views. But in September 2004, when back-to-back hurricanes ransacked Florida, the peak traffic on one day more than tripled: over 70 million page views by more than 7 million unique visitors. Read the full success story now.

Marketplace