Announcement

Collapse
No announcement yet.

Access Denied adding network printer. Computer Starup Script. Trusted Domain.

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Access Denied adding network printer. Computer Starup Script. Trusted Domain.

    Hi,

    We have two trsuted domain. Domain A and domain B trust fully each other. We've just installed a server A belonging to domain A. Workstations belong to domain B and I've created a Computer startup script to add network printers from server A from the other domain.

    When workstation are applying their configuration all of them get an access denied error 800A0046. The line is in this way:

    Set WshNetwork = CreateObject("WScript.Network")
    WshNetwork.AddWindowsPrinterConnection "\\serverA\PrinterQueue"

    It's likely there are a permission problem, but it's just some users trying to install a netowrk printer from a truted domain.

    I've already granted rights to Domain Users and Computer Machines from the other domain, no way.

    Thanks in advance.

  • #2
    Re: Access Denied adding network printer. Computer Starup Script. Trusted Domain.

    The error code you receive refers more often than not to a permission issue. you could rule that out by granting Allow Print permissions on the security tab of the shared printer to a specific user from the other trusted domain, then run the script under their credentials.
    The next step will depend on that outcome.

    Ta
    Caesar's cipher - 3

    ZKHQ BRX HYHQWXDOOB GHFLSKHU WKLV BRX ZLOO UHDOLVH LW ZDV D ZDVWH RI WLPH!

    SFX JNRS FC U6 MNGR

    Comment


    • #3
      Re: Access Denied adding network printer. Computer Starup Script. Trusted Domain.

      Originally posted by L4ndy View Post
      The error code you receive refers more often than not to a permission issue. you could rule that out by granting Allow Print permissions on the security tab of the shared printer to a specific user from the other trusted domain, then run the script under their credentials.
      The next step will depend on that outcome.

      Ta
      Hi,

      Thank you for the answer.

      I've already tried that. As I said in my last post, I granted permissions to Domain Machines group, as I using Computer Starup Script, and to Domain Users. The outcome is the same, access denied.

      It's strange beacuse when the user has logged to the server, I go to the path where the vbs file si located and run the file with succesful result, the printers are installed with no erros.

      Regards.

      Comment


      • #4
        Re: Access Denied adding network printer. Computer Starup Script. Trusted Domain.

        Hi,

        Looking on the Internet I've seen this:

        Your problem is that the script runs
        under the local machine account, which is unknown to the [COLOR=blue ! important][COLOR=blue ! important]network[/COLOR][/COLOR], so access
        to network resources is denied

        So I'll have to looking for an alternative.

        Our big problem is that some users are are moving around many offices and with user start script he would have installed printers from other offices.

        Thank you.

        Regards.

        Comment


        • #5
          Re: Access Denied adding network printer. Computer Starup Script. Trusted Domain.

          Hi there,

          I had the same problem with a startup script that was driving me up the walls.... I had set permissions on the share where the script resided so 'Domain Computers' could access it, but still 'Access Denied' in the logs.

          I finally found the solution by starting a command prompt with system priveleges (by starting cmd.exe through 'at') and ran:

          start \\server\share

          and a logon prompt popped up.... So instead I ran:

          \\server.ad-domain.local\share

          and voila! So, fqdn solved it for me - I hope this can help other frustrated sysadmins out there!

          Cheers,
          Örjan

          Comment


          • #6
            Re: Access Denied adding network printer. Computer Starup Script. Trusted Domain.

            Originally posted by winobob View Post
            So, fqdn solved it for me - I hope this can help other frustrated sysadmins out there!
            Good to know. Thanks for the tip
            Gareth Howells

            BSc (Hons), MBCS, MCP, MCDST, ICCE

            Any advice is given in good faith and without warranty.

            Please give reputation points if somebody has helped you.

            "For by now I could have stretched out my hand and struck you and your people with a plague that would have wiped you off the Earth." (Exodus 9:15) - I could kill you with my thumb.

            "Everything that lives and moves will be food for you." (Genesis 9:3) - For every animal you don't eat, I'm going to eat three.

            Comment


            • #7
              Re: Access Denied adding network printer. Computer Starup Script. Trusted Domain.

              Hi Örjan,

              great tip. That pointed me to the right direction. We solved this problem by creating a group policy with the following setting:

              Computer Configuration; Administrative Templates; Network/DNS Client; DNS Suffix Search List: here we added all our needed suffixes (e.g. germany.domain.local and domain.local)
              Additionally i enabled the "Primary DNS Suffix" option and added our suffix (e.g. germany.domain.local).

              Now i can run scripts from our servers (e.g. server1.germany.domain.local or server2.domain.local)

              Regards,
              Mole

              Comment

              Working...
              X