Tuesday, 31 January 2017

Weblogic Error : unable to get file lock, will retry ...



unable to get file lock, will retry ...


This is a common issue for weblogic user/developer. Developers are always facing this issue with file lock.Something went wrong.

Weblogic Console Error Log -


<31/01/2017 2:25:12 PM EST> <Info> <Security> <BEA-090906> <Changing the default Random Number Generator in RSA CryptoJ from ECDRBG to FIPS186PRNG. To disable this change, specify -Dweblogic.security.allowCryptoJDefaultPRNG=true>
<31/01/2017 2:25:12 PM EST> <Info> <WebLogicServer> <BEA-000377> <Starting WebLogic Server with Java HotSpot(TM) Client VM Version 17.0-b17 from Sun Microsystems Inc.>

<31/01/2017 2:25:23 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:25:33 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>
<31/01/2017 2:25:43 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:25:53 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:26:03 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:26:13 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:26:23 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:26:33 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:26:43 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:26:53 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:27:03 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:27:13 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:27:23 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:27:33 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:27:43 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:27:53 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:28:03 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:28:13 PM EST> <Info> <Management> <BEA-141281> <unable to get file lock, will retry ...>

<31/01/2017 2:28:18 PM EST> <Critical> <WebLogicServer> <BEA-000362> <Server failed. Reason:

There are 1 nested errors:

weblogic.management.ManagementException: Unable to obtain lock on /usr/java/Oracle/Middleware/user_projects/domains/base_domain/servers/AdminServer/tmp/AdminServer.lok. Server may already be running
    at weblogic.management.internal.ServerLocks.getServerLock(ServerLocks.java:206)
    at weblogic.management.internal.ServerLocks.getServerLock(ServerLocks.java:67)
    at weblogic.management.internal.DomainDirectoryService.start(DomainDirectoryService.java:74)
    at weblogic.t3.srvr.ServerServicesManager.startService(ServerServicesManager.java:461)
    at weblogic.t3.srvr.ServerServicesManager.startInStandbyState(ServerServicesManager.java:166)
    at weblogic.t3.srvr.T3Srvr.initializeStandby(T3Srvr.java:881)
    at weblogic.t3.srvr.T3Srvr.startup(T3Srvr.java:568)
    at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:469)
    at weblogic.Server.main(Server.java:71)

>
<31/01/2017 2:28:18 PM EST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to FAILED>
<31/01/2017 2:28:18 PM EST> <Error> <WebLogicServer> <BEA-000383> <A critical service failed. The server will shut itself down>
<31/01/2017 2:28:18 PM EST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to FORCE_SHUTTING_DOWN>



Solutions :-

You can fix the by simple one step. Just delete the AdminServer.lok file from  your domain.

I have deleted below , check the below commands ..

Go to the /tmp directory inside your weblogic domain.


cd  /usr/java/Oracle/Middleware/user_projects/domains/base_domain/servers/AdminServer/tmp




Checking the existing files inside /tmp directory.


dev@jdg-desktop /usr/java/Oracle/Middleware/user_projects/domains/base_domain/servers/AdminServer/tmp $ ls
AdminServer.lok  WebServiceUtils.ser  _WL_internal  _WL_user


 

Now delete the AdminServer.lok file from this /tmp directory.
 
dev@jdg-desktop /usr/java/Oracle/Middleware/user_projects/domains/base_domain/servers/AdminServer/tmp $ rm -rf AdminServer.lok




Hope it will help you.




Follow for more details on Google+ and @Facebook!!!

Find More Issues & Solutions -