• No se han encontrado resultados

Tissue-specific expression of transcription factors

3. 4 Computational facilities

4. Results

4.2 Identification and functional characterisa- characterisa-tion of human transcripcharacterisa-tion factors

4.2.4 Tissue-specific expression of transcription factors

In this practice, you use several tools to navigate the ASM file hierarchy, manage aliases, manage templates, and move files to different disk regions.

1) ASM is designed to hold database files in a hierarchical structure. After setting up the grid environment, navigate the orcl database files with ASMCMD.

[grid@host01 ~]$ . oraenv ORACLE_SID = [grid] ? +ASM1

The Oracle base has been set to /u01/app/grid [grid@host01 ~]$ asmcmd

ASMCMD> ls -l DATA/ORCL/*

Type Redund Striped Time Sys Name

Oracle University and Mazz Soluciones SRL use only

ONLINELOG MIRROR COARSE MAY 01 08:00:00 Y

2) The default structure may not be the most useful for some sites. Create a set of aliases for directories and files to match a file system. Use EM.

Step Screen/Page Description Choices or Values a. Cluster Database:

orcl.example.com

In the Instances section, click the +ASM1_node_name.example.com link.

b. Automatic Storage Management:

+ASM1_node_name.exampl e.com Home

Click the Disk Groups tab.

c. Automatic Storage Management Login

Enter:

Username: SYS

Password: oracle_4U Click Login.

d. Automatic Storage Management:

+ASM1_host01.example.co m DiskGroups

Click the DATA disk group link.

e. Disk Group: DATA General Click the Files tab.

f. Disk Group: DATA Files Select ORCL.

Click Create Directory.

g. Create Directory Enter:

New Directory: oradata Click Show SQL.

Oracle University and Mazz Soluciones SRL use only

Step Screen/Page Description Choices or Values

h. Show SQL The SQL that will be executed is shown

ALTER DISKGROUP DATA ADD DIRECTORY '+DATA/ORCL/oradata'

Click Return.

i. Create Directory Click OK.

j. Disk Group: DATA Files Expand the ORCL folder.

Expand the DATAFILE folder.

Select EXAMPLE.nnn.NNNNNN.

ALTER DISKGROUP DATA ADD ALIAS '+DATA/ORCL/oradata/example_01.dbf'

n. Disk Group: DATA: Files Click the

EXAMPLE.nnn.NNNNN

link.

o.

EXAMPLE.nnn.NNNNNN

: Properties

Notice the properties that are displayed in the General section.

Click OK.

p. Disk Group: DATA Files Click the

example_01.dbf

link.

q. example_01.dbf: Properties Note that the properties include System Name.

Click OK.

r. Exit EM.

3) Using ASMCMD, navigate to view

example_01.dbf

and display the properties.

Using the system name, find the alias. Use the

ls –a

command.

[grid@host01 ~]$ asmcmd

ASMCMD> ls +DATA/ORCL/oradata/*

example_01.dbf

ASMCMD> ls -l +DATA/ORCL/oradata/*

Type Redund Striped Time Sys Name N

example_01.dbf => +DATA/ORCL/DATAFILE/EXAMPLE.264.782110251

ASMCMD> ls --absolutepath +DATA/ORCL/DATAFILE/example*

+DATA/ORCL/oradata/example_01.dbf => EXAMPLE.264.782110251

Oracle University and Mazz Soluciones SRL use only

4) Create a new tablespace. Name the file using a full name. Use EM.

Step Screen/Page Description Choices or Values x. Cluster Database:

orcl.example.com Home

Click the Server tab.

y. Cluster Database:

orcl.example.com Server

In the Storage section, click the Tablespaces link.

z. Tablespaces Click Create.

aa. Create Tablespace: General Enter:

Name: XYZ

In the Datafiles section, click Add.

bb. Add Datafile Enter:

Alias directory: +DATA/ORCL/oradata Alias name: XYZ_01.dbf

Click Continue.

cc. Create Tablespace: General Click OK.

dd. Tablespaces

5) Create another data file for the XYZ tablespace. Allow the file to receive a default name. Did both the files get system-assigned names?

Step Screen/Page Description Choices or Values

a. Tablespaces Select XYZ tablespace.

Click Edit.

b. Edit Tablespace: XYZ In the Datafiles section, click Add.

c. Add Datafile Click Continue.

d. Edit Tablespace: XYZ Click Show SQL.

e. Show SQL Note: The SQL provides only the disk group name.

Click Return.

f. Edit Tablespace: XYZ Click Apply.

g. Edit Tablespace: XYZ In the Datafiles section, note the names of the two files. One name was specified in the previous practice step, xyz_01.dbf, and the other is a system-assigned name.

Click the Database tab.

h. Cluster Database:

orcl.example.com

In the Instances section, click the +ASM1_host01.example.com link.

i. Automatic Storage Management:

+ASM1_node_name.example.com Home

Click the Disk Groups tab.

j. Automatic Storage Management Login

Enter:

Username: SYS

Password: oracle_4U Click Login.

k. Automatic Storage Management:

+ASM1_host01.example.com

Click the DATA disk group link.

Oracle University and Mazz Soluciones SRL use only

Step Screen/Page Description Choices or Values DiskGroups

l. Disk Group: DATA General Click the Files tab.

m. Disk Group: DATA Files Expand the ORCL folder.

Expand the DATAFILE folder.

Note that there are two system-named files associated with the XYZ tablespace.

Expand the oradata folder.

Click the xyz_01.dbf link.

n. XYZ_01.dbf: Properties Observe that the xyz_01.dbf file is an alias to a file with a system name.

Click OK.

o. Disk Group: DATA Files

6) Move the files for the XYZ tablespace to the hot region of the DATA disk group.

Step Screen/Page Description Choices or Values a. Disk Group: DATA: Files Click the General tab.

b. Disk Group: DATA: General In the Advanced Attributes section, click Edit.

c. Edit Advanced Attributes for Disk Group: DATA

Change Database Compatibility to 11.2.0.0.0

Show SQL.

d. Show SQL Notice the SET ATTRIBUTE clause.

Click Return.

e. Edit Advanced Attributes for Disk Group: DATA

Click OK.

f. Disk Group: DATA General Click the Files tab.

g. Disk Group: DATA: Files Expand the ORCL folder.

Expand the oradata folder.

Select the xyz_01.dbf file.

Click Edit File.

h. Edit File: XYZ_01.dbf In the Regions section, select the Primary Hot and Mirror Hot options.

Click Show SQL.

i. Show SQL Note that the SQL statement uses the alias name and attributes clause.

Click Return.

j. Edit File: XYZ_01.dbf Click Apply.

k. Disk Group: DATA: Files Expand the DATAFILE folder.

Select the XYZ file that is not in the HOT region.

Click Edit File.

l. Edit File:XYZ.nnn.NNNNN In the Regions section, select Primary Hot and Mirror Hot options.

Click Show SQL.

m. Show SQL Note that the SQL statement uses the system

Oracle University and Mazz Soluciones SRL use only

Step Screen/Page Description Choices or Values

name and attributes clause.

Click Return.

n. Edit File: XYZ.nnn.NNNNNN Click Apply.

o. Disk Group: DATA: Files

7) Create a template that changes the default placement of files to the hot region.

Step Screen/Page Description Choices or Values a. Disk Group: DATA: Files Click the Templates tab.

b. Disk Group: DATA: Templates Click Create.

c. Create Template Enter:

Template Name: HOT_FILES

In the Regions section, select the Primary Hot and Mirror Hot options.

Click Show SQL.

d. Show SQL Note the SQL statement attributes clause.

Click Return.

e. Create Template Click OK.

f. Disk Group: DATA: Templates Note the attributes of the HOT_FILES template compared with the DATAFILE template.

8) Add another data file to the XYZ tablespace using the template. Was the file placed in the HOT region?

Step Screen/Page Description Choices or Values a. Disk Group: DATA: Templates Click the Database tab.

b. Cluster Database:

orcl.example.com Home

Click the Server tab.

c. Cluster Database:

orcl.example.com Server

In the Storage section, click the Tablespaces link.

d. Tablespaces Select the XYZ tablespace.

Click Edit.

e. Edit Tablespace: XYZ In the Datafiles section, click Add.

f. Add Datafile Change Template to HOT_FILES.

Click Continue.

g. Edit Tablespace: XYZ Click Show SQL.

h. Show SQL Note the data file specification

"+DATA(HOT_FILES)."

Click Return.

i. Edit Tablespace: XYZ Click Apply.

Click the Database tab.

j. Cluster Database:

orcl.example.com

In the Instances section, click the

+ASM1_node_name.example.com link.

k. Automatic Storage Management:

+ASM1_node_name.example.com

Click the Disk Groups tab.

Oracle University and Mazz Soluciones SRL use only

Step Screen/Page Description Choices or Values Home

l. Automatic Storage Management Login

Enter:

Username: SYS

Password: oracle_4U Click Login.

m. Automatic Storage Management:

+ASM1_host01.example.com DiskGroups

Click the DATA disk group link.

n. Disk Group: DATA General Click the Files tab.

o. Disk Group: DATA Files Expand the ORCL folder.

Expand the DATAFILE folder.

Notice that there are three system-named files associated with the XYZ tablespace.

All have the HOT and HOT MIRROR attributes set.

9) Create a table in the XYZ tablespace.

a) In a terminal window, as the

oracle

OS user, use the following command connect to the ORCL database (the password for

SYS

is

oracle_4U

):

sqlplus sys@orcl AS SYSDBA

[oracle@host01 ~]$ . oraenv ORACLE_SID = [oracle] ? orcl

The Oracle base has been set to /u01/app/oracle

[oracle@host01 ~]$ sqlplus sys@orcl as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Wed May 2 09:27:40 2012

Copyright (c) 1982, 2011, Oracle. All rights reserved.

Enter password:oracle_4U << password is not displayed

Connected to:

Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,

Data Mining and Real Application Testing options

SQL>

b) Create a large table in the XYZ tablespace called CUST_COPY by executing the

cr_cust_copy.sql

script. This script makes a copy of the

SH.CUSTOMERS

table into the XYZ tablespace.

SQL> @/home/oracle/labs/less_13/cr_cust_copy.sql SQL>

Oracle University and Mazz Soluciones SRL use only

SQL> CREATE TABLE Cust_copy TABLESPACE XYZ AS 2 SELECT * FROM SH.CUSTOMERS;

Table created.

SQL>

10) Query the new table. Select all the rows to force some read activity with the

command:

SELECT * FROM CUST_COPY

. Use the

SET PAGESIZE 300

command to speed up the display processing.

SQL> SET PAGESIZE 300

SQL> SELECT * FROM CUST_COPY;

… /* rows removed */

100055 Andrew Clark F

1978 Married 77 Cumberland Avenue 74673 Duncan 51402

SC 52722 52790

260-755-4130 J: 190,000 - 249,999 11000

[email protected] Customer total 52772 01-JAN-98 A

55500 rows selected.

SQL>

11) View the I/O statistics by region. Use EM to view the statistics, and then repeat using ASMCMD.

a) View the I/O statistics by region with Enterprise Manager.

Step Screen/Page Description Choices or Values

a. Disk Group: DATA Files Click the Performance tab.

b. Disk Group: DATA: Performance In the Disk Group I/O Cumulative Statistics section, observe the values for Hot Reads and Hot Writes.

b) In a terminal window, on your first node as the

grid

user, set the oracle environment for the +ASM1 instance. View the I/O statistics by region using ASMCMD.

[grid@host01 ~]$ . oraenv ORACLE_SID = [grid] ? +ASM1

The Oracle base has been set to /u01/app/grid

[grid@host01 ~]$ asmcmd

Oracle University and Mazz Soluciones SRL use only

ASMCMD> iostat --io --region -G DATA

Group_Name Dsk_Name Reads Writes Cold_Reads Cold_Writes Hot_Reads Hot_Writes

DATA ASMDISK01 37273 96572 20565 56990 2 0

DATA ASMDISK02 11367 121355 2637 85453 2 0

DATA ASMDISK03 252111 106941 245150 72748 0 0

DATA ASMDISK04 21430 63937 21283 18831 1 0

ASMCMD> exit

12) Drop the tablespaces and templates created in this practice.

a) As the

oracle

OS user, connect to the orcl database, and then use the

drop_XYZ.sh

script to drop the XYZ tablespace.

[oracle@host01 ~]$ sqlplus sys@orcl as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Wed May 2 09:41:59 2012

Copyright (c) 1982, 2011, Oracle. All rights reserved.

Enter password: oracle_4U << password is not displayed

Connected to:

Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,

Data Mining and Real Application Testing options

SQL> @/home/oracle/labs/less_13/drop_XYZ.sql SQL>

SQL> DROP TABLESPACE XYZ INCLUDING CONTENTS AND DATAFILES;

Tablespace dropped.

SQL>

SQL> EXIT;

Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 –

With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,

Data Mining and Real Application Testing options [oracle@host01 ~]$

Oracle University and Mazz Soluciones SRL use only

b) As the

grid

OS user, use asmcmd to remove the HOT_FILES template.

[grid@host01 ~]$ . oraenv ORACLE_SID = [grid] ? +ASM1

The Oracle base has been set to /u01/app/grid [grid@host01 ~]$ asmcmd

ASMCMD> rmtmpl -G DATA HOT_FILES ASMCMD> exit

[grid@host01 ~]$

Oracle University and Mazz Soluciones SRL use only

Practices for Lesson 14

In this practice you will create, register, and mount an ACFS file system. In addition, you will manage ACFS snapshots.

Oracle University and Mazz Soluciones SRL use only