2

I want to unlock the black screen over ssh (screensaver). I have a desktop ubuntu 21.04 and I want to log into this via ssh and unlock the screensaver. I tried xdotool in a script:

#!/bin/bash
export DISPLAY=:0
xdotool type "1234"

and also ydotool:

#!/bin/bash
export DISPLAY=:0
ydotool type "1234"

xdotool does nothing and with ydotool i get an error ( ydotool: notice: ydotoold backend unavailable (may have latency+delay issues) terminate called after throwing an instance of 'std::runtime_error' what(): failed to open uinput device ).

How can I unlock the screensaver over an ssh connection?

Thanks

Regards David

Dave
  • 39
  • @Nmath: Thank you very much. I hope the question is now clearer. – Dave Jul 19 '21 at 18:59
  • @Organic Marble: Thanks, yes thats the question. When I use the kill command like you write sudo kill -9, he tells me the help of the kill command – Dave Jul 19 '21 at 19:04

1 Answers1

0

Solution: I don`t have a keyboard on this pc, because i have a touchscreen. When I insert a keyboard and use ydotool as su, it works. Maybe also this solution with keyboard but without sudo could work https://github.com/ReimuNotMoe/ydotool/issues/36

Dave
  • 39