public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Eliot Moss <moss@cs.umass.edu>
To: john doe <johndoe65534@mail.com>, cygwin@cygwin.com
Subject: Re: Remotely restart a windows machine
Date: Fri, 25 Sep 2020 10:57:36 -0400	[thread overview]
Message-ID: <f79197e6-5680-8252-c08e-410b56f02cf9@cs.umass.edu> (raw)
In-Reply-To: <c1a6607a-5cd4-9822-ba33-5b11c5e4f2ee@mail.com>

On 9/25/2020 10:36 AM, john doe wrote:
> On 9/25/2020 4:28 PM, Peter J. Krum via Cygwin wrote:
>> The syntax of this command is:
>>
>> NET
>>      [ ACCOUNTS | COMPUTER | CONFIG | CONTINUE | FILE | GROUP | HELP |
>>        HELPMSG | LOCALGROUP | PAUSE | SESSION | SHARE | START |
>>        STATISTICS | STOP | TIME | USE | USER | VIEW ]
>>
> 
> This is a Windows command, I would look at 'shutdown.exe' or whatever
> tools is using rpc to restart windows remotely.

shutdown is the program that the OP desires to run remotely.  The question boils down to: How, using 
Cygwin, can I send a remote command to another computer on the network?

If the remote has sshd installed and set up, you could:

ssh user@remote shutdown ...

If you don't, I'm not sure what tools are available.  NET SESSION might be relevant;
it's a Windows thing I have never used.


But I suspect you really want Samba administration tools under Windows.  A little bit
of web search found RSAT (Remote Samba Administration Tools, for Windows).  Maybe that
will help?  If it has command line tools, you can invoke them from Cygwin if they're
on your PATH.

Regards - EM

  reply	other threads:[~2020-09-25 14:57 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-25 13:32 Peter J. Krum
2020-09-25 14:23 ` john doe
2020-09-25 14:28 ` Peter J. Krum
2020-09-25 14:36   ` john doe
2020-09-25 14:57     ` Eliot Moss [this message]
2020-09-27 21:45       ` Andrey Repin
2020-09-27 23:24         ` Eliot Moss
2020-09-28  4:47           ` Mark Geisert
2020-09-29 15:56             ` Stephen Carrier
2020-09-25 17:45   ` Peter J. Krum
2020-09-25 17:49     ` Eliot Moss

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=f79197e6-5680-8252-c08e-410b56f02cf9@cs.umass.edu \
    --to=moss@cs.umass.edu \
    --cc=cygwin@cygwin.com \
    --cc=johndoe65534@mail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).