I figured it out, with some help. You have to be on the same server where the files are located to use wp media import. The steps are:
- Log out of ssh connection
- Log into the remote server using sftp
- Upload the files using sftp, then log out
- Log back in using ssh
- Then you can use
wp media import
Essentially, ssh is for commands and sftp is for file transfers.
I hope this helps someone else with this issue.