07-02-2008
command execution time
Hi all,
I want to display a progressbar depending upon the completion status of a command. I am coding from scratch as I dont want to use in place code. so Is there anyway of getting the progress of a command in percentage or in any other units while its running , is it possible using the top command?
for example I am using command xyz which takes A time to complete
so if I fork the xyz , A/100* (something ) is complete every second , is it possible to find that something?
thanks in advance
Cheers,
Hashin
10 More Discussions You Might Find Interesting
1. Programming
hi ,
i ve coded a C program
in that im using malloc dynamically ,
it is being called many times in the program
The program is to simulate jobs in manufacturing system.
the execution time is increasing drastically as the number of jobs are increased.
could any body tel what may be the problem... (2 Replies)
Discussion started by: ramki_rk
2 Replies
2. UNIX for Dummies Questions & Answers
Hello,
I am new to this forum and relatively new to unix, but hope to become an expert soon!
My question is: How can I find out the execution time of a command that has already completed execution? More specifically, I launched a Python script to populate a PostgreSQL database on Suse... (2 Replies)
Discussion started by: marina
2 Replies
3. UNIX for Dummies Questions & Answers
is there a command in Solaris 8 that will show a particular scripts last execution time? (1 Reply)
Discussion started by: cubs0729
1 Replies
4. UNIX for Advanced & Expert Users
Hi all,
do ny o u'll know how to set a particular execution time for a program???
for eg.:
--> during the execution of a file, i call a certain other function.
--> while calling this function, my comp hangs.
now is there ny way in which i can go to the nxt line of code by aborting the call... (7 Replies)
Discussion started by: VGR
7 Replies
5. Shell Programming and Scripting
Hi All,
One of my script runs (approximately) for 20 to 40 hours
Is there any way in unix to find the estimated time required for a shell script(Cron job).ie to find the time required for execution even before the script is executed.
Any discussion(pointers) regarding the same is most welcome. (4 Replies)
Discussion started by: Sreejith_VK
4 Replies
6. Shell Programming and Scripting
Hi,
I have a simple question. How can I get the execution time of a script and maybe put it in a variable?
Another question. How can I get only time and not date and put it in a variable? I tried something with "date" command but with no success...
If someone could help me... (8 Replies)
Discussion started by: Moumou
8 Replies
7. Shell Programming and Scripting
Hello,
I am on solaris 9 (KSH). I need to get the execution time of my script. I can't use the time command as I have to send by mail the result in a human readable way.
So I am looking for a code to add to my script.
The output result would be :
Execution time :... (1 Reply)
Discussion started by: Aswex
1 Replies
8. UNIX for Dummies Questions & Answers
how much time a particular command or shell script executed
there is any command to know this
thanks (5 Replies)
Discussion started by: tsurendra
5 Replies
9. Shell Programming and Scripting
Hello Guys,
I would like to know is there a way to take the script execution time
For e.g i am having a script.sh i need to write inside he script.sh like
Start time : 10-Mar-2016 02:30:35
all code over here
...
End time : 10-Mar-2016 03:30:32
Script start time - 02:30:35 ... (7 Replies)
Discussion started by: Master_Mind
7 Replies
10. Shell Programming and Scripting
We are trying to execute below script for finding out the occurrence of a particular word in a log file Need suggestions to optimize the script.
Test.log size - Approx to 500 to 600 MB
$wc -l Test.log
16609852 Test.log
po_numbers - 11 to 12k po's to search
$more po_numbers
xxx1335... (10 Replies)
Discussion started by: KumarPiyush7225
10 Replies
LEARN ABOUT OSX
ttk_progressbar
ttk::progressbar(n) Tk Themed Widget ttk::progressbar(n)
__________________________________________________________________________________________________________________________________________________
NAME
ttk::progressbar - Provide progress feedback
SYNOPSIS
ttk::progressbar pathName ?options?
_________________________________________________________________
DESCRIPTION
A ttk::progressbar widget shows the status of a long-running operation. They can operate in two modes: determinate mode shows the amount
completed relative to the total amount of work to be done, and indeterminate mode provides an animated display to let the user know that
something is happening.
STANDARD OPTIONS
-class -cursor -takefocus
-style
See the ttk_widget manual entry for details on the standard options.
WIDGET-SPECIFIC OPTIONS
[-orient orient] One of horizontal or vertical. Specifies the orientation of the progress bar. [-length length] Specifies the length of
the long axis of the progress bar (width if horizontal, height if vertical). [-mode mode] One of determinate or indeterminate. [-maxi-
mum maximum] A floating point number specifying the maximum -value. Defaults to 100. [-value value] The current value of the progress
bar. In determinate mode, this represents the amount of work completed. In indeterminate mode, it is interpreted modulo -maximum; that
is, the progress bar completes one "cycle" when the -value increases by -maximum. [-variable variable] The name of a Tcl variable which is
linked to the -value. If specified, the -value of the progress bar is automatically set to the value of the variable whenever the latter
is modified. [-phase phase] Read-only option. The widget periodically increments the value of this option whenever the -value is greater
than 0 and, in determinate mode, less than -maximum. This option may be used by the current theme to provide additional animation effects.
WIDGET COMMAND
pathName cget option
Returns the current value of the specified option; see ttk::widget(n).
pathName configure ?option? ?value option value ...?
Modify or query widget options; see ttk::widget(n).
pathName identify x y
Returns the name of the element at position x, y. See ttk::widget(n).
pathName instate statespec ?script?
Test the widget state; see ttk::widget(n).
pathName start ?interval?
Begin autoincrement mode: schedules a recurring timer event that calls step every interval milliseconds. If omitted, interval
defaults to 50 milliseconds (20 steps/second).
pathName state ?stateSpec?
Modify or query the widget state; see ttk::widget(n).
pathName step ?amount?
Increments the -value by amount. amount defaults to 1.0 if omitted.
pathName stop
Stop autoincrement mode: cancels any recurring timer event initiated by pathName start.
SEE ALSO
ttk::widget(n)
Tk 8.5 ttk::progressbar(n)