Solved

Calculate server uptime

Posted on 2000-03-08
5
920 Views
Last Modified: 2008-01-09
Hi, On my site running on a windows NT server with IIS I want to display the server uptime in day's:hours:mins

Does anyone know how I can accomplish that ??

Thanks
0
Comment
Question by:boret
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 4

Accepted Solution

by:
CoolAss earned 200 total points
ID: 2598452
You need the WinNT option pack which includes a utility called uptime.exe. This returns the information you want.

You then need to place that utility (which is normally placed in the system32 directory to which the IIS account doesn't have access to) into a directory which the IIS account has been given permissions.

Now use a program like ASPExec or a custom COM object to call the application and then parse the results to display on the page. ASPExec is free, and can be downloaded here:

http://www.serverobjects.com/comp/Aspexec.zip 

Hope that helps. Please post comments if you need clarifacation before you decide to decline my answer if the case may be.

0
 
LVL 4

Expert Comment

by:CoolAss
ID: 2598457
By the way, ASPExec is a COM object itself, and needs to be registered with regsrv32.exe before you can use a Server.CreateObject to put it on an ASP.
0
 

Author Comment

by:boret
ID: 2604309
Hi, I have the optionpach but I can't find the utility uptime.exe, Can you tell me where I can find it. I downloade the ASPExec and I think (hope) that it wil work if I have uptime.exe
0
 
LVL 4

Expert Comment

by:CoolAss
ID: 2605995
It's not the option pack... it's the NT Resource Kit.

www.microsoft.com

I am farely sure it's free... if not, i can provide you with a link to download uptime.exe, after all, that's a free program.
0
 

Author Comment

by:boret
ID: 2611437
Hi CoolAss, UPTIME.EXE is neither in the option pack or in the Resource kit version that I have but I did found it on microsoft.com as you suggested and it works (Though not as good as in the good old Novell days :) )

Anyway, the combination with ASPExec works super so thank you for the advice.
0

Featured Post

SharePoint Admin?

Enable Your Employees To Focus On The Core With Intuitive Onscreen Guidance That is With You At The Moment of Need.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Hello, all! I just recently started using Microsoft's IIS 7.5 within Windows 7, as I just downloaded and installed the 90 day trial of Windows 7. (Got to love Microsoft for allowing 90 days) The main reason for downloading and testing Windows 7 is t…
I was asked about the differences between classic ASP and ASP.NET, so let me put them down here, for reference: Let's make the introductions... Classic ASP was launched by Microsoft in 1998 and dynamically generate web pages upon user interact…
In this video, viewers will be given step by step instructions on adjusting mouse, pointer and cursor visibility in Microsoft Windows 10. The video seeks to educate those who are struggling with the new Windows 10 Graphical User Interface. Change Cu…
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …

729 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question