Scripts

Discussion in 'MCSE' started by Worm, Nov 16, 2004.

  1. Worm

    Worm Guest

    I know this is not a cert question, but it is most likely a question anyone
    in the IT industry could use, so, here goes...I need a bat file that will
    delete and directory that is more than 7 days old. I need to set this up on
    a schedule so the video logs files do not fill up the drive. Any ideas?
    Thanks!
    Worm, Nov 16, 2004
    #1
    1. Advertising

  2. Worm

    Neil Guest

    incase you missed it "Worm" <*m> said in
    news:#:

    > I know this is not a cert question, but it is most likely a question
    > anyone in the IT industry could use, so, here goes...I need a bat file
    > that will delete and directory that is more than 7 days old. I need to
    > set this up on a schedule so the video logs files do not fill up the
    > drive. Any ideas? Thanks!
    >
    >
    >


    look into robocopy

    --
    Neil MCNGP #30
    "Human beings, who are almost unique in having the ability to
    learn from the experience of others, are also remarkable for
    their apparent disinclination to do so."

    Doug Adams
    Neil, Nov 17, 2004
    #2
    1. Advertising

  3. Worm

    Worm Guest

    Schweet! Thanks!

    "Neil" <guess!!!@gmail.com> wrote in message
    news:Xns95A3E99D0F5F7neilmcsegmailcom@207.46.248.16...
    > incase you missed it "Worm" <*m> said in
    > news:#:
    >
    >> I know this is not a cert question, but it is most likely a question
    >> anyone in the IT industry could use, so, here goes...I need a bat file
    >> that will delete and directory that is more than 7 days old. I need to
    >> set this up on a schedule so the video logs files do not fill up the
    >> drive. Any ideas? Thanks!
    >>
    >>
    >>

    >
    > look into robocopy
    >
    > --
    > Neil MCNGP #30
    > "Human beings, who are almost unique in having the ability to
    > learn from the experience of others, are also remarkable for
    > their apparent disinclination to do so."
    >
    > Doug Adams
    Worm, Nov 19, 2004
    #3
  4. Worm

    Kev Guest

    Scripts this will delete oldest directory in folder

    this will delete the oldest directory in the folder I use
    this for autoclean up and schedule to run daily. Just a
    simple batch file. Some of the lines may wrap, hope you
    can follow.

    begin batch
    --------------------------------------

    @Rem Purpose: Remove oldest directory in folder
    @Rem Last Author: KTC

    @Rem get bare directory list in reverse date order

    dir \\gwpp09\bckpc\ /a:d /b /o:-d>c:\1.txt


    @Rem set deldir var as read thru 1.txt last set will be
    oldest directory
    for /f %%1 in ('type c:\1.txt') do set deldir=\\gwpp09
    \bckpc\%%1


    @Rem Windows NT+ will remove directories files and subs
    rd /S /Q %deldir%

    ----------------------------
    end batch
    Kev

    >-----Original Message-----
    >I know this is not a cert question, but it is most likely

    a question anyone
    >in the IT industry could use, so, here goes...I need a

    bat file that will
    >delete and directory that is more than 7 days old. I need

    to set this up on
    >a schedule so the video logs files do not fill up the

    drive. Any ideas?
    >Thanks!
    >
    >
    >.
    >
    Kev, Nov 24, 2004
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?Smlt?=

    Wireless Login Scripts

    =?Utf-8?B?Smlt?=, Apr 26, 2005, in forum: Wireless Networking
    Replies:
    1
    Views:
    6,036
    Laura E. Hunter \(MVP\)
    Apr 26, 2005
  2. Vartkes

    Does Mozilla dislike scripts?

    Vartkes, Jan 9, 2005, in forum: Firefox
    Replies:
    5
    Views:
    442
    Vartkes
    Jan 10, 2005
  3. =?Utf-8?B?Q29yZXk=?=

    Offline folders and Login Scripts

    =?Utf-8?B?Q29yZXk=?=, Aug 18, 2004, in forum: Microsoft Certification
    Replies:
    1
    Views:
    713
    Randy & Cindy
    Aug 19, 2004
  4. Luigi Formisano

    TCL IVR Scripts in IOS

    Luigi Formisano, Jul 18, 2003, in forum: Cisco
    Replies:
    0
    Views:
    746
    Luigi Formisano
    Jul 18, 2003
  5. Walter Roberson

    Re: (newbie) PIX-501 Configuration scripts

    Walter Roberson, Feb 5, 2004, in forum: Cisco
    Replies:
    1
    Views:
    538
    Justin
    Feb 5, 2004
Loading...

Share This Page