Port selfupdate: "Sources of macPorts: command execution failed"

I try to selfupdate my macros, but I get the following message:

 Error: /opt/local/bin/port: port selfupdate failed: Error synchronizing MacPorts sources: command execution failed 

I checked my /opt/local/bin/macports and the directory does not exist. Instead, it is located in /opt/local/var . Could this be a problem?

Running with -dt , I get the following:

 [Users/user] > selfupdate DEBUG: MacPorts sources location: /opt/local/var/macports/sources/rsync.macports.org/release/base ---> Updating MacPorts base sources using rsync rsync: failed to connect to rsync.macports.org: Connection refused (61) rsync error: error in socket IO (code 10) at /SourceCache/rsync/rsync-42/rsync/clientserver.c(105) [receiver=2.6.9] Command failed: /usr/bin/rsync -rtzv --delete-after rsync://rsync.macports.org/release/base/ /opt/local/var/macports/sources/rsync.macports.org/release/base Exit code: 10 DEBUG: Error synchronizing MacPorts sources: command execution failed while executing "macports::selfupdate [array get global_options] base_updated" Error: /opt/local/bin/port: port selfupdate failed: Error synchronizing MacPorts sources: command execution failed 

What is error 61? Any ideas how I can fix this?

+69
macports
Jul 12 '12 at 7:26
source share
11 answers

I stood behind the firewall. I tried on another network and worked.

+43
Jul 16 '12 at 5:25
source share

I had the same problem recently and forgot to run the command as root. If anyone else has a problem, be sure to run the command like this:

 sudo port selfupdate 
+120
Feb 11 '13 at 19:13
source share

No /opt/local/bin/macports . The required executable is /opt/local/bin/port . (Port files are located in /opt/local/var/... , which is true.)

Based on command execution failed :

  • You may have forgotten to run it as root.
  • port opens the following programs: rsync , tclsh , openssl , tar , chmod , chown . Are they executable in PATH ? (Is /opt/local/bin in your PATH ?)

If this does not help, run the port with -dt to get all kinds of debugging information. This may help find the problem. Attach interesting parts to your question, maybe.

+21
Jul 12 '12 at 8:45
source share

I ran into the same problem. But I used this method in after.

$prefix/etc/macports/sources.conf link: $prefix/etc/macports/sources.conf (my way is this :)

 /opt/local/etc/macports/sources.conf 

Comment out the rsync entry and add a new entry as follows:

 #rsync://rsync.macports.org/release/tarballs/ports.tar [default] https://distfiles.macports.org/ports.tar.gz [default] 

After that you can run:

 sudo port -d sync 

He also explained to MacPorts.com .

+14
Feb 24 '15 at 8:59
source share

Update for Mavericks: to verify that the xcode-select โ€“-install command-line tools are installed, open a terminal and run xcode-select โ€“-install , then follow the instructions in the pop-up window that appears:

  • accept license

Of course, this is in addition to other tips, such as doing sudo port selfupdate .

+13
Oct 23 '13 at 19:02
source share

If anyone else has this problem and they recently updated Xcode, the root of my problem was that the command line tools were omitted from the last build.

Opening Xcode and installing command-line tools using the Xcode preference panel fixed this error caused by MacPorts.

+11
Jul 07 '13 at 2:49
source share

If your company is blocking access through rsync, you can use http tarball. Explained here

Hope this helps.

EDIT: Now Prefer Using Homebrew

+4
Jun 10 '13 at 8:02
source share

I also had the same error. This is because the network connection is rejected. If you use Wi-Fi or a public connection with a university / company, the firewall refuses to connect.

As you can see from the output of -dt "rsync: could not connect to rsync.macports.org: Connection reject (61)"

The workarounds available on the macports website are:

1) Using svn .

2) If svn doesn't work either, you can try Daily tarball .

You can test the changes by running "sudo port -d sync"

Note. If https fails, you can replace it with http. But this is not recommended, as you will receive from an insecure connection.

+2
Apr 10 '15 at 10:16
source share

I ran into the same problem. The main problem was my network. Since the NETWORK port was blocked,

Rsync: //rsync.macports.org/release/tarballs/ports.tar

Try using a different network.

+1
Jun 30 '14 at 22:27
source share

for those who do not exist yet, you may have forgotten your consent to the Xcode license:

 # sudo xcodebuild license 

Remember to browse and enter โ€œagreeโ€ at the end.

+1
Apr 23 '16 at 15:16
source share

In my case, the problem was internal to Macports! I updated rsync (the one that was installed by Apple old) with Macports and then Macports was unable to use it (/ opt / local / bin / rsync), but instead asked to use / usr / bin / rsync, which does not exist (or was erased using rsync macros?). I created a soft bond between them, and now it works again.

0
May 20 '16 at 7:51 am
source share



All Articles