0

Two slackware 14.2 systems,ssh is 7.9p1.

On local system

mkdir -p -v "I want to create long dir name with spaces"
mkdir: directory 'I want to create long dir name with spaces' created

And is OK

On remote

ssh remote mkdir -p -v "I want to create long dir name with spaces"
mkdir: created directory 'I'
mkdir: created directory 'want'
mkdir: created directory 'to'
mkdir: created directory 'create'
mkdir: created directory 'long'
mkdir: created directory 'dir'
mkdir: created directory 'name'
mkdir: created directory 'with'
mkdir: created directory 'spaces'

Why?

I have tried using ' instead of " and

ssh remote mkdir -p -v 'I want to create long dir name with spaces'

Exit with 0(success) but no dir created

marked as duplicate by Stephen Kitt, Community Mar 26 at 9:28

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

0

Solution found

ssh remote mkdir -p -v 'I\ want\ to\ create\ long\ dirname\ with\ spaces'

I don't understand why on remote is different and I have to escape with \.

Not the answer you're looking for? Browse other questions tagged or ask your own question.