Solved

Scripting customized information into a report

Posted on 2012-03-21
3
240 Views
Last Modified: 2012-03-22
Experts,

I am looking to create a script in which I can pull the following information from a server and save it to a text file on the machine.

Information needed:
1. Machine Name:
2. Number of CPU's
3. Version of Oracle running on each machine.

Now the Oracle Version can be gotten by running Sqlplus -v from a command prompt.

I am at a loss on the others.

In order to get full points please provide a fully functional script that can pull items 1 - 3 and save them in a text file on the workstation.
0
Comment
Question by:itguy565
[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
  • 2
3 Comments
 
LVL 54

Accepted Solution

by:
Bill Prew earned 500 total points
ID: 37750523
Here's a simple BAT script that will do the job.
@echo off
set LogFile=c:\temp\info.txt
echo %COMPUTERNAME%>"%LogFile%"
systeminfo 2>NUL|find /i "Processor(s):">>"%LogFile%"
sqlplus -v>>"%LogFile%"

Open in new window

~bp
0
 
LVL 11

Author Closing Comment

by:itguy565
ID: 37751141
Exactly what I was looking for..
0
 
LVL 54

Expert Comment

by:Bill Prew
ID: 37751915
Great, glad that helped, thanks for the feedback.

~bp
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

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

Suggested Solutions

With User Account Control (UAC) enabled in Windows 7, one needs to open an elevated Command Prompt in order to run scripts under administrative privileges. Although the elevated Command Prompt accomplishes the task, the question How to run as script…
In threads here at EE, each comment has a unique Identifier (ID). It is easy to get the full path for an ID via the right-click context menu. However, we often want to post a short link within a thread rather than the full link. This article shows a…
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

710 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