Posts

ORA-01012: not logged on startup failed

DB startup failed with error: ORA-01012: not logged on Background: ============== Database is taking more time to stop say almost one hour and its hung so killed background process using below command $ kill -9 <PID> OR $kill -9 -1 Problem: ========== Now while starting the DB instance. $ sqlplus / as sysdba SQL*Plus: Release 11.2.0.3.0 Production on Tue Sep 25 07:23:45 2018 Copyright (c) 1982, 2011, Oracle.  All rights reserved. Connected. SQL> startup ORA-01012: not logged on SQL> conn / as sysdba Connected to an idle instance. SQL> startup ORA-01012: not logged on So whenever we forcefully shut down the DB this issue may occurs “SYSRESV”  shows a shared memory segment for a non-existing instance Solution: ======= At OS level remove the orphaned shared memory segment using this utility $ sysresv IPC Resources for ORACLE_SID “SID” : Shared Memory: ID              KEY ...

How to Update Datasource Connect String ?

Scenario 1) Updating all datasource with same connect string  =============================================== step a) create updateds.py file at $DOMAIN_HOME dsURL="jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=orcl)))" print("*** Wait for a moment trying to connect *****") connect('weblogic','xxxxxxx','t3://localhost:7001') print("*** Connected *****") cd('Servers/AdminServer') edit() startEdit() cd('JDBCSystemResources') for tmpDS in allDS:   dataSourceName=tmpDS.getName();   print  'changing datasource connect string for', dataSourceName   cd('/JDBCSystemResources/' + dataSourceName + '/JDBCResource/' + dataSourceName + '/JDBCDriverParams/' + dataSourceName)   cmo.setUrl(dsURL)   print("*** connect string changed for your: ", dataSourceName)   print ('')   print (...

How to resolve issues related to Errors: 1) connection limit (1) exceeded 2) Too Many Open files error & 3) native OutOfMemory ?

Image
Problem Definition:- ================ Usually these type of errors will be seen in WebLogic, WebSphere, Tomcat logs due to Unix resource exhaustion ie. when soft limit of the open file descriptor crossed the specified limit value. Before increasing the open file descriptor limit just check is there any process holding lock for deleted log files by using lsof command.  Solution-1) Increase the open file descriptor value temporarily at user session level. Example:  ulimit -n    #command for checking current value of file descriptor  ulimit -n  8192  # Command for increasing file descriptor value Solution-2) Increase the file descriptor limit using WebLogic commEnv.sh upto 12.1.3 OR commBaseEnv.sh from 12.2.1.1.0 on wards. Change from 4096 to higher value   Similar to below   Solution-3) Change the soft limit of file descriptor using /etc/security/limits.conf Current value: 409...

How to Automate WebLogic Domain Restart? When Physical or Virtual Linux Server Restart

Image
==> This Method is very Useful in below Scenarios  When Physical/Virtual  Linux Servers Crashed and You Brought Up Linux Server at the Same Time WebLogic Servers Also Started Without Manual Intervention. During Maintenance of Linux Servers, If Your Restarting Linux Server in that case also WebLogic Application Servers will be Started Automatically by Using this Method. If WebLogic Server Crashed Due to OOM(OutOfMemory) OR Due to any JVM BUG in that case also JVM will be restarted automatically.  Summary: ======== 1) Create nodemanager Script 2) Save the Script Inside Directory /etc/init.d 3) Issue the Command chkconfig for Script nodemanager 4) Change Properties Values in nodemanager.properties  File 5) Start the NodeManager, AdminServer & Managed Server Through NodeManager 6) For Testing Purpose Restart the Linux Server & Check WebLogic Application Server Status. STEPS:- ======= Step-1) Create nodemanager Script  ...

How To Increase Tomcat Performance Using Tomcat Native Library ?

Image
The Apache Tomcat Native Library is an optional component for use with Apache Tomcat that allows Tomcat to use certain native resources for performance, compatibility, etc. Specifically, the Apache Tomcat Native Library gives Tomcat access to the Apache Portable Runtime (APR) library's network connection (socket) implementation and random-number generator. Summary ============= 1) Download Softwares APR library, OpenSSL libraries & Tomcat Native Library 2) Install APR library 3) Install OpenSSL libraries  4) Install Tomcat Native Library 5) Add the Libraries Path to tomcat CLASSPATH 6) Restart Tomcat Server & Validate Libraries Loaded or Not at Run time. Steps: ===== 1) Download Softwares APR library, OpenSSL libraries & Tomcat Native Library Use Below links for downloading software's APR ==>  http://www-eu.apache.org/dist//apr/apr-1.5.2.tar.gz OpenSSL ==>   https://www.openssl.org/source/openssl-...

How to Start, Stop & Dissable Firewall in CentOS 7 using systemctl?

Image
1) Below command is used for checking status of firewall  systemctl status firewalld 2) Below command is used for starting firewall  systemctl start firewalld 3) Below commands are used for Stopping &  Disabling firewall systemctl stop firewalld systemctl disable firewalld

Tar Command Examples

Image
1) Creating tar files     a) How to Create .tar file             Below command creates uncompressed archive file.               tar -cvf log.tar log Options Meaning: c – Creates a new .tar archive file. v – Verbosely show the .tar file progress. f – File name type of the archive file.     b) How to Create .tar.gz OR .tgz files         Below command creates compressed  gzip archive file.Use z option           tar zcvf logs.tar.gz logs/         OR     tar zcvf logs.tgz logs/           c) How to create   tar.bz2 OR  tbz OR  tb2         The bz2 feature compress and create archive file less than the size of the gzip           To create highly compressed tar file we use option as j. ...