Question: We need to change a static parameter value in the SPFILE used at instance startup, but we get the following error message:
SQL> alter system set audit_trail=DB scope=both; * ERROR at line 1: ORA-02095: specified initialization parameter cannot be modified
According to the definition of a static parameter, it cannot be modified during instance life, but only in the init or spfile parameter file. SCOPE=BOTH applies the modification at the instance level and in the spfile used at startup. Use the value that applies the modification in the spfile only, provided that the spfile was used at startup:
SQL> alter system set audit_trail=DB scope=spfile; System altered.
If no spfile was used at startup, you would get another error message such as:
SQL> alter system set audit_trail=DB scope=spfile; alter system set audit_trail=DB scope=spfile * ERROR at line 1: ORA-32001: write to SPFILE requested but no SPFILE specified at startup