Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Networking
User Name
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.


  Search this Thread
Old 06-16-2006, 08:00 PM   #1
Registered: Sep 2004
Distribution: Debian Tesing / Unstable
Posts: 169
Blog Entries: 1

Rep: Reputation: 30
Autofs auto.smb attempts to mount printer drivers

In the Debian Autofs package the auto.smb script contains the following line:

/Disk/ { if (first) { print opts; first=0 }; print " \\\n\t /" $2, "://" key "/" $2 }

SAMBA for some reason lists printer drivers as 'Disk' shares:

Disk|print$|Printer Drivers
Printer|HPLJ4L|HP LaserJet 4L

This produces error messages when a mount is attempted for


which doesn't exist:

automount[17409]: mount(generic): calling mount -t cifs -s -o rw,credentials=/etc/auto.cifs.DELL3000
//DELL3000/print /smb/DELL3000/print
Jun 16 19:32:50 EMACH433 automount[17409]: >> retrying with upper case share name
Jun 16 19:32:50 EMACH433 automount[17409]: >> mount error 6 = No such device or address

Any way to either modify the awk program in auto.smb to exclude the 'print$' service or modify the smbclient
options to list hard drives only?
Old 06-20-2006, 07:50 PM   #2
Registered: Sep 2004
Distribution: Debian Tesing / Unstable
Posts: 169
Blog Entries: 1

Original Poster
Rep: Reputation: 30
Fixed by inserting a couple of 'if' statements to weed out the 'printer driver' shares reported by Win9x (PRINTER$) and WinXP (print$):

BEGIN { ORS=""; first=1 }
/Disk/ { if (first) { print opts; first=0 }; if ($2 != "PRINTER$") { if ($2 != "print$") print " \\\n\t /" $2, "://" key "/" $2 } }
END { if (!first) print "\n"; else exit 1 }


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
smb mount folders disappear on mount & konqueror smb fails: network unreachable tisource Linux - Networking 1 10-17-2007 12:30 AM
Autofs auto.smb attempts to mount printer drivers sixerjman Linux - Software 0 06-16-2006 07:31 PM
using autofs to auto mount my usb drives DesertWolf0132 Slackware 8 07-30-2004 10:27 AM
how to mount fstab vs autofs rrich100 Red Hat 1 11-13-2003 11:46 PM
autofs enabled in kernel but auto.mount and auto.master are NOT in /etc! Alybyzrp Linux - General 0 11-11-2003 12:26 PM

All times are GMT -5. The time now is 06:19 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration