Fwd: ssh and change group id

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



bah, this didn't make it to the list, but I _had_ replied with some
"helpful" guidance :-D


---------- Forwarded message ----------
From: Daniel Llewellyn <daniel@xxxxxxxxxxxxxxx>
Date: Wed, Aug 12, 2009 at 21:37
Subject: Re: ssh and change group id
To: Kyle S Hoyt <Kyle_S_Hoyt@xxxxxxxxxxxx>


On Wed, Aug 12, 2009 at 01:13, Kyle S Hoyt<Kyle_S_Hoyt@xxxxxxxxxxxx> wrote:
> ssh myname@myhost sg mygroup -c myprog --display mydisplay:0 -myparam 5
> ssh myname@myhost "sg mygroup -c myprog --display mydisplay:0 -myparam 5"
> ssh myname@myhost sg mygroup -c "myprog --display mydisplay:0 -myparam 5"
> ssh myname@myhost sg mygroup -c 'myprog --display mydisplay:0 -myparam 5'

nearly - you need to send the quotes to the _remote_ machine, but the
way you have it in your commandline(s) is that they will be
interpreted by the _local_ shell before sending to the server.

> If I issue the sg command locally (no ssh), then the parameters do get
> passed to the script
>
> sg mygroup -c "myprog --display mydisplay:0 --myparam 5"

you want this command to be sent _exactly_ as it appears over the
wire, including the " characters.

hint, shells "escape" characters with the backslash symbol: \
e.g. \n = new line

this should be enough information for you to determine what you need
to do, or what to lookup in google.

-- 
Regards,
    Daniel Llewellyn

[Index of Archives]     [Open SSH Unix Development]     [Fedora Users]     [Fedora Desktop]     [Yosemite Backpacking]     [KDE Users]     [Gnome Users]

  Powered by Linux