cancel
Showing results for 
Search instead for 
Did you mean: 

error while using pam_mount

 
SOLVED
Go to solution
iinfi1
Super Advisor

error while using pam_mount

i am using pam_mount on my suse desktop machine to mount shared drives from windows domain controlller's shared drives

my test environment:
e.g user4 has access to a shared drive (everyone) on the windows file server (residing on the DC itself).
the user is able to create files and folders on the shared folder BUT is not able to edit n save the text files on the shared drive.

the image contains the error i get while i try to save the edited file residing on the shared windows drive.
http://img205.imageshack.us/img205/9006/pammount.jpg

what could be the reason?
interesting i just noticed that if i open those text files in open Office the users are able to edit and save the existing files on the shared drive. the error pops up only when i use gedit.

thanks
6 REPLIES
Ivan Ferreira
Honored Contributor

Re: error while using pam_mount

¿Can you provide the error that you get when trying to create a file on that directory from command line, for example, using touch?

Also, check the share and NTFS permissions on the Windows server.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
iinfi1
Super Advisor

Re: error while using pam_mount

hi ivan,

there is no error whatsoever when i create a file on the shared folder on the windows server.

i can create a file through vi,touch, gedit or Open Office. the file gets created fine.

when i edit a file through open office or vi, i am able to edit the file and save it back to the disk.

its only when i open an EXISTING text file through gedit, i get this error.
strangely it happened with RHEL as well.

any clues.
Ivan Ferreira
Honored Contributor

Re: error while using pam_mount

¿What if you edit an existing file with vi?

What is the output of

id
ls -la ?
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
iinfi1
Super Advisor

Re: error while using pam_mount

hi ivan
thanks for your reply :)
as i had told you i face this issue only when i use gedit to edit the files. i dont get the error when i am use gedit to create the text files.
permissions-wise i dont see an issue.

DOM1\user4@sled1:~/share2> id
uid=10001(DOM1\user4) gid=10000(DOM1\domain users) groups=10000(DOM1\domain users),10002
DOM1\user4@sled1:~/share2> ls -l sample.txt
-rwxrwSrwx 1 DOM1\user4 DOM1\domain users 26 2009-03-27 12:10 sample.txt
DOM1\user4@sled1:~/share2>


using vi or open office i am able to create or edit he files. only when i use gedit this problem arises.

am i being clear? should i explain it in a better way.
thanks :)

Ivan Ferreira
Honored Contributor
Solution

Re: error while using pam_mount

Ok, this is the problem:

Gedit opens a file, moves the original file to a backup file while keeping the file open, and finally deletes the backup file if you choose not to keep backups.
The rename method sets errno = ETXTBSY, so moving the original file fails.

There was a plugin that can solve the problem, but the site is not available anymore:

http://chrisnicholls.ca/code/gedit-plugins

This plugin moves the original file to a temporary directory. If you can find the plugin, you probably will solve the problem.

And please remember to assign poins to the answers you get. See:

http://forums1.itrc.hp.com/service/forums/helptips.do?#28

Cheers.
Por que hacerlo dificil si es posible hacerlo facil? - Why do it the hard way, when you can do it the easy way?
iinfi1
Super Advisor

Re: error while using pam_mount

i will check if i can get the plugin for gedit