Skip to main content

Admin Tool

The Admin Tool (Admin.exe) is the maintenance console that ships with an on-premise LutraCAD server. It installs and repairs the database and server services, manages the firewall rules and the weekly backup task, creates server client tokens, and can disable user login or the remote server connection.

It is a Windows command-line tool: a text menu, not a graphical application. It is meant for the person who administers the server, not for clinic staff.

warning

Every action needs administrator rights. The tool manages Windows services, the firewall and scheduled tasks. Start it with right-click Admin.exe, then Run as administrator and accept the User Account Control (UAC) prompt. Starting it from an already elevated command prompt works too.

Starting the tool

  1. In the server's install folder, right-click Admin.exe and choose Run as administrator.
  2. The main menu appears.
  3. Navigate by typing the number of an option and pressing Enter.
  4. After most actions the tool prints a result and waits for a key press before returning to the menu.
  5. Choose 0 to go back or exit.

The tool can also run a single command without the menu. See Create a token from the command line.

How do I…?

TaskWhere
Install the server for the first time1) Server, then 1) Install / Autofix. Installs the database first, then the server service, and starts it. Each step should end in OK.
Fix a server that will not start1) Server, then 1) Install / Autofix to repair and start it, or 2) Restart to stop and start the running service.
Fix the database2) Database, then 2) Autofix. Creates the database if missing, installs and starts the database service, and confirms the connection.
Test the database connection2) Database, then 1) Test connection. Prints OK or ERROR.
Create a client token1) Server, then 3) Create server client token. Enter the database name (empty for the default). Copy the printed token and give it to the client.
Turn the weekly backup on or off1) Server, 4) Backup task scheduler, then 1) Enable / Disable.
Change the backup time1) Server, 4) Backup task scheduler, then 2) Change run at hour. Enter the hour (0 to 23).
Fix the firewall3) Firewall: Autofix. Checks the firewall rules for the server and manager programs and grants them if missing.
Empty the database2) Database, then 3) Truncate. Deletes all data and cannot be undone; you must type yes to confirm.
Disable user login4) User management: Disable user login.
Switch off the remote server connection5) Server: Remove remote connection. Sets the connection to local.
Choose an option:
1) Server
2) Database
3) Firewall: Autofix
4) User management: Disable user login
5) Server: Remove remote connection
0) Exit
OptionWhat it does
1) ServerOpens the Server menu: install, restart, client token, backup schedule.
2) DatabaseOpens the Database menu: test, autofix, truncate.
3) Firewall: AutofixChecks and grants the firewall rules for the LutraCAD programs.
4) User management: Disable user loginTurns off the user-login requirement.
5) Server: Remove remote connectionSwitches the machine off a remote server connection.
0) ExitCloses the tool.

Server menu

Choose an option for Server:
1) Install / Autofix
2) Restart
3) Create server client token
4) Backup task scheduler
0) Back to main menu
OptionWhat it does
1) Install / AutofixFull install or repair. Installs the database first, then checks the server service: installs it from Server.exe if missing, checks the service points at the right file, and starts it. Each step prints OK, NOK or an error. Use this for a first install and to repair a broken server.
2) RestartStops the running server service and starts it again. If the service is not installed it reports NOT INSTALLED; if it is not running it just starts it.
3) Create server client tokenAsks for the database name (empty is the default), creates a token and prints it. Give this token to the client that needs to connect.
4) Backup task schedulerOpens the Backup schedule menu.
0) Back to main menuReturns to the main menu.

Backup schedule menu

Choose an option for backup schedule:
1) Enable / Disable
2) Change run at hour
0) Back to server menu

Both options first ask for the service name (leave empty to use the default server service name). If no service by that name exists, the tool reports "Service is not running" and returns.

OptionWhat it does
1) Enable / DisableToggles the weekly backup task. If the task already exists it switches between enabled and disabled. If it does not exist yet, a weekly task is created that runs the backup every Sunday. The default run time is 04:00.
2) Change run at hourShows the current hour and asks for a new hour (0 to 23). The weekly backup then runs at that hour. Enter a whole number; anything else is rejected.
0) Back to server menuReturns to the Server menu.
note

The scheduled task is named after the product plus the service name, so each server service has its own backup task.

Database menu

Choose an option for Database:
1) Test connection
2) Autofix
3) Truncate
0) Back to main menu
OptionWhat it does
1) Test connectionOpens a database connection and prints OK or ERROR. A quick health check.
2) AutofixInstalls and repairs the database. If no database is found it creates or upgrades it, installs the database service if missing, starts it if stopped, then confirms the connection. This also runs automatically as the first step of the Server Install / Autofix.
3) TruncateDrops every table in the database.
0) Back to main menuReturns to the main menu.
danger

Truncate deletes all data. It is irreversible: there is no undo and no backup is taken. You must type yes to proceed; anything else cancels. Only use this to wipe a machine you are sure about.

Firewall: Autofix

Main menu, 3) Firewall: Autofix. It checks that the Windows Firewall allows the LutraCAD programs and grants the rule if it is missing. It validates the manager (ManagerStandalone.exe) and the server (Server.exe):

  • If the program file is not found it is skipped with a note.
  • If it already has a firewall rule it prints OK.
  • If not, the rule is added and it prints GRANTED.

If the firewall itself is not installed, it reports so and does nothing. Run this when clients cannot reach the server over the network.

User management: Disable user login

Main menu, 4) User management: Disable user login. This turns off the user-login requirement in the database settings and saves. Use it when you need the server to run without enforcing per-user login. It prints "User login removed" when done.

Server: Remove remote connection

Main menu, 5) Server: Remove remote connection. This edits the local settings and sets the server connection to off (local). Use it to switch a machine that was pointed at a remote server back to a local setup.

  • If the settings file or the connection setting is not found, the tool reports it.
  • On success it prints "Configuration updated".

Create a token from the command line

For scripting and automated installs, the tool can create a token without the menu:

Admin.exe create-token <dbname>
  • <dbname> is the database to create the token in.
  • On success it prints only the token to standard output, so a calling script can capture it cleanly.
  • On failure it prints a JSON error, for example {"error":"Cannot save token."}, and exits with a non-zero code.

This is the scriptable equivalent of Server menu, 3) Create server client token. Like the menu, it needs administrator rights.

What each action changes

ActionWhat it touches
Server, Install / AutofixDatabase service and server service (Windows services), starts them
Server, RestartServer service state
Server, Backup task schedulerA weekly Windows scheduled task that runs the backup
Database, AutofixDatabase files and schema, and the database service
Database, TruncateDrops all tables in the database (irreversible)
Firewall: AutofixWindows Firewall rules for the manager and server programs
Disable user loginThe user-login setting in the database
Remove remote connectionThe local settings (sets the server connection off)
create-tokenAdds a server token record to the database