Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to set up USB Network Printer and Scanner Server on Debian

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly explains "how to set up USB network printer and scanner server on Debian". The content in the article is simple and clear, easy to learn and understand. Please follow Xiaobian's train of thought to study and learn "how to set up USB network printer and scanner server on Debian".

Suppose you want to set up a Linux print server in your home / office network, and you have only USB printers available (because they are much cheaper than printers with built-in network interfaces or wireless modules). In addition, what if one of these devices is integrated and you want to share its integrated scanner over the network? In this article, I'll show you how to install and share an all-in-one USB (Epson CX3900 inkjet printer and scanner), a USB laser printer (Samsung ML-1640), and, as an added bonus, configure a PDF printer. All of this will be implemented in the GNU/Linux Debian 7.2 [Wheezy] server.

Although these printers look a little old (I bought the Epson all-in-one in 2007 and the laser printer in 2009), I still believe that what I learned during installation can also be applied to the brand's new products and other brands: some precompiled .deb package drivers are available, while others can be installed directly from the warehouse. After all, it is an important basic principle.

precondition

To set up network printers and scanners, we will use CUPS, an open source printing system for Linux/UNIX/OSX.

# aptitude install cups cups-pdf

Troubleshooting Tip: depending on your system condition (this problem is likely to occur after manual package installation fails, or when there is a lack of dependent packages), installing cups and cups-pdf front-end package management systems may prompt you to uninstall many packages to try to resolve the current dependency problem. If this happens, you have only two choices:

1) install the package through another front-end package management system, such as apt-get. Note that such a process is not recommended because it does not solve the current problem.

2) run the following command: aptitude update & & aptitude upgrade. This command fixes the problem and updates the package to the latest version.

Configure CUPS

In order to be able to access the web interface of CUPS, we need to make at least one minimum modification to the cupsd.conf file (the server configuration file for CUPS). Before making any changes, let's make a backup copy of cupsd.conf:

# cp cupsd.conf cupsd.conf.bkp

Then, edit the original file (only the most relevant parts are shown below):

Listen: listens to the specified address and port, or domain socket path. Location / path: specifies access control for the location represented by the name. Order: specifies the HTTP access control order (allow,deny or deny,allow). Order allow,deny means to allow a rule to precede (and give priority to) a reject rule. DefaultAuthType (you can also use AuthType): specifies the type of authentication used by default. Basic refers to the use of the / etc/passwd file to authenticate users in CUPS. DefaultEncryption: specifies the type of encryption used by the authentication request. WebInterface: specifies whether the web interface is enabled.

# Listen for connections from the local machine Listen 192.168.0.15:631 # Restrict access to the server Order allow,deny Allow 192.168.0.0/24 # Default authentication type, when authentication is required DefaultAuthType Basic DefaultEncryption IfRequested # Web interface setting WebInterface Yes # Restrict access to the admin pages Order allow,deny Allow 192.168.0.0/24

Now, let's restart CUPS to apply the changes:

# service cups restart

In order to allow another user (in addition to root) to modify printer settings, we must add him / her to the lp (authorizing access to the printer hardware and enabling the user to manage print tasks) and the lpadmin (with print priority) group as follows. If you do not need or need this setting in your current network setting, you can ignore this step.

# adduser xmodulo lp# adduser xmodulo lpadmin

Configure a network printer through a web interface

1. Launch a web browser and open the CUPS interface http://:Port. Here is http://192.168.0.15:631 in our example:

2. Go to the Management tab, and then click add Printer:

3. Select your printer; in this example, EPSON Stylus CX3900 @ debian (Inkjet Inkjet Printer), and then click continue:

4. it's time to give the printer a name and specify whether we want to share it from the current workstation:

5. Install the driver-select a brand and click continue.

6. If the printer is not supported by CUPS (not listed on the next page), we must download the driver (such as http://download.ebz.epson.net/dsc/search/01/search/?OSC=LX) from the manufacturer's website and return to this page after installation.

7. Note that the precompiled .deb file must be sent from the machine we use (for example, via sftp or scp) to the print server (of course, it would be easier if we had a direct download link instead of the download button):

8. After putting the .deb file on the server, we can install:

# dpkg-I epson-inkjet-printer-escpr_1.4.1-1lsb3.2_i386.deb

Troubleshooting Tip: if the lsb package (a third-party Linux application writer can rely on the standard core system) is not installed, the driver will not be installed:

We will install lsb and then try to install the printer driver again:

# aptitude install lsb# dpkg-I epson-inkjet-printer-escpr_1.4.1-1lsb3.2_i386.deb

9. Now we can return to step 5 and install the printer:

Configure a network scanner

Now we will continue to configure the printer server to share the scanner. First, install xsane, which is the front end for quick access to SANE-- scanners:

# aptitude install xsane

Next, let's edit the / etc/default/saned file to enable the saned service:

# Set to yes to start saned RUN=yes

Finally, we'll check to see if saned is already running (probably not-- so we'll start the service and check again):

# ps-ef | grep saned | grep-v grep# service saned start

Configure another network printer

With CUPS, you can configure multiple network printers. Let's configure an additional printer through CUPS: Samsung ML-1640, which is a USB printer.

The splix package contains monochrome (ML-15xx, ML-16xx, ML-17xx, ML-2xxx) and color (CLP-5xx, CLP-6xx) Samsung printer drivers. In addition, the details of this package indicate that some newly named Samsung printers, such as Xerox Phaser 6100, also apply to this driver.

# aptitude install splix

Then we will use the CUPS web interface to install the printer, just like before:

Install the PDF printer

Next, let's configure a PDF printer on the print server. In this way, you can convert the document from the client computer to PDF format.

Since we have installed the cups-pdf package, the PDF printer has been installed automatically and can be verified by the web interface:

When a PDF printer is selected, the document is written to a configurable directory (the default is ~ / PDF), or it can be copied through subsequent processing commands.

Thank you for your reading, the above is the content of "how to set up USB network printers and scanner servers on Debian". After the study of this article, I believe you have a deeper understanding of how to set up USB network printers and scanner servers on Debian. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report