Troubleshooting
SyteLine 'Locked' message: how to safely unlock functions and journals
Applies to: SyteLine 8, 9 and 10, and CloudSuite Industrial. The unlock utilities need the SyteLine username
Short answer
SyteLine locks a function or journal while a process is using it, so two people can't post the same journal at once. If that process is interrupted before it finishes, for example by a dropped connection, a crash or a killed task, the lock can be left behind, and the next person gets a "Locked" message. Once you've confirmed the original process really has stopped, clear it with Unlock Locked Journals (journals, plus their related functions) or Unlock Locked Functions (functions). Both need the SyteLine username. Crash Recovery does the same for everything at once and ends every user's session, so it's for real crashes, not one stuck lock.
Why SyteLine locks things
Some processes must not run twice at the same time: posting a journal, editing a journal while it's being posted, certain utilities. SyteLine marks them locked while they run and clears the lock when they finish normally.
The problem is the word normally. Infor's documentation says a journal stays locked if you stop any of these before they complete:
- editing a journal
- posting information into a journal
- posting a journal
Functions are the same: a function aborted before it finished stays locked. You find out when someone opens the process and gets a "Locked" message.
Step 1: Make sure it really has stopped
This is the important step. A lock that looks stuck may be a process that's still running: a long posting at month-end, or a task behind a blocker. Unlocking a function that's genuinely in use defeats the protection the lock was there to give.
Before unlocking, check:
- Ask who was running it. Did their session crash, lose connection, or did they close it part-way?
- Check Active Background Tasks. If the related posting or utility is still RUNNING, it isn't stuck. It's working, or it's blocked. See Why a SyteLine task runs for days and Find the SQL head blocker.
- Check Background Task History. A failed or cancelled run at the time the lock appeared is a strong sign the lock is left over.
- Check Session Management for the user's old, frozen session. See Find and clear orphan user sessions.
Only when you're confident nothing is still working on that journal or function, move on.
Step 2: Unlock the right thing
| Message is about | Use | What it clears |
|---|---|---|
| A journal (editing or posting) | Unlock Locked Journals | Locks on journals left by interrupted operations, and on their related functions |
| A function or utility | Unlock Locked Functions | Locks on functions that were aborted before finishing |
| Everything, after a utility server crash | Crash Recovery | All sessions except yours, and all locked functions and journals |
Both unlock utilities require the SyteLine username, so this is an administrator's job, not something to hand to every user.
Step 3: Check the data, then re-run
An interrupted posting may have done part of its work before it stopped. Before re-running:
- Look at what was posted. Check the journal, and the related transactions, for the period and range that was being processed.
- Re-run for what's left, not blindly for the whole range again, so nothing is posted twice.
- Note what happened on the ticket: who, when, which journal or function, and what was re-run.
Crash Recovery: the last resort
Crash Recovery ends the sessions of every user except the person running it, and unlocks all locked functions and journals. It's meant mainly for after a utility server crash. After a database server crash it isn't needed, because the database does this itself on restart.
Infor's own warning is not to run it against a database that users are still using. For one stuck journal or function, use the unlock utilities above. For one stuck user, use Session Management.
Why locks keep coming back
If the same journal or function is locked every few weeks, the unlock isn't the fix. Look for the cause:
- Users closing the client mid-posting, or laptops sleeping on VPN during long runs. Train people to let postings finish, or run big postings as background tasks.
- Unstable connections on the shop floor or remote sites. Turning on automatic orphan-session cleanup helps. See orphan sessions.
- Posting runs that are too big, so they take long enough to be interrupted. Post more often, in smaller batches.
- Killed tasks. If a task was stopped with
KILLin SQL Server, unlock and check the data as above, and fix whatever made the kill necessary.
FAQ
Why does SyteLine say a journal is locked?
A process that edits or posts the journal was interrupted before it finished, so its lock was left in place. Or someone else is genuinely using the journal right now.
How do I unlock a journal in SyteLine?
First confirm nothing is still running against it. Then use Unlock Locked Journals, which needs the SyteLine username, and check what was already posted before re-running.
What's the difference between Unlock Locked Functions and Crash Recovery?
The unlock utilities clear stuck locks. Crash Recovery also ends every user's session except yours, so it's only for real crashes, when nobody is using the system.
Is it safe to unlock a SyteLine function?
Only after confirming the process that locked it has really stopped. Unlocking a function that's still running removes the protection against it running twice.