1 Pluspunkt 0 Minuspunkte

Wie kann ich einen sudo Befehl mit SSH remote aufrufen?

ssh user@host "sudo cc get_object REF_PacPacWin11Ou
user@host's password:
sudo: no tty present and no askpass program specified
von  

1 Antwort

0 Pluspunkte 0 Minuspunkte

Du kannst SSH mit der -t Option ausführen.

Force pseudo-tty allocation. This can be used to execute arbitrary screen-based programs on a remote machine, which can be very useful, e.g., when implementing menu services.  Multiple -t options force tty allocation, even if ssh has no local tty.

von (728 Punkte)