Skip navigation
All Places > Licensing and Installation > Blog

I'm a huge fan of command line utilities that provide fast, no-nonsense access to information and allow me to perform some basic configuration tasks. Evidently there are some people at Microsoft who are as well, because they created the Windows Management Instrumentation Command-line utility, or WMIC.


I could not begin to describe everything you can do with it, but allow me to throw out a few commands to give you some ideas.


This command gets you the status of all the printers on the machine:


     C:> wmic printer list status


If I want to know the status of the printers on a remote machine, I can provide a node name:


     C:> wmic /node:"some-other-machine" printer list status


This command collects the environment variables from several machines and display it in list format:


     C:> wmic /node:"machine1", "machine2" environment get /format:list


This command gets information about the monitors that are attached to these computers (I can add as many as I want in a comma separated list). It provides some useful data like manufacturer, HxW, resolution, etc. By using the format type htable, I can create a web page that contains this information. It's a pretty cool way of gathering information if, lets say, you were trying to find out who the candidates are for a monitor replacement. BTW, wmic can get information about any hardware components in the system and also can report on installed software, the BIOS, etc.


     C:> wmic /node:"machine1", "machine2", "machine3"  desktopmonitor get /format:htable > monitors.htm


And now, two of my personal favorites!


This one shows me if a certain executable is running on any of the computers in my list. The 'where name=' stuff filters out information about all the other processes. Without that option, it would show me all processes running on the system(s). In this example, I used it to find out if any of these machines were running iCDB Server Monitor. Those that were displayed their hostname (csname) and the executable path. Without those two parameters, it would show me much, much more information about the process (way more than needed).


C:>wmic /node:"orw-foster-w7", "orw-kfost-t5610", "kvmw7x64" process where name="iCDBServerMonitor.exe" get csname, executablepath

CSName         ExecutablePath

ORW-FOSTER-W7  C:\MentorGraphics\7.9.5EE\SDD_HOME\iCDB\win32\bin\iCDBServerMonitor.exe

KVMW7X64       C:\MGC\RSCM\EEVX.1\SDD_HOME\common\win32\bin\iCDBServerMonitor.exe


Here's an idea: Run a scheduled task that uses wmic to look for a particular process, dump that information in htable format, and copy that .htm to a web page. Now you can see who is running what at a glance.


I mentioned that you could also use it to perform some configuration tasks. In this example, I'm using it to change the value of the existing MGLS_LICENSE_FILE environment variable on a remote machine. As before, I could have a number of machines in my list separated by commas. Note that the output below the command line confirms that the operation was successful. I could easily create variables with wmic as well.


C:>wmic /node:kvmw7x64 environment where name="MGLS_LICENSE_FILE" set variablevalue="1717@wv-lic-01"

Updating property(s) of '\\KVMW7X64\ROOT\CIMV2:Win32_Environment.Name="MGLS_LICENSE_FILE",UserName="<SYSTEM>"'

Property(s) update successful.


Give wmic a try! It may take a while to get the hang of the syntax, but it's worth it if you need to do a lot of remote administration.


If you come up with some good ones, please share!



vNPI 9.5 can be configured to automatically check the licenses back in when a certain idle period has elapsed. This is done in the Engineering Toolkit window configuration settings.

Open vNPI 9.5 Engineering Toolkit window.
Go to the Options dropdown and select Configuration.
In the Configuration Parameters window select the line beginning with 'auto_logout_timeout' and click Modify under the Edit dropdown.
Enter the desired number of minutes (minimum of 20) in the Value field in the Edit Configuration Parameter window.
Click Apply and OK and exit the Configuration setup.
The vNPI licenses will automatically check back in if 20 minutes (for example) have passed and the tool has been idle.

The default time value is 0. If the automatic timeout is no longer desired, change the value to 0 following the setup steps above.

What do you do when Explorer crashes?  No matter what you do, it won't respond to mouse clicks, the windows white out and all you get is the spinning circle.  Other applications are still working, it is only Windows itself that has failed.  Restarting your computer is the simple answer, but what if you've got something critical running?  The answer is to restart Windows without restarting your PC.


1) Save what work you can and quit what you don't need in case this trick doesn't work.

2) Invoke Task Manager by either using CTRL-ALT-DEL or right-clicking on the task bar and choosing Task Manager from the menu.

3) From the Task Manager window, click on the Processes tab and find explorer.exe (NOT iexplore.exe) in the list of processes. Highlight it and click End Process.

4) After killing the explorer.exe process, click on the Applications tab and then click on the New Task... button.

5) In the Create New Task button, type in C:\Windows\explorer.exe. Click on the browse button to make sure you're pointing to the right file. Then click Open and then OK.


Windows Explorer should now reload and give you control of your computer back. If it doesn't work, that means you probably cannot get around restarting your computer.


Even if this does regain control of your PC, reboot as soon as it is convenient as there could be underlying problems.

If you are tracking and maintaining licenses for multiple license servers and/or users, remembering which server or user has which HostID can be a challenge. The Mentor License Utility (MLU) provides a facility to create an ‘Alias’ for any given HostID.


Once the HostID alias has been created, any licenses that are downloaded or separated for the HostID using MLU, will be copied into a separate “By_Alias” folder, and the name of the license file will be the alias name. In addition, any time the HostID is referenced in the license file, or in any ‘install license’ dialogs, the alias name will appear in parenthesis next to the HostID.


For some examples of where you will see the alias name for a HostID, and to learn how to create a HostID Alias, refer to pages 69-75 in the MLU Users Manual (attached).


To download a copy of the Mentor License Utility v3.0 from SupportNet, click here.

When you need to run shell commands on Windows as an Administrator, you typically must right-click the cmd.exe and choose "Run as administrator" in order to elevate the privileges in that shell. Well, it's very easy to create a shortcut for cmd that elevates automatically.


1. Create a shortcut to cmd.exe, perhaps on your Desktop. You might want to rename it Admin_cmd or something similar.

2. Right-click the shortcut and select Properties.

3. Select the Shortcut tab and then click Advanced...

4. Check the Run as administrator option and click OK


5. Click OK


Now you can simply double-click this shortcut whenever you need elevated privileges.

Hello Community! Welcome to the first Tip of the Week for 2015.


I've been doing a lot of work in a DOS command window lately and I've learned a few things that have helped me be more productive. I thought I'd share some of them you. I hope you find them useful.


To reduce the amount of typing you have to do, there are a couple of useful function keys that are pre-defined on your DOS command shell:


  1. F3 -  Paste the last command you executed on the command line. Same as the up arrow, but easier to find on a laptop keyboard.
  2. F7 -  Pops a window up that has a numbered list of recently executed commands. Scroll to find what you want then press enter to execute it.
  3. F9 -  If you remember the number for the command you want (from the list when you pressed F7), you can execute it by pressing F9 and then enter the number.


There are other function keys defined, but these are the ones I use the most.


I find it easy to forget sometimes exactly what file system I'm in when I'm on a mapped drive. One trick I like to use is to modify the prompt so that when I'm on a remote file system I see the UNC path name instead of the drive letter. For example, the Z:\projects\> prompt becomes \\filesvr\mgc\projects Z:\>. Note that when I'm on a local drive, the prompt appears as simply driveletter:\path.


One of the best features in Windows is the Windows Explorer because it lets you see files and directories in a context of what's above them, beside them, and beneath them. In a DOS command shell, the tree command gives you that functionality. It's great for smaller directory structures as-is, but for larger ones you'll want to use it with a pipe  ( | more) or redirect the output to a file ( > filename.txt) as the scrolling capability is limited.


Give those a try! If you have any DOS commands you find useful, reply to this post and share them. I'm always looking for more.



The Configurator has been discontinued in all VX releases, replaced by the 'Registrator' and 'Release Switcher' programs. Here are the main points to know about on the topic of switching between PCB VX releases (for example: EE VX.1 and PADS VX.0):

  • The 'Release Switcher' is available in the Start Menu at the following location:
    • Mentor Graphics PCB Admin Utilities > The MGC PCB Release Switcher
  • VX releases support "side-by-side" registration, which means you no longer need to switch between releases like you did with the Configurator, for pre-VX versions.
    • There are a couple of exceptions when running the 'Release Switcher' is required, in order to define which VX release is the "active" release:
      • Automation
      • File Associations (for ex: double-clicking a .pcb to open Xpedition and the design in one action)
  • When you first run the 'Release Switcher', it may not know about all of the releases on your system, especially if they are in different install targets. The 'Release Switcher' learns, and in turn populates the list, as you 'Browse' to different releases.
  • In the 'Release Switcher, when browsing for the 'Release', navigate to the product root folder that is under the installation target.
    • Example target locations for releases installed to the default and recommended 'C:\MentorGraphics' target:
      • C:\MentorGraphics\7.9.5EE
      • C:\MentorGraphics\EEVX.1.1
      • C:\MentorGraphics\PADSVX.1
  • Do not attempt to use the 'Configurator' to configure a VX release, or to switch releases.
  • Use the 'Release Switcher' to switch releases, even pre-VX releases (for example, EE 7.9.5 or PADS 9.5).
    • Also works for releases in completely different root target locations (with the Configurator you had to run "Configurator -clean" every time you switched).
  • The Release Switcher is essentially a 'wrapper' program. It sub-invokes the 'Registrator' for any VX releases, and the 'Configurator' for pre-VX releases.

There are significant changes in the X-ENTP VX.1 release media and some new options that affect which downloads you should get and how you should install them. We strongly encourage you to carefully read the release documentation available on the download page before you make any selections or begin installing the software. This is especially important if you are considering one of the 64-bit native media sets. The information provided in the release documentation can help you make an informed decision about whether the 32-bit or 64-bit media set is the right one for you.


We also have a TechNote that augments some of the information in the release documentation.

Most of you reading this already know that opening a DOS command shell and entering the command 'ipconfig /all' will return a lot of useful information, including the MAC address. If you use the MAC address as the hostid for mobile compute licenses you have done this many times I suspect. Nothing wrong with doing that, it works. But if you'd like a way of doing it that returns a lot less data you don't need, can be executed remotely, and could be used to obtain this information programmatically for your entire user base- read on.


Such a command exists, and it's been there the whole time: getmac


getmac has some useful options which you can read about by running the command 'getmac /?'. Here are the ones I find most useful:


This one returns the MAC address for each network device without any header information.

C:\> getmac /nh

00-26-B9-xx-xx-xx   \Device\Tcpip_{66A49F71-AB71-42BE-99D0-71027A377490}

00-50-56-C0-00-01   \Device\Tcpip_{9A9C7A14-6867-4877-8DFD-E1DA5378ADDF}

00-50-56-C0-00-08   \Device\Tcpip_{7CABA731-102F-4BB1-A4DA-D054804F6E31}


It is easy to identify my wired device in this case, because I know anything that has 00-50-56-C0 at the beginning is a VMware virtual adapter. But let's pretend I had a wireless adapter in my machine also, and I got 2 addresses that were not virtual adapters. How would I know which of them was the one I wanted?


I'd use the /v (verbose) option:


C:\> getmac /nh /v

Local Area Conn Broadcom NetXtr 00-26-B9-xx-xx-xx   \Device\Tcpip_{66A49F71-AB71-42BE-99D0-71027A377490}

VMware Network  VMware Virtual  00-50-56-C0-00-01   \Device\Tcpip_{9A9C7A14-6867-4877-8DFD-E1DA5378ADDF}

VMware Network  VMware Virtual  00-50-56-C0-00-08   \Device\Tcpip_{7CABA731-102F-4BB1-A4DA-D054804F6E31}


If I'd had another hardware NIC, I could tell by the description which was which.


So far, all the information has come from my local machine. If I want to know the MAC addresses on a different machine, I'll use the /s option:


C:\>getmac /s orw-kfost-t5610


Physical Address    Transport Name

=================== ==========================================================

34-17-EB-xx-xx-xx   \Device\Tcpip_{EC36C646-EB29-4E80-92AC-3D3F91293B22}

00-50-56-C0-00-01   \Device\Tcpip_{9D1AE766-04FB-4E67-BE2E-FD6A64BDF54A}

00-50-56-C0-00-08   \Device\Tcpip_{E3C15C4F-DE49-4E01-8EA1-928704365A9A}


Note that this time I omitted the /nh option so I could see the header.


With a little elbow grease, you could wrap a script around getmac to gather the MAC addresses for your entire site in one go, and then parse that data into a useful report you can use for license ordering or renewal.


Thanks for reading!




Microsoft will end support for Windows Server
2003/R2 next summer on July 14, 2015.
End of support for Windows Server 2003/R2 means
that no more updates or patches will ship from Microsoft.


will no longer develop or release any updates after ending support. If you are
staying the Server OS, upgrade to either Windows Server 2008 or 2012.

Be sure to
check the approved platforms for your Mentor application before making any
platform changes.

If you ever need to figure out what the command line is for a sub-invoked or child process, here are some tips:


1). Enable the "Command Line" column in Task Manager


This is a simple and effective way to grab the command line if, A) you know the process name you're looking for, and B) the process sticks around long enough for you to capture the command line info. Unfortunately, no Copy and Paste is available, and the parent->child hierarchy is not shown.



2). Process Explorer - A great freeware tool from Microsoft. It's Task Manager on steroids!


Process Explorer includes a command line field similar to Task Manager, but adds the process hierarchy so you can quickly identify a parent process and one or more of its children. Right-click (or double-click) on the desired process and select "Properties", and the command line information (can be copied!) is available from the "Image" tab.


One drawback with Process Explorer, is when a sub-invoked (child) process only runs for a short while. If you're not quick enough you won't be able to grab the process info! For these cases consider Process Monitor (#3 below).



3). Process Monitor - Another great freeware tool from Microsoft. It's Process Explorer plus a whole lot more!


Process Monitor is a utility that logs process, file system, registry, and network activity. It's not for the faint of heart, but can be extremely useful in troubleshooting very difficult application problems or crashes. When it comes to capturing the command line of a sub-invoked process, it's a champ! Not only can you capture the process hierarchy, but since it's a logging tool you can grab (and copy) the command line info even if the process runs for only a split-second.


Follow the screen-shots with directions below:



After clicking the "Show Process Tree" icon:


The lmstat command will report the quantity of a particular feature with the -f option. However, if you have multiple versions of a license feature, they're rolled up into a single count by default. For example:


Z:\>lmutil lmstat -c 1717@lic_server -f qhsimvl

lmutil - Copyright (c) 1989-2011 Flexera Software, Inc. All Rights Reserved.

Flexible License Manager status on Fri 10/31/2014 14:09


[Detecting lmgrd processes...]

License server status: 1717@lic_server

    License file(s) on lic_server: C:\MentorGraphics\License_Files\lmstat_test.txt:


lic_server: license server UP (MASTER) v11.11


Vendor daemon status (on lic_server):


     mgcld: UP v11.11

Feature usage info:


Users of qhsimvl:  (Total of 10 licenses issued;  Total of 0 licenses in use)



This might leave you with the impression that you have more features available for the version of the application you're running than you really do.


Note: Every Mentor Graphics application requires a minimum version of a license feature, usually tied to the build or release date of the application.


Fortunately, adding the -i option to your lmstat command will break down the overall count of a feature into separate counts for each version of that feature. For example:


Z:\>lmutil lmstat -c 1717@lic_server -f qhsimvl -i

lmutil - Copyright (c) 1989-2011 Flexera Software, Inc. All Rights Reserved.

Flexible License Manager status on Fri 10/31/2014 14:09


[Detecting lmgrd processes...]

License server status: 1717@lic_server

    License file(s) on lic_server: C:\MentorGraphics\License_Files\lmstat_test.txt:


lic_server: license server UP (MASTER) v11.11


Vendor daemon status (on lic_server):


     mgcld: UP v11.11

Feature usage info:


Users of qhsimvl:  (Total of 10 licenses issued;  Total of 0 licenses in use)



NOTE: lmstat -i does not give information from the server,

      but only reads the license file.  For this reason,

      lmstat -a is recommended instead.


Feature                 Version   # licenses    Expires         Vendor

_______                 _______   __________    _______         ______

qhsimvl                 2014.030              5         10-nov-2014     mgcld

qhsimvl                 2015.100              5         10-nov-2014     mgcld



In this example, I could run up to 10 simultaneous Verilog simulations using a version of Modelsim that requires a qhsimvl with a minimum version of 2014.030 or older (2013.110 for example). However, I could only run 5 simultaneous simulations using a version of Modelsim that requires 2014.040 or newer.


Keep the -i option in mind if you ever suspect you're not able to use the full count of a particular feature.

If you have automation for removing the local WDIR in your Windows environment, then you know the challenge is that %WDIR% can be made of up several paths, like this one:




In most circumstances all you really want to remove is the first folder in the path, the local WDIR. You could hard code the paths to it in your script, but then you'd have to depend on everyone using a standardized name or passing it as an argument.


Here is some nifty code you can but into your batch script that will parse the %WDIR% variable, get the first path name (the local WDIR path), and assign it to a variable:


:: These commands are required so that variable expansion works in your script environment

setlocal enableextensions enabledelayedexpansion


:: Echo WDIR, then using ; as a delimiter, get the first token and assign its value to MY_WDIR

for /f "usebackq tokens=1,2 delims=; " %%w in (`echo %WDIR%`) do set MY_WDIR=%%w


:: Now that we've isolated the local WDIR folder, we can remove the folder

rmdir /s /q %MY_WDIR%


There you have it. I hope this tip is useful.



Testing an Oracle Server Installation

Use SQL Plus to verify that the database connection with the Oracle Server is okay.


The Oracle version installed is 11gR2,



In Services, check that the Oracle listener is started.

In Services, check that the Oracle database service is started.

Open a command prompt and use the cd command to navigate to <oracle_home>\BIN:

For example: C:\app\myuser\product\11.2.0\dbhome_1\BIN

Enter this command:

sqlplus system/<password>@<instance>

<password> is the password entered for the SYSTEM user when Oracle was installed

<instance> is the database instance.



If the database can be accessed using the credentials you have entered, sqlplus
lists information about the Oracle version and about the database, and displays
the prompt SQL>.



C:\app\myuser\product\11.2.0\dbhome_1>cd bin

C:\app\myuser\product\11.2.0\dbhome_1\BIN>sqlplus system/mypassword@mydb


Successful output:

SQL*Plus: Release Production on Tue Dec 18 15:11:32 2012

Copyright (c) 1982, 2011, Oracle. All rights reserved.

Connected to:

Oracle Database 11g Enterprise Edition Release - 64bit Production

With the Partitioning, OLAP, Data Mining and Real Application Testing options


I recently received a license file for Questa Core, the installation of which had me wrapped around the axel for a few minutes.  Spoiler alert: it was the line endings.


I'm consulting at a painfully small startup, which explains why every computer here is a Windows machine. Having a long and storied history in ASIC design, when confronted with the Windows OS, I will do my design and development work using Cygwin ( For those of you not familiar with Cygwin, it is "a large collection of GNU and Open Source tools which provide functionality similar to a Linux distribution on Windows." I think Cygwin is great, but you can expect to encounter Windows (DOS, really)/Unix line-ending interoperability problems.


Why am I telling you this. Because my experience with Cygwin has implanted some sort of watch-dog process in my brain. When confronted with very weird results for what should be a minor and straightforward effort, the watch-dog gets triggered, and it sends this message to my brain: "Maybe it's a line-ending issue."


And it was. Our license server (FlexLM) is hosted on a Windows computer. But the license was in Unix format. And try as I might, I couldn't get the license server to start *or* produce a log file.


LSS (long story short), my internal watch-dog got triggered, I ran Cygwin's unix2dos utility on the license file, and Bob's your uncle (that's British for "that fixed everything". No, I don't know why it means that).


So, is the moral of this story "When in doubt, maybe it's the line-endings!"? Not so fast.


A subsequent search of supportnet, Flexera's website, and even Google yielded no mention of this license file issue . Am I one of only a handful of people to encounter this? I would think this issue would be much more common these days. Have any of you, esteemed readers, ever tripped over this issue. Please let me know.


But in the meantime, when in doubt, maybe it's the line-endings.