Solved

Printers keep coming back after being deleted

Posted on 2010-09-07
11
11,336 Views
Last Modified: 2016-04-13
I previously had some printers being deployed per users, but are now being deployed per machine via group policy. Most are new names and new shares. Old shares have been deleted, and there is no longer any policy being applied that would install the old printers. I noticed though that somehow, some of the older printers are still appearing in the users Print and Fax list. If you delete the printers from the list and reboot, then will return. I have been going insane trying to resolve this issue. I found some entries in the registry (about 17 different entries per printer) for the printers, and decided to remove them all for one specific printer to see if it worked. It did. That particular printer no long appears. Is there an easier way to fix this. This method maybe a little time consuming for 100 machines and about 10 printers.

I also included the keys where I found some of the entries if it will help. You can see the server name and the specific printer I worked with at the time.

[HKEY_CURRENT_USER\Printers\Connections\,,datastore1,Legal P1]
[HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\Devices]
[HKEY_CURRENT_USER\Software\Microsoft\Windows NT\CurrentVersion\PrinterPorts]
[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\Control\Print\Connections\,,datastore1,Legal P1]
[HKEY_LOCAL_MACHINE\SYSTEM\ControlSet003\Control\Print\Connections\,,datastore1,Legal P1]
[HKEY_USERS\.DEFAULT\Printers\Connections\,,datastore1,Legal P1]
[HKEY_USERS\.DEFAULT\Software\Microsoft\Windows NT\CurrentVersion\Devices]
[HKEY_USERS\.DEFAULT\Software\Microsoft\Windows NT\CurrentVersion\PrinterPorts]
[HKEY_USERS\S-1-5-19\Printers\Connections\,,datastore1,Legal P1]
[HKEY_USERS\S-1-5-19\Software\Microsoft\Windows NT\CurrentVersion\Devices]
[HKEY_USERS\S-1-5-19\Software\Microsoft\Windows NT\CurrentVersion\PrinterPorts]
[HKEY_USERS\S-1-5-20\Printers\Connections\,,datastore1,Legal P1]
[HKEY_USERS\S-1-5-20\Software\Microsoft\Windows NT\CurrentVersion\Devices]
[HKEY_USERS\S-1-5-20\Software\Microsoft\Windows NT\CurrentVersion\PrinterPorts]

My server is Windows Server 2008 with SP2 and clients are all Windows XP with SP3.

Thanks,
0
Comment
Question by:mrevillaatico
11 Comments
 
LVL 3

Expert Comment

by:insightcomputing
ID: 33620920
Turn off the old server that was sharing the printers. get that old server off the domain as soon as possible. Not only will printers get screwy, so will shares.
0
 

Author Comment

by:mrevillaatico
ID: 33621037
That's not going to be possible. Its the same server. Would this even matter though? The shares are not even there any more. Like I said though, it seems as though it is client side now. I have read that it could be applied because of another user profile on the machine, which may be related to why when I removed all the entries in the registry it worked.

I also used this spooler cleanup utility on a VM to test. That worked also , but it seemed like it was very brute. It took out the MS office printer and a couple other locally installed printers, so I am avoiding that route at all costs.
0
 
LVL 16

Expert Comment

by:Spike99
ID: 33621582
We had the same problem: those old network printer connections were saved in the users' profile when we switched over to Tricerat's ScrewDrivers sofware (a 3rd party printing solution that streamlines redirected printers).  The users couldn't delete those old printers from their printers folder because they didn't have rights to do so (they're not admins or power users).

You could clear the user's  local and roaming profile to get rid of those saved network printer connections, but we couldn't do that.  We had hundreds of users having this problem, it wasn't practical to clear so many profiles.

Instead, we put in a VBS logon script that deletes the printers key from HKEY_Current_User.  This key will be regenerated the next time they log on.

How are users mapping to those shared printers? do you have logon scripts?

Because, deleting the HKCU\Printers key at log on would wipe out those, too.  So, you would have to map those printers for user in another logon script.

Here are some samples


RemPrinters.vbs
0
 
LVL 16

Expert Comment

by:Spike99
ID: 33621709
Oops.

I meant to also explain how to use a batch file to map network printers.

For each printer, add a line like this to the batch file:

rundll32 printui.dll,PrintUIEntry /in /u /z /n\\servername\printersharename

Add a this switch to the line for the default printer:   /y

This page has more details on what the different switches do for this command:
http://www.robvanderwoude.com/2kprintcontrol.php

I hope this helps.

Alicia
0
 

Author Comment

by:mrevillaatico
ID: 33621719
@Spike99

The old printers were being setup via a policy created on windows server 2008 as a per user. This was done through Group Policy Management and the applied to the specific user OUs.

What I did this time was create a blank policy and then use the deploy through group policy option directly from the printer, and linked to that new policy. We also are now doing it as per machine vs per users. There was an issue with slower logon times and also Citrix login issues with the per users.

I personally have never done any VB scripting.
0
Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

 
LVL 16

Accepted Solution

by:
Spike99 earned 500 total points
ID: 33621889
We had to use the VB script in our environment because we users can't use regedit.

If you don't restrict access to regedit, you could probably accomplish the same task using a BATCH file that imports the REG file that will delete the entries you want to remove..

Here are some articles on how to delete and add registry entries using REG files:

http://support.microsoft.com/kb/310516
http://www.robvanderwoude.com/regedit.php

Alicia
0
 

Author Comment

by:mrevillaatico
ID: 33635839
it seems that removing the entries from the registry is doing the trick. Still trying to narrow down all the keys that need to be removed to make sure the "ghost" printers do not show up. Thank you for all your help.
0
 
LVL 4

Expert Comment

by:DeDeckkerAndy
ID: 34417993
I think it's because they are in your hkey_users\.default section.
Maybe previously you had added the printers and made some changes to the default profile?
Changing the system and default settings in Regional and Language settings sometimes copies a lot from your own profile to the default profile. (it's just a guess of how this may have happened)

You can remove them from the default profile by just removing the hkey_users\.default\printers\connections\.. key.

If you don't remove it from the default profile, the printer will just be readded when a 'new' user logs on that server/pc.
0
 
LVL 59

Expert Comment

by:Darius Ghassem
ID: 34636965
This question has been classified as abandoned and is being closed as part of the Cleanup Program.  See my comment at the end of the question for more details.
0
 

Expert Comment

by:CMS-T
ID: 41548386
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
lync 2013 7 54
local administrator password solution 26 73
Troubles Logging On Creating New Profile 3 43
Windows 10 and WSUS 3.2 5 37
Printers have changed substantially in the last 30 or so years, not just in technical capabilities but in cost and usage as well.  Printers were originally used for interfacing with the operator, not necessarily for printing copy or pictures. In …
New Windows 7 Installations take days for Windows-Updates to show up and install. This can easily be fixed. I have finally decided to write an article because this seems to get asked several times a day lately. This Article and the Links apply to…
This tutorial will walk an individual through configuring a drive on a Windows Server 2008 to perform shadow copies in order to quickly recover deleted files and folders. Click on Start and then select Computer to view the available drives on the se…
This tutorial will show how to configure a new Backup Exec 2012 server and move an existing database to that server with the use of the BEUtility. Install Backup Exec 2012 on the new server and apply all of the latest hotfixes and service packs. The…

932 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now