1

I'm hitting an error while trying to uninstall some packages in my MacPorts 2.0.3 installation, and I can't figure out what's causing them or how to resolve them. Googling around lead to nothing addressing this case, so I'm hoping that fellow users here will have an answer.

Here is an example of the command and the error (where this is all done in a sudo'ed shell, so the problem is unrelated to root permissions):

port uninstall sleuthkit
--->  Deactivating sleuthkit @3.2.3_0+universal
Error: Target org.macports.deactivate returned: this entry does not own the given file
Log for sleuthkit is at: /opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_sleuthkit_3.2.3_0+universal/sleuthkit/main.log
Warning: Failed to execute portfile from registry for sleuthkit @3.2.3_0+universal
--->  Deactivating sleuthkit @3.2.3_0+universal
Error: Target org.macports.uninstall returned: this entry does not own the given file
Warning: Failed to execute portfile from registry for sleuthkit @3.2.3_0+universal
--->  Deactivating sleuthkit @3.2.3_0+universal
Error: Target org.macports.deactivate returned: this entry does not own the given file
Log for sleuthkit is at: /opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_sleuthkit_3.2.3_0+universal/sleuthkit/main.log
Warning: Failed to execute portfile from registry for sleuthkit @3.2.3_0+universal
--->  Deactivating sleuthkit @3.2.3_0+universal
Error: port uninstall failed: this entry does not own the given file

Looking in the file /opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_sleuthkit_3.2.3_0+universal/sleuthkit/main.log reveals nothing particularly useful to me:


version:1 
:debug:main Executing org.macports.main (sleuthkit) 
:debug:deactivate deactivate phase started at Tue Jan 31 19:18:24 EST 2012 
:debug:deactivate Executing org.macports.deactivate (sleuthkit) 
:msg:deactivate --->  Deactivating sleuthkit @3.2.3_0+universal 
:error:deactivate Target org.macports.deactivate returned: this entry does not own the given file 
:debug:deactivate Backtrace: this entry does not own the given file 
    while executing 
"$port deactivate $imagefiles" 
    invoked from within 
"registry::write { 
            $port deactivate $imagefiles 
            foreach file $files { 
                _deactivate_file $file 
            } 
    ..." 
    (procedure "_deactivate_contents" line 37) 
    invoked from within 
"_deactivate_contents $requested [$requested files] $force" 
    (procedure "portimage::deactivate" line 54) 
    invoked from within 
"registry_deactivate $subport $version $revision $portvariants [array get user_options]" 
    (procedure "portdeactivate::deactivate_main" line 3) 
    invoked from within 
"$procedure $targetname" 
:info:deactivate Warning: the following items did not execute (for sleuthkit): org.macports.deactivate 
:notice:deactivate Log for sleuthkit is at: /opt/local/var/macports/logs/_opt_local_var_macports_registry_portfiles_sleuthkit_3.2.3_0+univ\
ersal/sleuthkit/main.log 

Does anyone know what is behind these errors? More importantly, how can I fix my installation so that this doesn't happen anymore?

3
  • 1
    I can't help but notice your'e not using sudo ports uninstall (emphasis on the sudo). You might be using a root account, or maybe your installation of macports requires no administrator priviliges, but just in case you might have forgotten... I'm pretty sure you need to use sudo ports uninstall Just throwing this out there. Hope it helps. Kevin
    – kevin9794
    Feb 1, 2012 at 4:54
  • No, sorry, I was already in a root shell when I ran the commands. Should I have mentioned it. I'll edit the question to make that clear.
    – mhucka
    Feb 1, 2012 at 5:31
  • Try again using sudo ports uninstall and see if you have the same errors. The errors do look like permissions
    – mmmmmm
    Sep 28, 2013 at 12:20

1 Answer 1

1

Re install the required package then restart the computer and then run the uninstall.

Get into an elevated shell by using sudo -su firstly each time.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .