Reply
 
Thread Tools Display Modes
  #1  
Old 04-24-2010, 05:35 PM
bforest bforest is offline
Senior Member
 
Join Date: Feb 2009
Location: Va, USofA
Posts: 154
Thanks: 11
Thanked 8 Times in 6 Posts
Default Printing from VirtualBox to Local Host printer.
Hello all,

I am running a WindowsXPP VirtualBox under PCBSD Host.

VirtualBox is installed and maintained via PBI and PCBSD Update Manager.

Code:
[user@pcbsd-2153]/home/user(101)% uname -a
FreeBSD pcbsd-2153 8.0-RELEASE-p2 FreeBSD 8.0-RELEASE-p2 #4: Thu Jan  7 09:20:42 PST 2010
     root@build8x32.pcbsd.org:/usr/obj/usr/pcbsd-build80/fbsd-source/8.0-src/sys/PCBSD  i386
I have a parallel printer (HP1300 laser) attached to the PCBSD host. I need to be able to print to this local printer from the virtual machine. I can print to the printer fine via PCBSD (CUPS configuration). I assume I need to tell PCBSD to share this printer and have the VM print to the CUPS on the host.

1) I am thinking I need to open the firewall on PCBSD to allow the VM to contact the CUPS installation. True?

2) Also, CUPS has a driver for this printer but so does Windows. Should I set up a second instance of this printer with some kind of "RAW" passthrough driver that will allow the VM to get to the printer without any modification to the data?

Thanks
__________________
- Ben

Last edited by bforest; 04-24-2010 at 05:38 PM. Reason: minor mod
Reply With Quote
  #2  
Old 04-26-2010, 01:35 PM
kmoore134's Avatar
kmoore134 kmoore134 is offline
Administrator
 
Join Date: May 2005
Location: Knoxville, TN
Posts: 2,568
Thanks: 0
Thanked 163 Times in 127 Posts
Default Printing from VirtualBox to Local Host printer.
I'm thinking that yes, you'll need to share the printer via cups/samba,
and then add a network printer in XP for it to work.

The instructions will vary a bit depending upon your network
configuration, printer type, etc, but a quick google search plenty of
the relevant information:

http://tldp.org/HOWTO/Debian-and-Win...h_windows.html

The default smb.conf file on PC-BSD is in /usr/local/etc/smb.conf, and
to restart samba server, you use /usr/local/etc/rc.d/samba restart.

Aside from that, it'll take some trial and error to get it enabled, but
on the Win client side, you'll want to search for 10.0.2.2 as the host
for the printer.
__________________
----
Kris Moore
PC-BSD Founder
Reply With Quote
  #3  
Old 04-27-2010, 11:20 AM
bforest bforest is offline
Senior Member
 
Join Date: Feb 2009
Location: Va, USofA
Posts: 154
Thanks: 11
Thanked 8 Times in 6 Posts
Default Solved...
Thank you so much for the reply!

Actually I did get this working day before yesterday.

1) I did open the ipp(port 631) on the firewall but after it was working I removed this entry and it continues to work.

2) I ended up using the existing printer setup in PCBSD. (Did not create a RAW printer) This is an HP printer so it uses that HPLIP driver. It seems to handle the printing ok.

I set up the printer in WinXPP. That was interesting. Set up as a network printer.

First, assigned a name to the PCBSD host in the C:\Windows\System32\drivers\etc\host file. (Actually I used the Network IP. Maybe I should change to the internal one you suggested)

Next, went to the printer via the browser on WinXPP to see the printer name/URI (http://hostname:631/printers) so... ... The network URI is: http://hostname:631/printers/lp for me.

After that, it just worked.

Using the Web CUPS interface I could see jobs getting into the queue. I still need to do some testing with the user with printing from their Win applications to make sure there is no interference from the driver on PCBSD. If there is I will try making a RAW printer to print to.

BTW: This is one of those WORKERS as in (No Play) I was concerned how PCBSD would be received but felt it was ready. So far, they Love it!
__________________
- Ben
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 10:30 AM.


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.

Copyright 2005-2010, The PC-BSD Project. PC-BSD and the PC-BSD logo are registered trademarks of iXsystems.
All other content is freely available for sharing under the terms of the Creative Commons Attribution License.