problem with samba...
i have a LTSP server running with /home partition mounted from another machine using nfs samba is running on LTSP server. I also have a windows server that provides windows login to all the samba users. i have added LTSP users as samba users so that same user can get both windows and linux session. also i provide LTSP users home directory as a samba share during windows session.so i can access users /home during windows session. problem is when i am using windows session i cannot write into users /home using the mounted share... plz help...its very urgent |
hi there, check if ur /home has a write permission
ls -l /home if not then chomod u+w /home |
Quote:
actually when i an using windows session i can create files in the /home share but i cannot write into those files. if i try to i says "some other file is locking the file" something like that .. also if i try to create a wordpad file and write into it, it encodes the text in some other unreadable format and saves it i have a feelin that it is because of the machine running nfs....but dont know what exactly is the problem |
Do you use a [Profile] share to give users access to their home directories form Windows? Could you post the [General] and the service section of your smb.conf file?
The Samba 3 HOWTO & Reference Guide ( samba-doc package or their website ) has a chapter ( ch. 17) on File & Record Locking. When sharing files for both samba & nfs users, they recommend turning oplocks off. However it is possible that there could be changes. As I understand it, this is one area being addressed in Samba4 and improvements may be backported to recent samba versions. They may be writing this with NFS 2 in mind as well. (Just my guess) You might want to ssh into the server before accessing it form windows (i.e. using putty) and then run the "lsof" command to see which programs have a file open. Find out which services have the file open. Is the samba server running on the LTSP server or the client. Running the Samba on the client could be a problem. However I don't think there would be a problem if you have /home offered as an NFS service and use a [Profile] share which would have a path of %H which would evaluate to the server's /home/<username> directory. ( The path may be different on your system to accommodate the home partition being mounted somewhere else, of course ) Also check the samba logs. The Samba 3 boot may help you understand the logs as well. Quote:
Quote:
When you check for processes accessing user files just after they are created, check if the beagle daemon is accessing the file. When you create a new file, it receives an inotify message and then greps through the file. I would expect it to wait until the file is closed but this might be a possibility. Look at a user's file with getfattr. Code:
getfattr twim.xml Also, double check a file created from the windows client. Do the owner/group/permissions match one created locally by that user? |
Quote:
[global] wins support = yes dns proxy = yes workgroup = EXAMPLE netbios name = K12LTSP domain logons = yes domain master = yes os level = 99 preferred master = yes add machine script = /usr/sbin/useradd -d /dev/null -g winmachines -s /bin/false -M %u logon drive = H: [homes] create mask = 0600 directory mask = 0700 path = %H read only = no valid users = %S [netlogon] path = /home/netlogon guest ok = yes writable = no share modes = no |
Look at how the home directory is provided for an LTSP user.
I think the problem is how %H is expanded. I'm guessing that a directory like /srv/nfsroot is exported by the nfs/samba server and mounted by the clients as the root directory. Then from the client, their home directory is at /home/username. However for the samba server, it should share /srv/nfsroot/home/username instead. I think that your path should be defined as either /srv/nfsroot/home/%u or /srv/nfsroot/home/%U Note that I've made a guess where the nfsroot directory is located. |
I was reading the "man exports" page today to look at nfs4, and noticed the "unhide" option which may be needed if you have a mount point in a share. I don't know if this works for mounts of non nfs shares.
|
Quote:
i am using k12ltsp... i can easily copy files from samba directory to windows...but i cannot copy files from windows to samba share... |
Could you post information how shares are mounted on the server and the directory structure of the server. Where is the nfs root directory? Also post your revised smb.conf file as well as the /etc/exports file.
Have you tried an absolute path to the directory containing the users home directories instead of %H? Or would they evaluate the same. They might not be. I'm thinking that %H will evaluate to /home instead of <NFS_ROOT>/home. The /etc/password file may indicate /etc/home because the nfs root share is mounted on / at the users machine. Since the samba server is running on the NFS server that contains the users home directories, I think you want to share the users home directories using an absolute path to the home directory or an expression that evaluates to the home directory or the user's own home directory. Since k12ltsp is based on CentOS Linux, also check if there are seLinux security policies causing problems. Check the documentation for k12ltsp: http://k12ltsp.org/mediawiki/index.php/Main_Page Good Luck! |
All times are GMT -5. The time now is 10:29 AM. |