Difference between revisions of "RemoteCommand"

From wikieduonline
Jump to navigation Jump to search
 
(11 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
[[OpenSSH 7.6]] (Oct 2017)
 
[[OpenSSH 7.6]] (Oct 2017)
  
 +
[[RequestTTY]] yes
 +
RemoteCommand sudo su - -c "tmux new -A -s main"
  
  RequestTTY yes
+
  [[RequestTTY]] yes
 
  RemoteCommand [[screen -UDr]]
 
  RemoteCommand [[screen -UDr]]
 +
 +
[[RequestTTY]] yes
 +
RemoteCommand [[sudo su -]]
  
[[RequestTTY]]
+
=== Login change to root and move to an specific directory ===
 
 
  [[RequestTTY]] yes
 
  RemoteCommand [[sudo su -]]
 
 
 
 
 
Login change to root and move to an specific directory:
 
 
   RequestTTY yes
 
   RequestTTY yes
 
   RemoteCommand sudo su - -c "cd /tmp && [[bash]]"
 
   RemoteCommand sudo su - -c "cd /tmp && [[bash]]"
  
[[screen -RD]]
+
<code>[[screen -RD]]</code>
 +
 
 +
== Related ==
 +
* <code>[[RequestTTY]]</code>
 +
* <code>[[ControlMaster]]</code>
  
 
== See also ==
 
== See also ==
 
* {{ssh_config}}
 
* {{ssh_config}}
* {{OpenSSH}}
 
  
 
[[Category:SSH]]
 
[[Category:SSH]]

Latest revision as of 06:54, 19 March 2026

OpenSSH 7.6 (Oct 2017)

RequestTTY yes
RemoteCommand sudo su - -c "tmux new -A -s main"
RequestTTY yes
RemoteCommand screen -UDr

RequestTTY yes
RemoteCommand sudo su -

Login change to root and move to an specific directory[edit]

 RequestTTY yes
 RemoteCommand sudo su - -c "cd /tmp && bash"

screen -RD

Related[edit]

See also[edit]

Advertising: