Hello, first post here ever.
Set up my HA 2 days ago and now I want to start and shutdown my pc via HA.
Starting works fine.
For the shutdown, I wanna use the RPC Shutdown Addon.
Installed it. My config logs like this:
computers:
- address: [192.168.0.137](https://192.168.0.137/)
alias: Kobito-PC
credentials: 3434%xxxxx
delay: 0
message: >-
Home Assistant is shutting down this PC. This cannot be canceled. Please
save your work!
The RPC Shutdown tries to shut down my pc at 192.168.0.137. Logs say:
[13:42:15] INFO: Read alias: Kobito-PC
[13:42:16] INFO: Shutdown Kobito-PC -> 192.168.0.137
Could not connect to server 192.168.0.137
Connection failed: NT_STATUS_IO_TIMEOUT
Could not connect to server 192.168.0.137
Connection failed: NT_STATUS_IO_TIMEOUT
[13:42:26] ERROR: Shutdown fails ->
What I already did:
doublecheck the ip adress in router
run → services.msc → Remote Registry → Start
Allow an App through windowsfirewall → Windows Managment Instrumentation (WMI) → private check
Your config looks funny.
Not sure if it the website or something at your end that makes it look like that, but try to insert it again then mark it and click the </> to make sure it stays correct.
computers:
- address: 192.168.0.137
alias: Kobito-PC
credentials: 3434%xxxx
delay: 0
message: >-
Home Assistant is shutting down this PC. This cannot be canceled. Please
save your work!
If your password really has a % in it, or any other special characters - you are best advised to ensure the password is surrounded by " eg:
computers:
- address: 192.168.0.137
alias: Kobito-PC
credentials: "3434%xxxx"
delay: 0
message: >-
Home Assistant is shutting down this PC. This cannot be canceled. Please
save your work!
I see now reading the documentation and other threads, that the % is used to separate the user and password eg: asjmcguire%mysupersecretpassword There should not be any spaces, and the username will not be your full name, look in c:\users you will see that all the users are only one word. My username for example despite signing in with my full @outlook.com microsoft account, is only the first 5 letters of my email address. So for me it is asjmc%mysupersecretpassword
I think the RPC protocol is a 2-way communication setup, so you probably need to set it the other way too.
Since the same ports are used for Windows Sharing and a lot of other stuff, then its really puncturing the whole separation idea with segmented networks.
I think another way of doing this would be preferable.
I bet there is made services to achieve the same thing with just a TCP or UDP package.
I had the rpc shutdown working, but google assistant had problems with understanding the computer name. I changed my windows computer name, and also changed the config file in the addon window, to match the new name.
However, after restarting everything, when i give the command to shutdown, google assistant says ok and does it, but my pc is not going off. When i checked the log file from rpc addon, it shows : read alias: “kevin-pc” and that is the old name…
Has anyone an idea if there are other config files i need to config for rpc addon? In my config yaml, i also added the correct (new) computer name, but somehow there is something that still refers to the old name.
Firstly, if you run a script directly from HA does it shut off the PC correctly? If not, then it’s nothing tondo with Google Assistant.
How are you triggering it? I use Alexa rather than Google home, but my control method below should work…
Create a virtual switch for the PC.
Create an automation when the switch turns off, run the rpc shutdown script
Then in Alexa set a custom routine that when you say Alexa wake PC, it flicks the switch off.
I do the same for WOL.
Hi, I’m with the same problem.
I have a question. The password is the one from Microsoft account? The pin code? Or the password from the "local"account in users.