LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Yet More Samba (https://www.linuxquestions.org/questions/linux-newbie-8/yet-more-samba-173366/)

kopite2012 04-22-2004 11:59 AM

Yet More Samba
 
I have a Linux machine on which I installed samba. The machine is a VMWARE (for creating Virtual servers) machine which sits on a customised version of Linux 7.2. I have installed samba on this machine and setup the shares that I want.

Unfortunately, when I type \\<ip addresss>\public, from a windows machine I get a popup box asking me for a password. No matter what password I type I still get the same message "incorrect password".

Ideally, I would like to set it up so that it does not come up with a password at all. It sounds like a security setting on the Linux environment, but I am completely new to this environment and would be grateful if someone could guide towards what needs changing or amending.

many thanks.

hob 04-22-2004 01:28 PM

In order for the Windows client to connect the domain/workgroup, username and password submitted must match - my first guess is that the client and server are set to different and unrelated workgroups.

If you are on Windows 2000/XP map a drive to the share using the "connect as different username" option and try the username in this format:

vitual server's NETBIOS name\username

Another possibility is that you haven't yet used smbpasswd to enable SMB access for the user account on the virtual server.

If you're struggling with Samba generally, it might be useful if you give some idea of your level of experience. We can then point you at appropriate resources to help you along with this project - from the question I'd guess that you're a professional.

kopite2012 04-22-2004 06:18 PM

Hob,
I have very little experience of Linux. Throughout my career I have mainly worked with Windows OS and applications. so you can consider me a complete novice.

With regards to samba I have installed and configured Samba 3.0.2a on a RedHat Linux Machine and shared directories which can be accessed from any windows box without the need to supply username and/or password.

I have also installed Samba 2.2.7-3 for Linux 7.2 (which is the platform this VMWARE server sits on) and again I have no issues with accessing shares defined in the smb.conf file from a windows platform.

The problem i'm having is a couple of Linux 7.2 VMWare machines which have samba 2.2.7-3, and are sitting on a different subnet but the same domain. All machines are using the same smb.conf file with the shares being the only difference. As a test I have logged on to a windows machine on the same subnet supplying the domain admin username and password which doesn't allow me access to the shares.

I don't think its a problem with the share definition becuase even if I type
\\LinuxMachineName\ I am still prompted to enter username and password. Once again regardless of what username and password I supply it does not allow me access. I have tried domain admin account, linux root user and password. None of these have worked.

My domain is a Windows NT 4.0 domain

My smb.conf file looks like this

workgroup = <my domain name> (is the same on all servers with samba)
Security = Server (same on all linux servers )
password server = <PDC BDC> (same on all linux servers)


[public]
path = /home/sharename
public = yes
only guest = yes
writable = yes
printable = no

Many thanks in advance for any help. regards.

kopite2012 04-23-2004 05:53 AM

To resolve the problem I am having I enabled the line

Mapped to Guest = Bad user

This seems to have resolved the problem for me. Regards,

hob 04-24-2004 08:24 AM

I think that you need to consider why you are overriding the defaults to permit access by anonymous guest accounts. It can be hard to avoid using accounts which are not tied to specific individuals in Windows but it's really a bad practice, and many UNIX systems are wired to try to prevent it - this is why Samba rejects 'administrator' or 'root'.

The system that Samba is trying to adhere to is to have a standard account for each user with file access comtrol by groups. FWIW, mechanisms like 'su' and 'sudo' enable administrator powers for logons but with inherent safety controls - in normal circumstances you should never actually log in as root.

Not so much a novice mistake as hitting a difference between UNIX and Windows common practice - I had to try to explain a similar issue to a senior tech at my workplace. If you can explain the circumstance we can probably work out a secure way of getting the outcome you want.

Electro 04-24-2004 02:56 PM

If you want to test if SAMBA is working, every directory is shared perfectly, and files can be written to SAMBA with out any permission problems. You can change the line "security = server" to "security = share" in the global settings. Also you may want to add "guest only = yes" in the global settings. This is not the best way to test SAMBA, but only if you are testing the shared directories and files thats ok. If want a little more security, all you need to do is add a user to the SAMBA account. SAMBA account is not the same as unix or windows account. I do not remember the command to add users to the SAMBA. I think its smbadduser or something like that. I think newer versions of SAMBA syncs unix accounts with SAMBA. You may want to change the password on the accounts by doing smbpasswd. Do not forget to change "security = share" to "security = server" and disable "guest only = yes" by just putting # in the beginning of the line.

You can setup SAMBA to broadcast to multiple subnets.

If you are behind a router with NAT, you will be ok with security. If you are paranoid about security just run a packet scanner so only systems with a certain MAC address can access your SAMBA system.

I thought VMware has a feature to exchange data from certain directories in virtual machines to the host machine. Look up special folders in the advanced tab for each virtual machine.

BTW, there is no LINUX 7.2.

kopite2012 04-26-2004 04:48 AM

Hobs,
Thanks for the feedback. I supplied names of two password servers. One of them was at a different site on a different subnet. I changed this so that both password servers are on the same subnet and turned the guest access off. This seems to work fine. I guess it was an issue with WINS after all.

Electro,
Thanks for the info on Linux versions :-). Funny and embarrasing at the same time. I downloaded samba 2.2.7-3.7.2, and so assmumed
2.2.7-3 was the samba version and 7.2 was the linux version (Shows how much I know about linux).

With regards to VMWARE special folder, the files I'm trying to tranfer are the actual .dsk files (images of the virtual machine), the VMWRE utility fragments (into smaller cow files) any file bigger than 2gb and then reassembles it when it is transfered back. It also does not allow backup straight to tape as it does not support Arceserve (which is our backup utility)

Thanks again to everyone for the their help. regards.

kopite2012 04-28-2004 05:33 AM

Just when I thought I'm done with setting up this samba **** I now find that once I've setup the shares I can see all the files (via Windows) in the folder that I shared. However, When I try to copy a file that is larger than 4gb I get an error message that reads

"Cannot copy <filename>: Not enough memory
Quit one of more applications and then try again"

The machine that I'm trying to copy to has a 100gb of free disk space and 1.5gb Ram. The only software that is loaded on the machine is SQL. This seems to be more a samba/linux problem rather than a windows issue.

Does anyone know/have any idea's about why this might be happening. Many thanks in advance for any assistance. Regards.

kopite2012 04-29-2004 07:56 AM

found an RPM on the Web called samba-2.2.7-3.7.2.ia64.rpm.

There was very little info about this RPM but from what little there was I gather this is a patch which has the LFS (Large File Support) built in. I tried to install it and I got the following messages


Failed Dependencies:

Libc.so.6.1
libdl.so.2
libnsl.so.1
libpam.so.0

I assume this means that these libraries are not available, and I need to install them.

Firstly, Is the above .RPM likely to resolve my problem

and secondly, where can I download and install these libraries from. My machine is a i386 machine as opposed to Alpha.

Many thanks for your help. Best regards,

Electro 04-30-2004 05:24 AM

The SMB protocol can not handle any bigger than 2 gigabytes files. Use the split utility to copy files bigger than 2 gigabytes.

kopite2012 04-30-2004 05:44 AM

Quote:

Originally posted by Electro
The SMB protocol can not handle any bigger than 2 gigabytes files. Use the split utility to copy files bigger than 2 gigabytes.
I dont think thats correct. I can and have copied files that are 4gb. On that machine. On another machine which has a more updated Kernal I have copied files that are 20gb.

I think it all relates to LFS support. Which is enabled on later versions of the Linux. Unfortunately, VMware sits on Linux 7.2. I will have to go through the process of upgrading Vmware 2.0.1 to 2.1 which uses updated library's (I think) and thus supports LFS (I have this setup on another machine and can copy files bigger than 4gb).

The upgrade process for VMWare is very painful in that I will need to recreate all the virtual machines (VMs) and therefore I wanted to avoid it by getting this working. It looks more than likely that it is not possible.

Many thanks for your input. Regards,

Electro 05-01-2004 01:42 AM

My version of samba 2.2.7 can only copy 2 gigabytes for each file. My system can handle huge files like a few hundred gigabytes and many more. Right now I can only test up to 112 gigabytes because the limits of my hard drive space.

You do not need to recreate the virtual machines. Just make another hard drive image that is bigger than 2 GB. Then use something like Knoppix to make the partitions and then format them. Next mount the original linux drive. Then copy each partition individually but make sure you use the preserve option.

I use VMware 4 workstation. I made a 4 gigabyte virtual hard drive file with out splitting them. You should upgrade to it.

Again there is no LINUX 7.2. Are you using Redhat 7.2. An i386 is not an alpha processor. An alpha processor is whole seperate plateform. An i386 is a 80386 INTEL processor. The samba-2.2.7-3.7.2.ia64.rpm that you found can not run on your particular system. You need an INTEL Itanium, AMD Athlon 64, AMD Athlon FX, or AMD Opteron.

kopite2012 05-04-2004 04:25 AM

Electro,
My machine is an Compaq (i386 Intel) server running ESX 2.0.1, which is the VMWARE server edition (not workstation). The Server has 5 * 70GB disks in a raid 5 configuration. ESX server (as I understand it) is based on a customized RedHat 7.2. As I explained, I have samba 2.2.7-3.7.2 which allows me to copy a file (via a samba share) upto 4 gb.

I have another server with ESX 2.1 (as opposed to 2.01) and Samba 2.2.7-3.7.2 and this allows me to copy images of any size (so far I have only tested 60gb image).

With regards to copying images I will try using the VMBK.PL command, which is a vmware utility to see if I can successfully copy over the images, failing this I will try your solution.

Many thanks once again for your help. Regards,


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