Re: HOWTO: Setup Samba peer-to-peer with Windows
Quote:
Originally Posted by
stig
I have two Ubuntu 6.06 PCs and one Windows 98 behind a broadband NAT router, connected by cable and using DHCP.
I haven't seen a resolution so forgive me if you've already fixed it.
Does the problem go away if you change from "security = user" to "security=share"?
It's been several years since I dealt with Win9x but if I recall correctly 9x only supported share security in a workgroup. You had to be logged in to a domain (nt authentication) to use user security. To do that would mean setting up one of the ubuntu machines as a PDC and that's beyond the scope of this thread.
IPC$ (inter process communication) errors are usually authentication or capability errors (wrong password, wrong encryption or wrong security type.)
I seem to remember having to set "encrypt passwords = true" in the [global] section of smb.conf but thay may have changed.
If neither of the above works, then make try again using an account with a password on the win98 machine. Null passwords required a working guest account. (I'm unsure if one is set up by the ubuntu installation, nobody used to be the default)
Re: HOWTO: Setup Samba peer-to-peer with Windows
Looks like a great and detailed post, Stormbringer. I have one more of those 'stupid' questions for you. Does this work the same way for setting up file sharing between Ubuntu on my laptop and windows XP running on vmware? And would it work with a NAT network when both the ubuntu (host) and xp (guest)will have the same IP or will I need different IP addresses?
Thanks
Re: HOWTO: Setup Samba peer-to-peer with Windows
Quote:
Originally Posted by
hotch
I greatly appreciate the How To on setting up Samba with Windows. I followed it and it worked. I have two Windows computers networked peer to peer through a router, and have added a Ubuntu laptop. I can now access the Ubuntu computer from my Windows one via the Network Neighborhood. Mapping the laptop as a drive does not work because Windows XP does not appreciate a mapped drive when the computer it represents is not turned on.
That's right --- if the computer to which the network drive is mapped isn't powered up the drive is marked with a red "X" in "My Computer".
However, as soon as you boot up your lappy you simply need to click the mapped drive and the connection will be restored.
That's how it usually works by design ... just in case you wonder.
Quote:
Originally Posted by
hotch
The problem now runs the other way. I cannot access the Windows computers and their shared folders or files from the Ubuntu one. Under Places, Network Servers, the network is there and the various computers are there. When I try to access any of the computers in the workgroup, I get a notice such as this one:
"The filename "BOB" indicates that this file is of type "desktop configuration file". The contents of the file indicate that the file is of type "x-directory/smb-share". If you open this file, the file might present a security risk to your system.
"Do not open the file unless you created the file yourself, or received the file from a trusted source. To open the file, rename the file to the correct extension for "x-directory/smb-share", then open the file normally. Alternatively, use the Open With menu to choose a specific application for the file."
Since this happens even when trying to access the Ubuntu computer shared file from the network file browser (after all, it is there), I get the feeling that the problem is in Ubuntu and not in Windows. What went wrong and what do I do about it?
Well, if you try to access a Windows-Share FROM Ubuntu (no matter is you use Nautilus's "Connect to server" or manual mount by smbfs) it has NOTHING to do with samba as samba IS ONLY REQUIRED TO GAIN ACCESS FROM WINDOWS (<-- no shouting, just to trigger attention).
So, at the best there's something square with Gnome's VFS that gets used when connecting to Windows from Nautilus.
Why not trying to install smbfs and give it a shot on the commandline?
Open a terminal and type ...
sudo apt-get install smbfs
...and try to mount the share ...
sudo mount -t smbfs //SERVER/Share /media/mountpoint -o username=windows_username,password=windows_passwor d,fmask=0666,dmask=0777,iocharset=utf8
Note: You eventually need to create the directory under /media to which you mount the share ... sudo mkdir /media/mountpoint
If it works out you have confirmation that's something wrong with Gnome and/or it's VFS.
As the connection from Linux to Windows isn't related to samba I'm not really able to assist you in troubleshooting Gnome (order KDE or whatever flavor of Ubuntu you may using).
-Storm
Re: HOWTO: Setup Samba peer-to-peer with Windows
Quote:
Originally Posted by
Fraoch
Dangit, well although the procedure in this thread worked perfectly (no errors), my networking problems persist.
Both Windows PCs behave the same. The Samba share appears right away, with "Shared Printers" and "My Files" folders. The "My Files" folder contains the folder you had me define in the conf file.
I can copy files off my Ubuntu machine no problem at all. Maximum speed. I can even delete files off my Ubuntu machine from both Windows PCs as if it was a local drive. However I just cannot copy a file onto the Ubuntu machine. I get a long pause and "The network resource is unavailable" error.
The Ubuntu machine can barely see the Windows shares much less do anything to them - read or write usually result in timeouts.
It's like the Windows machines have write-not-read permissions and the Ubuntu machine has view-only permission. That's not the case though, and some of the other permissions act like they're trying to work.
It seems to be one of those nebulous general networking issues that's OS independent. I had high hopes that defining a WINS server would solve the issue as it appears to me like some sort of network locator isn't running properly, but that isn't it. My attention is now focused on NetBIOS but that seems to be running too.
Thanks for the great how-to though. Your instructions worked perfectly. It's something else that's causing me grief!
Check if the "My Files" folder on Ubuntu has the appropriate rights. Issue a ...
ls -lisa /media/MyFiles
... and look out for the columns showing your the access modes, the owner and the group.
If the permissions don't look like drwxrwxrwx you forgot to issue "sudo chmod 0777 /media/MyFiles".
If the owner and group IS NOT your username you forgot to issue "sudo chown your_username:your_username /media/MyFiles"
If there's something wrong with the permissions you won't be able to copy onto the share from Windows; but it should give a message like "You don't have the appropiate permissions blah blah" instead of a networking error.
Just give it a try and remember to correct paths to match your setup.
-Storm
Re: HOWTO: Setup Samba peer-to-peer with Windows
Quote:
Originally Posted by
isharra
I haven't seen a resolution so forgive me if you've already fixed it.
Does the problem go away if you change from "security = user" to "security=share"?
It's been several years since I dealt with Win9x but if I recall correctly 9x only supported share security in a workgroup. You had to be logged in to a domain (nt authentication) to use user security. To do that would mean setting up one of the ubuntu machines as a PDC and that's beyond the scope of this thread.
IPC$ (inter process communication) errors are usually authentication or capability errors (wrong password, wrong encryption or wrong security type.)
I seem to remember having to set "encrypt passwords = true" in the [global] section of smb.conf but thay may have changed.
If neither of the above works, then make try again using an account with a password on the win98 machine. Null passwords required a working guest account. (I'm unsure if one is set up by the ubuntu installation, nobody used to be the default)
If you run Win95/98/Me the example configuration of samba in the HOWTO isn't suitable.
However, as the aforementioned operating systems aren't any longer supported by Microsoft you're better off switching to a more recent OS (i.e. Windows XP) if your Computer is capable of running it.
-Storm
Re: HOWTO: Setup Samba peer-to-peer with Windows
Quote:
Originally Posted by
raja
Looks like a great and detailed post, Stormbringer. I have one more of those 'stupid' questions for you. Does this work the same way for setting up file sharing between Ubuntu on my laptop and windows XP running on vmware? And would it work with a NAT network when both the ubuntu (host) and xp (guest)will have the same IP or will I need different IP addresses?
Thanks
Should work fine with the VMware setup ... no idea about the NAT though.
I run VMware Server on my box, and inside of the "emulated" Windows XP I'm able to access the shares of samba running on the same box; difference is that I'm using bridged networking (the NAT to the outside world is done by my hardware router).
-Storm
Re: HOWTO: Setup Samba peer-to-peer with Windows
Quote:
Originally Posted by
Stormbringer
If you run Win95/98/Me the example configuration of samba in the HOWTO isn't suitable.
However, as the aforementioned operating systems aren't any longer supported by Microsoft you're better off switching to a more recent OS (i.e. Windows XP) if your Computer is capable of running it.
-Storm
First, in answer to Isharra, I seem to have everything working except accessing my Ubuntu shares from the Windows 98 box - but there is a possible complication becasue I'm using DHCP. I'm going to try setting static IP addresses and see if that gets me anywhere. But as I mentioned in previous posts, I will soon switch completely to Ubuntu, so the motivation is low! (And as Stormbringer points out, Win98 is no longer supported by MS - or people like ZoneAlarm.)
Second, Stormbringer, in what way is your example config in the Howto not suitable for Win98?
Re: HOWTO: Setup Samba peer-to-peer with Windows
Quote:
Originally Posted by
stig
(And as Stormbringer points out, Win98 is no longer supported by MS - or people like ZoneAlarm.)
I have no idea on how to interprete the line, but: Face the facts ... 9x/Me is discontinued ... and not only since yesterday's patchday.
Quote:
Originally Posted by
stig
Second, Stormbringer, in what way is your example config in the Howto not suitable for Win98?
As Isshara already pointed out:
- Win9x/Me seems to have issues with security=user (security=share should work out, but it isn't tested by me as I don't have any ancient Windows's to my avail anymore)
- Win9x/Me isn't really able to handle encrypted smb connections (this option isn't used here and defaults to unencrypted).
- In order to join into a domain (samba in PDC mode instead of stand-alone) you need to tweak some parameters to make it happen; not really sure if the parameters would also be needed in the stand-alone peer-to-peer setup).
Just take a look through the man-page or html documentation of samba and look out for remarks regarding Windows 9x ... there are some.
So, although I would really like to help in resolving Win9x/Me related issues I simply can't as I never used them (my way through Windows hell consisted of: Win3.xx -> NT 3.5x -> NT4 -> W2K -> WXP) and don't have them to my avail in order to setup a test-environment in VMware.
-Storm
Re: HOWTO: Setup Samba peer-to-peer with Windows
thankyou thankyou thankyou for this guide!!
this is the first guide that cleanly with no fuss sets up my windows installation to share files with ubuntu
this is great!
Re: HOWTO: Setup Samba peer-to-peer with Windows
ok thanks to this form my file sharing is up but my Print server is XXXX. ok This server has no gui, so to configure the printers im typing under root lynx 127.0.0.1:631/Administration/ and it shows new printer HP895C and my laserJet5 so I tab down to Add this Print
hit enter, it list the printer drivers its going to load all looks good so I tab to Add Printer, then I get not Authorized grrr then it asks for user name for cups so I tried everything and always get Authorization Failed..
this is cups 1.2.2
Please help do I need to down grade cups is it a bug? my hole damn office has no printers now ](*,)