Tuesday, October 21, 2008

Printers Config File and Status check in Sun Solaris

How to Check the printers that are configured in the server (O.S. - Sun Solaris)

$ cat /etc/printers.conf|grep printer_name


To check the status of the printer

$lpstat -p printer_name

Wednesday, October 8, 2008

Oracle user account LOCKED(TIMED)

If you are on Oracle 10g and frequently facing the issue "Oracle user account LOCKED(TIMED)" with any user account then.

You need to observe the profile assigned to the particular user

select username,profile from dba_profiles where username='MYLOGIN';

If you find that the profile is DEFAULT then you have to observe one thing

SELECT resource_name, resource_type, limit FROM dba_profiles WHERE profile='DEFAULT';

COMPOSITE_LIMIT KERNEL UNLIMITED
SESSIONS_PER_USER KERNEL UNLIMITED
CPU_PER_SESSION KERNEL UNLIMITED
CPU_PER_CALL KERNEL UNLIMITED
LOGICAL_READS_PER_SESSION KERNEL UNLIMITED
LOGICAL_READS_PER_CALL KERNEL UNLIMITED
IDLE_TIME KERNEL UNLIMITED
CONNECT_TIME KERNEL UNLIMITED
PRIVATE_SGA KERNEL UNLIMITED
FAILED_LOGIN_ATTEMPTS PASSWORD 10
PASSWORD_LIFE_TIME PASSWORD UNLIMITED
PASSWORD_REUSE_TIME PASSWORD UNLIMITED
PASSWORD_REUSE_MAX PASSWORD UNLIMITED
PASSWORD_VERIFY_FUNCTION PASSWORD NULL
PASSWORD_LOCK_TIME PASSWORD UNLIMITED
PASSWORD_GRACE_TIME PASSWORD UNLIMITED

The FAILED_LOGIN_ATTEMPTS PASSWORD is 10 in the previous versions it used to be UNLIMITED.

If you like to change the profile option edit the default profile, but its not suggested for security reasons.

You can create a new profile with options of that in the default profile and change the FAILED_LOGIN_ATTEMPTS PASSWORD to UNLIMITED.

CREATE PROFILE DEFAULT_NEW LIMIT
COMPOSITE_LIMIT KERNEL UNLIMITED
SESSIONS_PER_USER KERNEL UNLIMITED
CPU_PER_SESSION KERNEL UNLIMITED
CPU_PER_CALL KERNEL UNLIMITED
LOGICAL_READS_PER_SESSION KERNEL UNLIMITED
LOGICAL_READS_PER_CALL KERNEL UNLIMITED
IDLE_TIME KERNEL UNLIMITED
CONNECT_TIME KERNEL UNLIMITED
PRIVATE_SGA KERNEL UNLIMITED
FAILED_LOGIN_ATTEMPTS PASSWORD UNLIMITED
PASSWORD_LIFE_TIME PASSWORD UNLIMITED
PASSWORD_REUSE_TIME PASSWORD UNLIMITED
PASSWORD_REUSE_MAX PASSWORD UNLIMITED
PASSWORD_VERIFY_FUNCTION PASSWORD NULL
PASSWORD_LOCK_TIME PASSWORD UNLIMITED
PASSWORD_GRACE_TIME PASSWORD UNLIMITED;

Assign this profile to the user


ALTER USER mylogin PROFILE DEFAULT_NEW;

Now you would not face the issue of user account locking frequently.




Tuesday, September 9, 2008

Monday, September 1, 2008

Site with very useful Scripts,FAQ's n many more for DBA's

http://www.orafaq.com/wiki/Scripts

Error Msg: REP – 3000 internal error starting Oracle Tool Kit.

Error: Concurrent Requests are errored out in DEV1.

Error Msg: REP – 3000 internal error starting Oracle Tool Kit.
O.S. - SunSolaris

Sol:

1. Open .xml file & set display as : dlsnbss1:5.0
2. cat .xml|grep display
3. Run Autoconfig
4. Bounce Apache Server & Concurrent Server Services.

Reference Metalink NoteId:200474.1

ERROR [CODE=2] Compiling out of date JSP

Error occurred while applying Patch 5335967(Pre-req of CPU Patch Jul’08)

11i.AOL : Error When Compiling JSP Files During Application of Patch

Error code: ERROR [CODE=2] Compiling out of date JSP
O.S. - SunSolaris

cause: _oa__html subdirectory not present at $COMMON_TOP/html/_pages.

Solution:
1. Create the _oa__html subdirectory.
2. Rerun the perl command to compile JSP file using ojspCompile.pl
Syntax:
$ perl -x / --compile –quiet (or) rerun the patch

Reference: Metalink Note:251280.1

Discoverer Server Not Coming up after clone













Step:1 Run checkdiscoverer.sh script.

Found OAD is not running.

Step:2 Run startoad.sh script and found following error message:
Run-time exception error; current exception: CORBA_NO_RESOURCES
O.S. - SunSolaris

Solution:
To implement the solution, please execute the following steps:

1. Stop/Kill all the Discoverer Process that are running.(osagent, oad, dis*)
./stopall.sh

2. Run following commands to list the Visibroker implementation files and then rename them:

$ cd /dba/u01/app/applmgr/product/8.0.6STG/vbroker/adm/impl_dir
$ ls
README README.txt impl_rep impl_rep~
$ mv impl_rep impl_rep_sav
$ mv impl_rep~ impl_rep~_sav

3.Run the Environment variable Setting Script discwb.sh found in $ORACLE_806_HOME/discwb4 directory.
./discwb4

4. Now Start the Discoverer Server using, the startup scripts in the $ORACLE_806_HOME/discwb4/util directory:

Note: DOT SPACE DOT SLASH

a. ./startosagent.sh
b. ./startoad.sh
c. ./unregistersession.sh
d. ./unregisterpreference.sh
e. ./applypreference.sh
f. ./registerpreference.sh
g. ./registersession.sh
h. ./registercollector.sh
i. ./startlocator.sh
j. ./startgatekeeper.sh(Optional)
(OR)

Note: Instead of Performing Step 3 & 4 Perform Step 5

5. ERPTST1 > cd /dba/u01/app/applmgr/common/ERPTST1/admin/scripts/ERPTST1_dlsnbss1/
dlsnbss1:/dba/u01/app/applmgr/common/ERPTST1/admin/scripts/ERPTST1_dlsnbss1

ERPTST1 > ./addisctl.sh start
ERPTST1 > ./addisctl.sh status


Reference: Metalink NoteId:394163.1