How to install a HP Deskjet 845c under FreeBSD with CUPS, and how to make it work with samba. ( this is based on the how-to from http://www.freebsddiary.org/cups.php ) I installed the HP on a Compaq Deskpro EN 6400 with FreeBSD 4.7, so the USB procedure may vary on your system. But i guess it would also work on older(or newer) systems. Please make sure that your ports are up-to-date. 1. First you have to be sure that you have USB support in your kernel. I use these options: #USB things device uhci device usb device ulpt Compile the new kernel, and install it.(do not reboot, yet) 2. Edit /etc/rc.conf, and add the following if its not there already: usbd_enable="yes" Make the device ulpt0 under /dev. (Skip it if it is already there) cd /dev && ./MAKEDEV ulpt0 3. Reboot, so the new kernel, and rc.conf takes effect. 4. (if using X11 skip this) Add "WITHOUT_X11=yes" into /etc/make.conf 5. Install ghostscript from ports with the following command: cd /usr/ports/print/ghostscript-gnu && make install 6. Install CUPS from ports with the following command: cd /usr/ports/print/cups && make install distclean 7. (VERY IMPORTANT) Disabling stock FreeBSD lpr. a. Go to /usr/bin cd /usr/bin b. Backup print files. tar cvfz default_print_bin.tgz lp* c. Move compress file to a safe place. (Its up to you) mv default_print_bin.tgz ~ d. Remove default print binaries. rm /usr/bin/lp* e. Make sure a buildworld not will install those files again by editing make.conf NO_LPR=true 8. Copy cupsd.sh.sample to cupsd.sh, so cups will start at bootup. cp /usr/local/etc/rc.d/cups.sh.sample /usr/local/etc/rc.d/cups.sh 9. CUPS can be administrered via webbrowser. I did that. CUPS is looking for webadmin requests from localhost, so if you dont want that edit /usr/local/etc/cups/cupsd.conf and change 127.0.0.1 to the ip address for your workstation two places. 10. Uncomment application/octet-stream in /usr/local/etc/cups/mime.types and /usr/local/etc/cups/mime.convs Uncomment BrowseAddress @LOCAL in /usr/local/etc/cups/cupsd.conf. 12. Start CUPS with "/usr/local/etc/rc.d/cupsd.sh start" , and check with ps aux that CUPS is running. ps aux | grep cups 13. Use your webbrowser to begin admin CUPS, with the following address: http://YOUR_SERVER_NAME_OR_IP:631/admin. Add printer, and follow the directions. I used "USB Printer #1" in Device-section, "HP"and "HP DeskJet Series CUPS v1.1 (en) " for model/driver. After doing that, try printing a testpage from CUPS webinterface. If it worked that is great, if not - try checking your cables, and such stuff, and do the printer installation one more time. Now you should be able to print without any problems. Also try using lpr. echo This is a test > ~/test_page.txt lpr /~test_page.txt To get Windows computer to use the printer, make sure you got a Samba server installed and working. Then edit /usr/local/etc/smb.conf. (Make sure Samba is compiled WITH CUPS support.) A. ) Add to the [global] section: printcap name = cups use client driver = yes (The Windows clients need the drivers for the printer. get it from hp.com) B.) Add a [printers] section with this: comment = All printers path = /var/spool/samba guest ok = no read only = yes printable = yes browseable = no Restart Samba, and your Window machines should be able to see, and install the printer. Thanks to FreeBSD-Diary(www.freebsddiary.org) and Erik Thorsnes from BLUG for making this work. Fell free for mail questions, addins and such to dtun3z@SPAMBLOCK2000.online.no Last changed 8. Jan 2003. Written by Christer Solskogen / dizzy tun3Z