Operating Systems and Systems Integration

Setting up printing in the laboratory A306 (temporary IP address—will change IP address in a

few days)

1 Aim

After completing this exercise, you will:

• be able to print from Linux to the printer in the laboratory, and

• understand how to configure Linux to print to an HP JetDirect box.

2 Procedure

2.1 Running printtool

1. Start the printtool program:

   $ sudo printtool

2. Click on the [figure: Add]button

3. Select the radio button “Remote Unix (lpd) Queue”

4. You will see something like figure 1.

Figure 1: The ”Edit Remote Unix (lpd) Queue Entry” dialog box.

Setting up printing in the laboratory A306 (temporary IP address—will change IP address in a few days) Operating Systems and Systems Integration

2

(a) Leave the Names, Spool Directory, File Limit in Kb entries with their default values (don’t change them)

(b) For Remote Host, put the IP address of the JetDIrect printer box. Currently it is 192.168.128.48, but expect that to change in a week or two.

(c) Hewlett-Packard JetDirect printer server boxes have a printer queue name raw. Enter “raw” for Printer Queue.

(d) For Input Filter, click on the [figure: Select]button. A larger dialog box will appear.

5. In the Configure Filter dialog box,

(a) Select HP LaserJet 4/5/6 series, non-Postscript (we are printing to an old HP LaserJet 1100)

(b) Select 600x600 under Resolution

(c) Select a4 under Paper size.

(d) Click the [figure: OK]button.

6. In the Edit Remote Unix (lpd) Queue Entry box again, click the [figure: OK]button.

7. From the lpd main menu item, select Restart lpd.

8. From the File main menu item, select Quit.

2.2 Printing part of a text file (such as the part of rc.custom.gz that you wrote)

1. From the main http://CSAlinux.tycm.vtc.edu.hk/ web page, click on “Nick’s script to make emacs be nice is here.”, and follow instructions. This will enable (among many other nice things), automatic decompression of your compressed files, and recompression when you save them.

2. Open the file. Suppose it is rc.custom.gz.

3. Select the part that you wrote using the mouse.

4. From the Tools menu, select Print → Postscript Print Region. The section that you highlighted will be printed on the old HP 1100.