ssh doubt..


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting ssh doubt..
# 1  
Old 07-21-2009
ssh doubt..

Hi,

I want to remove some package in a remote server, I am executing as the below script
Code:
ssh -q REMOTE_SERVER "pkgrm PKGNAME"

but it is asking can you confirm for the removal of pkg?

so is this respose will go to REMOTE_SERVER and remove the package?

Thanks

Bala

Use CODE-tags when displaying code, data or logs to enhance readability and to preserve formatting like indention etc., ty.

Last edited by zaxxon; 07-21-2009 at 05:53 AM.. Reason: code tags
# 2  
Old 07-21-2009
You can try:

Code:
ssh -q REMOTE_SERVER "yes| pkgrm PKGNAME"

Or check the man page of pkgrm for a non-interactive flag.
# 3  
Old 07-21-2009
Thank you so much

---------- Post updated at 05:50 PM ---------- Previous update was at 04:34 PM ----------

Hi,

Is this correct? I am getting the below error..


/sbin/sh: yes: not found
# 4  
Old 07-21-2009
Quote:
Originally Posted by balamv
Thank you so much

---------- Post updated at 05:50 PM ---------- Previous update was at 04:34 PM ----------

Hi,

Is this correct? I am getting the below error..


/sbin/sh: yes: not found

go to the remote machine and type "which yes" if you get nothing back you do not have the command "yes"

Im guessing the remote box is a Sun server as your using pkgrm, and I think "yes" is in /bin/
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Find active SSH servers w/ ssh keys on LAN

Hi, I am trying to complete my bash script in order to find which SSH servers on LAN are still active with the ssh keys, but i am frozen at this step: #!/bin/bash # LAN SSH KEYS DISCOVERY SCRIPT </etc/passwd \ grep /bin/bash | cut -d: -f6 | sudo xargs -i -- sh -c ' && cat... (11 Replies)
Discussion started by: syrius
11 Replies

2. UNIX for Beginners Questions & Answers

Ssh script to validate ssh connection to multiple serves with status

Hi, I want to validate ssh connection one after one for multiple servers..... password less keys already setup but now i want to validate if ssh is working fine or not... I have .sh script like below and i have servers.txt contains all the list of servers #/bin/bash for host in $(cat... (3 Replies)
Discussion started by: sreeram4
3 Replies

3. Shell Programming and Scripting

Ssh = ssh expect and keep everything not change include parameter postion

I have write a script which contains ssh -p 12345 dcplatform@10.125.42.50 ssh 127.0.0.1 -p 5555 "$CMD" ssh root@$GUEST_IP "$CMD" before I use public key, it works well, now I want to change to "expect", BUT I don't want to change above code and "parameter position" I can post a... (1 Reply)
Discussion started by: yanglei_fage
1 Replies

4. Shell Programming and Scripting

Small doubt for using wget cia SSH!!!

Hi Guys, I have just ran into a small problem where I am trying to ssh to another server and the script does a wget on that server. Following is the syntax I am using though it's not working as expected. A normall wget on the local system simply shows the verbose output in one horizontal line... (2 Replies)
Discussion started by: rockf1bull
2 Replies

5. Ubuntu

SSH and VPM Doubt

hI MY Nerd folks...i have ubuntu 10.4 in my machine...i want to use open shh in my latop for the sake of being complete anonymous...but am just a noob anyont got any tips for me for the complete steps or for How to LInks ...watever..thanks in advance (4 Replies)
Discussion started by: surensach
4 Replies

6. Solaris

Doubt regarding SSH

Hi, I started my ssh daemon on my new built host, but still am not able to do ssh. Can you please let me know what file do I need to add my hostname for enabling the SSH. (4 Replies)
Discussion started by: rogerben
4 Replies

7. UNIX for Dummies Questions & Answers

A doubt with SSH

Hello forum members, I am trying login to remote machine so i have to know which is option with ssh. Iam on spdiu05 machine and iam trying to login to spdma505.so plz tell correct comand.ASAP Advance thanks. Siva Ranganath Ch (3 Replies)
Discussion started by: sivaranga001
3 Replies

8. UNIX for Dummies Questions & Answers

doubt in ssh command for remote login

Hello sir, Im using ubuntu distro. We all know that ssh is used for password less entry.So, I have the public key and the IP address and the username thats it. Now to login it to the system either I should have password or a private key.Now I have the blacklist of private/public keys. But I dont... (1 Reply)
Discussion started by: nsharath
1 Replies

9. UNIX for Dummies Questions & Answers

doubt in "ssh"

Hello sir, Im using a FEDORA 9 system. We can invoke the terminal of any user using ssh.For example for the local domain :- My req. is that I want to open the terminal and see that a command runs in the terminal that is opened. Eg: I want to invoke a terminal and run "ls". instead of typing... (11 Replies)
Discussion started by: nsharath
11 Replies
Login or Register to Ask a Question