Opened 8 years ago

Closed 8 years ago

#50867 closed defect (invalid)

couldn't create error file for command: permission denied

Reported by: orcioni@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: base Version: 2.3.4
Keywords: Cc: ryandesign (Ryan Carsten Schmidt)
Port:

Description

"port upgrade outdated" or "port install any_port" fails with checksum error. But "port checksum any_port" succeds.

I manually made a succesfully checksum also with "openssl dgst -rmd160 /opt/local/var/macports/distfiles/any_port".

The package in /opt/local/var/macports/distfiles/ is present only after the issue of the command "port checksum". I wasn't able to verify the packages downladed by "port install" or "port upgrade outdated", since I don't know where they are.

I attached the debug output of the issued commands.

Attachments (3)

upgrade_log.txt (8.0 KB) - added by orcioni@… 8 years ago.
output of "port -v -d upgrade outdated"
manual_checksum_log.txt (204 bytes) - added by orcioni@… 8 years ago.
output of manual checksum of package hdf5
checksum_log-txt (587 bytes) - added by orcioni@… 8 years ago.
output of "port -v checksum hdf5"

Download all attachments as: .zip

Change History (13)

Changed 8 years ago by orcioni@…

Attachment: upgrade_log.txt added

output of "port -v -d upgrade outdated"

Changed 8 years ago by orcioni@…

Attachment: manual_checksum_log.txt added

output of manual checksum of package hdf5

Changed 8 years ago by orcioni@…

Attachment: checksum_log-txt added

output of "port -v checksum hdf5"

comment:1 Changed 8 years ago by orcioni@…

Cc: orcioni@… added

Cc Me!

comment:2 Changed 8 years ago by ryandesign (Ryan Carsten Schmidt)

The log says:

DEBUG: openssl output: couldn't create error file for command: permission denied

Perhaps your tmp directory is not world-writable?

comment:3 in reply to:  2 ; Changed 8 years ago by orcioni@…

Replying to ryandesign@…:

The log says:

DEBUG: openssl output: couldn't create error file for command: permission denied

Perhaps your tmp directory is not world-writable?

I use Macport from a year now and now there is a problem. I should know if it ww or not, but I'm not shure. I assure that as normal user I can write on it, BTW:

bash-3.2# ls -ld /tmp
lrwxr-xr-x@ 1 root  wheel  11 15 Nov  2014 /tmp -> private/tmp
bash-3.2# sw_vers
ProductName:	Mac OS X
ProductVersion:	10.10.5
BuildVersion:	14F1605

thanks

Last edited 8 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

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

Replying to orcioni@…:

Replying to ryandesign@…:

The log says:

DEBUG: openssl output: couldn't create error file for command: permission denied

With a little more research, I've found that this is a Tcl error message, generated when Tcl is trying to launch a program, but cannot create a temporary file to store that program's error output. The problem is not specific to the openssl command. This explains why running the openssl command on the command line, outside of Tcl, succeeds.

bash-3.2# ls -ld /tmp
lrwxr-xr-x@ 1 root  wheel  11 15 Nov  2014 /tmp -> private/tmp

This only shows us the permissions of the /tmp symlink, not the permissions of the /private/tmp directory that the symlink points to. Can you try:

ls -ld /private/tmp

comment:5 in reply to:  4 ; Changed 8 years ago by orcioni@…

Replying to ryandesign@…:

Replying to orcioni@…:

Replying to ryandesign@…:

The log says:

DEBUG: openssl output: couldn't create error file for command: permission denied

With a little more research, I've found that this is a Tcl error message, generated when Tcl is trying to launch a program, but cannot create a temporary file to store that program's error output. The problem is not specific to the openssl command. This explains why running the openssl command on the command line, outside of Tcl, succeeds.

I agree that is not a porblem of openssl. On another computer I get the same error by upgrading hdf5:

Warning: Failed to verify signature for archive!
Error: org.macports.archivefetch for port hdf5 returned: archivefetch failed for hdf5 @1.8.16_2+cxx+hl
Please see the log file for port hdf5 for details:
    /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_science_hdf5/hdf5/main.log
Error: Unable to upgrade port: 1
To report a bug, follow the instructions in the guide:
    http://guide.macports.org/#project.tickets
bash-3.2# ls -ld /tmp
lrwxr-xr-x@ 1 root  wheel  11 15 Nov  2014 /tmp -> private/tmp

This only shows us the permissions of the /tmp symlink, not the permissions of the /private/tmp directory that the symlink points to. Can you try:

ls -ld /private/tmp

As said, I have the same problem on two computers. In the following you can find the result of the command execution on both of them:

drwxrwxrwt  7 root  wheel  238  1 Apr 19:37 /private/tmp
drwxr-xr-x@ 19 sim  staff  646  2 Apr 04:07 /private/tmp

On the first one, I work around the problem by completely uninstalling macport and reinstalling it. On the second I maintain the old macport.
thanks
S.

Last edited 8 years ago by ryandesign (Ryan Carsten Schmidt) (previous) (diff)

comment:6 in reply to:  5 ; Changed 8 years ago by ryandesign (Ryan Carsten Schmidt)

Replying to orcioni@…:

As said, I have the same problem on two computers. In the following you can find the result of the command execution on both of them:

drwxrwxrwt  7 root  wheel  238  1 Apr 19:37 /private/tmp

That looks correct.

drwxr-xr-x@ 19 sim  staff  646  2 Apr 04:07 /private/tmp

That's incorrect and needs to be fixed to match the first. These commands should do it:

sudo chmod 1777 /private/tmp
sudo chown root:wheel /private/tmp

comment:7 Changed 8 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: ryandesign@… added; orcioni@… removed
Component: portsbase

The same problem was reported by another user in #51220.

comment:8 Changed 8 years ago by ryandesign (Ryan Carsten Schmidt)

Summary: port upgrade outdated fails with checksum error but checksum is OK.couldn't create error file for command: permission denied

comment:9 in reply to:  6 Changed 8 years ago by orcioni@…

Replying to ryandesign@…:

Replying to orcioni@…:

As said, I have the same problem on two computers. In the following you can find the result of the command execution on both of them:

drwxrwxrwt  7 root  wheel  238  1 Apr 19:37 /private/tmp

That looks correct.

drwxr-xr-x@ 19 sim  staff  646  2 Apr 04:07 /private/tmp

That's incorrect and needs to be fixed to match the first. These commands should do it:

sudo chmod 1777 /private/tmp
sudo chown root:wheel /private/tmp

Your fixing worked!

Clearly from the previous "port upgrade outdated" the directory premissions were changed, I don't know how it happened, by many thanks for your suggestion.

You can close the ticket.
thanks
S.

comment:10 Changed 8 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: invalid
Status: newclosed

Great! Glad that worked.

Note: See TracTickets for help on using tickets.