using copy command and C$ admin share

Discussion in 'Scripting' started by John Grandy, Jul 12, 2005.

  1. John Grandy

    John Grandy Guest

    I am using Windows XP Pro SP2 machine (not a domain member) to Remote
    Desktop (RD) into a Windows 2003 Server Enterprise Edition ("Server1") that
    belongs to a domain.

    The RD session is established under a domain account that I have added to
    the local Administrators group of the server I am RD'ing into.

    Within the RD session, I am running a .BAT file located on Server1 that uses
    the copy command as follows:

    copy /y \\Server2\c$\Folder1\SubFolder1\*.* c:\FolderX


    This copy file command fails with an "Access Denied" error.

    Why would my RD login account not have access to the administrative C$ share
    ?

    I can make "\\Machine1\c$\Folder1\" into a shared network drive (and alter
    my .BAT file accordingly) but I want to avoid the use of shared network
    drives in automated scheduled processes.
     
    John Grandy, Jul 12, 2005
    #1
    1. Advertising

  2. John Grandy

    Roland Hall Guest

    "John Grandy" wrote in message
    news:%...
    :I am using Windows XP Pro SP2 machine (not a domain member) to Remote
    : Desktop (RD) into a Windows 2003 Server Enterprise Edition ("Server1")
    that
    : belongs to a domain.
    :
    : The RD session is established under a domain account that I have added to
    : the local Administrators group of the server I am RD'ing into.
    :
    : Within the RD session, I am running a .BAT file located on Server1 that
    uses
    : the copy command as follows:
    :
    : copy /y \\Server2\c$\Folder1\SubFolder1\*.* c:\FolderX
    :
    : This copy file command fails with an "Access Denied" error.
    :
    : Why would my RD login account not have access to the administrative C$
    share
    : ?

    Is Server2 the RD? Your command is running locally on the RD.
    If Server2 is the RD, then you don't need to use a share to access files.
    If it's not the RD, then you need to give the user account your logged in as
    access to the c$ administrative share of Server2.

    --
    Roland Hall
    /* This information is distributed in the hope that it will be useful, but
    without any warranty; without even the implied warranty of merchantability
    or fitness for a particular purpose. */
    Technet Script Center - http://www.microsoft.com/technet/scriptcenter/
    WSH 5.6 Documentation - http://msdn.microsoft.com/downloads/list/webdev.asp
    MSDN Library - http://msdn.microsoft.com/library/default.asp
     
    Roland Hall, Jul 13, 2005
    #2
    1. Advertising

  3. John Grandy

    John Grandy Guest

    Server2 is not the RD. Server1 is the RD. The batch file is located on
    Server1. The batch file contains a "copy" command which copies files from
    Server2 to Server1. The "copy" command copies files from a path such as
    "\\Server2\C$\Folder1\SubFolder1\*.*"

    The RD login account for Server1 is a member of the local Administrators
    group on Server2 ... wouldn't that give it rights on Server2's C$
    administrative share ?



    "Roland Hall" <nobody@nowhere> wrote in message
    news:eX0%...
    > "John Grandy" wrote in message
    > news:%...
    > :I am using Windows XP Pro SP2 machine (not a domain member) to Remote
    > : Desktop (RD) into a Windows 2003 Server Enterprise Edition ("Server1")
    > that
    > : belongs to a domain.
    > :
    > : The RD session is established under a domain account that I have added
    > to
    > : the local Administrators group of the server I am RD'ing into.
    > :
    > : Within the RD session, I am running a .BAT file located on Server1 that
    > uses
    > : the copy command as follows:
    > :
    > : copy /y \\Server2\c$\Folder1\SubFolder1\*.* c:\FolderX
    > :
    > : This copy file command fails with an "Access Denied" error.
    > :
    > : Why would my RD login account not have access to the administrative C$
    > share
    > : ?
    >
    > Is Server2 the RD? Your command is running locally on the RD.
    > If Server2 is the RD, then you don't need to use a share to access files.
    > If it's not the RD, then you need to give the user account your logged in
    > as
    > access to the c$ administrative share of Server2.
    >
    > --
    > Roland Hall
    > /* This information is distributed in the hope that it will be useful, but
    > without any warranty; without even the implied warranty of merchantability
    > or fitness for a particular purpose. */
    > Technet Script Center - http://www.microsoft.com/technet/scriptcenter/
    > WSH 5.6 Documentation -
    > http://msdn.microsoft.com/downloads/list/webdev.asp
    > MSDN Library - http://msdn.microsoft.com/library/default.asp
    >
    >
     
    John Grandy, Jul 13, 2005
    #3
    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. confused08

    Vista requires admin rights to copy file to network share

    confused08, Jan 12, 2008, in forum: Windows Vista Networking
    Replies:
    2
    Views:
    258
    confused08
    Jan 14, 2008
  2. Replies:
    2
    Views:
    434
    Paul Bergson [MVP-DS]
    Feb 17, 2009
  3. Blair

    Using command line to copy files

    Blair, Jul 19, 2005, in forum: Windows 64 Bit
    Replies:
    2
    Views:
    187
    Blair
    Jul 19, 2005
  4. MikeC
    Replies:
    2
    Views:
    492
    /\\/\\o\\/\\/ [MVP]
    Jan 26, 2006
  5. KWME

    Using the copy command

    KWME, Apr 16, 2007, in forum: Scripting
    Replies:
    1
    Views:
    152
    Michael Harris \(MVP\)
    Apr 17, 2007
Loading...

Share This Page