LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 07-06-2007, 12:12 PM   #1
pwabrahams
Member
 
Registered: Nov 2005
Location: Deerfield MA
Distribution: OpenSuSE, Kubuntu
Posts: 272

Rep: Reputation: 41
Mounting Samba shares under OpenSuSE and Kubuntu


I'm running OpenSuSE 10.2 (with KDE) on one of my machines and Kubuntu Feisty Fawn on another. Both systems are fully updated. I'm trying to mount a Samba share on each of them. I can access the share using Konqueror (with the smb: protocol) without difficulty on either machine, but mounting it is a different story. I've tried mounting it using both "-t cifs" and "-t smbfs", and I've installed winbind (or, in the case of OpenSuSE, winbind-samba).

Under OpenSuSE I get:

Code:
suillus:~ # mount -t cifs //hpmediavault/FileShare /mediavault
mount error: could not find target server. TCP name hpmediavault/FileShare not found
No ip address specified and hostname not found
suillus:~ # mount -t smbfs //hpmediavault/FileShare /mediavault
mount: wrong fs type, bad option, bad superblock on //hpmediavault/FileShare,
       missing codepage or other error
       In some cases useful info is found in syslog - try
       dmesg | tail  or so
suillus:~ #
But under Kubuntu I get:

Code:
root@lepiota:~# mount -t cifs //hpmediavault/FileShare /mediavault
mount error: could not find target server. TCP name hpmediavault/FileShare not found
No ip address specified and hostname not found
root@lepiota:~# mount -t smbfs -o guest //hpmediavault/FileShare /mediavault
root@lepiota:~#
So the mount under Kubuntu is apparently successful. However, it turns out to be read-only and I haven't managed to change that.

So how can I do the mount under OpenSuSE? Why do the two systems behave differently? And why is the mount read-only under Kubuntu?
 
Old 07-07-2007, 05:49 AM   #2
camorri
Senior Member
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 14.1
Posts: 4,851

Rep: Reputation: 432Reputation: 432Reputation: 432Reputation: 432Reputation: 432
Why are you bothering with Samba for file sharing on two linux boxes? NFS is simple to install and configure. Takes about 10% of the time and effort of Samba. It is fast, the shares mount into your file system without any trouble.

You need to configure your /etc/exports file, these define your shares, then a hosts.allow file and hosts.deny file. See the tutorials on this board.

Samba is windoze code and is only needed to share with windbloze machines.
 
Old 07-07-2007, 12:18 PM   #3
pwabrahams
Member
 
Registered: Nov 2005
Location: Deerfield MA
Distribution: OpenSuSE, Kubuntu
Posts: 272

Original Poster
Rep: Reputation: 41
I really do need Samba

My problem is not with the two machines communicating with each other. It's with each of them individually communicating with my HP Media Vault, which looks to the network like a Windows machine. So for that I really do need Samba. I also have Windows machines on my network aside from the Media Vault unit (which is quite nice).
 
Old 07-08-2007, 06:47 AM   #4
camorri
Senior Member
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 14.1
Posts: 4,851

Rep: Reputation: 432Reputation: 432Reputation: 432Reputation: 432Reputation: 432
O.K. so the HP vault is a windoze machine. That was not clear from your first post.

What flavor of windoze is it?

Notice both linux systems report "couldn't find target..."

Are these machines all on the same subnet?

Have you updated the /etc/hosts files on each linux system with the hostnames of vault? You probably need to update the hosts file on vault as well.
 
Old 07-08-2007, 11:17 AM   #5
rossonieri#1
Member
 
Registered: Jun 2007
Posts: 359

Rep: Reputation: 34
hi pwabrahams,

from yours :
mount error: could not find target server. TCP name hpmediavault/FileShare not found
No ip address specified and hostname not found

try to change the name to IP.

HTH.
 
Old 07-08-2007, 04:23 PM   #6
pwabrahams
Member
 
Registered: Nov 2005
Location: Deerfield MA
Distribution: OpenSuSE, Kubuntu
Posts: 272

Original Poster
Rep: Reputation: 41
HP Media Vault

The HP Media Vault is a Network Attached Storage (NAS) unit. As far as I know it isn't actually running Windows but supports the Windows protocols. I doubt if it has a Windows license. In any event it has no attached terminal nor any way to attach a terminal.

I know I can bypass the mount problems by specifying the IP address of the HP unit in one way or another, either by specifying it explicitly in the mount or using /etc/hosts to record it. But that seems to me to be "cheating", given that the older version of Samba didn't need an explicit IP address and Konqueror has no trouble figuring out the IP address without any further assistance. As I understand it, winbind is supposed to make this problem go away -- and it more or less does under Kubuntu aside from the surprising read-only behavior.
 
Old 07-29-2007, 06:04 PM   #7
Baloo_PNW
LQ Newbie
 
Registered: Jun 2006
Posts: 12

Rep: Reputation: 0
I'm in the same boat. Since upgrading from Suse 9.3 to 10.2 the two Suse Boxes on my home network will no longer mount samba shares without suppllying fstab with an ip address. XP boxes and Macs have no problem mounting any of the shares but only smb://Server/Share/ works on Suse. Any help would be greatly appreciated. I really don't want to have manage static ips and I can't understand how/why the upgrade killed the older functionality

Thanks.
 
Old 07-30-2007, 05:38 AM   #8
camorri
Senior Member
 
Registered: Nov 2002
Location: Somewhere inside 9.9 million sq. km. Canada
Distribution: Slackware 14.1
Posts: 4,851

Rep: Reputation: 432Reputation: 432Reputation: 432Reputation: 432Reputation: 432
Quote:
As I understand it, winbind is supposed to make this problem go away
After spending some time with Samab 3 doc, as I understand it, winbind is for resolving users, groups and authentication, not resolving IP to host names.

That task is done by lmhosts file. Have you looked into the contents of lmhosts? This is something like the 'hosts' file but for samba. It is supposed to be located in the same directory as smb.conf.
 
Old 07-30-2007, 07:06 PM   #9
Baloo_PNW
LQ Newbie
 
Registered: Jun 2006
Posts: 12

Rep: Reputation: 0
From what I can tell lmhosts is just another way to map static ips to NetBios Host names. What I'm trying to do (and could do by default before upgrading to Suse10.2)is use dynamic ips from the the router's DHCP server.
My best guess is some default setting somewhere got changed.
 
Old 08-09-2007, 06:38 AM   #10
dtmbmw325i
Member
 
Registered: May 2006
Location: Lebanon, PA
Distribution: Ubuntu 7.10
Posts: 47

Rep: Reputation: 16
I feel as if I could be having the same issue so any help is appreciated. When trying to connect to a Samba share from a Windows XP machine I cannot connect to it via hostname only by IP address. The odd thing is that the first time on another box I set this up without issue, this time I am having this issue. I am assuming its a DNS style issue. I am obtaining DHCP ip numbers from the router so creating entries into an lmhosts file or wins file is pointless because of that ip address getting changed at some point. Can the router resolve in house dns or do I have to run a dns server? I would prefer not to run dns on my server unless thats what was going on with my original box. Thanks in advance for the help.
 
Old 08-10-2007, 01:18 AM   #11
rossonieri#1
Member
 
Registered: Jun 2007
Posts: 359

Rep: Reputation: 34
Quote:
Originally Posted by Baloo_PNW
From what I can tell lmhosts is just another way to map static ips to NetBios Host names. What I'm trying to do (and could do by default before upgrading to Suse10.2)is use dynamic ips from the the router's DHCP server.
My best guess is some default setting somewhere got changed.
hi,

does your router DHCP assign your network a name server? DNS or WINS?
if it doesnt - then add a name server (DNS and or WINS server) option for your DHCP lease.

HTH.
 
Old 08-28-2007, 12:55 PM   #12
pwabrahams
Member
 
Registered: Nov 2005
Location: Deerfield MA
Distribution: OpenSuSE, Kubuntu
Posts: 272

Original Poster
Rep: Reputation: 41
Resolving hpmediavault references in OpenSuSE 10.2

I just discovered something very interesting: to get winbind resolution to work, you have to activate winbind in the runlevel editor. It is not activated by default. You can do it in Yast / System Services / Runlevel Editor (in expert mode only).
 
Old 09-11-2007, 10:57 AM   #13
jimu
LQ Newbie
 
Registered: Sep 2007
Posts: 5

Rep: Reputation: 0
Quote:
Originally Posted by pwabrahams View Post
mount -t cifs //hpmediavault/FileShare /mediavault
mount error: could not find target server. TCP name hpmediavault/FileShare not found
No ip address specified and hostname not found
try editing /etc/nsswitch.conf:

change:
hosts: files dns
to:
hosts: files dns wins

ref: http://wiki.samba.org/index.php?title=Mounting_samba_shares_from_a_unix_client
 
Old 09-11-2007, 12:19 PM   #14
pwabrahams
Member
 
Registered: Nov 2005
Location: Deerfield MA
Distribution: OpenSuSE, Kubuntu
Posts: 272

Original Poster
Rep: Reputation: 41
Samba name resolution - solved, it seems

Quote:
Originally Posted by jimu View Post
try editing /etc/nsswitch.conf:

change:
hosts: files dns
to:
hosts: files dns wins

ref: http://wiki.samba.org/index.php?title=Mounting_samba_shares_from_a_unix_client
Putting wins in the hosts: line of /etc/nsswitch.conf seems to do the trick - thanks. If it does not work for anyone following this thread, that would be well worth knowing.
 
Old 09-11-2007, 11:44 PM   #15
Baloo_PNW
LQ Newbie
 
Registered: Jun 2006
Posts: 12

Rep: Reputation: 0
Quote:
Originally Posted by pwabrahams View Post
Putting wins in the hosts: line of /etc/nsswitch.conf seems to do the trick - thanks. If it does not work for anyone following this thread, that would be well worth knowing.

Unfortunately it's still not working for me. (Suse 10.2) And yes I restarted smbd and nmbd afterwards.

Quote:
Originally Posted by rossonieri#1 View Post
hi,

does your router DHCP assign your network a name server? DNS or WINS?
if it doesnt - then add a name server (DNS and or WINS server) option for your DHCP lease.

HTH.
I'm not quite sure what you mean by this. The router provides DNS addresses from my ISP. I haven't changed any of the factory defaults on the router aside from the password. It's worth repeating that Samba was working fine until I went from Suse 10.1 to Suse 10.2 with no changes in router configuration. It's also worth noting that this only affects the Suse clients the one Mac and one XP box that are on the network have no problems mounting any of the samba shares by name only.

Last edited by Baloo_PNW; 09-11-2007 at 11:46 PM. Reason: I can't spell
 
  


Reply

Tags
cifs, mount, samba, winbind, wins


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
mounting samba shares wheaties_box Linux - Software 1 01-23-2007 12:21 AM
mounting shares with samba darkleaf Linux - Software 1 02-13-2005 06:13 AM
Mounting Samba shares and Samba Share Login time112852 Linux - Software 1 09-14-2003 02:23 PM
mounting samba shares easily crisponions Linux - General 4 07-16-2003 11:07 PM
Mounting Win98 shares using SAMBA desbyleo Linux - Software 3 02-17-2002 07:47 PM


All times are GMT -5. The time now is 07:28 AM.

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