Link to home
Create AccountLog in
Avatar of Mik Mak
Mik Mak

asked on

Command find syntax on Synology NAS

I'm trying to list the files older than 14 days on a Synology 918 NAS - using the planned scheduler, but keep getting "No such file or directory" when running the task - problem is, the device interface is in danish so I'm uncertain ie the volume names is correct ?

find /volume1/syndata1/scanner -atime +14

Open in new window


User generated image
Avatar of Bill Prew
Bill Prew

Have you tried SSH'ing in to the NAS and then doing a ls  command there using that folder path to confirm it exists and is valid?


»bp
Avatar of Mik Mak

ASKER

Hi Bill, thanks for the idea, but I'm on a windows 7 platform, so will need to get a SSH client to try that
ASKER CERTIFIED SOLUTION
Avatar of noci
noci

Link to home
membership
Create a free account to see this answer
Signing up is free and takes 30 seconds. No credit card required.
See answer
Avatar of Mik Mak

ASKER

I can't get the SSH connection to work but through the built-in scheduler i manged to get a ls -l / fired, and volume1  looks like it does exits - so far so good


drwxr-xr-x   1 root root   304 Feb 23 16:00 volume1
drwxr-xr-x   4 root root  4096 Dec 18 04:14 volumeUSB1
ok then ls -l /volme1
or boldly go for the find command..
Avatar of Mik Mak

ASKER

noci was right - it was down to the case  :)

An ls -l /volume1/Scanner gives me a list of all the files in the folder

- but  find /volume1/Scanner -atime +14 just returns nothing ?
Avatar of Mik Mak

ASKER

I think I need mtime instead
Depends what you are looking for ;-)

mtime is modified/created....
atime is last access time (if it is enabled) ... depends on volume & mount options. (and what filesystem is used).

probably you will need mtime.