I recently had to add secondary data files to the tempdb and a user db because the disk that the primary files were on was running low on space. After freeing up space on that disk I did a SHRINKFILES/EmptyFile followed by Alter Database/Remove File to get rid of the secondary files. Commands completed successfully and the database properties show that the secondary files are no longer referenced.
However, I have found a couple of anomalies:
1) I also checked SYSFILES and SYSFILES1 and found that on the user db there is no reference to the secondary file in SYSFILES but it is still referenced in SYSFILES1. I don't know if this is a problem or not. Is this best simply left alone?
2) In the case of tempdb the physical file was left on disk. There is no reference to the file in SYSFILES nor in SYSFILES1. To be safe I checked SYSFILES and SYSFILES1 for ALL of the databases on that server and the physical file is not referenced by any of them. Is it safe to delete this file?
Integrity checks are not reporting problems and users are able to do everything they need to.