Manual Rollback Segements Undo to Automatic Undo

August 22, 2011 at 11:08 am (Oracle) (, , )

Steps are as follows:

shutdown immediate;
startup;
select TABLESPACE_NAME, CONTENTS, STATUS from dba_tablespaces where contents=’UNDO’;
select ‘alter rollback segment ‘ || segment_name || ‘ offline;’ from dba_rollback_segs where segment_name like ‘%RBS%’;
Execute the result of the above sql query to take the rollback segments offline
drop tablespace rbs including contents and datafiles;
drop tablespace rbs_large including contents and datafiles;
CREATE UNDO TABLESPACE UNDOTBS DATAFILE ‘/u01/db_name/undotbs01.dbf ‘ SIZE 5G REUSE AUTOEXTEND ON NEXT 500M MAXSIZE 8000M , ‘/u01/db_name/undotbs02.dbf ‘ SIZE 5G REUSE AUTOEXTEND ON NEXT 500M MAXSIZE 8000M, ‘/u01/db_name/undotbs03.dbf ‘ SIZE 5G REUSE AUTOEXTEND ON NEXT 500M MAXSIZE 8000M , ‘/u01/db_name/undotbs04.dbf ‘ SIZE 5G REUSE AUTOEXTEND ON NEXT 500M MAXSIZE 8000M ;
ALTER SYSTEM SET UNDO_TABLESPACE=UNDOTBS scope=spfile;
ALTER SYSTEM SET UNDO_MANAGEMENT=AUTO scope=spfile;
shutdown immediate;
startup;
drop tablespace undotbs1 including contents and datafiles;
shutdown immediate;
startup;

Permalink Leave a Comment

setup wireless on OEL5.4 on Acer Laptop with AR928X wireless card

October 22, 2010 at 3:08 pm (Oracle) (, , , , , )

I tried to setup wireless lan on my ACER AS5740. I installed OEL5.5 (Oracle Enterprise Linux 5.5) that comes with 2.6.18-194 kernel. Both my ethernet card and wireless lan card were detected, but I ran into the following error: DHCPDISCOVER on ath0 to 255.255.255.255 port 67 interval 19
No DHCPOFFERS received.
Later i found out that this issue was caused by the following bug in https://bugzilla.redhat.com/show_bug.cgi?id=543719

Credit goes to the gstanden (OP) whose posting helped me fix my LAN card.
Original Link: http://www.centos.org/modules/newbb/viewtopic.php?topic_id=20243&start=20
Thread Title: Re: CentOS 5.3 and Atheros AR928x – wireless network problem

Step 1:
modprobe tg3

Step 2:
check if ndiswrapper is installed. If not install it having a wired connection.
rpm -qa | grep ndis
yum install ndiswrapper

Step 3:
now go to this website http://www.atheros.cz/ to get the WindowsXP 64-bit drivers:

At the bottom of that page you find: AR928X and you want to click the second column WXP 64-bit blue checkmark. On the next page click on the button:

- – - – - – - – - – -
Download
- – - – - – - – - – -

be patient – I guess this mirror is in Czech Republic or something and it takes up to a couple minutes for the download pop-up box to appear.

The download pop-up should be indicating download of: xp3264-7.7.0.456-whql.zip

save it to your desktop or wherever you prefer.

Now open a terminal and go to where you have download this windows driver file and do:

Step 4:
unzip xp3264-7.7.0.259-whql.zip

You want to use the netathwx.inf with ndiswrapper.

NOTE: Be sure to use the netathwx.inf (with an x in the name) and NOT the netathw.inf

Step 5

While located in the directory where the netathwx.inf file is located, do the following command:

ndiswrapper -i netathwx.inf

Next:

ndiswrapper -l

You should get output from this:

netathwx : driver installed
device (168C:002A) present

depmod -a

modprobe ndiswrapper

ndiswrapper -m

Step 7

You have to create an ifcfg-wlan0 file next. But first, you can check if the card is there with this command:

iwlist scan

You should see info on wireless networks which look something like this (and be patient this can take 20-30 seconds if there are alot of networks)

Cell 01 – Address: 00:1E:E5:80:3F:01
ESSID:linksys
Protocol:IEEE 802.11g
Mode:Managed
Frequency:2.437 GHz (Channel 6)
Quality:26/100 Signal level:-79 dBm Noise level:-96 dBm
Encryption key:off
Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s; 18 Mb/s
24 Mb/s; 36 Mb/s; 54 Mb/s; 6 Mb/s; 9 Mb/s
12 Mb/s; 48 Mb/s
Extra:bcn_int=100
Extra:atim=0
Cell 02 – Address: 00:24:B2:72:36:16
ESSID:ofcnoce57
Protocol:IEEE 802.11g
Mode:Managed
Frequency:2.462 GHz (Channel 11)
Quality:84/100 Signal level:-42 dBm Noise level:-96 dBm
Encryption key:on
Bit Rates:1 Mb/s; 2 Mb/s; 5.5 Mb/s; 11 Mb/s; 6 Mb/s
12 Mb/s; 24 Mb/s; 36 Mb/s; 9 Mb/s; 18 Mb/s
48 Mb/s; 54 Mb/s
Extra:bcn_int=100
Extra:atim=0
IE: WPA Version 1
Group Cipher : TKIP
Pairwise Ciphers (1) : TKIP
Authentication Suites (1) : PSK
etc….

Step

cd /etc/sysconfig/network-scripts

create a file called ifcfg-wlan0 (using vi for example) and put this in it:

DEVICE=wlan0
BOOTPROTO=dhcp
ONBOOT=yes
METRIC=10
MII_NOT_SUPPORTED=no
WIRELESS_MODE=Managed
WIRELESS_ESSID=any

Step

service network restart

service NetworkManager start

Reboot. NOTE: You may have to add some DNS server to /etc/resolv.conf. One that almost always works is:

nameserver 4.2.2.1

Permalink Leave a Comment

Change Value Column size for show parameters in sqlplus

February 23, 2010 at 1:46 pm (Oracle) (, , , )

Ever wondered how to change the Value column size in sqlplus, here it is. The output columns for show parameter are NAME_COL_PLUS_SHOW_PARAM, VALUE_COL_PLUS_SHOW_PARAM and TYPE.

If you try using column VALUE format a60 and use show parameters spfile it would not work because the column name is VALUE_COL_PLUS_SHOW_PARAM
For example,
SQL> set linesize 150
SQL> column VALUE format a60
SQL> show parameters spfile;

NAME TYPE VALUE
———————————— ———– ——————————
spfile string /opt/oracle/products/11gr1/dbs
/spfileCTPD01.ora
SQL>

The following uses column VALUE_COL_PLUS_SHOW_PARAM format to set the size.

SQL> set linesize 150
SQL> column VALUE_COL_PLUS_SHOW_PARAM format a60
SQL> show parameters spfile;

NAME TYPE VALUE
———————————— ———– ————————————————————
spfile string /opt/oracle/products/11gr1/dbs/spfileCTPD01.ora

As displayed above, the entire row is displayed as a single line.

Permalink Leave a Comment

Rename/move all files/datafiles in a database to another location

February 3, 2010 at 3:28 pm (Oracle) (, , , )

Rename/move all files/datafiles in a database to another location

old location: /oracle/mnt02/oradata/orcl1
new location: /oracle/mnt03/oradata/orcl1

If you are not sure of the location, execute the below queries to find out the location of all files related to the database

select name from v$controlfile;
select member from v$logfile;
select name from v$datafile;
select name from v$tempfile;
select filename from v$block_change_tracking;

save this data onto a notepad.

Read more …..

Permalink Leave a Comment

Roles and Privileges

November 24, 2009 at 11:55 am (Oracle)

DBA_ROLES
This Query returns all roles defined in the database, except the PUBLIC role:

SELECT role FROM dba_roles;

DBA_ROLE_PRIVS
Roles granted to users or roles. This query returns all roles granted to user SCOTT:

SELECT granted_role FROM dba_role_privs WHERE grantee=’SCOTT’;

Read more …..

Permalink Leave a Comment

Next page »

Follow

Get every new post delivered to your Inbox.