Posts

Find out a process ID if knowing a port

Three ways to find out a process ID if we know the port: lsof -w -n -i tcp :PORT_NUMBER fuser -n tcp PORT_NUMBER netstat -anpgrep :PORT_NUMBER

Disable SNMP under Solaris/HPUX/AIX

Even all SUN servers are running Solaris 10 OS, there is a different way to disable it for different level of patch. To run this command: # svcs -a grep sma the output : if "legacy_run Oct_22 lrc:/etc/rc3_d/S82initsma" To disable by: /etc/rc3.d/S82initsma stop mv /etc/rc3.d/S82initsma /etc/rc3.d/s82initsma else if "online 10:26:00 svc:/application/management/sma:default" To disable it by: svcadm disable svc:/application/management/sma:default else Send email to me } HPUX: edit /etc/rc.config.d/SnmpMaster Change the following line from SNMP_MASTER_START=1 TO SNMP_MASTER_START=0 to disable the SNMP to startup AIX: edit /etc/rc.tcpip Comment out the following line #start /usr/sbin/rwhod "$src_running"

mamange RPM

1> Remove multiple same rpm packages rpm -e --allmatches

ORA-01950: no privileges on tablespace

When imp the DB data, we might get error message: ORA-01950: no privileges on tablespace To sovle it: GRANT UNLIMITED TABLESPACE TO

Oracle EM Could be started

Check the hostname or IP address Check /etc/hosts & /etc/nsswitch.conf

Create Oracle tablespace

CREATE BIGFILE TABLESPACE "YFS" DATAFILE '+ASM_DATA' SIZE 200G AUTOEXTEND ON NEXT 10G MAXSIZE UNLIMITED LOGGING EXTENT MANAGEMENT LOCAL SEGMENT SPACE MANAGEMENT AUTO

Recreate Oracle ASM password

Oracle ASM password must use pure alphanumerics. It will cuase some problems (i.e. emctl could not start) if not follow this rule. Here are steps to make emctl work: 1> Remove the old ASM password cd $GRID_HOME mv orapw+ASM orapw+ASM.orig 2> Create a new password orapwd file=orapw+ASM password= 3> Setup Env export ORACLE_SID=+ASM export ORACLE_HOME=$GRID_HOME 4> Create ASM User sqlplus / as sysasm create user asmsnmp identified by grant sysdba to asmsnmp; 5> Drop EMCA emca -deconfig dbcontrol db -repos drop 6> Create EMCA emca -config dbcontrol db -repos recreate /u01/app/grid/product/11.2.0/dbhome_1/dbs >emca -config dbcontrol db -repos recreate STARTED EMCA at Jan 11, 2011 4:18:47 PMEM Configuration Assistant, Version 11.2.0.0.2 ProductionCopyright (c) 2003, 2005, Oracle. All rights reserved. Enter the following information:Database SID: HPUX03 Listener port number: 1521 Listener ORACLE_HOME [ /u01/app/...