vwait(n) Tcl Built-In Commands vwait(n)
__________________________________________________________________________________________________________________________________________________NAME
vwait - Process events until a variable is written
SYNOPSIS
vwait varName
_________________________________________________________________DESCRIPTION
This command enters the Tcl event loop to process events, blocking the application if no events are ready. It continues processing events
until some event handler sets the value of variable varName. Once varName has been set, the vwait command will return as soon as the event
handler that modified varName completes. varName must globally scoped (either with a call to global for the varName, or with the full
namespace path specification).
In some cases the vwait command may not return immediately after varName is set. This can happen if the event handler that sets varName
does not complete immediately. For example, if an event handler sets varName and then itself calls vwait to wait for a different variable,
then it may not return for a long time. During this time the top-level vwait is blocked waiting for the event handler to complete, so it
cannot return either.
SEE ALSO
global(n)
KEYWORDS
event, variable, wait
Tcl 8.0 vwait(n)
Check Out this Related Man Page
vwait(n) Tcl Built-In Commands vwait(n)
__________________________________________________________________________________________________________________________________________________NAME
vwait - Process events until a variable is written
SYNOPSIS
vwait varName
_________________________________________________________________DESCRIPTION
This command enters the Tcl event loop to process events, blocking the application if no events are ready. It continues processing events
until some event handler sets the value of variable varName. Once varName has been set, the vwait command will return as soon as the event
handler that modified varName completes. varName must be globally scoped (either with a call to global for the varName, or with the full
namespace path specification).
In some cases the vwait command may not return immediately after varName is set. This can happen if the event handler that sets varName
does not complete immediately. For example, if an event handler sets varName and then itself calls vwait to wait for a different variable,
then it may not return for a long time. During this time the top-level vwait is blocked waiting for the event handler to complete, so it
cannot return either.
EXAMPLES
Run the event-loop continually until some event calls exit. (You can use any variable not mentioned elsewhere, but the name forever
reminds you at a glance of the intent.)
vwait forever
Wait five seconds for a connection to a server socket, otherwise close the socket and continue running the script:
# Initialise the state
after 5000 set state timeout
set server [socket -server accept 12345]
proc accept {args} {
global state connectionInfo
set state accepted
set connectionInfo $args
}
# Wait for something to happen
vwait state
# Clean up events that could have happened
close $server
after cancel set state timeout
# Do something based on how the vwait finished...
switch $state {
timeout {
puts "no connection on port 12345"
}
accepted {
puts "connection: $connectionInfo"
puts [lindex $connectionInfo 0] "Hello there!"
}
}
SEE ALSO
global(n), update(n)
KEYWORDS
event, variable, wait
Tcl 8.0 vwait(n)
Hi,
Wonder is someone can help.
I've got a server SCO_SV 3.2v5.0.7 PentIII that is located at a different site and is running slow and has been for a week. I've been speaking to a third party who say nothing is wrong with it but its still running slow.
The 3rd party advise it could be a... (2 Replies)
Hi! This is my first post and im not that familiar with UNIX but I'll try to explain my problem..
I have a server here at work running Open UNIX Release 8.0.0
It has a special application on it that I'm trying to run a database backup on. For the last 2 weeks this has failed.. Usually the... (2 Replies)
I am using the GNU automake.
I have created the Configure.in and Makefile.am files but don't know how to link in my dependencies.
I have basically added another project (OpenCV) to my eclipse workspace and want to reference this in the build. I have set Eclipse up to include the Cpp files... (5 Replies)
Friends, I have to find out the greatest amoings three values using awk. Actually i have to run the iostat -d command on my linux box for 5 or 6 iterations and print the largest value for tps at each iteration
for e.g
iostat -d 3 3
Linux 2.6.18-8.el5 (abhijit) 11/19/2009 _i686_ (2... (8 Replies)
Hello
i ve got the following error on a C servor.
signal SEGV (no mapping at the fault address)
when running in dbx
program terminated by signal SEGV (no mapping at the fault address)
0xff1d5cb4: srch_dir+0x0154: cmp %o1, %o0
Current function is _log
533 ... (4 Replies)
Hi All
Currently i had a server directly connect to the EMC box.
The EMC storage is a FC Direct Attached Storage to the server without going through SAN switches
And i had download the Daily data file in /var/adm/sa/sardd
But i not sure which one in /var/adm/sa/sardd is the correct... (14 Replies)
Can somebody explain why my sed command is not working.
I do the folloinwg:
Generates a binary file to /tmp/x1.out
/usr/lib/sa/sa2 -s 4:00 -e 8:00 -i 3600 -A -o /tmp/x1.out
decodes the file (no problem so far)
sar -f /tmp/x1.out
When I do this it does not appear to delete the... (4 Replies)
Dear all,
I would like to ask if there are any positive effects from having a dedicated hard disk for the operating system.
The scenario would be to have a dedicated disk for the OS and a dedicated disk for the applications.
Do you see any advantages in such a configuration such as better... (9 Replies)
My server is running HP-UX 11.23 and one Oracle database. The server has 8 CPUs and is mostly idle all the time. Buffer cache is set to 10%min/max with 5GB memory on the server.
I have a user complaining that a batch process is all of a sudden taking a long time to finish. The DBA gave me the... (13 Replies)
I was reviewing yesterday's sar file and came across this strange output! What in the world? Any reason why there's output like that?
SunOS unixbox 5.10 Generic_144488-07 sun4v sparc SUNW,T5240 Solaris
00:00:58 device %busy avque r+w/s blks/s avwait avserv
11:20:01 ... (4 Replies)
hi Friends,
I am writing a shell script to extract data from sar logs for my daily analysis.
I have this in sar logs
HP-UX dhpcdbe1 B.11.31 U ia64 05/09/12
01:22:42 device %busy avque r+w/s blks/s avwait avserv
01:27:59 disk30 8.79 13.72 26 427 36.47 ... (3 Replies)
Hi Experts,
glance is showing disk util 100% on of production domain and while collecting sar data using sar -d 5 5, avserv for some of the disks are more than 10 miliseconds. Need your advise on steps that needs to be taken to reduce the disk utilitzation.
device %busy avque r+w/s ... (2 Replies)
Hi,
Recently we have new server T5 Oracle. We set up it for our database. For out database files we set one zfs filesystem. When i use iostat -xc the output as below. As you see the value for vdc4 is quite high.
extended device statistics cpu
device ... (32 Replies)