FREE Citrix XenApp Training

Are you setting up a new Proof of Concept
or a Production Environment?

I'll coach you through the configurations step-by-step with Real World Best Practices.

  • Microsoft Active Directory and Group Policy...
  • Install and Configure Citrix XenApp...
  • Citrix Web Interface and Licensing...
  • And Much Much More...

I respect your privacy. I'll NEVER sell, rent or share your email address. That's more than a policy, it's my personal guarantee!

Replicating Print Drivers in Citrix XenApp 6.5

Replicating Print Drivers 2 300x110 Replicating Print Drivers in Citrix XenApp 6.5

Many people are wondering where the Printer Management node used for replicating print drivers is located in Citrix XenApp 6.x. This is now managed with the Windows Printer Management Role in Windows Server 2008 R2 or through XenApp PowerShell Cmdlets. I’m a big fan of the Citrix Universal Printer Driver but in some cases that’s not good enough and replicating print drivers to all Citrix XenApp servers are required. Luckily there’s light in the end of the tunnel.

Citrix Universal Print Server Tech Preview is available and will most likely be released at Citrix Synergy 2012. The Citrix Universal Print Server Technical Preview extends XenApp 6.5 and XenDesktop 5.5 Universal printing support to network printing. This feature eliminates the need to install numerous network printer drivers on XenApp and XenDesktop hosts, and enables more efficient network utilization. The new Citrix Universal printer driver supports direct network printing on Windows and non-Windows clients.

So while we wait for this new Citrix Universal Print Server, here’s the steps for replicating print drivers with XenApp PowerShell Cmdlets :

First you’ll need to decide which Citrix XenApp server you’ll be using as the source. A good suggestion would be your Preferred Data Collector. In our example that would be XA65-01. Start PowerShell as Administrator and run the following commands

  1. Set-ExecutionPolicy RemoteSigned
  2. Add-PSSnapIn Citrix.*
  3. Get-XAPrinterDriver –Servername XA65-01

Replicating Print Drivers 3 300x148 Replicating Print Drivers in Citrix XenApp 6.5

This will display a list of all the locally install printer drivers on that particular server. The simplest way to install a lot of printer drivers is to connect to your print server and select to connect to the printers you need.

Replicating Print Drivers 4 300x191 Replicating Print Drivers in Citrix XenApp 6.5

Now rerun the command : Get-XAPrinterDriver –Servername XA65-01

Replicating Print Drivers 5 300x148 Replicating Print Drivers in Citrix XenApp 6.5

To make sure that all your Citrix XenApp servers have the same printer drivers it’s recommend to add the required printer drivers to the Auto-Replication-List. A good tip would be to have these commands in a Notepad file to make it easier for you to Add/Remove printer drivers.

Replicating Print Drivers 6 300x57 Replicating Print Drivers in Citrix XenApp 6.5

Simply copy and paste the commands to the PowerShell window.

Add-XAAutoReplicatedPrinterDriver “Print Driver Name” -SourceServerName XA65-01

Replicating Print Drivers 7 300x148 Replicating Print Drivers in Citrix XenApp 6.5

To display a list of Printer Drivers in the Auto-Replication-List you’ll use the following command :

Get-XAAutoReplicatedPrinterDriver

I’m pretty sure there’s some smart people out there in the Citrix Community who have already created some smart automatic scripts for replicating print drivers in Citrix XenApp 6.x. Please share with the rest of the readers by adding your comment below if you know any good resources.

Resoures :

Prepare For Your Next Citrix Exam with FREE Training
Enter you email to Get Instant Access to Citrix Training and blog post updates directly to your inbox. Over 14644 people have already enjoyed this comprehensive training.

{ 13 comments… read them below or add one }

Frank Peter Schultze January 25, 2012 at 09:09

The PowerShell code below could be taken as a start for a scripted/automated solution to add printer driver names to the replication list.

Copy the code in notepad, fill in the driver names that shouldn’t be added to the replication list ($ExcludedDriverList parameter), and save the code as .ps1 file

Btw, I didn’t test it. Therefore take care ;-)

===
param (
$CitrixServer = $env:COMPUTERNAME,
$ExcludedDriverList = @{“…”, “…”}
)

Add-PSSnapin Citrix* -ErrorAction SilentlyContinue

Get-XAPrinterDriver –Servername $CitrixServer | ForEach-Object {
if ($ExcludedDriverList -notcontains $_.DriverName) {
Add-XAAutoReplicatedPrinterDriver $_.DriverName -SourceServerName $_.ServerName
}
}
===

Reply

Trond Eirik Haavarstein January 25, 2012 at 09:22

Awesome Frank, thank you very much

Reply

olivier dsm April 26, 2012 at 11:16

The Site worked for me.
Thanks a lot for sharing.

Reply

theo van kann May 23, 2012 at 11:29

To enumerate printerdrivers installed on your server I advice the tool mentioned in the Citrix article CTX116474
It works fine and has done a lot of work for me.
Thank you for the above article (replicating print driver)

Reply

Trond Eirik Haavarstein May 23, 2012 at 11:39

Great find, thanks for sharing Theo

Reply

Jennifer June 1, 2012 at 16:13

When does auto replication happen? If I delete a problem driver on a server (and the driver is in the auto replication list with a source server) when does the driver replicate? Can I force that process through a PowerShell command? I actually wanted to replicate several printers that were deleted. I don’t want to type each driver name using the Start-XAPrinterDriverReplication command. I just want all drivers to replicate to the server that they are missing from. Is that how it works or am I missing something?

Reply

Jennifer June 1, 2012 at 17:22

I did figure out that I could use a wildcard value for the driver name which worked in this instance as follows: Start-XAPrinterDriverReplication -drivername “Canon*” -servername wcxaxx

I would still like to understand how the auto replication process works with my questions above. Also, can I change the overwrite value after a driver has already been added to the auto replication list?

Reply

Trond Eirik Haavarstein June 2, 2012 at 08:51

To delete printer drivers you can use a tool like Print Detective http://support.citrix.com/article/CTX116474

Also take a look at this post for an automatic solution
http://www.xenappblog.com/2012/adding-printer-drivers-from-print-server-using-powershell/

Reply

Jennifer June 4, 2012 at 15:31

Trond-
Thank you for the response, but that doesn’t really answer the questions that I asked. I don’t have a problem deleting the drivers. My questions: When does autoreplication happen if there is a change? Can I force the replication? Can I change the overwrite value without re-adding a driver to the auto-replication list? Any ideas?
Jennifer

Reply

Trond Eirik Haavarstein June 9, 2012 at 09:52

They’re replicated automatically, normally 5-15 minutes. You will also see that this happens when the server restarted.

Reply

Dennis June 19, 2012 at 08:14

And if you don’t like typing, you can use this;

http://www.gourami.eu/products/xenapp-printer-driver-manager

It’s a GUI to manage the printer drivers.

(it’s free optional donation)

Reply

Trond Eirik Haavarstein June 19, 2012 at 08:41

Thanks Dennis, got confused the first time I check since price says 25 euro, but see now that the License type is free. Thanks for sharing.

Reply

Melanie July 26, 2012 at 10:00

This is a great tool only the error message “cannot invoke this function…” is confusing – but it works anyway. Thank you for this hint!

Reply

Leave a Comment

{ 1 trackback }

Previous post:

Next post: