تجربیات اوراکلی و آموزش و ... در شهر اوراکل

How to Move Oracle Table to Another Tablespace of Another Database

Moving an Oracle table can move it to another tablespace and another database with TNS.

 

cat /u01/app/oracle/product/19.0.0/dbhome_1/network/admin/tnsnames.ora

 

target  =

  (DESCRIPTION =

    (ADDRESS = (PROTOCOL = TCP)(HOST = srv2.cloud.com)(PORT = 1521))

    (CONNECT_DATA =

      (SERVER = DEDICATED)

      (SERVICE_NAME = orcl2)

    )

  )

 

alter table hr.employees move tablespace users@target online parallel 16;

 

We can all transactions on all databases .

Build it Oracle.

۲۵ خرداد ۰۱ ، ۱۰:۵۴ ۰ نظر موافقین ۰ مخالفین ۰
سعید حسینی فر

How To Keep Same Password For Oracle User When Its EXPIRED(GRACE) State

unlock کردن یوزر EXPIRED بدون تغییر رمز عبور آن.

 

Users’ passwords are valid for the duration of PASSWORD_LIFE_TIME in their profile. At the end of this period the password expires and must be changed. After the password expires, the user’s status will be in EXPIRED(GRACE) State until the day of PASSWORD_GRACE_TIME in the profile.

Detailed information about Oracle profiles can be found in the following article.

 

 

You can create the necessary command with the following query to change user status from EXPIRED (GRACE) to NORMAL by keeping the current password.

ادامه مطلب...
۰۲ اسفند ۰۰ ، ۱۰:۲۱ ۰ نظر موافقین ۰ مخالفین ۰
سعید حسینی فر

Reset ESXi Root Password with Host Profile

فراموشی رمز ESXi Root

 

ESXi host root password fails to authenticate forgotten and cannot authenticate into CLI

 

 
1. Login to the vCenter WebClient
2. Go to Home and then choose Host Profiles from Operations and Policies Section.
3. Choose > Extract profile from a host.
4. In the Extract Host Profile menu wizard > Select the host you want to update the password for.
5. Name the Host Profile and click Next and then Finish to complete the capture of the host profile template.
 - The new host profile should appear on the Host Profile Objects Field.
ادامه مطلب...
۰۲ اسفند ۰۰ ، ۱۰:۱۴ ۰ نظر موافقین ۰ مخالفین ۰
سعید حسینی فر

ACTUAL RESULT: PORT 3872 PASSED IS BUSY CHECK COMPLETE

Either port is unavailable or hostname configuration is not valid. Expected result: 3872 Actual Result: Port 3872 passed is busy Check complete. The overall result of this check is: Failed Make sure the port is available and the hostname configuration is proper 3872

 

This error appear while trying to deploy agent for Enterprise manager 13c (em13c) and the cause for this error that port 3872 is already in use :

 

solution:

[root@em13c Middleware]# netstat -anp | grep 3872

tcp        0      0 :::3872                     :::*                        LISTEN      2391/java    
     
[root@em13c Middleware]# kill -9 2391

[root@em13c Middleware]# netstat -anp | grep 3872

Deploy Again

۱۷ آذر ۰۰ ، ۱۱:۳۷ ۰ نظر موافقین ۰ مخالفین ۰
سعید حسینی فر

Adobe Flash End-of-Life Impact on Oracle Enterprise Manager Cloud Control

Adobe Flash End-of-Life

Cause :

The Adobe Flash EOL is December 31, 2020.
Adobe has announced that the Flash player will be blocked from running after the EOL date.

 

Adobe Flash Plug-in End-of-Life and Enterprise Manager

Many database performance screens in Enterprise Manager were implemented using Adobe Flash technology in versions prior to Enterprise Manager 13.3.2.0.   These database performance pages include ‘Performance Home’, ‘Top Activity’, ‘ASH Analytics’, ‘Real-time SQL Monitoring’ among others.

These Flash pages were replaced with the Oracle JET UI in Enterprise Manager 13.3.2.0 (EM 13.3 PG), released in 2019, and were later enhanced in Enterprise Manager 13.4.

Adobe Flash is being de-supported by Adobe on December 31, 2020.   If you are running versions of Enterprise Manager 13.3.1 or older and use the database performance pages with Adobe Flash goto solution.

ادامه مطلب...
۱۶ آبان ۹۹ ، ۱۵:۱۷ ۰ نظر موافقین ۰ مخالفین ۰
سعید حسینی فر

RAC GRID Root.sh ORA-27091 ORA-15081 unable to queue I/O

RAC GRID Root.sh ORA-27091 ORA-15081 unable to queue I/O

ERROR:

[root@node-01 install]# /u01/app/11.2.0/grid/root.sh
Running Oracle 11g root script...

The following environment variables are set as:
    ORACLE_OWNER= grid
    ORACLE_HOME=  /u01/app/11.2.0/grid

Enter the full pathname of the local bin directory: [/usr/local/bin]:
The contents of "dbhome" have not changed. No need to overwrite.
The contents of "oraenv" have not changed. No need to overwrite.
The contents of "coraenv" have not changed. No need to overwrite.

Entries will be added to the /etc/oratab file as needed by
Database Configuration Assistant when a database is created
Finished running generic part of root script.
Now product-specific root actions will be performed.
Using configuration parameter file: /u01/app/11.2.0/grid/crs/install/crsconfig_params
LOCAL ADD MODE
Creating OCR keys for user 'root', privgrp 'root'..
Operation successful.
OLR initialization - successful
Adding daemon to inittab
ACFS-9200: Supported
ACFS-9300: ADVM/ACFS distribution files found.
ACFS-9307: Installing requested ADVM/ACFS software.
ACFS-9308: Loading installed ADVM/ACFS drivers.
ACFS-9321: Creating udev for ADVM/ACFS.
ACFS-9323: Creating module dependencies - this may take some time.
ACFS-9327: Verifying ADVM/ACFS devices.
ACFS-9309: ADVM/ACFS installation correctness verified.
CRS-2672: Attempting to start 'ora.mdnsd' on 'node-01'
CRS-2676: Start of 'ora.mdnsd' on 'node-01' succeeded
CRS-2672: Attempting to start 'ora.gpnpd' on 'node-01'
CRS-2676: Start of 'ora.gpnpd' on 'node-01' succeeded
CRS-2672: Attempting to start 'ora.cssdmonitor' on 'node-01'
CRS-2672: Attempting to start 'ora.gipcd' on 'node-01'
CRS-2676: Start of 'ora.cssdmonitor' on 'node-01' succeeded
CRS-2676: Start of 'ora.gipcd' on 'node-01' succeeded
CRS-2672: Attempting to start 'ora.cssd' on 'node-01'
CRS-2672: Attempting to start 'ora.diskmon' on 'node-01'
CRS-2676: Start of 'ora.diskmon' on 'node-01' succeeded
CRS-2676: Start of 'ora.cssd' on 'node-01' succeeded

ASM created and started successfully.

Disk Group OCR_VOTE created successfully.

Errors in file :
ORA-27091: unable to queue I/O
ORA-15081: failed to submit an I/O operation to a disk
ORA-06512: at line 4
PROT-1: Failed to initialize ocrconfig
PROC-26: Error while accessing the physical storage
ORA-27091: unable to queue I/O
ORA-15081: failed to submit an I/O operation to a disk
ORA-06512: at line 4

Failed to create Oracle Cluster Registry configuration, rc 255
Oracle Clusterware Repository configuration failed at /u01/app/11.2.0/grid/crs/install/crsconfig_lib.pm line 6471.
/u01/app/11.2.0/grid/perl/bin/perl -I/u01/app/11.2.0/grid/perl/lib -I/u01/app/11.2.0/grid/crs/install /u01/app/11.2.0/grid/crs/install/rootcrs.pl execution failed
[root@node-01 install]#



Solution:

The ASM Lib configuration was done with oracle id,But the grid installation i am doing with grid user.

[root@node-02 11202stage]# /usr/sbin/oracleasm configure
ORACLEASM_ENABLED=true
ORACLEASM_UID=oracle
ORACLEASM_GID=dba
ORACLEASM_SCANBOOT=true
ORACLEASM_SCANORDER=""
ORACLEASM_SCANEXCLUDE=""
ORACLEASM_USE_LOGICAL_BLOCK_SIZE="false"

[root@node-02 11202stage]#

Update the configuration of ASMlib

/usr/sbin/oracleasm configure -u grid 

[root@node-02 11202stage]# /usr/sbin/oracleasm configure
ORACLEASM_ENABLED=true
ORACLEASM_UID=grid
ORACLEASM_GID=asmadmin
ORACLEASM_SCANBOOT=true
ORACLEASM_SCANORDER=""
ORACLEASM_SCANEXCLUDE=""
ORACLEASM_USE_LOGICAL_BLOCK_SIZE="false"

[root@node-02 11202stage]#

For fresh installation delete the Disk group at asmlib.

/usr/sbin/oracleasm deletedisk OCR_VOTE01
/usr/sbin/oracleasm deletedisk ASM_DATA01
/usr/sbin/oracleasm deletedisk ASM_FRA01

And Recreate

/usr/sbin/oracleasm createdisk OCR_VOTE01 /dev/sde1
/usr/sbin/oracleasm createdisk ASM_DATA01 /dev/sdf1

/usr/sbin/oracleasm createdisk ASM_FRA01 /dev/sdg1

/usr/sbin/oracleasm listdisks

/usr/sbin/oracleasm scandisks

Now rerun the root.sh

 

 

http://oracletechdba.blogspot.com/2014/09/rac-grid-rootsh-ora-27091-ora-15081.html

۱۶ آبان ۹۹ ، ۱۵:۰۷ ۰ نظر موافقین ۰ مخالفین ۰
سعید حسینی فر

Failed to start the virtual machine file not found .vmdk

I'm using VMware Workstation Pro 15.5.1 with monolithic disk files (on a Win 10 host). I worked with snapshots, but always deleted them again because they're not needed anymore.

Unfortunately, it does not delete the Snapshot files from my disk, when I try to delete them by hand it says This file is required to power on this virtual machine. If this file was moved, specify the new location.

 *.vmdk file which works independently from the snapshot files.

 

Solution:

1. Shut down the virtual machine
2. Go to the option 'VM' > Snapshot Manager
3. Select each snapshot and delete them from left-to-right

۰۹ آبان ۹۹ ، ۱۶:۳۶ ۰ نظر موافقین ۰ مخالفین ۰
سعید حسینی فر

How To Move Spfile From File System To ASM In RAC

Below are the steps for moving spfile from file system to ASM diskgroup in RAC.

database name – ORCL
instance_names – ORCL1,ORCL2
oracle DB nodes – dbhstorcl1, dbhstorcl2

1. Check current pfile location:

SQL> show parameter pfile
 
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
spfile string /oracle/app/oracle/product/dbs/temp_init.ora

2. Now required directory in ASM diskgroup(where pfile will be created)

export ORACLE_HOME=/crsapp/app/oracle/product/12.1.2.0/grid12c
export ORACLE_SID=+ASM1
export PATH=$ORACLE_HOME/bin:$PATH
 
asmcmd
ASMCMD>mkdir +DATA/PARAM
 

3. Create the spfile from pfile:

create spfile='+DATA/PARAM/spfileORCL.ora' from pfile='/oracle/app/oracle/product/dbs/temp_init.ora';

4. Update INIT FILE on each node (pointing to actual spfile path)

on node 1(dbhstorcl1)

cd $ORACLE_HOME/dbs
 
cat initORCL1.ora
SPFILE='+DATA/PARAM/spfileORCL.ora'

on node 2(dbhstorcl2)

cd $ORACLE_HOME/dbs
 
cat initORCL2.ora
SPFILE='+DATA/PARAM/spfileORCL.ora'

5. update database config

srvctl modify database -d racdb1 -p +DATA/PARAM/spfileORCL.ora
 
srvctl config database -d B2CPRE | grep Spfile
Spfile: +CRMDB01/paramfile/spfileB2CPRE.ora
 

6. Restart the database

srvctl stop database -d ORCL
srvctl start database -d ORCL
 
 
SQL> show parameter pfile
 
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
spfile string +DATA/PARAM/spfileORCL.ora
 

 

۰۹ آبان ۹۹ ، ۱۱:۵۷ ۰ نظر موافقین ۰ مخالفین ۰
سعید حسینی فر

DBCA Does Not Display ASM Disk Groups In 12cR2

I was installing Oracle 12c R2 with ASM but somehow the DBCA did not list ASM diskgroups. After struggling for hours, I could find a solution, not sure if it is approved by Oracle but it works !!

 

Problem

 

I’ve installed Grid infrastructure with user grid, and I was trying to install oracle database 12cr2 with oracle user but during this installation I wasn’t able to see any of my ASM disk in the select disk group.

 

Solution

 

log in as root user

 

/dev/oracleasm/

ls -lrt to check the permission on oracleasm directory

chown -R grid:oinstall oracleasm

 

cd /dev/oracleasm/disks

 

Login as grid user

 

cd $ORACLE_HOME

cd bin

ls -ld to check the permision on oracle directory

chmod 6571 oracle

ls -ld oracle

 

Login as oracle user

 

cd $ORACLE_HOME

cd bin

ls -ld oracle to check the permision

 

However, oracle directory permision in both grid user and oracle user must have the same permission. Therefore, issue the following command;

 

chmod 6571 oracle

 

Go back to select disk group and refresh.

 

۰۹ آبان ۹۹ ، ۱۱:۵۳ ۰ نظر موافقین ۰ مخالفین ۰
سعید حسینی فر

DBSNMP Account Locked ORA-28000 in the Standby Database

 

This is because the standby is open read-only and cannot update any tables.
When a user's account has to be locked on the standby database, it is locked only in memory there.

 

ادامه مطلب...
۰۵ آذر ۹۸ ، ۰۸:۵۶ ۰ نظر موافقین ۰ مخالفین ۰
سعید حسینی فر