Академический Документы
Профессиональный Документы
Культура Документы
Quick-Start Guide
May 2000 DSA070841
Warranties and Liabilities The information and the software discussed in this document are subject to change without notice and should not be considered commitments by Intergraph Corporation. Intergraph Corporation assumes no responsibility for any errors in this document. The software discussed in this document is furnished under a license and may be used or copied only in accordance with the terms of the license. No responsibility is assumed by Intergraph for the use or reliability of software on equipment that is not supplied by Intergraph or its affiliated companies. All warranties given by Intergraph Corporation about equipment or software are set forth in your purchase contract, and nothing stated in, or implied by, this document or its contents shall be considered or deemed a modification or amendment of such warranties. Trademarks Intergraph and the Intergraph logo are registered trademarks of Intergraph Corporation. Microsoft is a registered trademark of Microsoft Corporation. Windows NT and the Windows NT logo are trademarks of Microsoft Corporation. Other brands and product names are trademarks of their respective owners. Copyright 1998-2000 Intergraph Corporation, including this documentation, and any software and its file formats and audiovisual displays described herein; all rights reserved; may only be used pursuant to the applicable software license agreement; contains confidential and proprietary information of Intergraph and/or other third parties which is protected by copyright, trade secret and trademark law and may not be provided or otherwise made available without prior written authorization. Restricted Rights Legend Use, duplication, or disclosure by the United States Government is subject to restrictions as set forth in subdivision (c)(1)(ii) of the rights in technical data and computer software clause at DFARS 252.227-7013. Unpublished -- rights reserved under the copyright laws of the United States. Intergraph Corporation Huntsville AL 35894-0001
iii
Contents
Contents ............................................................................................................................................................... iii Preface................................................................................................................................................................... 1 About This Document ................................................................................................................................... 1 Finding Additional Batch Services Information ............................................................................................ 1 Finding Operating System Information ......................................................................................................... 2 Getting Documentation and Training ............................................................................................................ 2 Getting Telephone Support............................................................................................................................ 2 Finding Intergraph on the Internet ................................................................................................................. 2 1. Batch Services Overview ................................................................................................................................ 2 1.1 Batch Services Defined ........................................................................................................................... 2 1.2 Batch Services Features........................................................................................................................... 2 1.3 Batch Services Components .................................................................................................................... 3 1.4 Getting Started......................................................................................................................................... 4 2. Installing and Configuring Batch Services ................................................................................................... 6 2.1 Before Installing Batch Services ............................................................................................................. 6 2.2 Installing Batch Services ......................................................................................................................... 6 2.3 Starting and Stopping Batch Services...................................................................................................... 8 2.4 Configuring Batch Services Desktop Access........................................................................................... 8 2.5 Removing Batch Services........................................................................................................................ 9 3. Using Batch Manager ................................................................................................................................... 10 3.1 Understanding the Batch Manager Interface ......................................................................................... 10 3.2 Granting Batch Service Privileges......................................................................................................... 11 3.3 Understanding Account Mapping.......................................................................................................... 12 4. Creating and Managing Queues .................................................................................................................. 14 4.1 Creating and Deleting Queues ............................................................................................................... 14 4.2 Changing Queue Properties ................................................................................................................... 16 4.3 Setting the Default Queue...................................................................................................................... 17 4.4 Adding Shells to a Batch Queue ............................................................................................................ 17 4.5 Adding Destinations to a Pipe Queue .................................................................................................... 18 4.6 Enabling and Disabling a Queue ........................................................................................................... 18 4.7 Starting and Stopping a Queue .............................................................................................................. 19 4.8 Displaying Queue Status........................................................................................................................ 20 5. Submitting a Batch Job ................................................................................................................................ 22 5.1 Creating a Script .................................................................................................................................... 22 5.2 Submitting a Job .................................................................................................................................... 23 5.3 Saving and Restoring Named Batch Jobs .............................................................................................. 26 Glossary .............................................................................................................................................................. 28 Index.................................................................................................................................................................... 30
Preface
The Intergraph Batch Services for Windows NT Quick-Start Guide describes how to install, configure, and use Intergraph Batch Services on a computer running the Microsoft Windows NT operating system.
This document assumes that you understand basic networking concepts, and that you have a working familiarity with the Transmission Control Protocol/Internet Protocol (TCP/IP), Internet addressing, and Windows NT services.
To find information on training for Intergraph systems and products, or to enroll for an available class, contact Intergraph Education Services at 1-800-766-7701. Detailed information on Intergraph documentation and training is also available on Intergraph Online, Intergraphs World Wide Web Server. See Finding Intergraph on the Internet for more information.
Have the following information readily available when you call: The products serial number. For software, you can find this on the license agreement. Your name and telephone number. The products name. A brief description of the problem.
3 Batch Services can continue processing tasks even after a system interruption. Batch Services manages the tasks so that you do not have to restart them yourself, providing the following features: Batch Services resubmits jobs when the network is down, or the remote host is unavailable. Batch Services automatically restarts jobs if the system crashes while a job is running, or if the system is down when a job is scheduled to run.
With Batch Services, you control the processing of tasks submitted as batch jobs. The following features allow you to manage task processing: You can use Batch Manager, a graphical user interface (GUI) for managing batch jobs. You can manage batch and pipe queues on remote nodes from one location. You can determine which jobs run at a given time, and in what order. You do not have to monitor jobs. Batch Services supports SMTP mail or event log notification when a batch job completes successfully or encounters errors.
Batch Services provides the following additional features: An application programming interface (API). Support for multiprocessor systems. A command-line interface that can be used with scripts. Job submission to or from Windows NT systems. Job submission to or from systems running Intergraphs Network Queuing System (NQS) when UNIX interoperability is required.
NOTE
Batch Services software can work with any network adapter supported by Windows NT. Such adapters include Ethernet and Token Ring boards although other types of adapters may also be compatible. The network adapter you use must be properly installed and configured for your computer before you install Batch Services software. Refer to your Windows NT documentation for a list of compatible network adapters, and to the documentation for your network adapter for installation and configuration instructions.
7 3. 4. Insert the Batch Services CD-ROM into the CD-ROM drive. To start Setup, do one of the following: 5. 6. From the Start menu, select Run; then key the following into the Open box, where drive is the drive letter for the CD-ROM drive: drive:\setup In Windows NT Explorer, select the CD-ROM drive; then double-click on SETUP.EXE.
Follow the instructions displayed as Setup installs the Batch Services software. During installation, take note of the following: When prompted for user information, type your name and the products serial number (available from the software license agreement). Company name is optional. Setup verifies the serial number before installation continues. If the serial number is incorrect, the product will not install. Keep a record of the products serial number in case you need to re-install the product later.
CAUTION
When prompted for a path to the destination directory for product files, type a new path, or leave the default path as displayed. If the destination directory contains a version of the product you are installing, warning messages display. You may install the new version of the product over the currently installed version, or install the new version in another directory. During Setup, Batch Services displays the Account Mapping dialog, allowing you to configure account mapping. If you select Yes to configure account mapping, Setup displays the User Name dialog. Otherwise, Setup warns you that you must configure account mapping before you can submit jobs, and you may use the Batch Manager graphical interface (BATCHMGR.EXE) to configure account mapping after Setup is complete.
NOTE
NOTE
7. 8. 9.
Select whether or not you want to configure account mapping at this time. If you select Yes, proceed to the next step; otherwise, skip to step 11. Type in the username you want to configure (the default username is Guest). Type the password for the username into the Password and Confirm Password fields.
10. Select Continue, or select Cancel to set up account mapping after installation is complete. 11. Select whether you want jobs to have access to the desktop. If you allow jobs to have access to the desktop, an iconified and non-active window will appear on the screen when a job is runs. These windows will only appear when a user is logged on to the system. If your site is one where batch jobs might require some user input, you should select Yes. If your site is one where security is a major concern, you should select No; a logged-on user will be able to interact with running batch jobs, even if the job is running as a different user. NOTE You can change whether you want jobs to have access to the desktop later. See 2.4, Configuring Batch Services Desktop Access, for details. Jobs that try to access the desktop will not run unless the user running the job is a member of the Administrators group.
12. After Setup completes, reboot your system to restart Windows NT and start Batch Services.
NOTE
If you configure Batch Services to be started manually, you must start the batch server each time you restart your system, or each time you want to run Batch Services. Take the following steps to start Batch Services manually: 1. 2. 3. Open Control Panel; then open Services. In Services, select Intergraph Batch Server from the Service list; then select Start. After the batch server starts, close Services; then close Control Panel.
Take the following steps to stop Batch Services: 1. 2. 3. 4. Open Control Panel; then open Services. In Services, select Intergraph Batch Server from the Service list; then select Stop. When prompted, confirm that you want to stop Batch Services. After the batch server stops, close Services; then close Control Panel.
9 4. 5. You must stop and restart Batch Services to make the changes take effect. Select Stop; answer Yes; then select Start. Close Services; then close Control Panel.
10
Figure 3-1. Batch Manager The Batch Manager toolbar, located below the Batch Manager menus, provides shortcuts to the following tasks. Position the cursor over a toolbar button to display a tip describing the command associated with that button. Buttons are provided for the following tasks: Submitting and deleting jobs Holding and releasing jobs Creating and deleting queues Enabling and disabling queues Starting and stopping queues
11 The server view displays information about the server and its queues. Information on each queue in the server view includes its name and type, its priority, its inflow and outflow state, and the number of jobs currently in the queue. When the server view is active, you can create, delete, and manage queues. Doubleclicking on a queue listed in a server view displays the queue view of that queue. The queue view displays information about the jobs contained in a specific queue. Information on each job in a queue includes its ID and status, its priority, its name, and the username of the jobs submitter. When the queue view is active, you can manipulate specific jobs in that queue. Double-clicking on a job listed in a queue view displays the properties of that job.
You can have multiple server and queue views active in the main window, and can tile or cascade the views to fit them into the main window. In Figure 3-1, a server view is shown in the main window. The status bar, at the bottom of the main window, displays information about the active view. For an active server view, the status bar displays the server name. For an active queue view, the status bar displays the queues name and type, its description, and its inflow and outflow states.
12 4. Select Add; then key into the Add Names box the username of a user, or the group name of a group, to which you want to grant privileges. Specify local users and groups (on your system) by username or group name only. Use one of the following formats when keying in a username or group name: Users on Windows NT systems Groups on Windows NT systems domain_name\username or system_name\username domain_name\group_name or system_name\group_name
Separate multiple users or groups with a semicolon (;). 5. 6. 7. 8. Select the type of privilege you want to grant the user or group (manager or operator). Select OK. Repeat steps 4 through 6 for each user or group to which you want to grant privileges. When you have finished assigning privileges to users or groups, select OK.
To remove privileges from a user or group, take the following steps: 1. 2. 3. 4. 5. 6. 7. Open Batch Manager. Click Server > Properties. Select the Security tab. The Security page displays, shown in Figure 3-2. The current users and groups with Batch Service privileges are displayed in the Managers and Operators list. In the Managers and Operators list, select the user or group from which you want to remove privileges. Select Remove. Repeat steps 4 and 5 for each user or group from which you wish to remove privileges. When you have finished removing privileges from users and groups, select OK.
To change a users or groups privileges, first remove the current privileges from the user or group; then add the user or group to the privilege list with the new privilege.
13 2. 3. 4. If the server cannot find an exact match, the server then searches the account mapping entries using the job owners domain or machine name, with * (meaning any user) as the username. If no match is found, the server then searches the account mapping entries using * (meaning any machine or domain) as the domain name, with the job owners username. Finally, if a match still has not been found, the server searches with * as the domain name and * as the username.
How you configure account mapping depends on the security needs and configuration of your site. Refer to the Batch Services Help (BATCHMGR.HLP) for complete instructions on configuring account mapping.
14
Refer to 4.4, Adding Shells to a Batch Queue, for more information on batch queues.
15
Refer to 4.5, Adding Destinations to a Pipe Queue, for more information about pipe queues.
When prompted, Select Yes to confirm that you want to delete the queue.
16
Job Defaults
Scheduling Priority
31
Security
Queue Access
Unrestricted
None
17
You must have manager privileges on the batch server to set the default queue.
To add a shell to a batch queue, take the following steps: 1. 2. 3. 4. 5. 6. Open Batch Manager. Click on the batch queue listed in the server view, or select the queue view for that queue. Select Properties from the Queue menu. The Queue Properties dialog displays. Select the Shells tab. Under Shell Configuration, key the name of the shell into the Name box; then key the path to the shell into the Location box. Select Add. The name and location of the shell display in the Shell box. If you wish to set a default shell for the queue, proceed to the next step. Otherwise, skip to step 8. You may want to specify the default shell for a batch queue on your system. The default shell is the one run when a user submits a job, but does not explicitly request a shell. When you set a default shell for a batch queue, you must explicitly select another shell if you want to submit a job to run a script that uses another shell. If you wish to submit executable programs (.EXE files) to a batch queue, do not set a default shell for that queue, or set the default shell to be CMD.EXE.
NOTE
7.
Select the shell in the Shell List box; then select Default. The name of the shell displays in the Default Shell box.
18 8. Select OK.
You must have manager privileges on the batch server to set the default shell for a batch queue.
A destination can be a local queue (on your system) or a remote queue (on other systems). Specify a local queue by its queue name. To specify a remote queue, use one of the following formats when keying in the remote queue name: Queues on Windows NT systems \\system_name\queue_name Queues on Intergraph NQS systems queue_name@system_name NOTE 6. 7. If you list more than one destination for a pipe queue, the pipe queue will send a job to the first available queue in its destination list that will accept the job.
Repeat step 5 for each destination you want to add to the pipe queue. When you have finished adding destinations to the pipe queue, select OK.
You must have manager privileges on the batch server to add a destination to a pipe queue.
19 The availability of the Enable and Disable menu and toolbar commands toggles, depending on the current inflow state of the queue. To disable a queue, take the following steps: 1. 2. 3. Open Batch Manager. Click on the queue listed in the server view, or select the queue view for that queue. Select Disable from the Queue menu, or select Disable Queue now show as DISABLED in its listing in the server view. from the toolbar. The queue should
The availability of the Enable and Disable menu and toolbar commands toggles, depending on the current inflow state of the queue. You must have at least operator privileges on the batch server to enable or disable a queue.
The availability of the Start and Stop menu and toolbar commands toggles, depending on the current outflow state of the queue. To stop a queue, take the following steps: 1. 2. 3. Open Batch Manager. Click on the queue listed in the server view, or select the queue view for that queue. Select Stop from the Queue menu, or select Stop Queue show as STOPPED in its listing in the server view. from the toolbar. The queue should now
The availability of the Start and Stop menu and toolbar commands toggles, depending on the current outflow state of the queue. You must have at least operator privileges on the batch server to start or stop a queue.
20
Use one of the following formats when keying in the server name: Windows NT system Remote Intergraph NQS system NOTE \\system_name @system_name
You can also use Connect To in the Queue menu to display a queue view for a particular queue on a remote system.
21
22
The following example is a .BAT script that prints all PostScript files in the C:\TEMP directory on the batch server to a printer on a remote Windows NT system. To use the script, ensure that a local batch queue has been created, enabled, and started; that the queues default shell is the CMD.EXE program; and that your system has access to the printer on the remote Windows NT system.
REM This script will do the following: REM REM 1. Associate a remote printer on a Windows NT system REM (\\machine\printer) with a local printer port. REM 2. Copy files in c:\temp that end in .ps to the local printer REM port. REM 3. Remove the printer association. REM net use lpt1: \\machine\printer cd c:\temp for %%I in (*.ps) do copy %%I lpt1: net use /delete lpt1:
23
Batch Manager provides tabbed pages in the Job Submit dialog for the following job parameter categories: General Scheduling Notification Output Resources File Staging Advanced Sets basic information about the job. Sets the parameters associated with scheduling the job for execution. Sets the notification preferences for the job. Specifies how output should be handled for the job. Configures job resources needed for the batch job. Describes how necessary files for the job are handled. Sets advanced job parameters as well as those that are only used by Intergraph NQS.
The following sections describe basic operational parameters found in the Job Submit dialog, along with brief instructions for using them when submitting a job.
24
Shell
Displays the currently selected shell for the job. If this value is not specified, the default shell for this queue will be used.
25 6. 7. 8. 9. Select a weekly frequency of every 1 week. Select the Monday and Thursday checkboxes, making sure that no other checkboxes are selected. Set the effective date to September 1, 2001. Set the start time to 19:00 (7:00 PM). The Next Occurrence field will note that the first occurrence of the backup job will be run on Tuesday, September 1, 2001 at 7:00 PM.
Job Abort is selected by default. Mail Address By default, notification messages are written to the Event Log of the submitting machine. This field lists mail addresses in the form \\host (the event log on system host) or user@host (an SMTP mail address). Mail will be sent to each recipient. Key in a mail address, and select Add to add the address to the List box. You can specify more than one recipient by keying in addresses separately, and selecting Add after each address.
Specifies whether or not the output should be kept on the machine where the job runs. Specifies whether or not output is to be created directly in the specified pathname. Normally, the output file is kept internally by Batch Services until the batch job ends; the files are then returned to the intended directories. Spooling is not supported on remote machines. Disables the Standard Error group box, indicating that all output should be sent to the Standard Output Pathname. If the Join Output is unselected, the Standard Error group box becomes available again.
26
Adds all environment variables in the current environment to the name list.
NOTE
27
5.
28
Glossary
account mapping The process of determining the account name to use when running jobs. Batch Services requires an account name and password to use when running jobs. To perform account mapping, the server tries to match the job owner with an account mapping entry. A set of instructions to Batch Services to perform a given task or set of tasks on a computer system. A batch job is identified with a script that is run by a shell. The job may also be an executable (.EXE). See also job, shell. A queue that accepts requests to execute scripts or commands from the keyboard as if the user submitting the request were logged in to the system. See also queue. A Windows NT service that processes batch jobs, and maintains queue and job information. Also, the system on which Batch Services runs. The queue to which a job is assigned when a user does not specify a queue. The shell that is used to run a job submitted to a queue when a user does not specify a shell for that job. A queue state in which the queue will not accept new jobs. A queue state in which the queue will accept new jobs. The machine where a batch job is run. A delay in running a job submitted to a queue. A held job will not run until the hold is released. A user hold may be placed on a job submitted by that user when the job is submitted. An operator hold may be placed on a job by a user with operator or manager privileges, after the job is submitted but before it runs. See also privilege. The state of a queue with regard to accepting jobs. See also queue state, enable, disable. A set of instructions needed to perform a given task or set of tasks on a computer system. See also batch job, shell. A unique alphanumeric string that identifies a job. A batch job ID is in the form jobid.orighost, where jobid is a sequentially assigned number up to 5 digits in length, and orighost is the name of the system from which the batch job originated. See privilege. A network-based, multipurpose printing, plotting, and command-execution system that runs on Intergraph and other UNIX-based systems.
batch job
batch queue
batch server default queue default shell disabled enabled execution host hold
29
See privilege. The state of a queue with regard to processing jobs. See also queue state, start, stop. A queue that routes jobs to another queue. A pipe queue receives a job and routes it to the first available queue on its destination list that will accept the job. Pipe queues can accept jobs from batch queues or from other pipe queues. An operational permission level assigned to every Batch Services user. Nonprivileged users can submit jobs to queues to which they have been granted access; operators can issue commands that directly affect queue management; and managers can control all aspects of Batch Service operation. A waiting line in which jobs reside until they are processed. See also batch queue, pipe queue. The operational state of a queue. A queue has an inflow state that is either enabled or disabled; it also has an outflow state that is either started, stopped, or stopping. See also enabled, disabled, started, stopped. The view in Batch Manager that shows information on the jobs in a queue. A file that contains instructions for the execution of a batch job. The view in Batch Manager that shows information about the operation of one or more queues. An executable program that can be used to run a script. For example, CMD.EXE is a shell that can be used to run .BAT scripts. See also script. The process of storing a file internally by Batch Services until the batch job ends. A queue state in which the queue will run jobs submitted to it. A queue state in which the queue will not run jobs submitted to it.
privilege
30
Index
A
access to desktop, 7 account mapping, 7, 12, 28 adding destinations, 18 adding shells, 17 adding shells, 17 default shell, 17 disabling, 18 enabling, 18 modifying, 16 starting, 19 status, 20 stopping, 19 removing privileges, 12 server view, 29 setting default queue, 17 starting queues, 19 status bar, 11 stopping queues, 19 submitting named batch job, 27 using, 10 views, 10 batch queue, 28 batch server, 28 Batch Services account mapping, 7, 12 batch job, 22 basic information, 23 job output, 25 notification, 25 resources, 26 scheduling, 24 submitting, 23 Batch Manager, 10 compatibility with network adapters, 6 components, 3 configuring desktop access, 8 destination directory for product files, 7 getting started using, 4 installation requirements, 6 installing, 6 named batch job, 26 creating, 26 submitting, 27 privileges, 11, 12 queue default, 17 queues, 14 adding destinations, 18 adding shells, 17 creating, 14 batch, 14 pipe, 15 default shell, 17 deleting, 15 disabling, 18 enabling, 18
B
batch job, 28 basic information, 23 creating named, 26 job output, 25 named, 26, 27 notification, 25 resources, 26 scheduling, 24 script, 22 submitting, 23 batch job, 22 Batch Manager, 10 account mapping, 12 adding destinations, 18 adding shells, 17 batch job, 22 basic information, 23 job output, 25 notification, 25 resources, 26 scheduling, 24 submitting, 23 creating queues, 14 batch, 14 pipe, 15 default shell, 17 deleting queues, 15 disabling queues, 18 enabling queues, 18 granting privileges, 11 named batch job, 26 creating, 26 overview, 10 queue default, 17 queue status, 20 queue view, 29 queues, 14 adding destinations, 18
31
modifying, 16 starting, 19 status, 20 stopping, 19 removing, 9 setting default queue, 17 starting, 7, 8 stopping, 8 using Batch Manager, 10 Batch Services Help, 1
N
named batch job, 26 creating, 26 submitting, 27 network adapters and Batch Services, 6
O
online documentation, 1 outflow state, 29 started, 29 stopped, 29
C
creating a named batch job, 26 creating script, 22
D
default queue, 28 default shell, 17, 28 desktop access, 7, 8 disabling queues, 18 DNS, 6
P
pipe queue, 29 privilege, 29 privileges granting, 11 removing, 12 product directory for Batch Services, 7
E
enabling queues, 18 execution host, 28
Q
queue, 29 inflow state, 28 outflow state, 29 queue state, 29 queue status, 20 queue view, 29 queues, 14 adding destinations, 18 adding shells, 17 creating, 14 batch, 14 pipe, 15 default shell, 17 deleting, 15 disabling, 18, 20 enabling, 18 modifying, 16 properties, 16 setting default, 17 starting, 19 stopping, 19
G
Getting started using Batch Services, 4
I
inflow state, 28 disabled, 28 enabled, 28 installation requirements, 6 installing Batch Services, 6 Intergraph finding on the Internet, 2 Intergraph NQS, 6, 28 Internet finding Intergraph, 2
J
job, 28 job hold, 28 job ID, 28
R
removing Batch Services, 9
32
S
script, 29 server view, 29 shell, 29 spooling, 29 starting Batch Services, 7, 8 starting queues, 19 status bar, 11 stopping Batch Services, 8 stopping queues, 19 submitting a batch job, 23 submitting a named batch job, 27
T
TCP/IP, 6 telephone support, 2 training, 2
V
views, 10
33