0

We have a samba share on an Ubuntu box that an office full of macs use. Something has happened recently and various folders now seem to have a created date of 1984 and are greyed out/inaccessible for Mac users, whereas Windows users can view these fine.

My terminal skills are extremely limited and this is rather time sensitive. I'm trying to run a command/script that will first identify all of these folders (created before 2000) within the share recursively, and then another to change these attributes. I've managed to learn that ctime is different from what I'm looking for, but perhaps to use to stat's birth time? It seems I'd have to write a script if using start?

I've not even looked at the second part yet just trying to get identifying the files/folders out of the way first.

Could anybody please point me in the right direction?

1 Answer 1

2

First, put your specific timestamp in a file with touch and then, use the find command.

The following code will search for the files and directories in the current directory, recursively.

Complete code:

touch -t 200001010000 /tmp/timestamp
find . ! -newer /tmp/timestamp

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .