OHMS user manual
Chapter 18 · For: Administrator

Administration, security and backups

This chapter is for the administrator: looking after user accounts, security settings, the audit trail and backups. First-time setup of settings, departments, roles and users is in First-time setup: where to start.

1. Looking after user accounts

Open Administration Users and click a user. Their page shows staff details, roles, last sign-in, recent sign-ins and the devices they are signed in on. Under Account actions:

EditChange details or roles. Untick Account active when someone leaves: they can no longer sign in, and their records stay.
Reset passwordSet a new temporary password when a user has forgotten theirs. They must change it at the next sign-in. (Users with an email can also use Forgot password? on the sign-in page.)
Unlock accountAfter too many wrong passwords (default 5) the account locks for 15 minutes. Unlock it at once after checking it was really the user.
Sign out all devicesEnds every session of that user, for example after a lost phone or a suspected shared password.
Reset two-factorWhen a user with two-factor sign-in has lost their phone and their recovery codes; they set it up again at the next sign-in.
Delete userOnly for an account created by mistake. You cannot delete yourself or the last Super Administrator. For staff who leave, deactivate instead.
Note: Only a Super Administrator can change a Super Administrator account or give that role.

2. Security settings

Administration Hospital Settings Security:

  • Automatic logout after inactivity: default 20 minutes. Keep it short on shared computers.
  • Failed logins before account lock (default 5) and Account lock duration (default 15 minutes).
  • Minimum password length (default 10), upper, lower case, digit and symbol (on), password expiry (0 = never).
  • Roles that must use two-factor login: users in these roles must set up an authenticator app at their next sign-in. Recommended for administrators and accountants.

Two-factor sign-in (every user can turn it on)

  1. Name menu (top right) → My profile → Two-factor authentication → Set up now.
  2. Install an authenticator app on your phone (Google Authenticator, Microsoft Authenticator or similar).
  3. Scan the QR code, or type the key shown.
  4. Enter the 6-digit code from the app and click Enable.
  5. Write down the recovery codes and keep them safe. Each code works once if the phone is lost.

My profile also has Change password and your own Signed-in devices, where you can sign out a device you no longer use.

3. Audit log

Security & Audit → Audit Log
Security & Audit → Audit Log

Security & Audit Audit Log records who did what and when: every create, change, cancel, approval, export, role or settings change and sign-in, with the device. (Opening or printing a patient's documents and reports is recorded separately in a record-access log kept on the server; IT can extract it if needed.) Filter by date, user, event and record type. Click Details to see each changed field before and after. The log cannot be edited or deleted. Export CSV needs a separate permission.

Tip: Use it to answer questions such as "who changed this bill?", "who cancelled this receipt?" or "who changed the consultation fee?".

4. Login history and active sessions

Security & Audit → Login History
Security & Audit → Login History

Security & Audit Login History: every sign-in attempt with the username entered, result (success / failed), time and device. Many failures for one username may mean someone is guessing a password.

Security & Audit → Active Sessions
Security & Audit → Active Sessions

Security & Audit Active Sessions: who is signed in now, on which device, and when they were last active. Sign out ends a session. Idle sessions are also ended automatically by the scheduled clean-up job.

5. Backups

Backups run by themselves every night at 01:30 once IT has set up the scheduled jobs (First-time setup: where to start). Each backup set has the database and the uploaded files (X-rays, documents), with checksums.

  • Sets are kept for 14 days, and never fewer than the newest 7.
  • With a backup passphrase set, backups are encrypted. Without the passphrase they cannot be restored: keep it written down outside the server, with two people.
  • A second copy goes to another disk or NAS (if set). Also keep a copy outside the building (encrypted).
  • Every month (1st, 03:00) the newest backup is restored into a scratch database and checked automatically; the result is written in restore-tests.log in the backup folder.

For IT: useful commands

php spark ohms:checkProduction check: security, configuration, backups and jobs, each PASS / WARN / FAIL with the fix. Run after every update.
php spark ohms:backupMake a backup now (for example before an update). --list shows the sets, --verify checks the newest.
php spark ohms:restore-testRun the restore test now.
/healthAddress for an uptime monitor; shows whether the application and database are working.
Important: Every week: check that the newest backup is from last night and that the second copy exists. Every month: check the restore test result. A backup that has never been restored is not a backup.

6. Patient data and privacy (DPDP Act)

  • Give each person only the roles they need. Review users and roles every three months and deactivate those who left.
  • Consent is recorded on the patient's Consent tab; a withdrawal stops reminders at once.
  • Exports are recorded in the audit log; opening and printing patient records are recorded in the record-access log.
  • Do not send patient data by personal WhatsApp or email, or keep it on personal phones or USB drives.