Sponsored Content
Top Forums Shell Programming and Scripting How can I bypass the Prompt in SFTP Post 302309274 by pierluigi22 on Tuesday 21st of April 2009 01:26:10 PM
Old 04-21-2009
How can I bypass the Prompt in SFTP

I am on a sun solaris server and trying to create a script that will test if SFTP is up and running on a remote server (which could be unix or windows).

My thought was to simply invoke sftp and if I get the prompt ofr "Password" then that is an indication that the service is running and I am done.

The problem is that the "prompt" for password takes over the and is wainting for a reply.

This script will run as a sceduled task (cron) to validate the service is up and will simply hang.

Is there a way to capture the fact that password is prompted for and then terminate the script.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

How to bypass error in shell script?

Hi again, I have a script that moves files based on filelist: ------------------------------ filelist1=./rated.txt for file in $(< $filelist1) do mv ./$file ./Backup/$file done ------------------------------ If the file in filelist is not found from the folder the script fails.... (1 Reply)
Discussion started by: tmikahan
1 Replies

2. Shell Programming and Scripting

How to get the exit satus of a command which I executed in sftp prompt

Hi All, I need the exit status of a command which is executed through sftp connection. Example: sftp user@host <<EOF mkdir /home/karteek/testing put /home/xyz.txt /home/karteek/testing EOF ------ In the above example, I need the exit status of the put command. Please help me. ... (2 Replies)
Discussion started by: Karteek
2 Replies

3. Solaris

bypass password authentication for sftp in unix

I am using solaris unix 8.2 version. I want to bypass password authentication for sftp. Can you please give some ideas on this. thanks.Regards. (4 Replies)
Discussion started by: vijill
4 Replies

4. Solaris

can't bypass password authentication

I can able to SFTP from my web server unix to apps server unix end. but the other way from APPS server to Web server is still asking me the password. I have done same procedure both side. still i am having same problem. Any one help on this. thanks, regards (3 Replies)
Discussion started by: vijill
3 Replies

5. Cybersecurity

authentication bypass vulnerability

what does it mean? I searched in google but I could not find a clear document that explain to me what does it mean. (1 Reply)
Discussion started by: programAngel
1 Replies

6. Solaris

How to disable/bypass passphrase prompt in ssh?

Hi Folks, I have setup a passwordless connection from my Linux ( source) machine toSolaris ( destination ) machine. I have added passphrase while creating the rsa key. Now problem is each time when i make a connection i have to give the passphrase to make connection. How to override this ? I... (4 Replies)
Discussion started by: chidori
4 Replies

7. Shell Programming and Scripting

awk Division By Zero Bypass

Hi Friends, I don't understand why "a" is always being printed as zero, when I execute the following command. awk '{if($6||$8||$10||$12==0)a=b=c=d=0;else (a=$5/$6);(b=$7/$8);(c=$9/$10);(d=$11/$12); {print... (6 Replies)
Discussion started by: jacobs.smith
6 Replies

8. Solaris

Unable to move from rsc prompt to ok prompt

Hi, on sunfire v890 unable to move from rsc prompt to ok prompt, i have executed the command break. (9 Replies)
Discussion started by: manoj.solaris
9 Replies

9. HP-UX

Bypass stale PE ?

Hello, I have an ancient HP-UX 11.11 system where I have a logical volume marked stale and I can't get it sync'd. I have tried lvsync and lvreduce/lvextend to no avail. It is just one 4Mb PE on the disk that I can't get current. # lvdisplay -v /dev/vg00/lvol5 | grep stale LV Status ... (17 Replies)
Discussion started by: port43
17 Replies

10. UNIX for Beginners Questions & Answers

Bypass crontab??

Hi there. I've put something in crontab that my raspberry doesn't like, it's trying to draw a window before the graphics are ready after login. Problem being after the error it throws me back to the login, so I can't log in. There is only one user setup on this raspberry so I can't log in... (6 Replies)
Discussion started by: MuntyScrunt
6 Replies
asadmin-freeze-transaction-service(1AS) 			   User Commands			   asadmin-freeze-transaction-service(1AS)

NAME
asadmin-freeze-transaction-service, freeze-transaction-service - freezes the transaction subsystem SYNOPSIS
freeze-transaction-service --user admin_user [--password admin_password][--host localhost] [--port 4848][--secure|-s] [--passwordfile file- name] [--terse=false] [--echo=false] [--interactive=true] Freezes the transaction subsystem during which time all the inflight transactions are suspended. Invoke this command before rolling back any inflight transactions. Invoking this command on an already frozen transaction subsystem has no effect. This command is supported in remote mode only. OPTIONS
--user authorized domain application server administrative username. --password password to administer the domain application server. --host machine name where the domain application server is running. --port port number of the domain application server listening for administration requests. --secure if true, uses SSL/TLS to communicate with the domain application server. --passwordfile file containing the domain application server password. --terse indicates that any output data must be very concise, typically avoiding human-friendly sentences and favoring well- formatted data for consumption by a script. Default is false. --echo setting to true will echo the command line statement on the standard output. Default is false. --interactive if set to true (default), only the required password options are prompted. Example 1: Using freeze-transaction-service asadmin> freeze-transaction-service --user admin --password adminadmin EXIT STATUS
0 command executed successfully 1 error in executing the command asadmin-unfreeze-transaction-service(1AS), asadmin-rollback-transaction(1AS) J2EE 1.4 SDK March 2004 asadmin-freeze-transaction-service(1AS)
All times are GMT -4. The time now is 12:53 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy