thanks, but in my case, the system treats the ~ as remote home dir, not the local one, since the command gets executed, but the remote system is complaining about the argument part.
line 1: syntax error at ''
Quote:
Originally Posted by scottn
Hi.
You need to either escape the tilde (~), or quote the command, otherwise the ~ means the local user's home directory, not the remote one:
On Solaris 5.9, is there any way to pass parameter(s), via SSH, to a command defined in the remote host's authorized_keys file?
We have a menu that uses SSH to control some apps on our various hosts. I've been tasked with enhancing it and making it more secure.
So far, the local host menu... (2 Replies)
I'm trying to run a command over ssh to AIX 5.2, something like:
ssh machine ls
but it just hangs. I can ssh into the machine and run a command, but can't pass it like above. Is there a security setting that disables this by default? If so, how do I change it?
Thanks! (8 Replies)
Hi,
I wan to pass arguments to remote script in Unix .
For that I'm using ssh
PFB the code I'm using:
ssh -t -l osdac 10.81.33.51 "cd /appl/OSD/LOGS/flstr010/test.sh "$1" "$2""
Problem is I'm not able to pass second argument .
Can anyone plz help me in resolving this. (5 Replies)
hi everobody
kindly consider the following
in tclsh
I understand that we can do the following
%exec UnixCmd arg1 arg2
but if I assinged the arguments to a list insde tclsh how can I use them back
i.e
%set ArgList
%exec UnixCmd
%exec Unixcmd $list
%exec
all the... (1 Reply)
I have an for loop that reads the following file
cat param.cfg
val1:env1:opt1
val2:env2:opt2
val3:env3:opt3
val4:env4:opt4
.
.
The for loop extracts the each line of the file so that at any one point, the value of i is
val1:env1:opt1 etc...
I would like to extract each... (19 Replies)
I'm pretty new to bash scripting and I've found myself writing things like this (and the same with even more nesting):
if $CATEGORIES; then
if $LABEL_SLOTS; then
$pyth "$wd/texify_grammar.py" "$input" "$texfile" "--label-slots" "--categories" "$CATEGORY_LIST"
... (9 Replies)
Hi
Im trying to run zip shell command from an Oracle job, but this has limitations.
This should take a few of explanaition,..
Oracle allows me to execute a command and then I can set up a fixed number of arguments. Ex: (summarizing in something like..):
JOB DEFINITION
job_name: test... (4 Replies)
Hi
Am pretty new to C..
Am trying to pass the arguments from command line and use them in switch case statement..
i have tried the following
#include <stdlib.h>
main(int argc, char* argv)
{
int num=0;
if ( argc == 2 )
num = argv;
printf("%d is the num value",num);
switch ( num )
... (2 Replies)
Hi Experts,
I have specific requirement where I want to pass the password with the ssh username@hostname command .
I dont want to use RSA public and private keys also. Because that will be on production server and no one wants to give access like that.
Second thing it is production... (14 Replies)
I have a variable called $a1 which maps to something like "http://servername proxy1 count http" and a lots of entries in a file on remote server.
If I have the following in my .sh script:
sed -i "\%$a1%d" mylog.txtthe line is deleted from mylog.txt. Great.
I'm trying now to remvoe this from a... (3 Replies)
Discussion started by: say170
3 Replies
LEARN ABOUT SUNOS
script
script(1) User Commands script(1)NAME
script - make record of a terminal session
SYNOPSIS
script [-a] [filename]
DESCRIPTION
The script utility makes a record of everything printed on your screen. The record is written to filename. If no file name is given, the
record is saved in the file typescript. See WARNINGS.
The script command forks and creates a sub-shell, according to the value of $SHELL, and records the text from this session. The script ends
when the forked shell exits or when Control-d is typed.
OPTIONS
The following option is supported:
-a Appends the session record to filename, rather than overwriting it.
NOTES
script places everything that appears on the screen in filename, including prompts.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWcsu |
+-----------------------------+-----------------------------+
|CSI |Enabled |
+-----------------------------+-----------------------------+
SEE ALSO attributes(5)WARNINGS
script can pose a security risk when used in directories that are writable by other users (for example, /tmp), especially when run by a
privileged user, that is, root. Be sure that typescript is not a link before running script.
SunOS 5.10 30 Jan 2004 script(1)