Compiled Messages: ------------------------------------------------------------ Message no. 888 Posted by Rhonda Nichols (renichols2) on Monday, November 27, 2006 11:30am Subject: Final Assignment In Step 8 of final assignment, I am confused as to what Dr. Liu is wanting. My first interpretation of this step seems too simple-- Just turning auditing all on for both users. Did anyone else use a trigger like we did in Assignment #10? -Rhonda ------------------------------------------------------------ Message no. 891[Branch from no. 888] Posted by Naziya Shaik (snaziya) on Monday, November 27, 2006 6:31pm Subject: Re: Final Assignment Hi, .....just trying audit functions.... I was trying to audit the alter,drop or create statements, when these statements are issued by 'dbsec' user. But when I view the content of dba_audit_trail..for auditing records, i get 0 rows. I am missing something in here? SQL> SHOW USER USER is "SYSTEM" SQL> AUDIT TABLE BY DBSEC; Audit succeeded. SQL> CONN DBSEC Enter password: ******** Connected. SQL> DROP TABLE TB; Table dropped. SQL> CONN SYSTEM Enter password: ******** Connected. SQL> SELECT * FROM DBA_AUDIT_TRAIL; no rows selected Why did I get 0 rows???....did I miss anything?? -------------------- Naz ------------------------------------------------------------ Message no. 893[Branch from no. 891] Posted by Naziya Shaik (snaziya) on Tuesday, November 28, 2006 12:25am Subject: Re: Final Assignment oh ya...after answering discussion questions..i understood the problem.. Thanks Naz ------------------------------------------------------------ Message no. 898[Branch from no. 891] Posted by Kelsey Pooley (kjpooley) on Tuesday, November 28, 2006 8:46pm Subject: Re: Final Assignment When I try to execute the SHUTDOWN command, I get the error that I have insufficient privilege to do so. How can I change this? Thanks, Kelsey ------------------------------------------------------------ Message no. 899[Branch from no. 898] Posted by Lakshmikar Padmaraju (lpadmaraju) on Wednesday, November 29, 2006 10:13am Subject: Re: Final Assignment Kelsey, You can shutdown your computer, and reboot, database will shutdown and start up again. This may not be right approach when you use server but in this case it works. Other wise if you have windows machine go to services and stop the Oracle processes and start again it will bounce the database. Raju. ------------------------------------------------------------ Message no. 900[Branch from no. 899] Posted by Ravinder Gaur (rgaur) on Wednesday, November 29, 2006 12:21pm Subject: Re: Final Assignment I agree with Raju -- on windows it has to be the service that handles the startup/shutdown. If you still are very enthusiastic about doing it commandline, try connecting as 'SYS as sysdba' and then issue the shutdown command -- 1) connect sys as sysdba 2) shutdown immediate. - Ravi ------------------------------------------------------------ Message no. 901[Branch from no. 900] Posted by Gnaneshwar Bukka (gbukka) on Wednesday, November 29, 2006 1:49pm Subject: Re: Final Assignment I agree with Ravi, I couldnt shutdown the database with 'system' account, but I could with 'sys' account. Gnaneshwar Bukka. ------------------------------------------------------------ Message no. 902[Branch from no. 901] Posted by Kelsey Pooley (kjpooley) on Wednesday, November 29, 2006 5:59pm Subject: Re: Final Assignment Thanks everyone...I will give it a try. Kelsey ------------------------------------------------------------ Message no. 904 Posted by Paras Pradhan (ppradhan) on Wednesday, November 29, 2006 8:18pm Subject: audit_trail Hello all, Do we need to include the settting up of audit_trail=db in our single sql script? and also when i run (as system): select os_username,username,timestamp,action_name from dba_audit_trail; D6G1SYB1\pparas SYSTEM 29-NOV-06 SELECT D6G1SYB1\pparas VPD_CLERK1 29-NOV-06 CREATE TABLE D6G1SYB1\pparas DBSEC_CLERK 29-NOV-06 CREATE TABLE It is working but why my select statement envoked from system user is being audited? is it normal? Thanks Paras. ------------------------------------------------------------ Message no. 906[Branch from no. 904] Posted by Naziya Shaik (snaziya) on Thursday, November 30, 2006 12:19pm Subject: Re: audit_trail I dont think we need to include setting up of audit_trial parameter. and about the system's select statement..i too got similar output when i did it...i was also wondering the same thing...because we wanted to audit only particular user's activities but not all of the users...so why is it included? Naz ------------------------------------------------------------ Message no. 908[Branch from no. 900] Posted by Suresh Methuku (smethuku) on Thursday, November 30, 2006 12:34pm Subject: Re: Final Assignment I gave a try from command line and i could do it. Thankyou very much ravi. ------------------------------------------------------------ Message no. 915[Branch from no. 901] Posted by Venkat Munagala (vrmunagala) on Thursday, November 30, 2006 10:13pm Subject: Re: Final Assignment I too agree with u Ravi. Even when u tried to shut down the database with system account I couldn't do it successfully. And it worked when done using the 'SYS' account. Rohit ------------------------------------------------------------ Message no. 917[Branch from no. 899] Posted by Krishnamurth Ashwini (kashwini) on Friday, December 1, 2006 4:12pm Subject: Re: Final Assignment I am also used to turning off my oracle processes using the control panel>administrative tools>services. I usually prefer to keep all the processes stopped when I'm not using Oracle. Ash ------------------------------------------------------------ Message no. 918 Posted by Naziya Shaik (snaziya) on Friday, December 1, 2006 8:32pm Subject: Final Project doubt In step 5 in Final Project, it was said to 'enable VPD_CLERK1' to access to CUSTOMER data through the view'. But what kind of access..like should we just permit tht user to select...or can he even alter the table? or should we permit him to do everything? Naz ------------------------------------------------------------ Message no. 921[Branch from no. 904] Posted by Eric Knuth (elknuth2) on Friday, December 1, 2006 10:53pm Subject: Re: audit_trail I have had problems adding two users to the sql part of the trigger script. I tried to use: if ((USER = 'xxx')||(USER = 'yyy')) but it didn't work. Any suggestions? Eric ------------------------------------------------------------ Message no. 923[Branch from no. 921] Posted by Venkat Munagala (vrmunagala) on Friday, December 1, 2006 11:14pm Subject: Re: audit_trail Hi Eric I done using IF USER = 'DBSEC_CLERK' ELSIF USER = 'VPD_CLERK1' Hope this helps Rohit ------------------------------------------------------------ Message no. 928[Branch from no. 917] Posted by Anjana Divakar (adivakar) on Saturday, December 2, 2006 12:46am Subject: Re: Final Assignment I too had a problem with the shutdown command. Thanks everyone for your help! ------------------------------------------------------------ Message no. 931[Branch from no. 921] Posted by Paras Pradhan (ppradhan) on Saturday, December 2, 2006 11:11am Subject: Re: audit_trail Not pretty though,but i did using if user = dbsec_clerk then .... if user=vpd_clerk1 then ,,, Worked well Paras. ------------------------------------------------------------ Message no. 933[Branch from no. 888] Posted by Sagun Piya (srpiya2) on Saturday, December 2, 2006 1:04pm Subject: Re: Final Assignment Thanks everyone for the suggestion Sagun ------------------------------------------------------------ Message no. 934[Branch from no. 904] Posted by Sagun Piya (srpiya2) on Saturday, December 2, 2006 1:51pm Subject: Re: audit_trail paras, My works fine. I got OS_USERNAME ------------------------------------------------------ USERNAME TIMESTAMP ACTION_NAME ------------------------------ --------- ------------- SAGUN\Sagun VPD_CLERK1 02-DEC-06 CREATE TABLE SAGUN\Sagun DBSEC_CLERK 02-DEC-06 CREATE TABLE Sagun ------------------------------------------------------------ Message no. 935[Branch from no. 921] Posted by Lakshmikar Padmaraju (lpadmaraju) on Saturday, December 2, 2006 2:39pm Subject: Re: audit_trail Eric, Oracle don't accept "||" for "OR" you can try if ((USER = 'xxx') or (USER = 'yyy')) then it will work. also you can try if USER in ('xxx','yyy') then Raju. ------------------------------------------------------------ Message no. 936[Branch from no. 918] Posted by Lakshmikar Padmaraju (lpadmaraju) on Saturday, December 2, 2006 2:49pm Subject: Re: Final Project doubt Nazia, Final project is nothing but putting Project 1 to 10 in an order. just copy and paste each project in to SQL file one by one and test it if it works then add next project. This is real test for everybody about how to combine multiple SQL scripts into one script. I did not have any problem at all, I compleated whole thing in just 25 min including testing. Best approch will be go step by step like add a project-- test-- if not ok fix it else Add next project -- continue till end; Raju. ------------------------------------------------------------ Message no. 938[Branch from no. 936] Posted by Gnaneshwar Bukka (gbukka) on Saturday, December 2, 2006 5:50pm Subject: Re: Final Project doubt Hi raju, Thank you for the suggestion. I shall try doing in your way. Gnaneshwar Bukka. ------------------------------------------------------------ Message no. 941[Branch from no. 934] Posted by Ravinder Gaur (rgaur) on Sunday, December 3, 2006 5:06pm Subject: Re: audit_trail Paras and Naz, Although I've never paid attention to this, I believe Oracle turns on SYSTEM id auditing by default when auditing is started. You'd need to explicitly turn it off (noaudit all by system) to turn that off. In regards to the question about the IF clause, here's what I typically use -- IF USER in ('DBSEC_CLERK','VPD_CLERK1) THEN ... Try to avoid putting "OR" or putting multiple IF..ELSIF statements esp. in frequently executed triggers because in bigger busier systems, it might carry its own overhead. - Ravi ------------------------------------------------------------