Oracle commands

  • ps -ef | grep pmon (List active instances)
  • cat /etc/oratab (List instance installed)
  • ORACLE_SID=INST1 sqlplus “/ as sysdba” (Connect to the instance)
  • ORACLE_SID=INST1 sqlplus “/as sysdba” @/tmp/grantrights.sql
  • shutdown immediate;
  • startup
  • SELECT username from dba_users (List all the schemas in a instance)
  • SELECT count(*) from DBA_OBJECTS where OWNER=’USER1′
  • CREATE user abc identified by pass123;
  • GRANT create sesssion to abc;
  • GRANT dba to user1;
  • SELECT * FROM PRODUCT_COMPONENT_VERSION;
  • SELECT * FROM v$version;
  • SELECT version FROM v$instance;
  • $PWFILE_USERS and REMOTE_LOGIN_PASSWORDFILE
  • rman list archivelog;
  • roman /
  • SELECT table_name, status, num_rows FROM USER_TABLES;
Advertisements

About Ishtiaque

I am IBM Certified Infrastructure Systems Architect, Linux Foundation Certified System Administrator, Oracle Certified Programmer in Java and Web Component Developer, and TOGAF 9 certified with over 10 years of support and development experience in IBM middleware software and Java. Additionally, have a sound grip in databases and OpenStack administration. I hold the following certifications: IBM Certified Infrastructure Systems Architect Linux Foundation Certified System Administrator (LFCS) TOGAF 9 Certified Oracle Certified Expert, Java EE6 Web Component Developer Oracle Certified Professional – Java 6 Programmer ITIL v3 Foundation Certified IBM Certified Solution Architect – Cloud Computing Infrastructure V1 IBM Certified System Administrator – WebSphere Portal V8, V7, V6.1, V6 IBM Certified System Administrator – WebSphere Application Server V7, V6.1 IBM Certified System Administrator – AIX V7 IBM Certified System Administrator – WebSphere MQ V7 IBM Certified Deployment Professional – Business Process Manager Advanced V7.5 IBM Certified Solution Advisor – Cloud Computing Architecture V3 IBM Certified Solution Developer – WebSphere Portal V5.1
This entry was posted in AIX, Linux, Oracle and tagged , , . Bookmark the permalink.