Migration wiki page

Ryan Schmidt ryandesign at macports.org
Fri Feb 17 14:39:09 PST 2012

On Feb 17, 2012, at 16:31, Jacob Schwartz wrote:

>> First question: did you rebuild everything first?
>> http://trac.macports.org/wiki/Migration
> I upgraded to Lion recently and I used this webpage, since it's been
> mentioned several times here.  But after spending a lot of time on
> this (and having the uninstall process fail! now what?!), I found that
> it was not what I needed.  What I wanted to do was to delete (or move
> to a backup location) the old /opt/local area and just re-install
> MacPorts (and my needed ports) from scratch.

Note that not all of MacPorts is necessarily confined to /opt/local. The uninstall instructions show all of the locations standard ports and MacPorts itself might install things into:


> This was faster and left
> my installation much cleaner.  (Turns out I'd also been accumulating
> tons of old versions of ports, inactive but still installed; so it was
> nice to free up that space, too.)

If your MacPorts were working properly and you just wanted to uninstall inactive ports, that's easy to do:

sudo port uninstall inactive

> Anyway ... is there a reason that this wiki page doesn't have a brief
> preface explaining that a clean re-install is also an option, and
> listing under what circumstances a migration might be preferred?
> In fact, I can't even imagine when a migration would be preferred.

The migration instructions do have you uninstall and reinstall all ports. And there should be no need to uninstall MacPorts base itself; simply installing the latest version on top of what you've got, like the migration instructions say to do, should work fine.

> Maybe it saves some download time if you've already got the latest
> packages downloaded?

Yes, that would be a good reason, if by "packages" you mean "distfiles".

> Oh, maybe if you've put other files in
> /opt/local/ by means other than MacPorts?

Many programs have configuration files. Some store other user-created items in /opt/local, including databases.

> I install things by hand
> into /usr/local, so I knew that only MacPorts was using /opt/local/.
> I guess that if other people aren't doing that, then they'd need to
> migrate, to make sure they only uninstall MacPorts files?

Please do not install anything in /usr/local as it will probably interfere with MacPorts.

More information about the macports-users mailing list