1

When I try to use scp to copy files with long filenames and containing non-alphanumeric characters, I get

scp: open local "[some capricious filename]": Invalid argument

I can copy them some places, but I can't copy them onto a USB thumb drive.

Why can I copy some files some places and not others?

Johannes Bauer
  • 343
  • 2
  • 13

1 Answers1

2

The problem is that the USB thumb drive is formatted with a FAT file system that can't handle these file names. They're legal in a modern file system, but illegal in file systems that are commonly used for USB sticks. Scp tries to open the file for writing and the OS complains.

Johannes Bauer
  • 343
  • 2
  • 13