|
请使用QQ关联注册PLM之家,学习更多关于内容,更多精彩原创视频供你学习!
您需要 登录 才可以下载或查看,没有账号?注册
x
117. 如何查看我的 NX 许可证服务器上的许可证使用情况?
) x, ]; q/ V+ J- X( ^问题/症状 ( l+ a: S7 D' \) d
如何查看 NX 许可证服务器上的许可证使用情况?我目前的 NX 版本是 NX9 及以上版本.
6 b; R1 c( |% m8 t' Q9 W解决方法
6 U8 C. H+ u* O. K; L% g您把下面的文字做成一个批处理文件, 然后双击运行就能看到您的 NX 许可证服务器上的* ~) N- v* t" S7 f$ x3 H
NX 许可证的使用情况. 3 N, h9 U) i5 L& Z- f$ V
这个程序也可以在客户端运行,运行的时候, 我们假设您的下面 2 个环境变量已经在您的
' D% Z" w0 v/ n系统环境变量中设定好: $ t% h5 E* S5 |9 n8 c
UGII_BASE_DIR
$ k d5 s p( RSPLM_LICENSE_SERVER * q2 ~! U6 ]4 R) m3 v8 h" E# I* @
@echo off
3 Q# c6 y) v+ U& C0 I, Q5 I* ~rem =========================================================================
5 @3 m4 ^, O5 T0 d+ P8 ~$ k$ @rem
* ^1 }2 [& E7 Z% O, u6 Vrem Copyright (c) 1996-2015 Siemens PLM Software.
, S" i+ e. P {& D5 V+ Rrem Unpublished - All rights reserved 0 g: p* p$ v" {5 G* U
rem /sar GTAC
% @3 g* R8 \+ M, ?8 arem =========================================================================
u: y8 {! N( {4 Q( p( krem : |0 J& L: V% r' m
rem File Name: LICENSECHECKV9.BAT 9 {$ K- R2 y x1 l; D( ]$ P8 H7 w! L
rem
4 F, D" X, d4 C$ v; @# z8 q6 krem =========================================================================
$ |, l( d1 }# H1 y5 m# zrem
6 M# r+ e, B" e4 q2 J2 O \rem This script will check what NX licenses are in use. * \& {, G n1 x7 P& B, D0 Q
rem ! J; E p7 w7 u+ i7 O0 t. \- ~% ]
rem NOTE:
3 P0 O7 i1 l4 n/ n r3 yrem & c8 Q4 A/ ~- [9 X
rem This script assumes that UGII_BASE_DIR and SPLM_LICENSE_SERVER 8 [! e, _9 s) [& l) j. Z& R4 U
rem are properly defined ! R1 I( ~8 p# O! N: ^+ v) L
rem
, h' A" N O) P* f* j- Q
# }2 Y# e/ _. g+ O3 sREM To avoid double double quotes later, remove any quotes that
0 C o4 ?" \- NREM are part of the environment variable now
( I3 _, T' I- N8 s8 x9 @
) V7 f( P9 Q) p; vset UGII_BASE_DIR=%UGII_BASE_DIR:"=%
$ ]3 U5 O( Z9 b1 |# [' W5 Lset SPLM_LICENSE_SERVER=%SPLM_LICENSE_SERVER:"=%
( {2 X2 T8 q; K2 w2 [6 w; L0 |& VREM + b+ t2 m4 O6 j3 ^7 H
REM Check if UGII_BASE_DIR is defined.
- U: o2 I0 C6 }, ~7 y" bREM $ k) S; \: N+ B" {
5 z1 A: u, \; V' F0 @! p; f& c
if not defined UGII_BASE_DIR ( ; d6 h, s5 X: I0 k0 c& W% b& C
echo NX path could not be established. UGII_BASE_DIR not set.
% V+ S1 d% R8 P2 P goto ERROR_EXIT # y9 {% c; G( I6 s/ l
) ELSE ( # K. F% o2 S) E3 i# N
echo NX path established. UGII_BASE_DIR=%UGII_BASE_DIR% i7 Q9 n. ?/ w' Y% @
echo Checking for IN-USE NX Licenses... " @2 B; u. |; f: S. |9 Z
echo. : ]" A( e! {; \/ e
echo.
! E8 S2 r- B. r9 X% J2 z
2 b h q; z, o1 G( V% jREM
" J& o7 S: s1 h) }; X4 pREM Check if UGII_BASE_DIR really points to a valid directory. 4 H z8 F/ i: x7 n+ O& n
REM 0 l* z$ g p! x
& j1 F2 w* B' w1 W4 k
if EXIST "%UGII_BASE_DIR%\ugii" ( * q/ n& r- r" s2 D
set UGII_ROOT_DIR=%UGII_BASE_DIR%\ugii
4 k! j7 _ n" T( Y ) ELSE ( 7 n7 b. q0 [* J) i6 ?9 _
echo UGII_BASE_DIR set to invalid NX install.
% Y0 v- y$ O% V4 O goto ERROR_EXIT 9 i: n! n) V' j4 Q" i
) $ C* C+ v: S6 P+ o% ~
) ( q) `9 N6 v$ e
$ \) M1 \5 r/ f
REM
* A$ c! {: R8 g9 ~' c/ E* d. QREM Check for NX license server 2 F; C. P5 E7 G0 s% x1 G8 A, F
REM 4 i) V' n4 \. h0 V
% o- y9 j" X f/ r1 v+ \if not defined SPLM_LICENSE_SERVER ( : x2 _% n& F; D4 T
echo ERROR: SPLM_LICENSE_SERVER is not defined. ) C2 o7 Y) q! U9 l m4 @1 A
echo Current Setting: %SPLM_LICENSE_SERVER% * _* y' i: G: @ x' o9 K t2 H7 s
echo Check: SPLM_LICENSE_SERVER=28000@<server>.
- N8 ~" ]0 |2 | goto ERROR_EXIT $ r; v! `+ s! w9 G7 ~! z
)
1 S* {. H' k$ T! s1 Q' Z3 }' T' e2 ^9 r' f( j) B* z, @% i: ?7 u$ X
"%UGII_BASE_DIR%\ugflexlm\lmutil" lmstat -c %SPLM_LICENSE_SERVER% -A
# Z& N/ w% `, x- w* b
* a m% Q# ~/ q# M. Wpause 6 } v R3 N$ u4 q+ H
goto end
" y! K( a6 B. k2 T" P:ERROR_EXIT
0 @6 ~; o( _4 r3 w3 Necho.
9 l5 ?; p M5 Z( Q7 H% `2 f8 ~7 E gecho ERROR: Unable to check licenses.
- O6 I. O+ ~/ u+ lecho. - R8 M1 j2 E3 ^4 L/ n( [
pause ) ? G, N; D& E( a( }
:end # g6 {2 g4 ~( Q$ D3 p+ P
+ A' Q1 \; t0 J5 U* g+ z |
|