Sponsored Content
Top Forums Shell Programming and Scripting display time required to complete running script Post 302277825 by fpmurphy on Sunday 18th of January 2009 10:42:58 AM
Old 01-18-2009
Yes, it is possible. Whether it is accurate or not depends on a number of factors such as is the system heavily loaded or not at the time the script is run.
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Script to display last login date/time?

I was wondering if anyone had a script that would display the last time a user logged into a particular machine. I know about the "last" command, but it gives too much info.... I just wanted to know the last time a user used his/her id. ANy help would be greatly appreciated. Ryan (3 Replies)
Discussion started by: ryaneverett5
3 Replies

2. Shell Programming and Scripting

shell script takes long time to complete

Hi all, I wrote this shell script to validate filed numbers for input file. But it take forever to complete validation on a file. The average speed is like 9mins/MB. Can anyone tell me how to improve the performance of a shell script? Thanks (12 Replies)
Discussion started by: ozzman
12 Replies

3. Shell Programming and Scripting

Script to display time difference..

Hi i've written a script which reads last two line of the log file from N number of servers and send the mail by redirecting to a particular log file. And the two lines is displayed below. Oracle Q03 Begin Hot BACKUP Time: 07/23/08 18:35:46 Oracle Q03 End Hot BACKUP Time: 07/24/08 14:18:15... (1 Reply)
Discussion started by: suri.tyson
1 Replies

4. Shell Programming and Scripting

script to display time

hey folks, i am stuc in this problem. You all might help me out. I want to write a BASH script to display time every 15 seconds using %r field descriptor. And want to clear the window each time before displaying time using clear command. Please help me out (3 Replies)
Discussion started by: manojrsb
3 Replies

5. Shell Programming and Scripting

<AIX>Problem in purge script, taking very very long time to complete 18.30hrs

Hi, I have here a script which is used to purge older files/directories based on defined purge period. The script consists of 45 find commands, where each command will need to traverse through more than a million directories. Therefore a single find command executes around 22-25 mins... (7 Replies)
Discussion started by: sravicha
7 Replies

6. UNIX for Advanced & Expert Users

Need to display complete format of ps

Hi All, For one of my script I need to get the complete format of PS as result. Actually in our application, we have to execute some program to get the data for batch files. Now there is some java script is running on unix for this which is not identifiable. I want to know how to... (2 Replies)
Discussion started by: nishank.jain
2 Replies

7. UNIX Desktop Questions & Answers

Shell script to display user logged in within given time

how can i know which users have logged in at specified given start and end time in 24 hour format? (3 Replies)
Discussion started by: meherzad4u
3 Replies

8. UNIX for Dummies Questions & Answers

Display problem when running a remote script

Hi, Quick question, someone will hopefully be able to stop me from :wall:. I currently have a script which calls a script on a remote machine and captures the stdout to a file: ssh <user>@<server> > output 2>/dev/null <<_EOF /path/script.ksh _EOF This runs the script but the... (4 Replies)
Discussion started by: chris01010
4 Replies

9. Shell Programming and Scripting

How to display information of the script while its running?

how to display the messages on screen IN PERL such as " 1. Entering while loop" if the script enters a while loop. 2. Checking FILENAME. etc... 3. Print statement is also not helpful.... (1 Reply)
Discussion started by: Rashid Khan
1 Replies

10. Shell Programming and Scripting

Display current directory for a running process for script

I'm trying to create a ksh script to do the following: 1) Ask the user what process they want to search for. 2) Have the script read the input as a variable and use it to search for the process. 3) Display the current time & date, the working directory of the process, and finally display the... (6 Replies)
Discussion started by: seekryts15
6 Replies
Test::NeedsDisplay(3pm) 				User Contributed Perl Documentation				   Test::NeedsDisplay(3pm)

NAME
Test::NeedsDisplay - Ensure that tests needing a display have one SYNOPSIS
In your Makefile.PL... use inc::Module::Install; # ... or whatever else you use # Check for a display use Test::NeedsDisplay; # ... your Makefile.PL content as normal And again in each test script that loads Wx #!/usr/bin/perl use strict; use Test::NeedsDisplay; # Test content as normal... DESCRIPTION
When testing GUI applications, sometimes applications or modules absolutely insist on a display, even just to load a module without actually showing any objects. Regardless, this makes GUI applications pretty much impossible to build and test on headless or automated systems. And it fails to the point of not even running the Makefile.PL script because a dependency needs a display so it can be loaded to find a version. In these situations, what is needed is a fake display. The "Test::NeedsDisplay" module will search around and try to find a way to load some sort of display that can be used for the testing. Strategies for Finding a Display At this time, only a single method is used (and a very simple one). Debian Linux has a script called "xvfb-run" which is a wrapper for the "xvfb", a virtual X server which uses the linux frame buffer. When loaded without a viable display, the module will re-exec the same script using something like (for example) "xvfb-run test.t". As such, it should be loaded as early as possible, before anything has a chance to change script parameters. These params will be resent through to the script again. METHODS
There are no methods. You simply use the module as early as possible, probably right after "use strict;" and make sure to load it with only default params. Specifically, need must always load it before you set the test plan, otherwise the test script will report two plans, and the harness will complain about it and die. # Use it like this ... use Test::NeedsDisplay; # ... not like this ... use Test::NeedsDisplay 'anything'; # ... and not like this. use Test::NeedsDisplay (); And that's all there is to do. The module will take care of the rest. TO DO
- Find alternative ways to launch a display on different platforms SUPPORT
Bugs should be reported via the CPAN bug tracker at <http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Test-NeedsDisplay> For other issues, contact the author. AUTHOR
Adam Kennedy <adamk@cpan.org> COPYRIGHT
Copyright 2005 - 2009 Adam Kennedy. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. The full text of the license can be found in the LICENSE file included with this module. perl v5.10.0 2009-01-04 Test::NeedsDisplay(3pm)
All times are GMT -4. The time now is 09:13 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy