HP OpenVMS System Services Reference Manual


Previous Contents Index

The structure definition for the physical memory descriptor resides in PMMDEF.H.

Because the size of the physical memory map returned by $GETSYI can vary from system to system, HP recommends using the following steps when using this item code:

  1. Call $GETSYI first using the SYI$_PMD_COUNT to obtain the number of physical memory descriptors.
  2. Dynamically create a buffer to which $GETSYI can copy the physical memory map. The size of the buffer can be computed with the following formula:


    map_buffer_size = (PMM64$C_LENGTH * ret-val) + 4 
    

    where:

SYI$_PHYSICALPAGES

Returns the total number of PFNs that exist between the first PFN (typically PFN 0) and the highest numbered PFN.

Because this number is a longword, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_PMD_COUNT

Returns the total number of physical memory descriptors defined by the system. The return value of this parameter can be used to determine the buffer size to use when specifying the SYI$_PFN_MEMORY_MAP item code.

Because this number is a longword, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_POTENTIAL_CPU_BITMAP

The return argument is a bitmap with a bit indicating a member of the instance's potential set. A CPU in the potential set implies that it could actively join the OpenVMS active set for this instance if it is ever owned by it. To meet this rule the CPU's characteristics must match hardware and software compatibility rules defined particularly for that instance.

The size of the returned bitmap is determined by the number of supported CPUs on the system. You can compute the number of bytes needed for the bitmap as follows: Use the $GETSYI system service with an item code of SYI$_MAX_CPUS to find the minimum number of bits needed, round this number up to a multiple of 64, and divide the result by 8.

SYI$_POTENTIAL_CPU_MASK

Note that this item code is becoming obsolete; HP recommends that you not use it because it represents only up to 64 CPUs. The service continues to return the correct data for systems with up to 64 CPUs but fails for systems with more than 64 CPUs. For greater flexibility, use item code SYI$_POTENTIAL_CPU_BITMAP instead.

On Alpha and Integrity server systems, returns a value that represents a CPU-indexed bit vector. When a particular bit position is set, the processor with that CPU ID value is a member of the instance's potential set. A CPU in the potential set implies that it could actively join the OpenVMS active set for this instance if it is ever owned by it. To meet this rule, the CPU's characteristics must match hardware and software compatibility rules defined particularly for that instance.

SYI$_POTENTIALCPU_CNT

On Alpha and Integrity server systems, returns the count of CPUs in the hard partition that are members of the potential set for this instance. A CPU in the potential set implies that it could actively join the OpenVMS active set for this instance if it is ever owned by it. To meet this rule the CPU's characteristics must match hardware and software compatibility rules defined particularly for that instance.

SYI$_POWERED_CPU_BITMAP

The return argument is a bitmap with a bit indicating a member of the instance's powered set---those CPUs physically existing within the hard partition and powered up for operation.

The size of the returned bitmap is determined by the number of supported CPUs on the system. You can compute the number of bytes needed for the bitmap as follows: Use the $GETSYI system service with an item code of SYI$_MAX_CPUS to find the minimum number of bits needed, round this number up to a multiple of 64, and divide the result by 8.

SYI$_POWERED_CPU_MASK

Note that this item code is becoming obsolete; HP recommends that you not use it because it represents only up to 64 CPUs. The service continues to return the correct data for systems with up to 64 CPUs but fails for systems with more than 64 CPUs. For greater flexibility, use item code SYI$_POWERED_CPU_BITMAP instead.

On Alpha and Integrity server systems, returns a value that represents a CPU-indexed bitvector. When a particular bit position is set, the processor with that CPU ID value is a member of the instance's powered set---those CPUs physically existing within the hard partition and powered up for operation.

SYI$_POWEREDCPU_CNT

On Alpha and Integrity server systems, returns the count of CPUs in the hard partition that are physically powered up.

SYI$_PRESENT_CPU_BITMAP

The return argument is a bitmap with a bit indicating a member of the instance's present set -- those CPUs physically existing within the hard partition. Being in the present set does not imply that it is part of the powered set.

The size of the returned bitmap is determined by the number of supported CPUs on the system. You can compute the number of bytes needed for the bitmap as follows: Use the $GETSYI system service with an item code of SYI$_MAX_CPUS to find the minimum number of bits needed, round this number up to a multiple of 64, and divide the result by 8.

SYI$_PRESENT_CPU_MASK

Note that this item code is becoming obsolete, and HP recommends that you not use it because it represents only up to 64 CPUs. The service continues to return the correct data for systems with up to 64 CPUs but fails for systems with more than 64 CPUs. For greater flexibility, use item code SYI$_PRESENT_CPU_BITMAP instead.

On Alpha and Integrity server systems, returns a value that represents a CPU-indexed bitvector. When a particular bit position is set, the processor with that CPU ID value is a member of the instance's present set -- those CPUs physically existing within the hard partition. Being in the present set does not imply that it is part of the powered set.

SYI$_PRESENTCPU_CNT

On Alpha and Integrity server systems, returns the count of CPUs in the hard partition that physically reside in a hardware slot.

SYI$_PRIMARY_CPUID

On Alpha and Integrity server systems, returns the CPU ID of the primary processor for this OpenVMS instance.

SYI$_PROCESS_SPACE_LIMIT

On Alpha and Integrity server systems, this item code returns the 64-bit virtual address succeeding the last available process private address. The value returned is the upper bound on the process private address space. The value returned is the same for every process on the system.

Because this number is a quadword, the buffer length field in the item descriptor should specify 8 (bytes).

SYI$_PSXFIFO_PRIO_MAX

On Alpha and Integrity server systems, returns the maximum priority for the POSIX FIFO scheduling policy.

Because this number is a longword, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_PSXFIFO_PRIO_MIN

On Alpha and Integrity server systems, returns the minimum priority for the POSIX FIFO scheduling policy.

Because this number is a longword, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_PSXRR_PRIO_MAX

On Alpha and Integrity server systems, returns the maximum priority for the POSIX round-robin scheduling policy.

Because this number is a longword, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_PSXRR_PRIO_MIN

On Alpha and Integrity server systems, returns the minimum priority for the POSIX round-robin scheduling policy.

Because this number is a longword, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_PT_BASE

On Alpha and Integrity server systems, returns the 64-bit virtual address of the base of the page tables. The value returned is the same for every process on the system.

Because this number is a quadword, the buffer length field in the item descriptor should specify 8 (bytes).

SYI$_PTES_PER_PAGE

On Alpha and Integrity server systems, returns the maximum number of CPU-specific pages that can be mapped by one page table page.

Because this number is a longword, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_RAD_CPUS

On Alpha and Integrity server systems, returns a longword array of RAD/CPU pairs that can potentially be in this operating system instance. If there is no RAD support, all potential CPUs are in RAD 0. The array is terminated with a -1,-1 pair.

RAD is supported on AlphaServer GS series systems and starting from OpenVMS Version 8.4, support is extended to NUMA capable Integrity servers.

SYI$_RAD_MEMSIZE

On Alpha and Integrity server systems, returns a longword array of RAD/page count pairs. The number of pages of private memory is returned. If there is no RAD support, all memory is reported in RAD 0. The array is terminated with a -1,-1 pair.

RAD is supported on AlphaServer GS series systems and starting from OpenVMS Version 8.4, support is extended to NUMA capable Integrity servers.

SYI$_RAD_MAX_RAD

On Alpha and Integrity server systems, returns the maximum number of RADs possible on this platform. If there is no RAD support, 1 is returned.

RAD is supported on AlphaServer GS series systems and starting from OpenVMS Version 8.4, support is extended to NUMA capable Integrity servers.

SYI$_RAD_SHMEMSIZE

On Alpha and Integrity server systems, returns a longword array of RAD/page count pairs. The number of pages of shared memory is returned. If th ere is no RAD support, all shared memory is reported in RAD 0. If the current instance is not a member of a Galaxy, no shared memory is reported. The array is terminated with a -1,-1 pair.

RAD is supported on AlphaServer GS series systems and starting from OpenVMS Version 8.4, support is extended to NUMA capable Integrity servers.

SYI$_REAL_CPUTYPE

Returns the actual CPU type of the primary CPU of the system.

See the SYI$_CPUTYPE item code for a list of symbols and processors.

SYI$_SCSNODE

Returns the Galaxy instance name. Supported only on AlphaServer systems that support partitioning.

SYI$_SCS_EXISTS

Returns a longword value that is interpreted as Boolean. If the value is 1, the System Communication Subsystem (SCS) is currently loaded on the node; if the value is 0, the SCS is not currently loaded.

SYI$_SERIAL_NUMBER

Returns the system serial number from out of the Hardware Restart Parameter Block (HWRPB).

SYI$_SHARED_VA_PTES

On Alpha and Integrity server systems, returns the 64-bit virtual address of the PTE that marks the boundary between process-private PTEs and system-shared PTEs. The value returned is the same for every process on the system.

Because this number is a quadword, the buffer length field in the item descriptor should specify 8 (bytes).

SYI$_SID

Returns the contents of the system identification register of the node.

On Alpha and Integrity server systems, SYI$_SID returns a value in which all fields are 0 except the CPU-type field, which always contains the value 256.

Because the value of this register is a longword hexadecimal number, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_SWAPFILE_FREE

Returns the number of free pages in the currently installed swapping files.

Because this number is a longword, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_SWAPFILE_PAGE

Returns the number of pages in the currently installed swapping files.

Because this number is a longword, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_SYSTEM_RIGHTS

Returns the system rights list as an array of quadword identifiers. Each entry consists of a longword identifier value and the following longword identifier attributes:
Bit Position Meaning When Set
KGB$V_DYNAMIC Allows holders of the identifier to remove it from or add it to the process rights list using the DCL command SET RIGHTS_LIST.
KGB$V_NOACCESS Makes any access rights of the identifier null and void. This attribute is intended as a modifier for a resource identifier or the Subsystem attribute.
KGB$V_RESOURCE Allows holders of an identifier to charge disk space to the identifier. It is used only for file objects.
KGB$V_SUBSYSTEM Allows holders of the identifier to create and maintain protected subsystems by assigning the Subsystem ACE to the application images in the subsystem.

Allocate a buffer that is sufficient to hold the system rights list, because $GETSYI returns only as much of the list as will fit in the buffer.

SYI$_SYSTEM_UUID

On Integrity server systems, returns the Universal Unique Identifier (UUID) for the system. If the UUID is not supported or is not available, a null UUID (all zeroes) is returned.

Because SYI$_SYSTEM_UUID is 128 bits long, the buffer length field in the item descriptor must specify 16 bytes.

SYI$_SYSTYPE

On Alpha and Integrity server systems, returns the name of the family or system hardware platform. For example, the integer 2 represents a DEC 4000 processor, the integer 3 represents a DEC 7000 or DEC 10000 processor, and the integer 4 represents a DEC 3000 processor.

SYI$_VERSION

Returns, as a character string, the software version number of the OpenVMS operating system running on the node.

Because the version number is 8-byte blank-filled, the buffer length field in the item descriptor should specify 8 (bytes).

SYI$_VECTOR_EMULATOR

Returns a byte, the low-order bit of which, when set, indicates the presence of the Vector Instruction Emulator facility (VVIEF) in the system.

SYI$_VP_MASK

Returns a longword mask, the bits of which, when set, indicate which processors in the system have vector coprocessors.

SYI$_VP_NUMBER

Returns an unsigned longword containing the number of vector processors in the system.

SYI$_XCPU

Returns the extended CPU processor type of the node.

You should obtain the general processor type value first by using the SYI$_CPU item code. For some of the general processor types, extended processor type information is provided by the item code, SYI$_XCPU. For other general processor types, the value returned by the SYI$_XCPU item code is currently undefined.

Because the processor type is a longword decimal number, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_XSID

Returns processor-specific information. For the MicroVAX II system, this information is the contents of the system type register of the node. The system type register contains the full extended information used in determining the extended system type codes. For other processors, the data returned by SYI$_XSID is currently undefined.

Because the value of this register is a longword hexadecimal number, the buffer length field in the item descriptor should specify 4 (bytes).

SYI$_xxxx

Returns the current value of the system parameter named xxxx for the node.

The buffer must specify a longword into which $GETSYI writes the value of the specified system parameter. For a list and description of all system parameters, see the HP OpenVMS System Management Utilities Reference Manual.


Description

The Get Systemwide Information service returns information about the local system or about other systems in an OpenVMS Cluster configuration.

Required Access or Privileges

None

Required Quota

This service uses the process's AST limit quota (ASTLM).

Related Services

$ALLOC, $ASSIGN, $BRKTHRU, $BRKTHRUW, $CANCEL, $CREMBX, $DALLOC, $DASSGN, $DELMBX, $DEVICE_SCAN, $DISMOU, $GETDVI, $GETDVIW, $GETMSG, $GETQUI, $GETQUIW, $INIT_VOL, $MOUNT, $PUTMSG, $QIO, $QIOW, $SNDERR, $SNDJBC, $SNDJBCW, $SNDOPR


Condition Values Returned

SS$_NORMAL The service completed successfully.
SS$_ACCVIO The caller cannot read the item list, cannot write to the buffer specified by the buffer address field in an item descriptor, or cannot write to the return length address field in an item descriptor.
SS$_BADPARAM The item list contains an invalid item code.
SS$_EXASTLM The process has exceeded its AST limit quota.
SS$_NOMORENODE You requested a wildcard operation, and $GETSYI has returned information about all available nodes.
SS$_NOSUCHNODE The specified node does not exist or is not currently a member of the OpenVMS Cluster system.
SS$_UNREACHABLE Remote node is not currently reachable.

Condition Values Returned in the I/O Status Block

1
Same as those returned in R0.

Example


/*  Defining __NEW_STARLET enables the program to benefit from better type 
    checking for prototypes and structures provided by OpenVMS.             */ 
 
#define     __NEW_STARLET       1 
 
#include    <efndef>            /*  No Event Flag Event Flag  */ 
#include    <iledef>            /*  Item List Entry Definitions  */ 
#include    <iosbdef>           /*  I/O Status Block Structure Definition  */ 
#include    <starlet>           /*  Function Prototypes for System Services  */ 
#include    <stdio>             /*  C Standard I/O Functions  */ 
#include    <string>            /*  memset Prototype  */ 
#include    <syidef>            /*  $GETSYI Item Code Definitions  */ 
 
#define     NUM_ILE              3 
#define     BUFFER_SIZE         20 
 
 
/*  Macro to initialize a 32-bit item_list_3.                               */ 
 
#define init_ile32(ile, length, code, bufaddr, retlen_addr) \
{   (ile)->ile3$w_length = (length);           \
    (ile)->ile3$w_code = (code);         \
    (ile)->ile3$ps_bufaddr = (bufaddr); \
    (ile)->ile3$ps_retlen_addr = (retlen_addr); } 
 
 
/*  Simple status checking macro.                                           */ 
 
#define bad_status(status) (((status) & 1) != 1) 
 
main () 
{ 
char 
    node_name [BUFFER_SIZE], 
    version_string [BUFFER_SIZE]; 
 
int 
    status; 
 
unsigned short 
    node_name_length, 
    version_string_length; 
 
ILE3 
    syi_ile [NUM_ILE]; 
 
IOSB 
    iosb; 
 
 
/*  Zeroing the item list has the effect of creating the terminating entry. */ 
 
    memset (syi_ile, 0, ILE3$K_LENGTH*NUM_ILE); 
 
 
/*  Initialize the item list entries to fetch the operating system version 
    and the node name.                                                      */ 
 
    init_ile32 ( 
        &syi_ile [0], 
        BUFFER_SIZE, 
        SYI$_VERSION, 
        version_string, 
        &version_string_length); 
 
    init_ile32 ( 
        &syi_ile [1], 
        BUFFER_SIZE, 
        SYI$_NODENAME, 
        node_name, 
        &node_name_length); 
 
    status = sys$getsyiw ( 
        EFN$C_ENF, 
        NULL, 
        NULL, 
        &syi_ile, 
        &iosb, 
        NULL, 
        0); 
 
    if (bad_status (status)) return status; 
    if (bad_status (iosb.iosb$w_status)) return iosb.iosb$w_status; 
 
 
/*  Zero terminate the strings before displaying them.                      */ 
 
    version_string [version_string_length] = '\0'; 
    node_name [node_name_length] = '\0'; 
 
    printf ("Version:  %s    Node Name:  %s\n", 
        version_string, 
        node_name); 
} 
 
      

This example C program demonstrates how to use $GETSYIW to obtain the operating system version number string and the node name.


$GETSYIW

Returns information about the local system or about other systems in a cluster.

The $GETSYIW service completes synchronously; that is, it returns to the caller with the requested information. For asynchronous completion, use the Get Systemwide Information ($GETSYI) service; $GETSYI returns to the caller after queuing the information request, without waiting for the information to be returned. In all other respects, these services are identical; For information about the $GETSYIW service, see the documentation about $GETSYI.

For additional information about system service completion, see the Synchronize ($SYNCH) service.

On Alpha and Integrity server systems, this service accepts 64-bit addresses.


Format

SYS$GETSYIW [efn] ,[csidadr] ,[nodename] ,itmlst [,iosb] [,astadr] [,astprm]


C Prototype

int sys$getsyiw (unsigned int efn, unsigned int *csidadr, void *nodename, void *itmlst, struct _iosb *iosb, void (*astadr)(__unknown_params), int astprm);

You must specify either the csidadr or the nodename argument, but not both. For wildcard operations, however, you must use the csidadr argument.

$GETTIM

Returns the current system time in a 64-bit format.

On Alpha and Integrity server systems, this service accepts 64-bit addresses.


Format

SYS$GETTIM timadr,[flags]


C Prototype

int sys$gettim (struct _generic_64 *timadr,...);


Arguments

timadr


OpenVMS usage: date_time
type: quadword (unsigned)
access: write only
mechanism: by 32- or 64-bit reference

The 32- or 64-bit address of a quadword to receive the current time in 64-bit format.

flags


OpenVMS usage: mask_longword
type: longword (unsigned)
access: read only
mechanism: by value (Alpha and Integrity servers)

An optional argument that modifies the form of the returned time value. If this argument is not specified, it is same as specifying an argument of 0.

Description

The Get Time service returns time data in different formats depending on the flags parameter. If the flags parameter is not specified, or is specified as 0, the service returns the current system time in 64-bit format. The quadword is the number of 100-nanosecond intervals since November 17, 1858.

If the flags parameter is set to 1, the service returns a 64-bit time value as the number of 100-nanosecond intervals since an arbitrary point in the past such as system boot time. This base time does not change unless the system is rebooted. Since the returned value does not represent a time of day, it will not change if the system time is changed (for example, by $SETIME or an automatic timezone change). It increments at the same rate as the system time. Other flag values are reserved for future use.

On Alpha and Integrity server systems, the exact frequency at which system time is updated varies, depending on the characteristics of the server; however the update frequency is approximately 1 millisecond.

Required Access or Privileges

None

Required Quota

None

Related Services

$ASCTIM, $BINTIM, $CANTIM, $CANWAK, $GETTIM_PREC, $NUMTIM, $SCHDWK, $SETIME, $SETIMR

For more information about the system time, see the HP OpenVMS System Manager's Manual.


Condition Values Returned

SS$_NORMAL The service completed successfully.
SS$_ACCVIO The quadword to receive the time cannot be written by the caller.
SS$_BADPARAM The flags parameter contains a reserved value.


Previous Next Contents Index