back to prompt


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting back to prompt
# 8  
Old 03-21-2012
To answer the question in post #1.
It is not possible for a background task to type input on the foreground keyboard.
It is not normal to create a background process which outputs to a terminal - it will clash with any foreground process.
This User Gave Thanks to methyl For This Post:
# 9  
Old 03-21-2012
Quote:
Originally Posted by methyl
It is not normal to create a background process which outputs to a terminal - it will clash with any foreground process.
hmm... the script should look for running foreground processes on same terminal to prevent this? Smilie
there's just one problem left - guess we can not check if some chars already entered into prompt?
# 10  
Old 03-21-2012
I think you've missed the point about background processes.
# 11  
Old 03-21-2012
Quote:
Originally Posted by daWonderer
hmm... the script should look for running foreground processes on same terminal to prevent this? Smilie
there's just one problem left - guess we can not check if some chars already entered into prompt?
you can try like this Smilie
Code:
# ./cko 1 &>/dev/null &

# 12  
Old 03-21-2012
Quote:
Originally Posted by methyl
I think you've missed the point about background processes.
maybe you are right - background processes should not output something to stdout/terminal.
I just thought about emergency situation of processes in the back..
how to inform the terminal user?

how does command 'shutdown +15' handle this?
# 13  
Old 03-21-2012
The shutdown command is machine-specific. They usually use thewall command.
Code:
man wall
man write

The messages from wall or write still mess up the display on the receiving terminals.

We use email for alerts and also have dedicated monitor terminals for events (some of which may be alerts).
This User Gave Thanks to methyl For This Post:
Login or Register to Ask a Question

Previous Thread | Next Thread

8 More Discussions You Might Find Interesting

1. 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

2. UNIX for Dummies Questions & Answers

How to Change the % prompt to - prompt in UNIX?

how to Change the % prompt to - prompt in unix :wall: ---------- Post updated at 07:40 AM ---------- Previous update was at 07:38 AM ---------- How To display the last modification time of any file in unix ---------- Post updated at 07:40 AM ---------- Previous update was at 07:40 AM... (2 Replies)
Discussion started by: manjiri sawant
2 Replies

3. UNIX for Dummies Questions & Answers

Reset prompt back to "-bash-3.00$"

Can anyone tell me how to reset the command prompt back to the original 'bas'h prompt as these have all been changed via the /etc/profile to add username and hostname but some are too long. I just want to run it in a local .profile to put it back. Thanks (2 Replies)
Discussion started by: skewbie
2 Replies

4. IP Networking

Back-to-Back Connection using HBAs

Hi every body, Is it possible to connect two servers Back-to-Back (Point-to-Point) using HBA adapters & using Fiber. Note it is direct connection & there is no switches between the servers. I'm concern about using HBA adapters, it is possible or not. Thanks in advance. :) (3 Replies)
Discussion started by: aldowsary
3 Replies

5. AIX

back to back printing in UNIX

Hi , Can you suggest me how to back to back printing in UNIX? Is there any way? Kindly advise. Regards Vijaya Amirtha Raj (3 Replies)
Discussion started by: amirthraj_12
3 Replies

6. UNIX for Dummies Questions & Answers

How can I tell why my V120 is back at ok prompt?

I have a problem with a development Sun V120 platform. I will come back to it and sporadically find it's back at the ok prompt. :mad: There are no core dumps and I've had a look at /var/adm/messages and this hasn't really helped. Can someone give me some pointers on where else to look, or how... (5 Replies)
Discussion started by: mattd
5 Replies

7. Shell Programming and Scripting

back up

hi all i need to transfer files from one server to another,but i have to make up a backup with a datestamp on the destination server beore i move the new files from the source to the destination server. example source server destination server a.sun a.sun b.sun ... (0 Replies)
Discussion started by: bkan77
0 Replies

8. HP-UX

Help about back up

Hi this is Ramana.sv new to this group, please help me about my question, i am using HP-UX11.11i with oracle 10G this server is in india and i have another server in US with same HP-UX with oracle10G, what i want is i want to rename the local database in local HP server and copy the database from... (0 Replies)
Discussion started by: mcseramana
0 Replies
Login or Register to Ask a Question