none
cannot delete network printer

    Question

  • I've been trying to remove a connection to a network printer (which I believe was installed via domain group policy) and am unable to delete the printer. I have local and domain admin rights.

    1) Right clicking to delete printer (in control panel) results in "Printer connection cannot be removed. Access denied".
    2) rundll32 printui.dll,PrintUIEntry /dn /n\\print-server-name\printer-name fails with - "Printer connection cannot be removed. Access denied".
    3) rundll32 printui.dll,PrintUIEntry /gd /n\\print-server-name\printer-name fails with - "Unable to delete the per machine printer connection. Make sure you have typed the name correctly, and that the printer is connected to the network".

    I can however add a network printer manually and delete it manually. My troubles are only with printers pushed out via group policy. 

    The reason I want to do this is because I suspect the print driver is corrupt (either on the workstation or the print server) and want to recreate printer after deleting it and it's drivers (can't remove driver without first deleting the printer).

    I suppose I could simply stop the print spooler and clean out the entire contents of C:\Windows\System32\spool\drivers\w32x86\3\ but I don't quite dare do that.

    Any suggestions?  

    Thursday, August 13, 2009 6:58 PM

Answers

  • Using GP Preferences instead of GP Policies resolved our issues!

    We removed the printers from the "Deployed Printers" setting and used the User Configuration > Preferences > Control Panel Settings > "Printers" setting

    In response to my original resolution to this problem in our environment... We started noticing issues with Win7 machines either not getting the printers specified in the policy, or getting them, but they not being functional ("Access Denied")... The resolution we came up with is to apply the printers via the "User Configuration > Policies > Windows Settings > Printer Connections" setting in GP... Then for the labs where we need to specify a default printer we just create an "Update" task at "User Configuration > Preferences > Control Panel Settings > Printers"...

    Seems to be working well in our environment now.

    Justin

    Wednesday, October 12, 2011 5:21 PM

All replies

  • Hi,

    the print queues are listed under the following registry key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Printers .If you delete the registry key for a specific print queue it will disappear from printer and faxes.After that you will have the opptortunity to remove the driver.

    The second method is,you can change the driver of this print queue over the print queue properties.Switch the print queue in example from lasejet 4 to laser jet 5500 over the print queue properties > Advanced Tab.

    The print queue will release the open handels to this driver.After that you will able o remove the driver over the print server properties.In some situation a print spooler restart can be necessary prior removing the driver.

    Regards,
    Cengiz Kuskaya

    EDU
    • Edited by Cengiz Kuskaya Friday, August 14, 2009 9:23 AM
    • Proposed as answer by CCraddock Tuesday, October 01, 2013 6:28 PM
    Friday, August 14, 2009 9:09 AM
  • I looked at the registry location and none of the network printers are showing up under the printers subkey. It apears only manually installed printers are shown here. Can your suggest another location to look?

    Thanks for the help:-)

    Thursday, August 20, 2009 6:50 PM
  • Hi,

    as far as I know the current users connections are stored under the below keys.Remove all the mapped queues

    HKEY_CURRENT_USER\Printers\Connections
                                                  DevModePerUser
                                                  DevModes2

    Regards,
    Cengiz Kuskaya

    EDU
    Thursday, August 20, 2009 8:24 PM
  • I backed up and removed the mapped queues as suggested (everything under the Connections subkey) However, still no luck deleting the printer (or it's driver). The error remains the same "access denied".

    Its looking like the only way to remove the driver may be to stop the print spooler and remove the contents of C:\Windows\System32\spool\drivers\w32x86\3\

    While that would surely remove the driver and force a reinstall from the server (or perhaps the local driver package cache), it is curious why I am unable to delete the instance of the printer as seen in the control panel.
    Monday, August 24, 2009 6:05 PM
  • Hi,

    if you are getting an "access denied" and if you are in a domain environment you should check your default domain policies.Removing the driver DLL's from the C:\Windows\System32\spool\drivers\w32x86\3\ folder is not a recommended method.

    If you exactly know what every DLL does of course you can surely remove the dll's from the drivers folder.Please let us know if you in a domain environment ?

    If so I will prepare for you a list of the printer driver related policies.

    Regards,
    Cengiz Kuskaya




    EDU
    Monday, August 24, 2009 7:06 PM
  • I'm having the same exact issue.

    Using the deploy with group policy option from the print server I have a bunch of GPOs which deploy the printers based on computers on our Domain.  There were a few instances that I accidentally left the scope of the GPO to 'Authenticated Users' and now that I've corrected it to a specific security group of computers the PCs that pulled the policy when it was configured to Authenticated Users wont allow the deletion of the print queues.
    Thursday, August 27, 2009 4:02 AM
  • Ok thanks for the suggestion..I will look into our default domain policies.

    Yes, this issue is occuring in a domain environment (Win2k3 servers with Vista Enterprise clients).
    Thursday, August 27, 2009 1:47 PM
  • I am having the same issue with network printers deployed via group policy. On the client machines, all printers can be deleted accept for these. Access Denied. There should be no reason I have to modify registry settings or drivers. I just want to be able to remove and reconnect printers as normal in Devices and Printers. Has anyone found a solution to this?

    Thanks.

    Friday, July 09, 2010 12:39 PM
  • I have the same problem; on windows 7 client the network deployment works fine, but i'm unable to delete the added printers !!

    Regards.

    Ennio

    Tuesday, September 28, 2010 10:48 AM
  • Hi,

     

    basically delete the printer from the registry key. The printers are listed under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Printers .

     

    Regards,

    Cengiz Kuskaya

     

     


    http://www.PrintProcessor.com
    Tuesday, September 28, 2010 8:59 PM
  • I have exactly the same problem. I would like  to fix issues with network printer deployed by the group policy. I wanted to delete it and reconnect. I can't do it as a local administrator.

    Cengiz, there are NO network deployed printer under HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Printers. Only local printers are there, we are talking about the network ones.

     

    Does anybody found the way how to delete NETWORK printer DEPLOYED BY THE GROUP POLICY ???????

    Tuesday, November 02, 2010 2:24 PM
  • If you are using Server 2008, you can deploy a GPO Preference to remove the problem printers.
    Tuesday, November 02, 2010 7:23 PM
  • I guess you are talking about the case when you need to delete it once and forever What if you need just to reconnect printer in case of problems?
    Thursday, November 04, 2010 4:14 PM
  • Yesterday, I had the same problem but i suggest another solution which i done its.

    On the DomainCoroller " Start>Admin Tools>ADSI edit>Choose your "DomainName">CN= "Your Computer" and choose your cmputer whiche install printer in its> try to delete specific printer file.

    I did it yesterday and all right.

      Best regards,

     

    Mena L. Yousif

       IT Department.

    Thursday, November 11, 2010 10:15 AM
  • Remove network printers from Windows using registry

    Step 1: Click on Start, Run and then type in regedit and press Enter. This will open the registry editor.

    regedit

    Step 2: Navigate to the following key in the registry

        HKEY_CURRENT_USER – Printers – Connections

    Here you should now see a list of all network printers with the server name first, then a comma, and then the name of the actual printer.

    remove printer from registry

    Go ahead and click on the printer in the left menu and press the Delete button or right-click and choose Delete. But that’s not all! You have to delete the printer from one more location in the registry:

        HKEY_LOCAL_MACHINE – SYSTEM – CurrentControlSet – Control – Print – Providers – LanMan Print Services – Servers – Printers

    Now under the Printers key, you should be able to expand it and see the name of the print server that actually hosts the printer you want to delete. Go ahead and expand the print server key and delete the printer from the list.

    cannot delete printer

    Now close the registry editor and reboot your computer. The undeletable network printer should now be gone.
    Printer Support
    • Proposed as answer by Sickbh0y Monday, October 03, 2011 12:30 PM
    Tuesday, December 14, 2010 4:37 AM
  • 1) Michelsmith's solution is for Windows Xp only

    2) For Windows 7 and printers deployed by Group Policy the only solution I found is to remove user/computer from the scope of this policy. If everything is going good it works.

    Tuesday, December 14, 2010 5:05 PM
  • We experienced this same problem in our lab environment. In XP days we used to apply the printers to labs via the "Deployed Printers" setting in Group Policy (Computer Configuration > Policies > Windows Settings > Deployed Printers). Worked great for XP. Once labs were migrated to Windows 7, we could no longer remove the printers (until disabling the policy).

    Using GP Preferences instead of GP Policies resolved our issues!

    We removed the printers from the "Deployed Printers" setting and used the User Configuration > Preferences > Control Panel Settings > "Printers" setting (http://screencast.com/t/Wq2MIQMh ). The Printers User Preference even allowed us to set the default printer via GP, which is a huge plus for us.

    Justin

    • Edited by Justin007 Tuesday, January 04, 2011 6:13 PM fixed url
    • Proposed as answer by Justin007 Tuesday, January 04, 2011 6:16 PM
    • Unproposed as answer by Justin007 Wednesday, October 12, 2011 5:21 PM
    Tuesday, January 04, 2011 6:02 PM
  • Cengiz Kuskaya's first method worked for me.  Had to stop the Print Spooler service to make the printer completely delete.
    Tuesday, March 01, 2011 7:06 PM
  • I had a similar problem on Windows Server 2008. I logged in with administrative privileges, clicked Printers in Control Panel and when I wanted to remove a NETWORK printer, it said "Printer cannot be removed. Access denied." I right-clicked it, then clicked security tab and noticed that Administrator did not have a right to manage printers, neither to change permissions. Furthermore, the owner of the printer was SYSTEM. I changed the ownership to Administrator, gave manage printers permission to him, logged out from server, logged back in. Then I was able to remove the printer.
    Friday, June 24, 2011 7:34 AM
  • Hi beemobile4,

    yes thats right. This is a design change in windows server 2008. In older versions of windows the print queue owner was administrator. In windows 2008 and later the owner of the print queue is SYSTEM.

    If you want to programatically change the owner of all queues to administrator you can do it with setprinter.exe but you have to run the tool under the system account.

    This can be done with psexec.exe.

     

    With kind regards,

    Cengiz Kuskaya


    Friday, June 24, 2011 8:09 AM
  • This sorted the problem out for me... cheers!
    Monday, October 03, 2011 12:31 PM
  • Using GP Preferences instead of GP Policies resolved our issues!

    We removed the printers from the "Deployed Printers" setting and used the User Configuration > Preferences > Control Panel Settings > "Printers" setting

    In response to my original resolution to this problem in our environment... We started noticing issues with Win7 machines either not getting the printers specified in the policy, or getting them, but they not being functional ("Access Denied")... The resolution we came up with is to apply the printers via the "User Configuration > Policies > Windows Settings > Printer Connections" setting in GP... Then for the labs where we need to specify a default printer we just create an "Update" task at "User Configuration > Preferences > Control Panel Settings > Printers"...

    Seems to be working well in our environment now.

    Justin

    Wednesday, October 12, 2011 5:21 PM
  • I did delete the apropriate reg key for that printer in

    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Providers\LanMan Print Services\Servers\Printers
    and
    HKEY_CURRENT_USER\Printers\Connections
    and
    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Printers

    and teh restarted teh spool service. Fixed it for me 

    Sunday, November 06, 2011 10:00 AM
  • We had problems with remove network printers from computers in my company when is GPO set for machine.

    I find network printers in HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Print\Connections

    There is CLSID, every class is network printer, so when u delete it and restart print spooler network printers are gone.

     


    Network admin
    Friday, February 03, 2012 9:07 AM
  • How about the command GPUPDATE /FORCE - the force the policys refresh...
    Just an idea.
    Thursday, March 15, 2012 9:05 PM
  • We had problems with remove network printers from computers in my company when is GPO set for machine.

    I find network printers in HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Print\Connections

    There is CLSID, every class is network printer, so when u delete it and restart print spooler network printers are gone.


    Network admin

    This worked perfectly!

    In my situation, we retired an old Windows 2008 Print Server that was pushing its connections through GPO. The new print server pushes the same printers, so we had to remove the old GPO and apply the new one at the same time. Worked great for 130+ Win7 computers, failed on one. The user ended up with the new printers, but still had offline connections to all printers on the old print server showing in Devices and Printers.

    Deleted the CLSID's as directed above, restarted the print spooler service and performed the happy dance. Nagging problem solved!

    Thank you Jack.

    Cheers!
    Kevin

    Thursday, June 07, 2012 10:26 PM
  • To delete a printer in Win2008 that won't allow an admin to do it as it's owned by System, go to Start | Run and type in printmanagement.msc

    It will allow you to modify the permissions on the printer - set yourself up to manage the printer and then after applying, you can delete it.  Seriously, does it get any less intuitive??

    As for the earlier advise to psexec/setprinter, we couldn't get that advice to work.  Fortunately, the solution found contains none of the risks inherent with psexec.

    • Proposed as answer by ibcarolek Wednesday, October 03, 2012 7:26 PM
    Wednesday, October 03, 2012 7:26 PM
  • Hi,

    you can do it as described on my blog.

    http://www.kuskaya.info/2011/11/26/how-to-distribute-or-change-the-print-queue-objects-security-descriptor-in-windows-server-2008-r2-automation-for-administrators/

    First you have to change the owner of a print queue manually. Add or remove it to groups you wish. Read the security descriptor of the print queue like the example in my article and dstribute it to all print queues on a specific server.

    I have done this several times without any problem. If you experience any problems please tell us exactly where you experince the problem and if possible paste the error code.

    Info Level 3 in setprinter.exe will do this.

    Best regards,

    Cengiz Kuskaya



    Wednesday, October 03, 2012 7:43 PM
  • howdy,

    here is my situation:

    we originally deployed printers with normal group policy. (the strict version that gives you access denied when you attempt to delete a pushed out printer) i then switched us to GPP which is much more powerful. i have the old policies disabled but one of the old printers is still mapped to clients that had the original policy. i made a GPP deployment that will delete the old printers. it worked for most of them but the one still hangs around and wont delete. i have the setting for "run in logged on users security context" checked under the printer properties in GPP. i have also tried with the setting unchecked.

    i have double and triple checked that there are no old policies affecting my test users. i don't understand why the  old GP printers were not removed once the original GP was deactivated. so now i have a "stuck" printer connection on a bunch of clients that i cant remove remotely? i understand that there are lots of things in win 7 that are owned by the SYSTEM acct. so is that the issue at hand here? do i not have local permission to remove the printer connection? if not then why would some of the printers get deleted with the GPP and one still return an access denied? it doesn't make sense to me. would removing the printer on the server do anything to affect the stuck client printer connection?

    i really want to avoid doing anything on each local PC if i can.

    Thursday, October 18, 2012 6:01 PM
  • I developed a VBS script to replace the permissions on printers using the setprinter.exe as mentioned in Cengiz Kuskaya's blog. If you want the code, I posted it here:  "How to replace inheritable server permissions on printers" (http://social.technet.microsoft.com/Forums/en-US/winserverprint/thread/91067fd7-d910-4861-ba42-382425af5572).
    Friday, January 18, 2013 7:05 PM
  • hey   thank you your Path are right effectively for solve problem...

    thanking

    Shrikrushna 

    Friday, September 20, 2013 6:34 AM
  • Helpful thread. I replaced a server in the same network but put it in a new domain. A Windows 7 desktop joined to the new domain was hammering the old server with connection attempts that no longer worked (as I saw in the old machine's Security event log). Using Sysinternals Process Explorer, I did a Find on the old machine name and determined that the spoolsv.exe process was holding handles there. When I stopped the Printer Spooler service, the connection attempts stopped.

    I deleted most of the keys listed in this thread but finally had to delete the ones that Process Explorer was reporting. Basically I went here:

    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Print\Providers\Client Side Rendering Print Provider

    and searched every subkey, deleting all references to the old server. After that, I was able to restart the Print Spooler without causing the connection attempts to the old server.

    Sunday, November 24, 2013 2:29 AM