PowerShell script for network printer automation

Hello Experts,

I have a client who currently has network printers hosted on a Windows 2008 R2 printer server. All clients connecting to these printers are Windows 7 machines.

Because all these network printers reside on same VLAN where servers are hosted, we have decided to create a new VLAN and move all network printers from the original VLAN to new VLAN. I have created a new scope on the DHCP servers, and reservations to place all network printers.

Next steps are to change IP address and name for each network printer, move the printers to a new  printerserver then we would need to remap all of the printers. I am looking for a powershell script to remove the old printers from all computers in a AD site and install the new ones to all computers in same site. Other AD sites within the domain should not be affected by this change

Any ideas?

Client OS: Windows 7

Print server OS: Windows 2008 R2

Domain/functional level:  Windows 2003
Jerry SeinfieldAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Spike99On-Site IT TechnicianCommented:
I found a powershell script online that might help you.  This script is on the MS Technet script center repository:

This script swaps out one printer shared on the old print server for the corresponding printer shared on the new print server.  The IP port or address used for that printer on the respective print servers would not come into play since users are connecting to the printers by share name and not by IP.

Since you are using a new VLAN, I would make sure that printer ports are open between the VLAN where the printers & print server are going to be and the VLAN where the users are logged on.  The standard port used for printing is 9100, but your ports may vary depending on the type of printer.  For example, the old 3 port parallel HP JetDirect "print server" (not to be confused with a Server acting as a print server) used ports 9100, 9200 & 9300 for the 3 ports on the device.

I hope this helps.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.