Re: How to do an rm through ssh
- From: Kimmo Koivisto <kimmo.koivisto@xxxxxxxxx>
- Date: Fri, 14 Jul 2006 08:52:08 +0300
Wences wrote:
Hello, everybody.
The problem is that this line fails:
ssh -i /root/.ssh/some_user-identity -p XXX some_user@xxxxxxxxxxxxxxx
-s \
"rm -fr /cygdrive/d/backup/$day_of_week/*"
( $day_of_week is 1_Monday, 2_Tuesday, etc, and those directories exist
)
The error message says:
Request for subsystem 'rm -fr /cygdrive/d/backup/4_Thursday/*' failed
on channel 0
What's the meaning of that?
Hello
With -s you are requesting that ssh starts subsystem "your command and path"
and it fails, maybe you can find out exact reason from server log. I have
only used sftp subsystem and I don't know much about those.
But anyway, there is no need for -s when you wan't to execute commands, just
use:
ssh -options some_user@host "command"
Does this help?
BR
Kimmo Koivisto
.
- Follow-Ups:
- Re: How to do an rm through ssh
- From: Wences
- Re: How to do an rm through ssh
- References:
- How to do an rm through ssh
- From: Wences
- How to do an rm through ssh
- Prev by Date: Re: How to do an rm through ssh
- Next by Date: Re: How to do an rm through ssh
- Previous by thread: Re: How to do an rm through ssh
- Next by thread: Re: How to do an rm through ssh
- Index(es):