none
Is there batch file can move all files under the folder named Based on the source file name under sub folders named Based on the source date and time RRS feed

  • General discussion

  • before Jumping in I want to share the environment
    about the environment
     1. customers with FW (fortigate /checkpoint/juniper /....)
     2. FTP server over the internet at my side
    description
    all The FW of my customers send to my FTP server Backup Config files from the FW it self every day. nothing fancy and all working fine .
    about a 200 FW send new file every day.
    What is expected from the environment
    history of 14 restore point or more
    1. create a new folder named Based on the source file name
    2. create a sub-folder named Based on the source file date and time
    3. move all files under the folder named Based on the source file name under sub folders named Based on the source file date and time.
    4. Delete source files
    5. don't create a new folder if it's all already there but create a sub-folder named Based on the source file date and time under it
    problem
    the FW cannot change the name every time it send the new backup, nor change destination dr...
    so we are facing a tow problems
    1. to much analog work to create a new folders and move it .
    2. if by any chance we missed a file tomorrow it will be Written on it and we will lose 1 restore point
    example
    I have file name "x.conf" "y.conf.zip" "z.conf.gz" ".....".......
    I need to open a new folder named x/y/z and under it a new one named day&time and move the "x.conf" "y.conf.zip" "z.conf.gz" "....."....... under it
    so it be like
    Before:-
    date of the x.conf 1.1.19
    c:/www/root/ftp/xxx/x.conf
    date of the x.conf 2.1.19
    c:/www/root/ftp/xxx/x.conf
    date of the y.conf.zip 1.1.19
    c:/www/root/ftp/xxx/y.conf.zip
    date of the y.conf.zip 2.1.19
    c:/www/root/ftp/xxx/y.conf.zip
    date of the z.conf.gz 1.1.19
    c:/www/root/ftp/xxx/z.conf.gz
    date of the z.conf.gz 2.1.19
    c:/www/root/ftp/xxx/z.conf.gz
    After:-
    c:/Backup/x/1.1.19/x.conf
    c:/Backup/x/2.1.19/x.conf
    c:/Backup/y/1.1.19/y.conf.zip
    • Changed type Bill_Stewart Wednesday, September 4, 2019 9:30 PM
    • Moved by Bill_Stewart Wednesday, September 4, 2019 9:30 PM This is not "design solution for me" forum
    Thursday, April 25, 2019 7:14 PM

All replies