1. Skip to Menu
  2. Skip to Content
  3. Skip to Footer>

พื้นที่ลงโฆษณา

Thin Client Server

พื้นที่ลงโฆษณา

Linux Authentication

พื้นที่ลงโฆษณา

CUPS Server

PDF Print E-mail

Written by Mr. Sontaya Photibut Saturday, 02 May 2009 16:27

การติดตั้ง CUPS Server บน SLES (HeadOffice+Branches)

CUPS (Common UNIX Printing System) เป็นโปรแกรม OpenSource ภายใต้ลิขสิทธิ์แบบ GNU ทำงานบนระบบ UNIX และ LINUX ซึงเป็นโมดูลของระบบพิมพ์งานสำหรับ UNIX และ LINUX เพื่อทำให้คอมพิวเตอร์กลายเป็น Print Server ซึ่งคอมพิวเตอร์ที่ติดตั้ง CUPS จะเป็นโฮสซึ่งคอยรับงานพิมพ์ (print jobs) จากเครื่องไคลเอ็นต์

CUPS ประกอบด้วย Spooler และ Scheduler และระบบ filter ที่ทำการแปลงข้อมูลให้อยู่ในรูปแบบที่เครื่องพิมพ์เข้าใจ และทำงานเบื้องหลังเพื่อส่งข้อมูลไปยังเครื่องพิมพ์ CUPS ใช้ IPP (Internet Printing Protocol) เพื่อจัดการงานพิมพ์และคิวงานพิมพ์ CUPS สามารถควบคุมได้ทั้ง Text mode, GUI, Web-base

PCL และ Ghostscript
PCL เป็นภาษาคอมพิวเตอร์ที่ถูกคิดค้นโดย HP เพื่อใช้งานกับเครื่องพิิมพ์เพื่อกำหนดรูปแบบการส่งข้อมูลไปพิมพ์ลงบนกระดาษ
Ghostscript เป็นภาษาคอมพิวเตอร์ที่สามารถจัดการทางด้านกราฟิกส์ โดยที่ Ghostscript มีลักษณะที่เป็น Page Description Language (PDL) ก็คือสามารถที่จะ Encapsulated ไฟล์ภาษา PostScript ในลักษณะอื่นๆ ได้ สรุปก็คือ Ghostscript เป็นโปรแกรมแปลกภาษา Postscript และ Adobe Portable Document (PDF) ในรูปแบบที่เครื่องพิมพ์เข้าใจได้

Image

Network Diagram :

Image

Head Office : CUPS Server IP Address : 10.0.0.100 (SLSE)

Application Server : IP Address : 10.0.0.10 (Windows Server 2000)

Branches : CUPS IP Address: 10.0.x.x

 

1.ติดตั้งCUPS Server (Head Office)

ปกติ แล้ว SuSE จะติดตั้ง Package นี้มาให้อยู่แล้ว ถ้าคุณสังเกตตอนติดตั้งจะเห็นว่ามีการเลือก Service Print Server ด้วย ระหว่างการติดตั้ง

Image

2.เครื่องมือบริหาร CUPS

- CUPS web-based

Image


- GUI (GNOME)

Image


3.CUPS web-based

การเข้าใช้งาน CUPS web-based พิมพ์ 127.0.0.1:631 ที่ firefox ดังรูปครับ

Image


4.การใช้ ผ่านCUPS web-based

การ คอนฟิกไฟล์ cups.conf เพื่อที่จะให้สามารถ Remote จาก IP Address หรือ Network ที่เรากำหนดสามารถ เข้ามาตั้งค่าต่างใน CUPS Server ได้

# vim /etc/cups/cups.conf

ค้นหาคำว่า BrowseAllow @LOCAL แล้วเพิ่มบรรทัดนี้เข้าไปครับ

BrowesAllow 10.0.0.0/24 (ให้เปลื่ยนเป็น Network ของคุณ)

ค้นหาคำว่า Allow From 127.0.0.2 แล้วเพิ่มบรรทัดนี้เข้าไปครับ

Allow From 10.0.0.0/24

ค้นหาคำว่า <Location /admin> แล้วเพิ่มบรรทัดนี้เข้าไปครับ

Allow From 10.0.0.0/24

 

wq! -> save and exit แล้ว Restart CUPS Service ด้วยคำสั่ง

# rccups restart


สร้างผู้ใช้ให้กับ CUPS (root)

# lppasswd -a root

Enter password: cups1234

Enter password again: cups1234

# rccups restart


จากนั้นเข้าคอนฟิกจากเครื่อง Clients เปิด Firefox พิมพ์ 10.0.0.100 (CUPS Server) ดังรูป

Image


5.การใช้ ผ่าน GUI (GNOME)

การเข้าใช้งาน ไปที่เมนู Computer > YaST > Printer จะได้ดังรูปครับ

Image


6.ติดตั้ง CUPS ที่สาขาต่าง

# vim /etc/cups/cups.conf

ค้นหาคำว่า BrowseAllow @LOCAL แล้วเพิ่มบรรทัดนี้เข้าไปครับ

BrowesAllow 10.0.0.100 (ให้เปลื่ยนเป็น Network ของคุณ)

ค้นหาคำว่า Allow From 127.0.0.2 แล้วเพิ่มบรรทัดนี้เข้าไปครับ

Allow From 10.0.0.100

ค้นหาคำว่า <Location /admin> แล้วเพิ่มบรรทัดนี้เข้าไปครับ

Allow From 10.0.0.100

 

wq! -> save and exit แล้ว Restart CUPS Service ด้วยคำสั่ง

# rccups restart


7.การเพ ิ่มPrinters

Image

คลิก Manage Printers

Image


จะขึ้นหน้าต่างให้ใส่ Username & Password

Image

Username : root

Password : cups1234

Image


Image

Image

Image

Image

สร้างผู้ใช้ให้กับ CUPS (printer) ต้องสร้างผู้ใช้ชื่อ printer เข้าในระบบก่อนนะครับ

# useradd -D (ดูค่าเริ่มต้น) *** คำสั่งนี้ไม่สามารถใช้เพิ่มผู้ใช้งานในระบบ LDAP ได้ ถ้าคุณใช้ระบบ LDAP สามารถเพิ่มผู้ใช้งานได้จาก YaST

# useradd -m printer (เพิ่มผู้ใช้งาน)

# passwd printer (ตั้งรหัสผ่าน)

Changing password for printer.

New Password: printer123

Reenter New Password: printer123

Password changed.


สร้างผู้ใช้เข้าไปใน CUPS

# lppasswd -a printer

Enter password: printer123

Enter password again: printer123

# rccups restart


8.เพิ่มเครื่องพิมพ์แต่ละสาขามาที่ CUPS Server

เข้าใช้งาน CUPS web-based พิมพ์ 10.0.0.100:631

Image

Image

Image

Image

Image

Image


9.คอนฟิก Samba (SMB)

ที่เครื่อง CUPS Server (10.0.0.100)

คอนฟิก SMB

# vim /etc/samba/smb.conf

เปลื่ยนค่า workgroup = WORKGROUP เป็น workgroup = HOCUPS

ส่วนค่าอื่นๆ ไม่ต้องแก้ไขครับ เพราะ SMB จะ แชร์ เครื่องพิมพ์ไปที่ Windows ทุกเครื่อง ดังค่าคอนฟิกที่เห็นจากไฟล์ smb.conf

เพิ่มผู้ใช้ Samba (SMB)

# useradd -m cupssmb

# smbpasswd -a cupssmb

Enter password: printer123

Enter password again: printer123

 

10.ทำการเพิ่ม Printers ที่เครื่อง windows (Application Server)

ไปที่ Start > Run > พิมพ์ \\10.0.0.100\ คลิก OK

จากนั้นคลิกขวามือที่พิมพ์เตอร์ ที่ต้องการ เลือก Connect เป็นอันเสร็จการ Add Printer จากเครื่อง Windows ไป Linux CUPS Server

หลัง จากนั้นเมื่อเครื่อง Clients จากสาขาต่าง Remoter จากใช้งานที่เครื่อง Application Server ก็สามารถที่จะพิมพ์งานได้ครับ โดยผ่าน CUPS Server ครับ

*** การ Remote มาใช้งานที่ Application Server หรือ Head Office สามารถใช้ได้หลายโปรแกรมด้วยกัน ยกตัวอย่างเช่น Citrix Client, Remote Desktop เป็นต้น


Download PPD files เพิ่มเติมได้ที่ http://www.linuxprinting.org/printer_list.cgi

*** ถ้า เครื่องพิมพ์ของคุณไม่มี Printer Driver ที่สามารถใช้งานได้ แต่คุณต้องการที่จะใช้เครื่องพิมพ์นี้เฉพาะจาก windows workstations ของคุณผ่าน SAMBA คุณสามารถใช้ printer manufacturer RAW และติดตั้ง printer driver ที่ถูกต้องบน Windows workstation ของคุณได้


เป็นอันเสร็จ การติดตั้ง CUPS Server

 

 

 

 

 


Comments (0)Add Comment

Write comment

security code
Write the displayed characters


busy
 

SUSE Linux Enterprise Cool Solutions

  • Watch the future of Retail

    On YouTube I've published a three-part video of a presentation I did in early July 2010 to IBM retail partners. The sound volume is a bit low, and this was all recorded with a little flip mino camera, so please excuse the bad quality.

    The three video snippets are mainly intended for any of you who want to use Linux in retail as a solution provider and are wondering how solutions from Novell can help you be more successful.

    Nevertheless, especially the first part about how we see the future of the Point of Service might also be interesting to you if you are a decision maker in retail or just curious about how the future in retail IT may look like.

    The new features in SUSE Linux Enterprise Point of Service 11 Service Pack 1 are only mentioned briefly in this presentation. Watch out for more blog posts to come on Service Pack 1.

    This is Joachim Werner blogging live from the SUSE offices in Nuremberg, Germany.

    http://www.youtube.com/watch?v=WdYEeLIou7s
    http://www.youtube.com/watch?v=3Awr3tPpo2Y
    http://www.youtube.com/watch?v=pwwKpoEI9GI

  • Create an Appliance with SUSE Studio -- you could win $10,000

    They're looking for inventive minds to build the most innovative software appliances. Publish your unique appliance to the new SUSE® Gallery™ and enter into a contest to win $10,000!

    The contest runs from July 27 - September 30, 2010, so brush off your mad skills and pop on over here for all the details.

    It must not be too hard.... in the past year, more than 400,000 Linux appliances were built using SUSE Studio, with nearly 3 million downloads. SUSE Gallery is the place to strut your stuff and show off the appliances you have built with SUSE Studio. It also serves as a centralized online showcase where SUSE Studio users can browse and use both commercial and community-oriented appliances.

    Good luck! Make Cool Solutions proud.

  • See us at SHARE, Boston!

    The next SHARE event is approaching quickly - it takes place in Boston from August 1-5 at Hynes Convention Center: http://www.share.org/Events/UpcomingConference/tab...

    If you are attending, don´t miss the chance to meet our experts for System z, and visit us at Booth #319. To name just a few, watch out for Kim Lorusso (IBM Alliance Marketing Manager and Cool Blogger), Patrick Quairoli (Technical Alliance Manager), Marcus Kraft (Linux on mainframe "pioneer" and Product Manager for SUSE Linux Enterprise Server for System z), David Getzin (Partner Executive for IBM), John Jolly (Sys z Architect), and others. Chat with them about the SUSE Linux Enterprise Consolidation Suite tailored for IBM Solution Edition for Enterprise Linux. Don´t know what that is? Read more here: http://www.novell.com/products/systemz/els.html
    And get the latest about the new zEnterprise System - you bet that will be one of the "ruling" topics.

    Or listen to Mike Friesenegger, one of our most experienced Technical Specialists, when he talks about "ASP.NET on zLinux: A New Workload" (Tues Aug 3, 9:30-10:30AM, Room 305) and about how to " Implement the SUSE Linux Enterprise High Availability Extension on System z" (Tues Aug 3, 11AM-12PM, Room 208). And you´ll have the opportunity to hear from customers like Nationwide Insurance why and how they use SLES for System z.

    And as a side note - for those who have travel constraints and cannot attend personally, SHARE offers the option to participate online - just check out http://www.share.org/Events/UpcomingConference/SHA...

  • IBM zEnterprise System - Get the hard facts

    This week on Thursday IBM made a ground-breaking announcement about the revolutionary zEnterprise System - you might have read my article here on Cool Solutions:
    http://www.novell.com/communities/node/11670/ibm-f...

    Curious now about getting details and some hard facts? Just download the data sheet from IBM and see how it works. Want to discuss how this new system relates to SUSE Linux Enterprise ? Leave a comment or drop me an email at chabow@novell.com

    AttachmentSize
    11394070.pdf385.48 KB
  • What do you think about this country/language selector?

    The web team at Novell is tweaking the way people choose the language they want to read the website in. (Of course, this doesn't affect this communities section, which is only provided in English. But it does affect a lot of the marketing pages on novell.com. )

    We'd like your feedback, especially if you like to read the rest of Novell.com in a language other than English. Take a look at this design, and let us know what you think by posting comments.

    Thanks for your input!

    View design here.

Sponsors List