PowerShell을 사용하여 로컬 컴퓨터에 설치된 Printer 보기 및 공유된 프린터 추가하기


  1. PowerShell V3.0에서는 Printer에 대한 cmdlet가 추가되어 있다. Get-Command *-Printer를 해 보면 알 수 있다. PowerShell로 Printer를 관리한다면, 관리자가 원격 컴퓨터에 접속하여 프린터를 설치할 수 있는 장점이 있다
  2. 로컬 컴퓨터에 설치된 프린터를 보려면
    Get-Printer
    Get-Printer -Name  “HP LaserJet 400 M401 PCL 6”
    Get-Printer -Name  “HP LaserJet 400 M401 PCL 6” | Format-List *
    (이렇게 보면 “공유 여부”와 “공유 이름” 및 “Active Directory에 게시(Published) 여부”도 알 수 있다)
  3. [원격 컴퓨터]에 설치된 프린터를 보려면
    Get-Printer -ComputerName Server1
    Get-Printer -ComputerName Server1 | fl *
  4. Active Directory에 게시된 Printer를 보려면…
    Get-Printer -ComputerName DC1 | Where-Object {$_.Published}
    ** 이렇게 확인을 했으면 프린터 추가 마법사를 통하여 프린터를 설치하면 된다
  5. 공유된 프린터를 로컬 컴퓨터에 설치하기
    Get-Printer -ComputerName Server1 | fl *
    Get-Printer -ComputerName Server1 | Select-Object -Property ShareName
    Add-Printer -ConnectionName \\Server1\Sharedname
  6. 원격 컴퓨터에 접속하여 로컬 프린터 설치하기
    Enter-PSSession -ComputerName pc1
    Add-Printer -ConnectionName \\Server1\Sharedname

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s