can a GPO do this for me?

djc

Distinguished
Jun 16, 2004
75
0
18,630
Archived from groups: microsoft.public.win2000.active_directory (More info?)

My network has a database front end file (just an MS Access .mdb file) that
is updated almost weekly. I have used several techniques to distribute this
file to all machines on the network with varying levels of success. I'm
interested in finding out how Active Directory GPO's can do it. Below are
several questions concerning this... some I think I know but confirmation
can't hurt. I'm just looking for some initial info here to help me decide if
I should persue this.

1) can a gpo create a folder on the client's local file system? and what if
that folder already exists?

2) The main operation I'm looking for the gpo to perform is just a file
copy. I have no .msi file. Can I do this? and what if the file already
exists on the client?

3) would I be able to set the gpo up in a way that I can set it up once and
leave it? In other words, the .mdb file I need to keep up to date on the
clients can change as often as once a week (filename remains the same of
course). Can I simply create a gpo once that points to the location of the
file to copy so that all I need to do is copy over (overwrite) that file
with the new one and do nothing else?

any info is appreciated. Thanks.
 
G

Guest

Guest
Archived from groups: microsoft.public.win2000.active_directory (More info?)

Principle: In theory a GPO applied to machine or user
can do anything -- anything that can be done through the
registry or by running a program.

Reality: There may not be a pre-existing item to
accomplish the task/outcome and you have to decide
how hard you wish to work.

"djc" <noone@nowhere.com> wrote in message
news:uPTHQ8S3EHA.1292@TK2MSFTNGP10.phx.gbl...
> My network has a database front end file (just an MS Access .mdb file)
that
> is updated almost weekly. I have used several techniques to distribute
this
> file to all machines on the network with varying levels of success. I'm
> interested in finding out how Active Directory GPO's can do it. Below are
> several questions concerning this... some I think I know but confirmation
> can't hurt. I'm just looking for some initial info here to help me decide
if
> I should persue this.

General methods to attack this problem (with a GPO):

1) Batch file that just copies the update, creating any
directories or running any programs necessary for the
installation.

2) A formal Software installation package based on an MSI
(or MSP) file.

> 1) can a gpo create a folder on the client's local file system? and what
if
> that folder already exists?

Sure. A script file can do this and GPOs can run scripts, e.g.:

cd \somepath\DB
md mydatabasesubdirectory


Well, most methods would leave the directory there if it
already existed but...

cd \somepath\DB
rd /s /q mydatabasesubdirectory
md mydatabasesubdirectory

> 2) The main operation I'm looking for the gpo to perform is just a file
> copy. I have no .msi file. Can I do this? and what if the file already
> exists on the client?

Scripts.

Can you write a script to do this?

If so, do so and test it -- then try it from a submitted batch file or
in the GPO directly. (Running it as a submitted job removes the
assumptions you may have about environment or path etc.)

Once that is working, create it withing a GPO, paste in the working
script (easier to get right this way), and assign the GPO.

> 3) would I be able to set the gpo up in a way that I can set it up once
and
> leave it?

Yes.

> In other words, the .mdb file I need to keep up to date on the
> clients can change as often as once a week (filename remains the same of
> course).

Actually it could change as often as you wish (depending on
size and performance) and it could just work.

xcopy /d \\server\share\database.mdb c:\data\directory

/d will update based on date and time stamps.

One warning about MDB files and Access though: everytime they
are opened they change the last used time on the file and so in effect
it is a "new" version.

> Can I simply create a gpo once that points to the location of the
> file to copy so that all I need to do is copy over (overwrite) that file
> with the new one and do nothing else?

Watch out for permissions, paths etc, but yes. Probably best
to link this to the COMPUTER container if you can guarantee
the computer will boot, as the STARTUP script.

Also consider if this makes more sense as a RECURRING
task -- run on a schedule (e.g., at night) even if the machines
don't reboot and the user stays logged on????
 

djc

Distinguished
Jun 16, 2004
75
0
18,630
Archived from groups: microsoft.public.win2000.active_directory (More info?)

Thanks for the reply. I appreciate all the input. I accidentally left out
one key point. That is that a decision needs to be made as to whether a new
file is available or not... If there is a new file, then copy it. I have
been accomplishing this via a login script. The login script is a WSH
vbscript that actually opens the local database file to check for a version
number, then opens the database file on the server to compare the version
numbers... if the server contains a higher version number then it updates.
It works very well but I am interested in finding out how GPO's can to
this... I spent a lot of time creating this script (it does several things
including seting up necessary directory, shortcuts, and some registry
modifications, if they are not present), and thats one of the reasons I was
wondering if AD's GPO's may have been a better choice to begin with. Plus I
just like to learn and explore other methods.

It seems from your suggestions that even with GPO's, my own script would be
required. correct? I guess what I was looking for the GPO to do was provide
a way to just assign a file to client machines. To ensure each machine had
this file. And to somehow know when to re-copy, ie, new version present.
Maybe I could create my own msi for this? but even doing that what are my
options with GPOs with regard to knowing 'when' to copy the new file...
still need my script? or would I just leave out any decision making
functionality and simply enable/disable a GPO with a simpler script, or
package, when necessary? hmmm... dunno. Another reason for wondering about
this is I want to know if what I had done is way overkill and if GPO's could
have provided a much simpler, more elegant solution.

thanks again... any other input is welcome.

"Herb Martin" <news@LearnQuick.com> wrote in message
news:OwTOAcT3EHA.2592@TK2MSFTNGP09.phx.gbl...
>
> Principle: In theory a GPO applied to machine or user
> can do anything -- anything that can be done through the
> registry or by running a program.
>
> Reality: There may not be a pre-existing item to
> accomplish the task/outcome and you have to decide
> how hard you wish to work.
>
> "djc" <noone@nowhere.com> wrote in message
> news:uPTHQ8S3EHA.1292@TK2MSFTNGP10.phx.gbl...
> > My network has a database front end file (just an MS Access .mdb file)
> that
> > is updated almost weekly. I have used several techniques to distribute
> this
> > file to all machines on the network with varying levels of success. I'm
> > interested in finding out how Active Directory GPO's can do it. Below
are
> > several questions concerning this... some I think I know but
confirmation
> > can't hurt. I'm just looking for some initial info here to help me
decide
> if
> > I should persue this.
>
> General methods to attack this problem (with a GPO):
>
> 1) Batch file that just copies the update, creating any
> directories or running any programs necessary for the
> installation.
>
> 2) A formal Software installation package based on an MSI
> (or MSP) file.
>
> > 1) can a gpo create a folder on the client's local file system? and what
> if
> > that folder already exists?
>
> Sure. A script file can do this and GPOs can run scripts, e.g.:
>
> cd \somepath\DB
> md mydatabasesubdirectory
>
>
> Well, most methods would leave the directory there if it
> already existed but...
>
> cd \somepath\DB
> rd /s /q mydatabasesubdirectory
> md mydatabasesubdirectory
>
> > 2) The main operation I'm looking for the gpo to perform is just a file
> > copy. I have no .msi file. Can I do this? and what if the file already
> > exists on the client?
>
> Scripts.
>
> Can you write a script to do this?
>
> If so, do so and test it -- then try it from a submitted batch file or
> in the GPO directly. (Running it as a submitted job removes the
> assumptions you may have about environment or path etc.)
>
> Once that is working, create it withing a GPO, paste in the working
> script (easier to get right this way), and assign the GPO.
>
> > 3) would I be able to set the gpo up in a way that I can set it up once
> and
> > leave it?
>
> Yes.
>
> > In other words, the .mdb file I need to keep up to date on the
> > clients can change as often as once a week (filename remains the same of
> > course).
>
> Actually it could change as often as you wish (depending on
> size and performance) and it could just work.
>
> xcopy /d \\server\share\database.mdb c:\data\directory
>
> /d will update based on date and time stamps.
>
> One warning about MDB files and Access though: everytime they
> are opened they change the last used time on the file and so in effect
> it is a "new" version.
>
> > Can I simply create a gpo once that points to the location of the
> > file to copy so that all I need to do is copy over (overwrite) that file
> > with the new one and do nothing else?
>
> Watch out for permissions, paths etc, but yes. Probably best
> to link this to the COMPUTER container if you can guarantee
> the computer will boot, as the STARTUP script.
>
> Also consider if this makes more sense as a RECURRING
> task -- run on a schedule (e.g., at night) even if the machines
> don't reboot and the user stays logged on????
>
>
 
G

Guest

Guest
Archived from groups: microsoft.public.win2000.active_directory (More info?)

"djc" <noone@nowhere.com> wrote in message
news:#6VfliU3EHA.3316@tk2msftngp13.phx.gbl...
> Thanks for the reply. I appreciate all the input. I accidentally left out
> one key point. That is that a decision needs to be made as to whether a
new
> file is available or not... If there is a new file, then copy it. I have
> been accomplishing this via a login script.

Well, ok, but I answered that anyway: xcopy /d

XCOPY /d only copies files if they have changed or don't exist
on the destination.

> The login script is a WSH
> vbscript that actually opens the local database file to check for a
version
> number, then opens the database file on the server to compare the version
> numbers... if the server contains a higher version number then it updates.

Ok, so as long as you can script it this work.

You could also use various "flag" file tricks and
such but what you have seems to work.

> It works very well but I am interested in finding out how GPO's can to
> this...

By running the script as the STARTUP script would be the
obvious way.

> I spent a lot of time creating this script (it does several things
> including seting up necessary directory, shortcuts, and some registry
> modifications, if they are not present), and thats one of the reasons I
was
> wondering if AD's GPO's may have been a better choice to begin with. Plus
I
> just like to learn and explore other methods.

Probably not (except by running the script.)


> It seems from your suggestions that even with GPO's, my own script would
be
> required. correct?

Yes, as part of the GPO.

> I guess what I was looking for the GPO to do was provide
> a way to just assign a file to client machines. To ensure each machine had
> this file. And to somehow know when to re-copy, ie, new version present.

MSI -- but you would have to create and assign the
MSI packages, and updates to the GPO on each change.

> Maybe I could create my own msi for this? but even doing that what are my
> options with GPOs with regard to knowing 'when' to copy the new file...
> still need my script? or would I just leave out any decision making
> functionality and simply enable/disable a GPO with a simpler script, or
> package, when necessary? hmmm... dunno.

Yes, but MSI-GPOs might be extremely tedious to create each
week and offer an overly complex solution.

The script is basically the best way -- from what you have described.

> Another reason for wondering about
> this is I want to know if what I had done is way overkill and if GPO's
could
> have provided a much simpler, more elegant solution.

Probably would be the other way around.

--
Herb Martin


>
> thanks again... any other input is welcome.
>
> "Herb Martin" <news@LearnQuick.com> wrote in message
> news:OwTOAcT3EHA.2592@TK2MSFTNGP09.phx.gbl...
> >
> > Principle: In theory a GPO applied to machine or user
> > can do anything -- anything that can be done through the
> > registry or by running a program.
> >
> > Reality: There may not be a pre-existing item to
> > accomplish the task/outcome and you have to decide
> > how hard you wish to work.
> >
> > "djc" <noone@nowhere.com> wrote in message
> > news:uPTHQ8S3EHA.1292@TK2MSFTNGP10.phx.gbl...
> > > My network has a database front end file (just an MS Access .mdb file)
> > that
> > > is updated almost weekly. I have used several techniques to distribute
> > this
> > > file to all machines on the network with varying levels of success.
I'm
> > > interested in finding out how Active Directory GPO's can do it. Below
> are
> > > several questions concerning this... some I think I know but
> confirmation
> > > can't hurt. I'm just looking for some initial info here to help me
> decide
> > if
> > > I should persue this.
> >
> > General methods to attack this problem (with a GPO):
> >
> > 1) Batch file that just copies the update, creating any
> > directories or running any programs necessary for the
> > installation.
> >
> > 2) A formal Software installation package based on an MSI
> > (or MSP) file.
> >
> > > 1) can a gpo create a folder on the client's local file system? and
what
> > if
> > > that folder already exists?
> >
> > Sure. A script file can do this and GPOs can run scripts, e.g.:
> >
> > cd \somepath\DB
> > md mydatabasesubdirectory
> >
> >
> > Well, most methods would leave the directory there if it
> > already existed but...
> >
> > cd \somepath\DB
> > rd /s /q mydatabasesubdirectory
> > md mydatabasesubdirectory
> >
> > > 2) The main operation I'm looking for the gpo to perform is just a
file
> > > copy. I have no .msi file. Can I do this? and what if the file already
> > > exists on the client?
> >
> > Scripts.
> >
> > Can you write a script to do this?
> >
> > If so, do so and test it -- then try it from a submitted batch file or
> > in the GPO directly. (Running it as a submitted job removes the
> > assumptions you may have about environment or path etc.)
> >
> > Once that is working, create it withing a GPO, paste in the working
> > script (easier to get right this way), and assign the GPO.
> >
> > > 3) would I be able to set the gpo up in a way that I can set it up
once
> > and
> > > leave it?
> >
> > Yes.
> >
> > > In other words, the .mdb file I need to keep up to date on the
> > > clients can change as often as once a week (filename remains the same
of
> > > course).
> >
> > Actually it could change as often as you wish (depending on
> > size and performance) and it could just work.
> >
> > xcopy /d \\server\share\database.mdb c:\data\directory
> >
> > /d will update based on date and time stamps.
> >
> > One warning about MDB files and Access though: everytime they
> > are opened they change the last used time on the file and so in effect
> > it is a "new" version.
> >
> > > Can I simply create a gpo once that points to the location of the
> > > file to copy so that all I need to do is copy over (overwrite) that
file
> > > with the new one and do nothing else?
> >
> > Watch out for permissions, paths etc, but yes. Probably best
> > to link this to the COMPUTER container if you can guarantee
> > the computer will boot, as the STARTUP script.
> >
> > Also consider if this makes more sense as a RECURRING
> > task -- run on a schedule (e.g., at night) even if the machines
> > don't reboot and the user stays logged on????
> >
> >
>
>
 

djc

Distinguished
Jun 16, 2004
75
0
18,630
Archived from groups: microsoft.public.win2000.active_directory (More info?)

Thanks Herb. I appreciate your input.

"Herb Martin" <news@LearnQuick.com> wrote in message
news:Os76emd3EHA.1204@TK2MSFTNGP10.phx.gbl...
> "djc" <noone@nowhere.com> wrote in message
> news:#6VfliU3EHA.3316@tk2msftngp13.phx.gbl...
> > Thanks for the reply. I appreciate all the input. I accidentally left
out
> > one key point. That is that a decision needs to be made as to whether a
> new
> > file is available or not... If there is a new file, then copy it. I have
> > been accomplishing this via a login script.
>
> Well, ok, but I answered that anyway: xcopy /d
>
> XCOPY /d only copies files if they have changed or don't exist
> on the destination.
>
> > The login script is a WSH
> > vbscript that actually opens the local database file to check for a
> version
> > number, then opens the database file on the server to compare the
version
> > numbers... if the server contains a higher version number then it
updates.
>
> Ok, so as long as you can script it this work.
>
> You could also use various "flag" file tricks and
> such but what you have seems to work.
>
> > It works very well but I am interested in finding out how GPO's can to
> > this...
>
> By running the script as the STARTUP script would be the
> obvious way.
>
> > I spent a lot of time creating this script (it does several things
> > including seting up necessary directory, shortcuts, and some registry
> > modifications, if they are not present), and thats one of the reasons I
> was
> > wondering if AD's GPO's may have been a better choice to begin with.
Plus
> I
> > just like to learn and explore other methods.
>
> Probably not (except by running the script.)
>
>
> > It seems from your suggestions that even with GPO's, my own script would
> be
> > required. correct?
>
> Yes, as part of the GPO.
>
> > I guess what I was looking for the GPO to do was provide
> > a way to just assign a file to client machines. To ensure each machine
had
> > this file. And to somehow know when to re-copy, ie, new version present.
>
> MSI -- but you would have to create and assign the
> MSI packages, and updates to the GPO on each change.
>
> > Maybe I could create my own msi for this? but even doing that what are
my
> > options with GPOs with regard to knowing 'when' to copy the new file...
> > still need my script? or would I just leave out any decision making
> > functionality and simply enable/disable a GPO with a simpler script, or
> > package, when necessary? hmmm... dunno.
>
> Yes, but MSI-GPOs might be extremely tedious to create each
> week and offer an overly complex solution.
>
> The script is basically the best way -- from what you have described.
>
> > Another reason for wondering about
> > this is I want to know if what I had done is way overkill and if GPO's
> could
> > have provided a much simpler, more elegant solution.
>
> Probably would be the other way around.
>
> --
> Herb Martin
>
>
> >
> > thanks again... any other input is welcome.
> >
> > "Herb Martin" <news@LearnQuick.com> wrote in message
> > news:OwTOAcT3EHA.2592@TK2MSFTNGP09.phx.gbl...
> > >
> > > Principle: In theory a GPO applied to machine or user
> > > can do anything -- anything that can be done through the
> > > registry or by running a program.
> > >
> > > Reality: There may not be a pre-existing item to
> > > accomplish the task/outcome and you have to decide
> > > how hard you wish to work.
> > >
> > > "djc" <noone@nowhere.com> wrote in message
> > > news:uPTHQ8S3EHA.1292@TK2MSFTNGP10.phx.gbl...
> > > > My network has a database front end file (just an MS Access .mdb
file)
> > > that
> > > > is updated almost weekly. I have used several techniques to
distribute
> > > this
> > > > file to all machines on the network with varying levels of success.
> I'm
> > > > interested in finding out how Active Directory GPO's can do it.
Below
> > are
> > > > several questions concerning this... some I think I know but
> > confirmation
> > > > can't hurt. I'm just looking for some initial info here to help me
> > decide
> > > if
> > > > I should persue this.
> > >
> > > General methods to attack this problem (with a GPO):
> > >
> > > 1) Batch file that just copies the update, creating any
> > > directories or running any programs necessary for the
> > > installation.
> > >
> > > 2) A formal Software installation package based on an MSI
> > > (or MSP) file.
> > >
> > > > 1) can a gpo create a folder on the client's local file system? and
> what
> > > if
> > > > that folder already exists?
> > >
> > > Sure. A script file can do this and GPOs can run scripts, e.g.:
> > >
> > > cd \somepath\DB
> > > md mydatabasesubdirectory
> > >
> > >
> > > Well, most methods would leave the directory there if it
> > > already existed but...
> > >
> > > cd \somepath\DB
> > > rd /s /q mydatabasesubdirectory
> > > md mydatabasesubdirectory
> > >
> > > > 2) The main operation I'm looking for the gpo to perform is just a
> file
> > > > copy. I have no .msi file. Can I do this? and what if the file
already
> > > > exists on the client?
> > >
> > > Scripts.
> > >
> > > Can you write a script to do this?
> > >
> > > If so, do so and test it -- then try it from a submitted batch file or
> > > in the GPO directly. (Running it as a submitted job removes the
> > > assumptions you may have about environment or path etc.)
> > >
> > > Once that is working, create it withing a GPO, paste in the working
> > > script (easier to get right this way), and assign the GPO.
> > >
> > > > 3) would I be able to set the gpo up in a way that I can set it up
> once
> > > and
> > > > leave it?
> > >
> > > Yes.
> > >
> > > > In other words, the .mdb file I need to keep up to date on the
> > > > clients can change as often as once a week (filename remains the
same
> of
> > > > course).
> > >
> > > Actually it could change as often as you wish (depending on
> > > size and performance) and it could just work.
> > >
> > > xcopy /d \\server\share\database.mdb c:\data\directory
> > >
> > > /d will update based on date and time stamps.
> > >
> > > One warning about MDB files and Access though: everytime they
> > > are opened they change the last used time on the file and so in effect
> > > it is a "new" version.
> > >
> > > > Can I simply create a gpo once that points to the location of the
> > > > file to copy so that all I need to do is copy over (overwrite) that
> file
> > > > with the new one and do nothing else?
> > >
> > > Watch out for permissions, paths etc, but yes. Probably best
> > > to link this to the COMPUTER container if you can guarantee
> > > the computer will boot, as the STARTUP script.
> > >
> > > Also consider if this makes more sense as a RECURRING
> > > task -- run on a schedule (e.g., at night) even if the machines
> > > don't reboot and the user stays logged on????
> > >
> > >
> >
> >
>
>