All,
I am working on migrating users from an older system to a newer one. One of the things I am doing is setting up scripts to get rid of users who do not use the system anymore. Because much of the data is very old, and many peoples scripts look at other peoples files, this is my problem.
I have a script written to disable a user account after 90 days of inactivity, and after 120 days, it deleted the account and chowns all the data to a generic olddata account. The group remains the same. What I want to do is periodically do a find on all data in these file systems for data owned by olddata that has not been accessed in 90 days. My problem is my understanding of the find command is that when you do a find ./ -atime, it modifies the access time. Therefore, if I run a find once a week, I will never find anything that hasn't been accessed in 90 days. Does anyone have an idea to get around this?
Thanks
Will
I am working on migrating users from an older system to a newer one. One of the things I am doing is setting up scripts to get rid of users who do not use the system anymore. Because much of the data is very old, and many peoples scripts look at other peoples files, this is my problem.
I have a script written to disable a user account after 90 days of inactivity, and after 120 days, it deleted the account and chowns all the data to a generic olddata account. The group remains the same. What I want to do is periodically do a find on all data in these file systems for data owned by olddata that has not been accessed in 90 days. My problem is my understanding of the find command is that when you do a find ./ -atime, it modifies the access time. Therefore, if I run a find once a week, I will never find anything that hasn't been accessed in 90 days. Does anyone have an idea to get around this?
Thanks
Will