Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Wed 27 May 2015, 04:16
All times are UTC - 4
 Forum index » Advanced Topics » Hardware » Printers
IP4CUPS - a Network Printer Tool
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [5 Posts]  
Author Message
rcrsn51


Joined: 05 Sep 2006
Posts: 9938
Location: Stratford, Ontario

PostPosted: Tue 06 Jan 2015, 08:40    Post subject:  IP4CUPS - a Network Printer Tool  

In Windows, a standalone network printer is identified by its MAC address or NETBIOS name. So a Windows client can always find the printer even if the printer's IP address changes. However, CUPS configures its printers by IP address. If you reset your network and the printer gets a new address, you must reinstall it on every Puppy client machine.

The best solution is to give the printer a permanent static IP address. Many printers can do this through their own LCD control panel or through the printer's web interface. In some cases, you must run network configuration software through Windows. But if you don't want to bother with static IP, here is a one-click alternative. Use it on each Puppy client.

1. Install the ip4cups-1.3.pet attached below. It puts a menu entry in System.

2. Pick a simple one-word identifier for the printer, like EpsonNet.

3. Run the CUPS wizard and auto-detect your printer. Identify the Connection URI, like
Code:
socket://192.168.2.13:9100  or
lpd://192.168.2.14:515/PASSTHRU

4. But instead of auto-installing the printer, do a manual install. Replace the IP address with the name from Step 2.

For example, if your printer is auto-detected as a socket printer, manually install it using the AppSocket/JetDirect protocol as
Code:
socket://EpsonNet:9100

5. From the command line, run: arp-scan --localnet

6. Ignore the warning messages and locate the printer's IP. Write down its MAC address 00:11:22:33:44:55.

7. Go to /usr/sbin and open the file ip4cups in a text editor. Modify the final LOOKUP line to contain the items from Steps 2 and 6.

8. From the System menu, run IP4CUPS. There will be a pop-up confirmation message.

9. Open the file /etc/hosts. Note how the printer's name is associated with its current IP address.

10. Print something. CUPS will look up your printer's IP address in the hosts file.

11. The next time that your network resets, just run IP4CUPS again.

IP4CUPS can handle multiple printers. Add a LOOKUP line for each device.

The hosts file can also be used with some models of networked scanners. Epson and HP have been confirmed to work.

---------------------------------
Back to top
View user's profile Send private message 
ralplpcr

Joined: 06 Jan 2014
Posts: 22

PostPosted: Wed 06 May 2015, 20:31    Post subject:  

FYI - I'm not seeing any ip4cups-1.3.pet attached in this post. Did you miss attaching it?
Back to top
View user's profile Send private message 
starhawk

Joined: 22 Nov 2010
Posts: 3838
Location: Everybody knows this is nowhere...

PostPosted: Wed 06 May 2015, 21:15    Post subject:  

I'm not seeing an attachment, either... a pity -- I'd love to have that feature.
_________________

Back to top
View user's profile Send private message 
starhawk

Joined: 22 Nov 2010
Posts: 3838
Location: Everybody knows this is nowhere...

PostPosted: Wed 06 May 2015, 21:40    Post subject:  

The dotPET was PM'd to me.

I followed the instructions in this thread almost exactly to the letter. The only thing I did differently was to delete the existing printer install as I was effectively reinstalling the printer a different way.

Success!

If I could ask one small favor...

I have an extremely unusual Internet situation, in that my router has to be reset at least once a day due to heat. It's actually not a defective router -- it's an uncaring ISP -- we have Verizon and the signal is so weak that the router overheats pulling it in. (Of course if we want a better signal we have to move... there literally are no other options in our area. I've looked.) There are literally not enough swear words in the English language to do proper justice to that vile corporation.

Is there a way to turn this into a sort of a daemon sort of a thing that runs automatically whenever the 'Net is lost and then reconnected again? (Maybe by detecting whenever Puppy receives an IP address of its own?)

_________________

Back to top
View user's profile Send private message 
rcrsn51


Joined: 05 Sep 2006
Posts: 9938
Location: Stratford, Ontario

PostPosted: Wed 06 May 2015, 22:49    Post subject:  

Glad to hear that IP4CUPS works for you. The previous versions were downloaded many hundreds of times and I never got a single report back.

Regarding the daemon: maybe you could set up a cron job that simply runs the ip4cups script at regular intervals. There is no problem if you run ip4cups when the IP address has NOT changed.

Or just add it to your Startup folder.
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [5 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Hardware » Printers
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0583s ][ Queries: 11 (0.0100s) ][ GZIP on ]