LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-21-2014, 11:07 PM   #1
shipon_97
Member
 
Registered: Oct 2005
Location: Bangladesh
Posts: 484

Rep: Reputation: 30
Need auto prompt (yes/no) in a script !


Dear Friends ,

I write a script to kill a oracle impdp job like below :
--
[oracle@rptsvr ~]$ cat kill_job.sh
export ORACLE_HOME=/u01/app/oracle/product/10.2.0/db_1
export ORACLE_SID=PBLPRIM

impdp ultimus/ultimus_123 attach=SYS_IMPORT_FULL_02 << !
kill_job
--

After run the script it needs to manual entry , 'yes' or 'no' .

like :

Import> Are you sure you wish to stop this job ([yes]/no): UDI-00005: unexpected End-Of-File encountered
while reading input.

Now I want this script will be killed prompting 'yes' command automatically , not manually .

Hope My question is clear .

Please help me regarding this .
 
Old 01-22-2014, 04:00 AM   #2
kooru
Senior Member
 
Registered: Sep 2012
Posts: 1,385

Rep: Reputation: 273Reputation: 273Reputation: 273
yes command could be your solution

Code:
man yes
http://hscripts.com/tutorials/linux-commands/yes.html
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] apt-get auto prompt disappears after kernel upgrade wzyboy Linux - Software 1 05-09-2012 01:43 AM
script to prompt yes/no to user. jimmyjiang Red Hat 3 11-20-2011 08:43 PM
gdesklets auto start display file and without first screen prompt nvadekar Linux - Desktop 0 07-29-2009 11:54 PM
command runs at prompt not in script newbie_m Linux - Newbie 2 01-20-2005 03:12 PM
auto-completion - how does it work & can my script args auto-complete? BrianK Programming 1 06-11-2004 05:51 PM


All times are GMT -5. The time now is 06:52 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration