|
请使用QQ关联注册PLM之家,学习更多关于内容,更多精彩原创视频供你学习!
您需要 登录 才可以下载或查看,没有账号?注册
x
117. 如何查看我的 NX 许可证服务器上的许可证使用情况? : ^' x i+ ]% z, ]
问题/症状 2 t5 P* i4 d2 m v7 l
如何查看 NX 许可证服务器上的许可证使用情况?我目前的 NX 版本是 NX9 及以上版本.
" P* ]1 _' }1 S4 q" E解决方法 1 b7 N2 `/ P1 X
您把下面的文字做成一个批处理文件, 然后双击运行就能看到您的 NX 许可证服务器上的/ s( u) o$ C* E0 a @' B# g
NX 许可证的使用情况.
% Z ^: j- c! m# ^这个程序也可以在客户端运行,运行的时候, 我们假设您的下面 2 个环境变量已经在您的
8 b" I+ X" }- d" A2 B+ P系统环境变量中设定好:
6 \. Y ?4 c+ N1 N: EUGII_BASE_DIR / U1 ~" B8 Z, P- [
SPLM_LICENSE_SERVER
* u, f; ?0 v5 K@echo off 2 |, {0 J& e6 m0 [2 E
rem ========================================================================= ' m# f1 I( x* `6 m8 p# P9 _
rem 1 c$ Y3 j0 z B4 l Y1 c
rem Copyright (c) 1996-2015 Siemens PLM Software.
+ g' m& ^4 T8 K% o! \' Vrem Unpublished - All rights reserved 4 @. M. x2 J. ^1 ^1 C, j& N
rem /sar GTAC 9 N! V+ `- c- D3 ]1 G
rem =========================================================================
9 I7 V6 ]' f4 r Nrem
8 g- D5 C6 m5 R W' orem File Name: LICENSECHECKV9.BAT
! O' Q1 x! u: U, u* arem
5 Q8 Y& E! M- ~: {" s6 L0 {$ U0 `rem ========================================================================= 9 ]; S$ u0 c( K; `5 w& T3 q3 V( d
rem + G+ }% w, T& k, B0 n+ ?+ _
rem This script will check what NX licenses are in use. 4 [* e: _0 ~: t& m% ~
rem
) c+ d5 f! z: J$ i- S% W2 yrem NOTE: ; E: _4 R1 o/ L/ q7 o6 X
rem
2 G0 u2 P! R1 P7 K) Orem This script assumes that UGII_BASE_DIR and SPLM_LICENSE_SERVER 2 S3 c6 j5 f( z2 V' T) C
rem are properly defined 5 ]4 d8 _+ }' ~
rem
1 J# W. H N% A0 o5 r" D; ]- p$ n/ ~7 z7 O. m& y% r' V/ l
REM To avoid double double quotes later, remove any quotes that
' q" \7 d; K& P9 ?! r. LREM are part of the environment variable now 7 |4 `, Q6 u/ U( F E8 Z# N
# r. E; E7 @! \7 h4 X, }9 N. J
set UGII_BASE_DIR=%UGII_BASE_DIR:"=% _0 o% O% ? W2 u# }
set SPLM_LICENSE_SERVER=%SPLM_LICENSE_SERVER:"=% ( _6 l! L, Z# K0 C" f- N
REM - q6 A5 D+ I7 V7 f) D1 S/ J# P& Q
REM Check if UGII_BASE_DIR is defined. 4 v7 _+ C" z3 ~$ n4 w- A& D4 m
REM ) S; p# R0 y- u; ~+ Q1 |( S+ x( X
4 d5 K, K, w9 X8 p" }
if not defined UGII_BASE_DIR (
/ y' t# I& N5 U! } echo NX path could not be established. UGII_BASE_DIR not set.
, H" g$ O4 y1 h goto ERROR_EXIT
" ~( L9 I) ]2 {7 W& ^6 z) ELSE (
7 }7 I {4 s8 i/ x( V6 ^* z echo NX path established. UGII_BASE_DIR=%UGII_BASE_DIR%
- C' \; v* u; I$ C: Y! Z echo Checking for IN-USE NX Licenses... ) q9 u: s. C s1 t! @4 M
echo. - h$ u6 ^6 m% e/ `) U
echo.
( D/ U W& y" y6 ?# M: Y
2 J1 x( u& e% R; W. v( \REM
/ h6 W6 F+ n+ U1 i6 I" M- YREM Check if UGII_BASE_DIR really points to a valid directory.
X+ h m( Z0 r" K- U' a) p6 \REM
" r6 O+ G$ y' q1 _3 @! l- v/ U7 Z7 j/ I' b
if EXIST "%UGII_BASE_DIR%\ugii" (
8 h6 q% v/ Q3 _0 b5 w# _ set UGII_ROOT_DIR=%UGII_BASE_DIR%\ugii
* y a( J( p v- S) ?4 @! ^ ) ELSE ( : P; I* e4 \1 i8 p( R
echo UGII_BASE_DIR set to invalid NX install.
4 D6 n% {& W3 {* \ goto ERROR_EXIT / Y' t4 K2 J! C& n( e! S
)
2 G# t8 [9 j) H+ \* u3 W)
- G4 L/ _# W# x7 m n# q$ j" y6 W5 y- P/ R1 F+ h
REM 8 F# R* `3 L4 y6 _8 @( \) o- U
REM Check for NX license server
. [ E, N: y' p6 v2 N1 ?1 m2 rREM ! J' ^7 j# P- d o1 D9 v
9 R# M O% B: y$ iif not defined SPLM_LICENSE_SERVER (
}; Z" k! \( M echo ERROR: SPLM_LICENSE_SERVER is not defined. 1 t1 x. Z: l) N- B7 z
echo Current Setting: %SPLM_LICENSE_SERVER% # I) w/ i- h7 B3 L; C& _) E% [! T
echo Check: SPLM_LICENSE_SERVER=28000@<server>.
6 q0 W: C0 b8 H& B f6 L- x6 D goto ERROR_EXIT 1 I1 p% j- y1 k# B4 G. R. l
) 9 x6 f' c# \/ X" u/ H# G% P* G* }
m0 W; j v" k. ^
"%UGII_BASE_DIR%\ugflexlm\lmutil" lmstat -c %SPLM_LICENSE_SERVER% -A
! O e* y) h. {9 s: v- P* z B0 o$ `3 n; @9 C9 C. w. ^
pause % R4 j$ S, {" C' `% `
goto end
+ X; W- \7 a7 X6 b$ S7 }:ERROR_EXIT
) d# V, q9 q: r" Becho. & I, Z; n8 E% V0 S. K' s& U
echo ERROR: Unable to check licenses.
6 l$ P' c8 i0 t! \' H7 K- hecho. 0 A( A* W9 K, o$ s: T2 b5 k( D; ?& {
pause 6 i0 a+ m! I. C' |7 p
:end
1 [6 M6 m. @4 e0 n& } ~: v1 b0 E( P
. ]. y" V* U2 G( f6 g |
|