Printing in OSX

About SheepShaver, a PPC Mac emulator for Windows, MacOS X, and Linux that can run System 7.5.3 to MacOS 9.0.4.

Moderators: Cat_7, Ronald P. Regensburg, ClockWise

emendelson
Forum All-Star
Posts: 1726
Joined: Tue Oct 14, 2008 12:12 am

Post by emendelson »

Try this: Restart your machine. Do not enter the cupsctl command at the terminal. Try printing to the local printer using the technique in rbsfou's messages. You will get an error message from the Finder in Sheepshaver (at least I get an error message). Open a terminal in OS X; enter the cupsctl command. Print again from Sheepshaver - it will work. At least it does for me.

The command does not persist through a reboot, at least on my machine.

There are multiple ways to make a command run at startup. For example: Create this text file:
#!/bin/bash
/usr/sbin/cupsctl 'BrowseLocalProtocols="cups dnssd lpd"'
exit
Save the file with a name like ShareLPD.command (with a .command extension, NOT a .txt or other extension); put it in in a convenient folder. Go to System Preferences, Users & Groups, Login Items, and add the new file to the login items.

Alternatively, in the AppleScript editor, enter the following:
do shell script "/usr/sbin/cupsctl 'BrowseLocalProtocols=\"cups dnssd lpd\"'"
Save it as an Application in some convenient folder, and add that to the list of Login Items.

There are probably plenty of other ways to do this.

In my own application (which runs WordPerfect for the Mac), I use an Applescript that launches a SheepShaver .sheepvm that is stored inside the AppleScript bundle itself. I've added a "do shell script" command that runs this command when my Applescript starts up, so I don't need to add anything to the Login Items.
Last edited by emendelson on Sun Dec 11, 2011 4:12 pm, edited 1 time in total.
User avatar
Ronald P. Regensburg
Expert User
Posts: 7833
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Post by Ronald P. Regensburg »

This printing setup survived multiple restarts of my OSX 10.6.8 machine without again using that command.

When I do just cupsctl in Terminal to view the current settings, this is what I get (note the line BrowseLocalProtocols):

Code: Select all

Last login: Sun Sep 11 09:08:40 on console
MacKanjer4:~ ronald$ cupsctl
_debug_logging=0
_remote_admin=0
_remote_any=0
_remote_printers=1
_share_printers=1
_user_cancel_any=0
BrowseLocalProtocols=cups dnssd lpd
BrowseRemoteProtocols=
DefaultAuthType=Basic
SystemGroup=admin
SystemGroupAuthKey=system.print.admin
MacKanjer4:~ ronald$ 
So the setting appears to be permanent in my OSX.

What do you see when you do this after a restart?
emendelson
Forum All-Star
Posts: 1726
Joined: Tue Oct 14, 2008 12:12 am

Post by emendelson »

Well, you're right: the command does persist after a restart. I can't figure out why it didn't seem to persist when I experimented with it last time.

On a clean system, with printer sharing NOT enabled, this line appears:
BrowseLocalProtocols=
When I enable printer sharing AND select a printer to share, it changes to
BrowseLocalProtocols=cups dnssd
I need to give the command - cupsctl 'BrowseLocalProtocols="cups dnssd lpd"' - for the line to read:
BrowseLocalProtocols=cups dnssd lpd
And, if you want to remove "lpd" from cupsctl, you can give the command:
cupsctl 'BrowseLocalProtocols="cups dnssd"'
I hope this is correct now, anyway.

The settings seem to be stored in /private/etc/cups/cupsd.conf and you can access them easily by opening a browser and going to this address:

http://localhost:631/admin/

where you go to the Administration tab, then, under "server," click "Edit Configuration File."
emendelson
Forum All-Star
Posts: 1726
Joined: Tue Oct 14, 2008 12:12 am

Post by emendelson »

The method described earlier in this thread by rbsfou works with the CUPS-PDF printer, making it easy to print PDFs from SheepShaver.

Search for CUPS-PDF for OS X and download and install the latest version. Create a CUPS-PDF printer in OS X's System Preferences. Share it. In SheepShaver, create a desktop printer as described in rbsfou's post (the queue name will be CUPS-PDF). Print to it. The PDF output will go to /Users/shared/cups-pdf/ANONYMOUS (this is actually a shortcut to a folder in a hidden folder, but this is the easiest way to reach it). Create a shortcut to that folder in a convenient place, and you get easy access to the PDF output.
emaculation99
Space Cadet
Posts: 3
Joined: Thu Nov 17, 2011 8:31 pm

Re: Printing in OSX

Post by emaculation99 »

I have followed the instructions several times, bet every time I get "There are no zones on this network" in the printer selector of 'Apple Printer Utility'.

It seems that Sheepshaver does not recognize any printers in OSX. I have 4 printers, all set to share, none show up in the list.

Any suggestions?
User avatar
Ronald P. Regensburg
Expert User
Posts: 7833
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Printing in OSX

Post by Ronald P. Regensburg »

emaculation99 wrote:"There are no zones on this network" in the printer selector of 'Apple Printer Utility'.
'Zones'? Sounds like you are trying to set up an AppleTalk desktop printer. That will not work. As described in the instructions, you need to select LPR printer in the opening window for setting up a new desktop printer. That is usually the second choice in the list. "LPR printer" may have a different name in some language versions, something like IP-printer or Internet printer.

And your printers will not show up in any list. You need to enter the IP-address of your host Mac and the print queue name of the printer you want to use. That printer needs to be the default printer on the OSX side.

Did you follow these instructions? http://www.emaculation.com/forum/viewto ... 175#p29175
Last edited by Ronald P. Regensburg on Thu Nov 17, 2011 9:12 pm, edited 2 times in total.
Reason:  
emendelson
Forum All-Star
Posts: 1726
Joined: Tue Oct 14, 2008 12:12 am

Re: Printing in OSX

Post by emendelson »

emaculation99 wrote:I have followed the instructions several times, bet every time I get "There are no zones on this network" in the printer selector of 'Apple Printer Utility'.
Actually, the instructions say to use the Desktop Printer Utility. They do not say to use the Apple Printer Utility. The steps listed in the instructions are not even possible to perform in the Apple Printer Utility.
emaculation99
Space Cadet
Posts: 3
Joined: Thu Nov 17, 2011 8:31 pm

Re: Printing in OSX

Post by emaculation99 »

Yes, indeed! I should be using Desktop Printer Utility, instead of Apple Desktop Printer Utility.

You know they 'sound' kind of the same!

But this was the only file found on my SheepShaver.

I will look around, and download the correct utility, and try again.

Thanks for your help.
User avatar
Ronald P. Regensburg
Expert User
Posts: 7833
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Printing in OSX

Post by Ronald P. Regensburg »

The "Desktop Printer Utility" is installed in the "Apple Extras" folder with a default MacOS 8.1 and later installation (possibly also with 7.6.1).

It is part of LaserWriter 8 printer driver version 8.5.1 or later. A default MacOS 9.0 installation includes LaserWriter 8 version 8.7 and Desktop Printer Utility version 1.2

If you do not have a full system installation, look for LaserWriter 8 version 8.5.1 (includes Desktop Printer Utility 1.0 and will work with System 7.5 and later) or LaserWriter 8.6.1 (includes Desktop Printer Utility version 1.1 and will work with MacOS 8.5 and later) on Apple's older software download page: http://www.info.apple.com/support/older ... elist.html
emaculation99
Space Cadet
Posts: 3
Joined: Thu Nov 17, 2011 8:31 pm

Re: Printing in OSX

Post by emaculation99 »

Yes! Found it, and it works perfect now! I tried it with 2 printers, an inkjet and a lazerwriter.

Now I just need to hook up the ImageWriter using a keyspan adapter, and hopefully I will be all done!

I will pick this up in the next few days:
http://www.tripplite.com/en/products/mo ... delID=3915

Thanks for the great help!
dholdmac
Space Cadet
Posts: 4
Joined: Mon Jan 02, 2012 7:16 pm

Re: Printing in OSX

Post by dholdmac »

I have followed the instructions for printing using very carefully( I think) and I'm having no luck.

My computer is a mac mini 2.3GHz i5 OS 10.7.2
SheepShaver 2.3.20091025 is installed Mac OS9.0.4 runs well (Appleworks 6 and Foxpro 2.6a, Internet explorer, and Outlook Express all run OK)
IP address 192.168.1.6
Printer hooked up with USB
Laserwriter 8 selected in chooser
In the desktop printer utility, the printer will not verify (queue name Brother_MFC_8460N)
CUPS-PDF (Queue name CUPS_PDF) will not verify
I have checked that Stealth Mode is off.

Any thoughts on where I may have gone wrong, or if printing is possible from this setup?

Thanks for any help you can provide.
User avatar
Ronald P. Regensburg
Expert User
Posts: 7833
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Printing in OSX

Post by Ronald P. Regensburg »

dholdmac wrote:Laserwriter 8 selected in chooser
You should not use the Chooser for this setup.
In the desktop printer utility, the printer will not verify (queue name Brother_MFC_8460N)
CUPS-PDF (Queue name CUPS_PDF) will not verify
I have checked that Stealth Mode is off.
You need to enter the printers queue name. Is also the IP-address of your Mac Mini entered correctly in the desktop printer utility and is printing sharing in MacOSX enabled with your printer selected as the shared printer?

You can also try to (temporarily) disable the firewall in MacOSX altogether while doing the setup. If your Mac Mini gets its IP-address automatically (by DHCP), that address may not always be the same. In that case, better give it a static address.

Code: Select all

Any thoughts on where I may have gone wrong, or if printing is possible from this setup?
With everything configured correctly, printing should be perfectly possible.
emendelson
Forum All-Star
Posts: 1726
Joined: Tue Oct 14, 2008 12:12 am

Re: Printing in OSX

Post by emendelson »

Ronald P. Regensburg wrote:
dholdmac wrote:Laserwriter 8 selected in chooser
You should not use the Chooser for this setup.
I've edited the instructions to include "Don't use the Chooser." It may not do any harm to use it, but it certainly won't help.

And, just to repeat what Ronald said: if printing doesn't work, then go back to the instructions, print them out, and follow them very carefully, checking off each step after finishing it.
dholdmac
Space Cadet
Posts: 4
Joined: Mon Jan 02, 2012 7:16 pm

Re: Printing in OSX

Post by dholdmac »

First, thanks for responding to this post. Making this work is important to me and I appreciate your patience.

I am now going through the instructions stepwise so that you can tell where I have gone wrong.

Restart the computer-System Preferences-Security & Privacy:firewall off:Stealth mode off
Start SheepShaver-SheepShaver preferences-Miscellaneous-Ethernet Interface:slirp
Click into SheepShaver-Control Panels-TCP/IP-Connect Via:Ethernet-Configure:Using DHCP Server-shut down Sheep Shaver
In OSX-Apple Menu-About This Mac-More Info-System Report-Network-WiFi IPv4 Address 192.168.1.4 Close System Profiler
OSX System Preferences-Sharing-Printer Sharing:checked-Printers:Checked and highlighted:Brother MFC-8460N-Open Print & Scan Preferences-Open Print Queue-Printer Setup
highlight Queue Name:Brother_MFC_8460N copy to clipboard-OK-close System Preferences.
Start SheepShaver-find Desktop Printer Utility-With Laserwriter 8-Create Desktop highlight Printer (LPR)-OK-LPR Printer Selection-Change- Printer Address:192.168.1.4-Queue:Brother_MFC_8460N using Cmd-V-Verify:The printer cannot be verified


Attempt to add static IP Address:(I really do not know what to do here)
System Preferences-Network-Ethernet-Configure:Manually-IP Address:192.168.1.4-Subnet Mask:255.255.255.0-Router:192.168.1.1- clicked lock to make changes

About This Mac-More Info-System Report-Network- Ethernet IPv4 Address and Wifi IPv4 Address:192.168.1.4

Start SheepShaver-find Desktop Printer Utility-With Laserwriter 8-Create Desktop highlight Printer (LPR)-OK-LPR Printer Selection-Change -printer Address:192.168.1.4-Queue:Brother_MFC_8460N using Cmd-V-Verify:The printer cannot be verified

The static address thing I'm not sure of but going through the instructions step by step checking each step off Ithink I've done. But obviously I've missed something, maybe you can tell from these notes.

Thanks.
emendelson
Forum All-Star
Posts: 1726
Joined: Tue Oct 14, 2008 12:12 am

Re: Printing in OSX

Post by emendelson »

In step 5, try entering 10.0.2.2 instead of your actual IP address. Let us know if it works.
User avatar
Ronald P. Regensburg
Expert User
Posts: 7833
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Printing in OSX

Post by Ronald P. Regensburg »

I don't think that can work. 10.0.2.2 is the slirp "router" address.

Please undo the the static ethernet address you entered. Your Mac is on a WiFi network. You should then set a static address for that network. That address should best be out of range of the DHCP distributed addresses. If you do not know how to do that, please ignore this. Just undo what you did.
dholdmac wrote:Click into SheepShaver-Control Panels-TCP/IP-Connect Via:Ethernet-Configure:Using DHCP Server
The addresses assigned by DHCP should be shown in the TCP/IP control panel. If they are not, configure manually:

Connection: Ethernet
Configure: Manually
IP address: 10.0.2.15
Subnet Mask: 255.255.255.0
Router address: 10.0.2.2
Name Server (DNS) address: 10.0.2.3
emendelson
Forum All-Star
Posts: 1726
Joined: Tue Oct 14, 2008 12:12 am

Re: Printing in OSX

Post by emendelson »

Ronald P. Regensburg wrote:I don't think that can work. 10.0.2.2 is the slirp "router" address.
10.0.2.2 absolutely does work. It's what I use under Lion. When I first wrote those instructions, I didn't know about 10.0.2.2, but that's what I use now.

If anyone can confirm what I think is true - which is that 10.0.2.2 also works under Snow Leopard (and maybe Leopard) - I'll change the instructions. This would certainly simplify things.
User avatar
Ronald P. Regensburg
Expert User
Posts: 7833
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Printing in OSX

Post by Ronald P. Regensburg »

Printing to 10.0.2.2 indeed works here in Snow Leopard, but only with SheepShaver running in 64-bit mode. Versions that are 32-bit only as well as my november 2010 build when set to run in 32-bit mode will consistently crash when I try to print.

Edit: This appears to be true also for printing to the hosts IP-address.
I suppose for printing to a printer that is shared on the host, one needs 64-bit SheepShaver in Lion and in Snow Leopard on 64-bit capable machines. (Early Intel Macs can run Snow Leopard, but are not 64-bit capable and cannot run Lion.)
Last edited by Ronald P. Regensburg on Tue Jan 10, 2012 7:52 pm, edited 1 time in total.
Reason:  
emendelson
Forum All-Star
Posts: 1726
Joined: Tue Oct 14, 2008 12:12 am

Re: Printing in OSX

Post by emendelson »

Hmmm... I'm using a 32-bit build which I downloaded from this very site. I think it's the 25 October 2009 build, but I'm away from my Mac for the next few hours, so I can't be certain. It's the same one that's in my SheepShaver Wrapper setup, described (and linked to) here:

http://www.emaculation.com/forum/viewto ... =33&t=7363

That prints perfectly to 10.0.2.2 every time.

I also use it in a completely prebuilt system that runs WordPerfect for the Mac, and which automatically installs a printer (or PDF writer) in SheepShaver, using GUI scripting for OS 8/9. But I don't think it's OK to post a link to it here, for the same reasons that this board doesn't post links to other prebuilt systems. Incidentally, in putting that system together, I found that printing sometimes doesn't work until shutting down MacOS and SheepShaver, and then starting up SheepShaver again. You might want to try that.
dholdmac
Space Cadet
Posts: 4
Joined: Mon Jan 02, 2012 7:16 pm

Re: Printing in OSX

Post by dholdmac »

In review:
My computer is a mac mini 2.3GHz i5 OS 10.7.2
SheepShaver 2.3.20091025(32 bit build?) is installed-Mac OS9.0.4(from disk image) runs well
Printer(Brother MFC-8460N) hooked up with USB Cable
About This Mac-More Info-System Report-Network-WiFi IPv4 address 192.168.1.4
In System Preferences-Sharing-print sharing on Brother printer checked and highlighted-Open Print Queue-Printer Setup-Highlight Queue Name- Cmd-C:(Brother_MFC_8460N)

First I will try 10.0.2.2 into Desktop Printer Utility:
In SheepShaver-Desktop Printer Utility-Printer LPR-LPR Printer Selection-Change-Printer Address:10.0.2.2 -Queue:Cmd-V(Brother_MFC_8460N)- Verify-The printer cannot be verified

The next effort is with the Fixed IP address:
I was able to get OSX happy with 192.168.1.201 with internet and mail working well.

Went into SS with this address-desktop printer utility etc... The printer cannot be verified.
As a side note with the DCHP assigned IP Address the internet and mail from SS worked
fine. With the static address not happy at all.

Next I tried setting up SS on my son's Macbook 2GHz Intel Core Duo with OSX 10.5.8
Everything went well. Printing was enabled the first try.

However printing seems to be only one page, multiple copies are not supported.

I would still like to get this to run with 10.7 on the i5 mac mini. if you have any ideas.

Thanks
User avatar
Ronald P. Regensburg
Expert User
Posts: 7833
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Printing in OSX

Post by Ronald P. Regensburg »

dholdmac wrote:As a side note with the DCHP assigned IP Address the internet and mail from SS worked fine. With the static address not happy at all.
Static address where? In the host or in SS? A working static address vs automatically assigned address in MacOSX should not make any difference as long as the address is at that moment the actual address (a automatically assigned address may not always be the same). In SS it needs to be DHCP (or the addresses I mentioned above, which are the same addresses that would be obtained from DHCP).
I would still like to get this to run with 10.7 on the i5 mac mini. if you have any ideas.
According to emendelson 32-bit SheepShaver should work also, but you could try a 64-bit version (see sticky topic about SheepShaver for MacOSX).

However, your problem is not with printing itself. The problem already starts with not being able to verify the printer during LPR desktop printer setup. That is really strange. Especially the 10.0.2.2 address should be found from within SheepShaver, no matter what.
dholdmac
Space Cadet
Posts: 4
Joined: Mon Jan 02, 2012 7:16 pm

Re: Printing in OSX

Post by dholdmac »

Static address in the host,that is in OSX

Since everything worked so well on the Laptop, I am going to start from scratch and remove SS from my mac mini using your instructions and start from scratch.
Maybe something went wrong when I loaded it in.

I will do this tonight and let you know. Time to go to work.

Thanks
User avatar
Ronald P. Regensburg
Expert User
Posts: 7833
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Printing in OSX

Post by Ronald P. Regensburg »

I have a new problem setting up new LPR desktop printers in both SheepShaver and BasiliskII on my iMac with OSX 10.6.8. I used to be able to set up LPR desktop printers before.

Whatever I try, I get a "The printer cannot be verified" during setup with the Desktop Printer Utility. It happens regardless whether I use the IP address of my the host Mac (10.0.1.13) or the slirp router address 10.0.2.2 and regardless which SheepShaver or BasiliskII build I try, new builds or old builds, 32-bit or 64-bit. Verification works fine when I use my printer's IP address (10.0.1.12), but that will not result in a working setup as my printer is not a PostScript printer.

It is exactly as when in the past I had stealth mode enabled in System Preferences > Security > Firewall > Advanced. But I made sure stealth mode is not enabled. In fact, I did not only disable stealth mode, but also turned the firewall off and disabled some firewall features in Virus Barrier X6, although that was not necessary in the past to be able to create LPR printers in SheepShaver and BasiliskII. I also have printer sharing turned on and my printer selected as the shared printer.

It may well be possible that existing LPR desktop printers would have continued to work (as did LPR desktop printers after again enabling stealth mode in the firewall), but I deleted them, so I cannot try.

Because it is so similar to what happened before with stealth mode enabled, I suspect that one of the recent security updates for OSX 10.6 somehow makes the host machine invisible from within SheepShaver and BasiliskII.

Are others with fully updated Snow Leopard or Lion having problems creating new LPR desktop printers, problems that they did not have before?

Again, this is about creating new LPR desktop printers, not about using them.
User avatar
Cat_7
Expert User
Posts: 6172
Joined: Fri Feb 13, 2004 8:59 am
Location: Sittard, The Netherlands

Re: Printing in OSX

Post by Cat_7 »

No problem in 10.7.3. SheepShaver from the sticky post, running in 32 bit. Mac OS 9.0.4.
Verification of a new desktop printer works with firewall on (stealth disabled). Printing works to a USB connected Epson printer.

Problems in 10.6.8. SheepShaver from the sticky post, running in 32 bit: sometimes no verification possible! and printing to a desktop printer that runs OK in 64 bit mode, sometimes doesn't work.
Running in 64 bit: verification on IP address alone already works, but also when using queue name. Printing works OK.

The issue seems to be that Networking doesn't always work in 32 bit mode. When I can't connect to the internet, I can't connect to printers on my host.
I tried setting TCP/IP in Mac OS to always load, but that didn't change a thing.

Best,
Cat_7
Last edited by Cat_7 on Sat Mar 24, 2012 1:27 pm, edited 5 times in total.
Reason:  
User avatar
Ronald P. Regensburg
Expert User
Posts: 7833
Joined: Thu Feb 09, 2006 10:24 pm
Location: Amsterdam, Netherlands

Re: Printing in OSX

Post by Ronald P. Regensburg »

Ronald P. Regensburg wrote:I have a new problem setting up new LPR desktop printers in both SheepShaver and BasiliskII on my iMac with OSX 10.6.8. I used to be able to set up LPR desktop printers before.
Solved, although I do not know which action I took eventually solved the issue.

- I again disabled stealth mode in the firewall and turned the firewall off
- I enabled printer sharing and selected my printer to be the shared printer
- I edited the CUPS conf file: "BrowseLocalProtocols CUPS dnssd lpd" (somehow "lpd" at the end of this line had disappeared)
- Restarted my iMac.

Now creating LPR desktop printers to 10.0.2.2 (the slirp router address) works in SheepShaver in both 32-bit mode and in 64-bit mode.

Printing to the shared printer works fine in 64-bit mode. But in 32-bit mode SheepShaver crashes when I try to print.

I reported the same issue with SheepShaver in 32-bit mode earlier in this thread. Cat_7 reports similar issues in 10.6.8 when trying to print to the OSX shared printer in SheepShaver in 32-bit mode, but I never had the problems connecting to the internet he mentions.
Post Reply