Solved

How to print from Windows on a remote unix server accessible with ssh

Posted on 2004-09-21
9
499 Views
Last Modified: 2013-12-23
Not sure if this is the right channel... I have an XP workstation and I can ssh to a unix server with LJ 4100 attached. I used to be able to use LPD/IPP to print from Windows on the remote printer, but the latest security enhancements don't let any traffic through but ssh (and Windows file sharing). Now to print the files I have to print to file first, copy the file to the server, then print it from the unix command line. I'd like to be able to just print from Windows without the intermediate steps. Is this possible? I know how to use ssh to print a remote file on a local printer, but I have an opposite situation. Needless to say, I don't have any admin privileges on the server, only on my workstation.
0
Comment
Question by:sergeis
  • 4
  • 3
  • 2
9 Comments
 
LVL 40

Expert Comment

by:jlevie
ID: 12123957
Have you asked about having LPD or IPP access enabled? If the remote site allows windows file sharing I can't see how IPP would present a greater security risk.
0
 
LVL 1

Author Comment

by:sergeis
ID: 12124627
Even before, when IPP worked, to print I had to login to my own workstation as a limited user with exact same credentials as my remote account, due to the stupid way XP does IPP (can't be a different user, unlike for file sharing). And no, the sysadmin is not the friendly type, so I just want to try and work around them. Many gave up and set up their own little networks, but I can't afford a LJ of my own, and everybody else is now behind their own firewall, so the central server is the only one I can reach. So how about remote printing over ssh from Windows?

Points doubled...
0
 
LVL 40

Expert Comment

by:jlevie
ID: 12125005
I'm sorry, but I can't think of a way other than printing to a file, transfering that to the remote server and then executing the print command on the remote. You could, since SMB file sharing is allowed, simplify things by printing to a file on a share mapped from the remote. And I suppose you could run a "watcher script" on the remote that looks for the print file in a specified location, submits that job and then deletes the print file. If you ran that in the background it would be sort of a remote printer.
0
Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

 
LVL 14

Expert Comment

by:chris_calabrese
ID: 12126708
Since SMB is allowed, then if the *nix server is running Samba, you could have the *nix admins setup a Samba share for the printer. That way it would look like a Windows server exporting a printer share to your PC.
0
 
LVL 1

Author Comment

by:sergeis
ID: 12128097
This may be an acceptable workaround. However, the sysadmin will definitely not spend his time creating a special samba printer share just for me. And I'm not about to start a remote printing support rally in this place. I just want to rpint without extra hassles. The sysadmin also frowns upon running your own infinite background script, even at nice -19. I guess a once-a-minute cron script wouldn't be that noticeable. Anyone cares to post one here, or suggest alternatives?
0
 
LVL 14

Expert Comment

by:chris_calabrese
ID: 12133426
Instead of a watcher script you could also kick off the script on the far end through SSH. If you're using PuTTY, for example, you could do this using PuTY's plink command-line interface. Package the plink call and the remote copy into a single batch script that you run after printing to a fixed-named file.
0
 
LVL 1

Author Comment

by:sergeis
ID: 12139559
Well, this defeats the purpose of transparent remmote printing. I might as well run ados or a cygwin script that logs in, copies the local file to remote machine, then prints, deletes and logs out... I guess I'd have to write the scripts myself. Any other suggestions?
0
 
LVL 40

Accepted Solution

by:
jlevie earned 400 total points
ID: 12139731
>  Well, this defeats the purpose of transparent remmote printing.

Quite true, but that's partly a result of your local system being windows and partly the result of an over-zealous and less-than-helpful SysAdmin. If the local system was a Linux or Unix system it would very easy to create a print filter that would transfer the file via scp, issue the ssh command to print it, and the delete the print file. That's a non-trivial task in windows. In a like manner the SysAdmin could be a bit more helpful and enable LPD/IPP or an SMB print share. We've just been trying to give you the least painful ways of working around the restrictions you face.
0
 
LVL 1

Author Comment

by:sergeis
ID: 12148288
Well, I have created a crontab entry, and it's working sufficiently well. Hope they don't disable my 1-min crontab...  Shouldn't be that noticeable? Thanks for the idea jlevie, even though I had to do my own thinking as well :).
0

Featured Post

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This is an article about my experiences with remote access to my clients (so that I may serve them) and eventually to my home office system via Radmin Remote Control. I have been using remote access for over 10 years and have been improving my metho…
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Viewers will learn how to connect to a wireless network using the network security key. They will also learn how to access the IP address and DNS server for connections that must be done manually. After setting up a router, find the network security…
In this tutorial you'll learn about bandwidth monitoring with flows and packet sniffing with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're interested in additional methods for monitoring bandwidt…

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question