#62612 closed defect (duplicate)

Losing Wifi connection when installing a Perl CPAN port

Reported by: jrjsmrtn Owned by:
Priority: Normal Milestone:
Component: base Version: 2.6.4
Keywords: Cc:
Port:

Description (last modified by jrjsmrtn)

TL;DR

The first Perl CPAN port installation on a M1 MacBook Air with macOS 11.2.3 and the Little Snitch 5.1.2 application firewall freeze the Wifi connection. The Mac must be restarted to restore Wifi connection; Little Snitch must be uninstalled to allow further CPAN ports installation.


I successfully performed a clean and Git source-based installation of MacPorts on a M1 MacBook Air with macOS 11.2.3 and the Little Snitch 5.1.2 application firewall.

However, when installing the ccache port, the process freezed, I lost network connections (Web, Mail...) then the Wifi connection indicated that it was connected but had no Internet connection. All other computers in the Wifi network were ok.

I have been able to reproduce the issue and observed that the first Perl CPAN port installation was starting a lot of pings to CPAN mirrors before the Network connection started to freeze. Those ping processes seems to hang indefinitely.

Turning the Wifi connection off then on or turning the Little Snitch network filter off does not resolve the network connection freeze. The Mac has to be _restarted_ to restore the Wifi connection and the Little Snitch firewall must be _uninstalled_ to continue MacPorts installations.

I have submitted the issue to Objective Development for further investigation on Little Snitch.


How to reproduce

Without Little Snitch:

  1. Install MacPorts dependencies
  2. Install MacPorts v2.6.4 from Git sources
  3. In macports.conf:
    1. set build_arch to arm64
    2. set buildfromsource to always
  4. Install ccache
    1. sudo port install -vs ccache
  5. Enjoy your M1...

With Little Snitch:

  1. Uninstall MacPorts
  2. Install Little Snitch 5.1.2
    1. Turn on Network Filter
    2. Prepare to allow a bunch of new rules… :-)
  3. Re-install MacPorts v2.6.4 from Git sources
  4. Re-configure macports.conf for arm64 source builds
  5. Start the Activity Monitor, select All Operations, Hierarchically and filter operations on ping. Or start a watch -x pstree -s ping in another session.
  6. Install ccache:
    1. sudo port install -vs ccache
  7. The installation freezes here:
    […]
    DEBUG: Starting logging for p5.28-locale-gettext
    DEBUG: macOS 11.2 (darwin/20.3.0) arch arm
    DEBUG: MacPorts 2.6.4
    DEBUG: Xcode 12.4
    DEBUG: SDK 11.2
    DEBUG: MACOSX_DEPLOYMENT_TARGET: 11.2
    DEBUG: Attempting ln -sf /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_perl_p5-locale-gettext/p5.28-locale-gettext/work /opt/local/var/macports/sources/rsync.macports.org/macports/release/tarballs/ports/perl/p5-locale-gettext/work
    DEBUG: dropping privileges: euid changed to 502, egid changed to 501.
    Warning: The macOS 11.2 SDK does not appear to be installed. Ports may not build correctly.
    Warning: You can install it as part of the Xcode Command Line Tools package by running `xcode-select --install'.
    DEBUG: Executing org.macports.main (p5.28-locale-gettext)
    DEBUG: Privilege de-escalation not attempted as not running as root.
    DEBUG: archivefetch phase started at Fri Apr  2 14:18:05 CEST 2021
    DEBUG: Executing org.macports.archivefetch (p5.28-locale-gettext)
    DEBUG: Privilege de-escalation not attempted as not running as root.
    DEBUG: fetch phase started at Fri Apr  2 14:18:05 CEST 2021
    --->  Fetching distfiles for p5.28-locale-gettext
    DEBUG: elevating privileges for fetch: euid changed to 0, egid changed to 0.
    DEBUG: dropping privileges: euid changed to 502, egid changed to 501.
    DEBUG: Executing org.macports.fetch (p5.28-locale-gettext)
    --->  gettext-1.07.tar.gz does not exist in /opt/local/var/macports/distfiles/perl5
    
  8. a bunch (89) of pings to CPAN mirrors appears in the Activity Monitor or the watch session:
    […]
         |   \-+= 46134 root sudo port -d install ccache
         |     \-+- 46135 root /opt/local/libexec/macports/bin/tclsh8.5 /opt/local/bin/port -d install ccache
         |       |--- 52854 root (ping)
         |       |--- 52855 root (ping)
         |       |--- 52856 root (ping)
         |       |--- 52857 root (ping)
         |       |--- 52858 root (ping)
         |       |--- 52859 root (ping)
         |       |--- 52860 root (ping)
         |       |--- 52861 root (ping)
         |       |--- 52862 root (ping)
         |       |--- 52863 root (ping)
         |       |--- 52864 root (ping)
         |       |--- 52865 root (ping)
         |       |--- 52866 root (ping)
         |       |--- 52867 root (ping)
         |       |--- 52868 root (ping)
         |       |--- 52869 root ping -noq -c3 -t3 cpan.mirror.ac.za
         |       |--- 52870 root (ping)
         |       |--- 52871 root (ping)
         |       |--- 52872 root ping -noq -c3 -t3 cpan.mirror.cdnetworks.com
         |       |--- 52873 root (ping)
         |       |--- 52874 root ping -noq -c3 -t3 cpan.mirror.colo-serv.net
         |       |--- 52875 root ping -noq -c3 -t3 cpan.mirror.constant.com
         |       |--- 52876 root ping -noq -c3 -t3 cpan.mirror.digitalpacific.com.au
         |       |--- 52877 root ping -noq -c3 -t3 cpan.mirror.iphh.net
         |       |--- 52878 root (ping)
         |       |--- 52879 root ping -noq -c3 -t3 cpan.mirror.serversaustralia.com.au
         |       |--- 52880 root (ping)
         |       |--- 52881 root ping -noq -c3 -t3 cpan.mirrors.hoobly.com
         |       |--- 52882 root (ping)
         |       |--- 52883 root ping -noq -c3 -t3 cpan.mirrors.tds.net
         |       |--- 52884 root ping -noq -c3 -t3 cpan.mirrors.uk2.net
         |       |--- 52885 root (ping)
         |       |--- 52886 root (ping)
         |       |--- 52887 root (ping)
         |       |--- 52888 root ping -noq -c3 -t3 cpan.pair.com
         |       |--- 52889 root (ping)
         |       |--- 52890 root ping -noq -c3 -t3 cpan.perl.pt
         |       |--- 52891 root (ping)
         |       |--- 52892 root ping -noq -c3 -t3 cpan.rinet.ru
         |       |--- 52893 root ping -noq -c3 -t3 cpan.saix.net
         |       |--- 52894 root (ping)
         |       |--- 52895 root ping -noq -c3 -t3 cpan.uib.no
         |       |--- 52896 root (ping)
         |       |--- 52897 root (ping)
         |       |--- 52898 root ping -noq -c3 -t3 cpan.webdesk.ru
         |       |--- 52899 root ping -noq -c3 -t3 cpan.zbr.pt
         |       |--- 52900 root (ping)
         |       |--- 52901 root (ping)
    
  9. Start losing your network connections...

Note: installing the p5.28-locale-gettext port instead of ccache should speed up the debugging process... :-)

Change History (2)

comment:1 Changed 22 months ago by jrjsmrtn

Description: modified (diff)

comment:2 Changed 22 months ago by raimue (Rainer Müller)

Resolution: duplicate
Status: newclosed

I think this must be a duplicate of #60509 or #61683.

Note: See TracTickets for help on using tickets.