in reply to Filesystem Device Queries

You can check if your new file is on a different file system with stat's 'device number' field (first item of the return list).