Status Ending Blocked on the Online User Screen

This question has suggested answer(s)

Dear All,

We found the status 'ending bloacked' showed in the online user screen for serveral times. After reading from the help it said as below

' Ending - Blocked - The administrator has clicked End sessions to end the session and the AOS has processed the request, but there is a problem disconnecting the session. '

This cause my user can't logon !!!

In fact we never did as mention above. Anyone experience this before please kindly share

- what is the reason  

- how to end this session ( currently we have to stop and start service of AOS server and impact to the service time )

Thanks You in advance  

 

 

 

 

All Replies
  •  

    Hi all,

     

    Can anybody help on this

    thk

     

     

  • Please help on this

  • Please any advise in this ??

  • Sounds like a SQL session which cannot be cut by AOS. This can f.ex. be caused by deadlocks. Take a look into the windows event logs on the AOS server machine. The AOS will declare the specific SQL session no. which has to terminated manually.

    You can also note the SPID from the "ending" user and than goto SQL administration tool and kill the process with the corresponding number.

    This should solve the blockade.

  • This case I think we can do as below:

    On the User Online screen we can see which userID and which session has status is Ending -Block

    Go to the SQL server, look into SQLCLIENTSESSIONS table to see all user sessions.

    Delete exactly the line with USERID and SESSIONID of that user.

    Regards,

    Anh Mai

  • Ah , I forgot

    The reason is the Admin was end session of this user on User Online Screen in AX

    Anh Mai

  • Mai,

    I have two sessions of an 'ending-blocked' user (same user) in AX2009. I have been looking through many tables and db's in SQL 2008 R2 trying to find the SQLSESSIONS table you mentioned. Can you clarify what the path to this table is?

    Many thanks.

  • Dear Hank,

    I never tried deleting this entries through table what i do is killing the process from the SQL Activity monitor . i think this is more trusty than deleting record that may affect the DB consistency

    Regards,

  • Thanks for the reply Emad.

    I was hoping to use that method but these two "Ending-Blocked" sessions are not showing up in the SQL Activity Monitor. I tried restarting the SQL and AOT services last night hoping that would help but it didn't change anything.

    One thing I did notice this morning is that, eventhough we have 17 active online AX users, there are only two users from AX showing up in the SQL Activity Monitor: RetailStoreConnect and the AOS service user. All of our AX Clients access the program through a terminal server. Is that why they don't show up in the SQL Activity Monitor processes? Maybe I don't have the Activity Monitor configured correctly...

  • urw

    this is a new case i always found the sessions in sql and force it to be closed .. try to restart the two sessions "restarting the clients" windows restarting

  • Hi.

    I had same symphtom.

    I've had only one active object server, and still sessions listed in "online users".

    Searching in the database there was no active connection from the aos in the database at all.

    The remedy was to startup up the aos-server with zombie sessions. Apparantly this cleared out the dead user sessions. After this I could end this aos-server again. With all users cleared out I was able to progress with my updates.

    Trond

  • I wanted to update the progress we made on our two locked AX users.

    Since I couldn't find their locked sessions in SQL I decided to check on the Terminal server box.

    I went to Task Manager, found the two locked users and forced them to disconnect/log off.  

    This worked and cleared out the locked sessions in AX.  

  • Another way to find this is by running this script to find the SPid # and AOS server name.  Then go into that particular AOS to AX > administration > online users to match the SPid# to identify which user is causing the initial blocking session.  Once identified, You can then kill that users session in sql.  All other user sessions that are blocked will quickly end themselves after that.  This works for multiple "Ending-Blocked" issues.

    SELECT

        spid

        ,status

        ,loginame   = SUBSTRING(loginame, 1, 12)

        ,hostname   = SUBSTRING(hostname, 1, 12)

        ,blk        = CONVERT(char(3), blocked)

        ,open_tran

        ,dbname     = SUBSTRING(DB_NAME(dbid),1,10)

        ,cmd

        ,waittype

        ,waittime

        ,last_batch

    FROM master.dbo.sysprocesses

    WHERE spid IN (SELECT blocked FROM master.dbo.sysprocesses)

    AND blocked = 0

    --When you find the spid#

    Kill <spid#>

  • And how to avoid this ?