Share Printers from Ubuntu host and VirtualBox Windows guest

Ubuntu Host

First of all you have to enable printer sharing, so open Printer Configuration from System/Administraton/Printing

ubuntu_share_printers_01

choose menĂ¹ Server/Settings

ubuntu_share_printers_02

enable check “Publish shared printers connected to this system”

ubuntu_share_printers_03

Ok, host is ok, and I hope you have printer installed…

Windows VirtualBox Guest

By default your network card is configured with a virtual nat router, and the only thing we need is host relative ip address, usually 10.0.2.2, but find out how to retrieve:

1. open a command prompt

2. execute “ipconfig -all” command to retrive guest virtual ip address (for example 10.0.2.15)

3. check gateway ip (for example 10.0.2.2)

this is host address from guest you can share a printer.

On Windows guest click on Start/Control Panels/Printers, and click on Add a Printer:

windows_share_printers_01

wow, great informations!, click Next

windows_share_printers_02windows_share_printers_02

Choose “A network printer, or a printer attached to another computer”,

windows_share_printers_03

choose last option and fill URL field with:

http://10.0.2.2:631/printers/yourprintername

where “yourprintername” is your printer name…

Click next, and set other parameters to setup you new network printer.

Uhm, printer name…

If you have some problems with printer name, open in browser

http://10.0.2.2:631/printers

it shows you very usefull informations about host shared printers.

Bye

VN:F [1.9.15_1155]
Rating: 0.0/10 (0 votes cast)
VN:F [1.9.15_1155]
Rating: 0 (from 0 votes)

8 Responses to “Share Printers from Ubuntu host and VirtualBox Windows guest”

  1. lm says:

    thank you for the lesson
    j’ve stepped through the lesson

    but typing http://10.0.2.2:631/printers

    gives me can not find the printer

    VA:F [1.9.15_1155]
    Rating: 0.0/5 (0 votes cast)
    VA:F [1.9.15_1155]
    Rating: 0 (from 0 votes)
  2. lm says:

    http://10.0.2.2:631/printers

    VA:F [1.9.15_1155]
    Rating: 0.0/5 (0 votes cast)
    VA:F [1.9.15_1155]
    Rating: 0 (from 0 votes)
  3. lm says:

    thank you for the lesson
    j’ve stepped through the lesson

    but typing http://10.0.2.2:631/printers/LPB3010B

    gives me can not find the printer

    VA:F [1.9.15_1155]
    Rating: 0.0/5 (0 votes cast)
    VA:F [1.9.15_1155]
    Rating: 0 (from 0 votes)
  4. admin says:

    Open in browser

    http://10.0.2.2:631/printers

    you should see printers;
    you can also test ip address with ping command.

    VN:F [1.9.15_1155]
    Rating: 0.0/5 (0 votes cast)
    VN:F [1.9.15_1155]
    Rating: 0 (from 0 votes)
  5. lm says:

    browser in ubuntu
    ——————
    http://10.0.2.2:631/printers
    == Server not found Firefox can’t find the server at http://www.10.0.2.2.

    browser in windows virtual
    ————————–
    http://10.0.2.2:631/printers
    ===la page est introuvable

    in windows
    ———-
    test ip address with ping command
    ping 10.0.2.2
    it works

    in terminal ubuntu : gedit /etc/cups/cupsd.conf
    ———————————————–
    LogLevel warn
    MaxLogSize 0
    SystemGroup lpadmin
    # Allow remote access
    Port 631
    Listen /var/run/cups/cups.sock
    Share local printers on the local network.
    Browsing On
    BrowseOrder allow,deny
    BrowseRemoteProtocols
    BrowseAddress @LOCAL
    BrowseLocalProtocols CUPS dnssd
    DefaultAuthType Basic

    # Allow shared printing…
    Order allow,deny
    Allow @LOCAL

    # Restrict access to the admin pages…
    Order allow,deny

    ………………………………………….
    ………………………………..

    *

    VA:F [1.9.15_1155]
    Rating: 0.0/5 (0 votes cast)
    VA:F [1.9.15_1155]
    Rating: 0 (from 0 votes)
  6. admin says:

    OK, Windows VM see 10.0.2.2 Ubuntu host.
    Windows can not navigate to http://10.0.2.2:631/printers.

    It seems print service is not available from Windows guest, so to check service you should from Ubuntu navigate http://127.0.0.1:631/printers; if you see it’s on, you have to allow print service to all network.

    Have you done a restart, after install cups?

    I hope you find a solution!

    VN:F [1.9.15_1155]
    Rating: 0.0/5 (0 votes cast)
    VN:F [1.9.15_1155]
    Rating: 0 (from 0 votes)
  7. lm says:

    thank you for your help
    I am create a IP fixed in ubuntu
    I have change host file in windows vm

    in connect printer
    http://lm-desktop:631/LBP3010B

    it works

    thank you again for your hel

    exuce me for my English
    because I speak French

    VA:F [1.9.15_1155]
    Rating: 0.0/5 (0 votes cast)
    VA:F [1.9.15_1155]
    Rating: 0 (from 0 votes)
  8. lm says:

    from Ubuntu navigate http://127.0.0.1:631/printers

    http://img28.imageshack.us/img28/5193/capture1n.png

    VA:F [1.9.15_1155]
    Rating: 0.0/5 (0 votes cast)
    VA:F [1.9.15_1155]
    Rating: 0 (from 0 votes)

Leave a Reply