Making an Android phone show up as a mount point on OS X

May 18, 2023    Android MacOS

Note: Don’t do this on public Wi-Fi, it relies on FTP, and everything is sent in the clear without encryption.

install app on Android phone

launch Cx File Explorer

  • go to NETWORK tab
  • click Access from n… (network)
  • click START SERVICE

Make a note of the URL, username and password.

connect via Finder

and then enter the username/password from the phone, click Connect

If this worked, Finder should bring up a window with the “device” folder.

Enjoy

From the command-line, you can now interact with it like any other mountpoint:

% cd /Volumes/192.168.1.233/device
% du -d 1 | sort -nr | head -7
41565684	.
36634748	./DCIM
2141624	./Movies
1249972	./Download
835856	./Pictures
651400	./Music
45880	./ReadEra

% tree -d | head -7
.
├── Alarms
├── Android
│   ├── data
│   ├── media
│   │   ├── com.Slack
│   │   │   └── Notifications
...

Disconnect

When you are done:

  • Click Eject button in Finder
  • Click STOP SERVICE button in the Android app.

Issues

If Finder becomes unable to connect, go into App Info for Cx File Explorer and do “Force stop”. Re-launch the app.

I’ve had to do this whenever the FTP server from the Android app starts to return too many connections.


The mountpoint gets mounted as read-only:

% mount | grep ftp
ftp://pc@192.168.1.233:6797 on /Volumes/192.168.1.233 (nfs, nodev, nosuid, read-only, mounted by user)

This is a limitation of mount_ftp:

     -o      Options passed to mount(2) are specified with the -o option followed by a comma separated string of options. See the mount(8) man page for
             possible options and their meanings. The rdonly option will be set even if it was not specified because mount_ftp does not allow files to
             be opened with write access on servers.