ORA-01516: nonexistent log file, data file, or temporary file
Cause:
I drop a datafile and run into the below error. I crosschecked syntax and it is correct.
kish@PRIM>alter database datafile '/u01/oracle/product/12.1.0/db/dbs/users' offline;
alter database datafile '/u01/oracle/product/12.1.0/db/dbs/users' offline
*
ERROR at line 1:
ORA-01516: nonexistent log file, data file, or temporary file "/u01/oracle/product/12.1.0/db/dbs/users"
Workaround:
Issue can be reproduced by creating a datafile and check to see what is the behaviour. This may happen in a RAC database with an active passive cluster with switchover operation performed
alter tablespace users add datafile '/u01/oracle/product/12.1.0/db/dbs/users' size 30G;