Getting error when running sm_edit.exe
search cancel

Getting error when running sm_edit.exe

book

Article ID: 435908

calendar_today

Updated On:

Products

Network Observability VMware Smart Assurance

Issue/Introduction

When running the sm_edit utility to modify configuration files (such as clientConnect.conf or serverConnect.conf) on a modern Windows operating system, the utility fails to open the file and may display an error message similar to:

The system cannot find the path specified.

or

Cannot execute C:/Program Files (x86)/Windows NT/Accessories/WORDPAD.EXE

Environment

All supported Smarts versions 

Cause

By default, the sm_edit utility on Windows attempts to use WordPad as the text editor. It looks for the executable at a hardcoded legacy path: C:/Program Files (x86)/Windows NT/Accessories/WORDPAD.EXE.

In recent Windows updates (specifically starting with Windows 11), Microsoft has deprecated and removed WordPad from the operating system. Since the executable no longer exists at that path, sm_edit cannot launch the editor to display the configuration file.

Resolution

You can resolve this issue by explicitly configuring Smarts to use a different text editor, such as Notepad, which is still available on all Windows systems.

Temporary Workaround (Current Session)

To fix the issue for your current command prompt session:

  1. Open your Command Prompt.
  2. This command will make changes to your environment variables for this session. Review it carefully before running: set SM_EDITOR=notepad
  3. Run your sm_edit command again:

Permanent Solution

To apply this fix permanently across all sessions:

  1. Navigate to your Smarts installation directory.
  2. Locate theruncmd_env.batfile on Windows.
  3. This command will make changes to your system configuration. Review it carefully before saving: Add the following line to the file:

      SM_EDITOR=notepad