Opened 17 years ago

Closed 15 years ago

Last modified 15 years ago

#14321 closed defect (wontfix)

Moving from DarwinPorts to MacPorts: Registry corruption

Reported by: jlnicolson@… Owned by: jmpalacios (Juan Manuel Palacios)
Priority: High Milestone:
Component: base Version: 1.6.0
Keywords: Cc: wheinbockel@…, ryandesign (Ryan Carsten Schmidt)
Port:

Description (last modified by jmpalacios (Juan Manuel Palacios))

I am using Mac OS X Tiger.

I have used darwinports for a long time. I upgraded to macports a couple of months ago, I regularly saw error messages such "this port is already installed" when upgrading my packages I uninstalled then reinstalled the package. This has been fine until now, I had tetex installed when I tried to install texlive, I had to remove tetex, when I did this a registry error occured. I assumed my registry was corrupted and did the following:

sudo rm -rf ${prefix} \
/Applications/MacPorts \
/Applications/DarwinPorts \
/Library/Tcl/macports1.0 \
/Library/Tcl/darwinports1.0 \
/Library/LaunchDaemons/org.macports.* \
/Library/StartupItems/DarwinPortsStartup \
/Library/Receipts/MacPorts*.pkg \
/Library/Receipts/DarwinPorts*.pkg \
/etc/manpaths.d/macports \
/etc/paths.d/macports

When trying to install the latest macports the installer kept reporting "please try installing again", when I run from the command line I get this:

james@edufb12@02:47 pm:~$ sudo /usr/sbin/installer -dumplog -verbose -pkg /Volumes/MacPorts-1.6.0/MacPorts-1.6.0.pkg -target /Volumes/sally/
installer[1950]: Localized installer scripts detected in the MacPorts-1.6.0 package. Switching to compatibility mode.
installer[1950]: Distribution: MacPorts
installer: Package name is MacPorts
installer: Installing onto volume mounted at /.
installer: Preparing for installation.....
installer[1950]: Localized installer script preflight found in the MacPorts-1.6.0 package. Using compatibility mode.
installer[1950]: Localized installer script postflight found in the MacPorts-1.6.0 package. Using compatibility mode.
installer[1950]: Starting installation:
installer: Preparing the Disk.....
installer[1950]: Preparing volume "sally" for installation
installer:      Preparing Target Volume
installer[1950]: Configuring volume "sally"
installer[1950]: Preparing local booted disk
#installer[1950]: Create temporary directory "/private/tmp/MacPorts-1.6.0.pkg.1950ATfxuo"

installer: Preparing MacPorts.....
installer:      Running MacPorts Installer script
installer[1950]: run preflight script for MacPorts
installer[1950]: Localized installer script preflight found in the MacPorts-1.6.0 package. Using compatibility mode.
installer[1950]: Install failed: The following install step failed: run preflight script for MacPorts
installer: The install failed.

Change History (7)

comment:1 Changed 17 years ago by jmpalacios (Juan Manuel Palacios)

Component: portsbase
Description: modified (diff)
Milestone: Port BugsMacPorts base bugs

Such failure would be my fault, as I wrote most of the migration code form DarwinPorts to MacPorts. Can you please provide me with more information? I'd need to know for certain what pkg installer you are using and your host platform (OS X version). A view of the /opt/local/var/db/dports and /opt/local/var/macports directories would also be very helpful, plus a manual run of the preflight script (after providing me with the view of those directories). To perform the latter please execute the following in a shell:

curl -O http://svn.macports.org/repository/macports/branches/release_1_6/base/portmgr/dmg/preflight && chmod +x preflight
set -x && sudo ./preflight 2>&1 | tee preflight.log

That'll create a preflight.log file where a debug run of the script will be recorded. It'd be great if you could attach that to this ticket.

And as for the other information I request, comments in this ticket would suffice. But please read WikiFormatting and our ticketing guidelines to learn how to properly paste console output (I'm particularly interested in that you use the {{{ }}} wrappers for proper Trac formatting).

Thanks!

-jmpp

comment:2 Changed 17 years ago by jmpalacios (Juan Manuel Palacios)

Owner: changed from macports-tickets@… to jmpp@…

Reread and realized you already mentioned Tiger as your host platform, sorry about that!

-jmpp

comment:3 Changed 16 years ago by wheinbockel@…

Since this issue does not appear to have been fixed and there has been no activity for ~6 months, here was at least a related issue that I had:

$ ls -l /
...
dr-xr-xr-x   2 root  wheel         1 Aug 14 17:15 net
lrwxr-xr-x   1 root  admin        11 Aug 15 20:48 opt -> /private/opt
drwxr-xr-x@  7 root  wheel       238 Aug 15 20:47 private
drwxr-xr-x@ 66 root  wheel      2244 May 28 17:49 sbin
lrwxr-xr-x@  1 root  admin        11 Apr 25 14:45 tmp -> private/tmp
drwxr-xr-x@ 13 root  wheel       442 Aug 14 22:40 usr
lrwxr-xr-x@  1 root  admin        11 Apr 25 14:45 var -> private/var


$ ls -l /private
drwxr-xr-x  86 root  wheel  2924 Aug 15 20:23 etc
drwxr-xr-x   2 root  wheel    68 Sep 24  2007 tftpboot
drwxr-xr-x  25 root  wheel   850 Apr 25 14:45 var

Since /opt is present, but the link target /private/opt does not exist, the mkdir /opt/* in the preflight script fails. A simple sudo mkdir /private/opt will fix the issue.

comment:4 in reply to:  3 Changed 16 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: wheinbockel@… ryandesign@… added
Summary: Moving from Darwin Ports to MacPorts: Registry corruptionMoving from DarwinPorts to MacPorts: Registry corruption

Replying to wheinbockel@…:

Since this issue does not appear to have been fixed and there has been no activity for ~6 months, here was at least a related issue that I had:

It's hard to know what to fix; there aren't enough specifics about the issues. The first issue, that of an allegedly corrupted registry, is hard to debug since the user already deleted the MacPorts installation, complete with its registry. The second issue, that of a failed preflight script during reinstallation, is hard to debug without some output from that preflight script.

Since /opt is present, but the link target /private/opt does not exist, the mkdir /opt/* in the preflight script fails. A simple sudo mkdir /private/opt will fix the issue.

I don't think this issue is related to the ones reported in this ticket. That's also not the recommended fix for it. See issue #13707.

comment:5 Changed 16 years ago by tobypeterson

Milestone: MacPorts base bugsMacPorts Future

Milestone MacPorts base bugs deleted

comment:6 Changed 15 years ago by jmroot (Joshua Root)

Resolution: wontfix
Status: newclosed

The dp2mp upgrade code is gone, see #17619.

comment:7 Changed 15 years ago by jmroot (Joshua Root)

Milestone: MacPorts Future
Note: See TracTickets for help on using tickets.