Sponsored Content
Top Forums UNIX for Dummies Questions & Answers ssh command to execute shell script in another server Post 302589741 by Corona688 on Thursday 12th of January 2012 12:37:45 PM
Old 01-12-2012
Quote:
Originally Posted by only4satish
this is the path of the script to be run

/opt/tcs/satish/tst.ksh
I said PATH, not path. PATH as in the special variable PATH, which the shell uses to hunt for programs.

Where is nohup on that server?

What value does the script have for PATH? 'echo $PATH' if unsure.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

how to execute shell script in another server that contain sql.

hi all, how to execute shell script in another server that contain sql script. i tried using "ssh -l" option.. but i am unable to load the environment variable of the remote host. please suggest how execute the shell script contain sql part inside it. (2 Replies)
Discussion started by: sandeep909
2 Replies

2. Shell Programming and Scripting

How to use ssh execute other shell script on other host (shell script include nohup)?

i want use ssh on the host01 to execute autoexec.sh on the host02 like following : host01> ssh host02 autoexec.sh autoexec.sh include nohup command like follwing : nohup /home/jack/deletedata.sh & after i execute ssh host02 autoexec.sh one the host01. i can't found deletedata.sh... (1 Reply)
Discussion started by: orablue
1 Replies

3. Shell Programming and Scripting

bash script to execute a command remote servers using ssh

Hello, I am running into few issues, please suggest me what I am missing. I am running this script on a linux host. Main idea of this script is to, login to each host via ssh and get uid of user, service user that I trying to run this script, has already deployed ssh keys and provide sudo... (8 Replies)
Discussion started by: bobby320
8 Replies

4. Shell Programming and Scripting

Connect (SSH) to Windows server via Linux server through a script and passing command.. but failing

I am trying to connect to Windows server via Linux server through a script and run two commands " cd and ls " But its giving me error saying " could not start the program" followed by the command name i specify e g : "cd" i am trying in this manner " ssh username@servername "cd... (5 Replies)
Discussion started by: sunil seelam
5 Replies

5. Shell Programming and Scripting

Shell script to copy a file from one server to anther server and execute the binary

Hi , Is there any script to copy a files (weblogic bianary + silent.xml ) from one server (linux) to another servers and then execute the copy file. We want to copy a file on multiple servers and run the installation. Thanks (1 Reply)
Discussion started by: Nawrajesh
1 Replies

6. Shell Programming and Scripting

Shell script help to execute ssh remote commands

Hi, The below command is not giving me the count , Can somebody help me in re-writing this pls . Proc_Exist=`ssh -q -o "BatchMode=yes" -o "PasswordAuthentication=no" $OAUSER@${Primary_Node} ps -ef | grep -v grep | grep "${ICM_Proc}" |wc -l ` Also the same problem with below... (13 Replies)
Discussion started by: Y.balakrishna
13 Replies

7. Shell Programming and Scripting

How to execute a shell script that resides in another server?

hi, i have a shellscipt that is in another server, my question is how do i run the script from a different server. EXAMPLE: SCRIPT_NAME: sample.sh SERVER: A what i wanted to achieve is to call that script from server B. Tried using ssh ssh <username>@serverB /home/sample.sh but... (5 Replies)
Discussion started by: reignangel2003
5 Replies

8. Shell Programming and Scripting

Execute command using ssh server 'cmd'

Hi The command below does not work as it require to take command in the breakers But If I do so the variable values get lost ssh testserver01 'dsmc q b "${ARCHIVE_DIR}*" -sub=yes -querysummary -inactive -fromd="${BACKUP_DATE}"' Thank you. (3 Replies)
Discussion started by: zam
3 Replies

9. Shell Programming and Scripting

Execute ssh command with additional terminal command to any remote user not working script

Hello i am having an issue with bash script and this is the code now=$(cat hosts1.txt | awk '{print $2;}') while read n ;do ssh root@$now 'useradd test1; echo -e "test1\ntest1" | passwd test1 && echo "test1 ALL=(ALL:ALL) ALL" >> /etc/sudoers' When i execute only part with cat, it... (8 Replies)
Discussion started by: tomislav91
8 Replies

10. UNIX for Beginners Questions & Answers

How to execute setDomainEnv.sh in wblogic via ssh on remote server in shell script?

How to execute setDomainEnv.sh in wblogic via ssh on remote server in shell script we execute setDomainEnv.sh manually as . ./setDomainEnv.sh from its location ie /opt/SP/users/domian/bin" My approach is not working. Please advise. #!/bin/bash set -x base="/opt/SP/users/d1/bin"... (5 Replies)
Discussion started by: abhaydas
5 Replies
AA-EASYPROF(8)							     AppArmor							    AA-EASYPROF(8)

NAME
aa-easyprof - AppArmor profile generation made easy. SYNOPSIS
aa-easyprof [option] <path to binary> DESCRIPTION
aa-easyprof provides an easy to use interface for AppArmor policy generation. aa-easyprof supports the use of templates and policy groups to quickly profile an application. Please note that while this tool can help with policy generation, its utility is dependent on the quality of the templates, policy groups and abstractions used. Also, this tool may create policy which is less restricted than creating policy by hand or with aa-genprof and aa-logprof. OPTIONS
aa-easyprof accepts the following arguments: -t TEMPLATE, --template=TEMPLATE Specify which template to use. May specify either a system template from /usr/share/apparmor/easyprof/templates or a filename for the template to use. If not specified, use /usr/share/apparmor/easyprof/templates/default. -p POLICYGROUPS, --policy-groups=POLICYGROUPS Specify POLICY as a comma-separated list of policy groups. See --list-templates for supported policy groups. The available policy groups are in /usr/share/apparmor/easyprof/policy. Policy groups are simply groupings of AppArmor rules or policies. They are similar to AppArmor abstractions, but usually encompass more policy rules. -a ABSTRACTIONS, --abstractions=ABSTRACTIONS Specify ABSTRACTIONS as a comma-separated list of AppArmor abstractions. It is usually recommended you use policy groups instead, but this is provided as a convenience. AppArmor abstractions are located in /etc/apparmor.d/abstractions. See apparmor.d(5) for details. -r PATH, --read-path=PATH Specify a PATH to allow owner reads. May be specified multiple times. If the PATH ends in a '/', then PATH is treated as a directory and reads are allowed to all files under this directory. Can optionally use '/*' at the end of the PATH to only allow reads to files directly in PATH. -w PATH, --write-dir=PATH Like --read-path but also allow owner writes in additions to reads. -n NAME, --name=NAME Specify NAME of policy. If not specified, NAME is set to the name of the binary. The NAME of the policy is often used as part of the path in the various templates. --template-var="@{VAR}=VALUE" Set VAR to VALUE in the resulting policy. This typically only makes sense if the specified template uses this value. May be specified multiple times. --list-templates List available templates. --show-template=TEMPLATE Display template specified with --template. --templates-dir=PATH Use PATH instead of system templates directory. --list-policy-groups List available policy groups. --show-policy-group Display policy groups specified with --policy. --policy-groups-dir=PATH Use PATH instead of system policy-groups directory. --author Specify author of the policy. --copyright Specify copyright of the policy. --comment Specify comment for the policy. EXAMPLE
Example usage for a program named 'foo' which is installed in /opt/foo: $ aa-easyprof --template=user-application --template-var="@{APPNAME}=foo" --policy-groups=opt-application,user-application /opt/foo/bin/FooApp BUGS
If you find any additional bugs, please report them to Launchpad at <https://bugs.launchpad.net/apparmor/+filebug>. SEE ALSO
apparmor(7) apparmor.d(5) AppArmor 2.7.103 2012-07-16 AA-EASYPROF(8)
All times are GMT -4. The time now is 04:04 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy