<div dir="auto"><div>Hi! Thanks for your assistance! </div><div dir="auto"><br></div><div dir="auto">This was indeed the problem. Walking from root onwards to:</div><div dir="auto"><br></div><div dir="auto"><span style="font-family:sans-serif">/opt/local/var/macports/source</span><span style="font-family:sans-serif">s</span><br></div><div dir="auto"><span style="font-family:sans-serif"><br></span></div><div dir="auto"><span style="font-family:sans-serif">I discovered that:</span></div><div dir="auto"><span style="font-family:sans-serif"><br></span></div><div dir="auto"><span style="font-family:sans-serif">/opt/local </span></div><div dir="auto"><span style="font-family:sans-serif"><br></span></div><div dir="auto"><span style="font-family:sans-serif">somehow over the course over the last few days had its permissions set to:</span></div><div dir="auto"><span style="font-family:sans-serif"><br></span></div><div dir="auto"><span style="font-family:sans-serif">rwxr-x---</span></div><div dir="auto"><span style="font-family:sans-serif"><br></span></div><div dir="auto"><span style="font-family:sans-serif">Changing this to:</span></div><div dir="auto"><span style="font-family:sans-serif"><br></span></div><div dir="auto"><span style="font-family:sans-serif">rwxr-xr-x</span></div><div dir="auto"><span style="font-family:sans-serif"><br></span></div><div dir="auto"><span style="font-family:sans-serif">Fixed the problem. </span></div><div dir="auto"><span style="font-family:sans-serif"><br></span></div><div dir="auto"><span style="font-family:sans-serif">I hope this information helps someone in the future! </span></div><div dir="auto"><span style="font-family:sans-serif"><br></span></div><div dir="auto"><font face="sans-serif">That is, if you experience this issue, "</font><span style="font-family:sans-serif">Error: Unable to execute port: Could not open file:..." that it may well be caused by permissions for others have been removed. </span></div><div dir="auto"><span style="font-family:sans-serif"><br></span></div><div dir="auto"><span style="font-family:sans-serif">Thanks again! </span></div><div dir="auto"><br></div><div dir="auto"><br></div><div dir="auto"><br><br><div class="gmail_quote" dir="auto"><div dir="ltr">On Sat, Sep 29, 2018, 1:19 AM Ryan Schmidt, <<a href="mailto:ryandesign@macports.org">ryandesign@macports.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><br>
<br>
On Sep 28, 2018, at 21:10, Anand Pathak Sharma wrote:<br>
<br>
> Hi everyone!<br>
> <br>
> I cannot figure out what and how happened to cause this issue but today, out of the perceived blue, I found that my local nginx/mysql servers installed via macports have stopped working. I have a feeling this may be related to the user/group ownership of the files in question.<br>
> <br>
> I tried uninstalling Nginx then re-installing it and received the following error:<br>
> <br>
> Error: Unable to execute port: Could not open file: /opt/local/var/macports/sources/<a href="http://rsync.macports.org/release/tarballs/ports/www/nginx/Portfile" rel="noreferrer noreferrer" target="_blank">rsync.macports.org/release/tarballs/ports/www/nginx/Portfile</a><br>
> <br>
> On a whim, I tried doing the same for another port and received the same message:<br>
> <br>
> Error: Unable to execute port: Could not open file: /opt/local/var/macports/sources/<a href="http://rsync.macports.org/release/tarballs/ports/php/php-timezonedb/Portfile" rel="noreferrer noreferrer" target="_blank">rsync.macports.org/release/tarballs/ports/php/php-timezonedb/Portfile</a><br>
> <br>
> I moved into the directory, "/opt/local/var/macports/sources/<a href="http://rsync.macports.org/release/tarballs/ports" rel="noreferrer noreferrer" target="_blank">rsync.macports.org/release/tarballs/ports</a>" and checked the ownership of the files in it and they are set to:<br>
> <br>
> root:rvm<br>
> <br>
> When viewing the ownership of macport files in parent directories, I see that they are set to:<br>
> <br>
> root:admin<br>
> <br>
> This inconsistency makes me feel that somehow ownership has changed and caused these issues.<br>
> <br>
> I'd greatly appreciate some assistance with working out this matter.<br>
> <br>
> Many thanks!<br>
<br>
The ownership of the files in /opt/local/var/macports/sources/<a href="http://rsync.macports.org" rel="noreferrer noreferrer" target="_blank">rsync.macports.org</a> should not matter. By default they will be owned by the uid and gid that are used on our main rsync server, which happen to be uid 500 and gid 505, but those aren't necessarily meaningful uid or gid values on your system.<br>
<br>
Check the ownership and permissions of each directory leading up to that one, though:<br>
<br>
ls -ld /opt /opt/local /opt/local/var /opt/local/var/macports /opt/local/var/macports/sources<br>
<br>
Are read and execute permission ("r-x") for every user present for each of those directories?<br>
<br>
</blockquote></div></div></div>