PDA

View Full Version : Unix/Windows deleting issues



Mike
18-01-2005, 06:39 PM
At work I use a Windows 2000 connected to a fairly big network, including several Unix servers. Up until mid-December I was able to delete files off a Unix server from my Windows login, however about half way through December this ability disappeared. I can still create/edit files on the Unix server, just can't delete or move them - moving them results in them just being copied.

If I log in via a remote terminal connection on my PC I can add/delete/modify files as normal - the issues only occur when trying to delete etc. from Windows explorer or other similar applications.

This doesn't affect just myself - everybody we have tested has the same problem - they cannot delete anything. There are no error messages - the file seems to be deleted, however a refresh shows the file to still be there. There don't appear to be any permission issues (I was even added to the Unix superuser group to test), and affects (so far tested) Windows 2000 Pro workstation, Windows 2000 server, Windows 2003 server.

What other info do I need to supply? I'm not in the IS dept, so I may not be able to supply all the info, but the Unix geek at work is stumped, and I'm sure would appreciate any help I (we) can offer :D

Cheers,
Mike.

PS I don't know if this makes any difference, but the Unix OS on the server is actually a fairly old version of Solaris (can't remember which version). Mike.

Edward
18-01-2005, 07:03 PM
if it's a fairly old version, what if you upgrade to a new(ish) version?

Mike
18-01-2005, 07:08 PM
if it's a fairly old version, what if you upgrade to a new(ish) version?

That wasn't very helpful :)

Upgrades cost... sometimes a lot. It wouldn't be worth the money to upgrade just because we suddenly can't delete files. It's worked for ages until it stopped suddenly in December - there has to be a logical solution, rather than having to take drastic measures such as upgrading an OS (which would in turn mean upgrading the hardware).

Mike.

PS Besides, like I said earlier, I'm not in our IS dept, so I have no say in the matter.

Prescott
18-01-2005, 07:10 PM
do you have the right permissions for deleting those files?

johnd
18-01-2005, 07:25 PM
I'm wondering if UNIX permissions seem OK, has something happened to the SAMBA server settings? Permissions can be changed there too.

Chilling_Silence
18-01-2005, 07:32 PM
Can you post back
ls -la /home/user/dirname


Chill.

Mike
18-01-2005, 07:36 PM
I'm wondering if UNIX permissions seem OK, has something happened to the SAMBA server settings? Permissions can be changed there too.

Is smb.conf anything to do with SAMBA settings? I know the Unix guru has looked a lot through smb.conf, and made lots of changes in there to see what could have changed. This also affects him (as well as everyone else we've tried).

Mike.

Mike
18-01-2005, 07:38 PM
Can you post back
ls -la /home/user/dirname

What's that going to do?

Mike.

johnd
18-01-2005, 08:33 PM
Is smb.conf anything to do with SAMBA settings?


Yes - that is the SAMBA configuration file that basically controls the behaviour of the server.

Chilling_Silence
18-01-2005, 08:46 PM
Its going to tell me who owns what files so we can check permissions etc

I'd say that samba is not using the correct groups etc when creating files or something similar

Mike
18-01-2005, 09:06 PM
Its going to tell me who owns what files so we can check permissions etc
We've checked and changed permissions left, right, & centre. Made me a superuser, almost everything you can think of to do with permissions, but the same thing happens. Usually if I try to delete/edit a file that isn't mine (even from Windows) I get a permissions error. However trying to delete files that I do have permissions for doesn't give an error, the file appears to delete, but just reappears on a refresh.

I'd say that samba is not using the correct groups etc when creating files or something similar
These could be files created either from Windows or from Unix, so that should be irrelevant to SAMBA shouldn't it? Some of the files I tried on were several months old, so were created and last edited long before this problem started.

Mike.

beama
18-01-2005, 10:52 PM
I am just learning about Samba and I have a XP machine, FC 2 and Xandros machines seeing each other and the linux machines are using the printing share on the xp machine the reason Im telling you this is Samba does control alot of permissions regaurdless of normal file and directory ownerships in this kind of setup, I would be talking to that linux guru and see what hes been up to in smb.conf (control file for samba).
Another question I would ask is, did your trouble start when the linux guru started tinkering with samba ?

Mike
18-01-2005, 11:03 PM
Another question I would ask is, did your trouble start when the linux guru started tinkering with samba ?

No, no, you misunderstand... he hasn't been "tinkering" with SAMBA - he's been working in there to try to solve our issues. Our organisation is big enough that the IS techies don't just "tinker" with settings.

We do (I think) have 2 or 3 other Unix servers, so I might suggest to him that he tests for the problem on those... it'll be interesting to see. He seems to think it's a Windows problem, possibly to do with recent updates or such, however only our Workstations are automatically updated - our servers have to be manually updated (for obvious reasons) and the issue occurs on both Win 2000 Workstation and server (and Win2003).

Mike.

beama
18-01-2005, 11:10 PM
Sorry Mike wrong choice of word there "tinkering" was just a figure of speech
I actually wondered when reading this thread about windows updates.

Mike
18-01-2005, 11:26 PM
Sorry Mike wrong choice of word there "tinkering" was just a figure of speech

Ah okay :) No, the "tinkering" ;) didn't start until I tried to get the problem fixed.

Cheers,
Mike.

Mike
19-01-2005, 09:24 AM
Its going to tell me who owns what files so we can check permissions etc

I'd say that samba is not using the correct groups etc when creating files or something similar

All the files in the folder I was looking at are owned by me, and the group is my group. This doesn't just happen in one directory, this happens in any directory on any drive for any user on the Unix server via Windows.

Mike.

Mike
19-01-2005, 11:57 AM
Can you post back
ls -la /home/user/dirname

-rw-rw-rw- 1 mike gis 46 Oct 11 15:19 ver.txt
-rwxrwxrwx 1 mike gis 132 Jan 17 11:04 z1.txt*
-rw-rw-r-- 1 mike gis 2852324 Jan 12 08:10 coach.eps

Those three files are three that we have tried deleting.

Mike.

vinref
19-01-2005, 01:36 PM
Sounds suspiciouly like a safety mechanism that has been activate/changed - like noclobber for cp in linux etc. Almost certainly in Solaris itself - not Samba or Windows. I do not know how Solaris implements this. Was anything changed in mid-Dec at the time this started happening? You say this also happens when you try to move/rename a file? Have you tried to overwrite a file? Try and tell us what happens.

vinref
19-01-2005, 03:44 PM
Ignore my post above. I just realised it is completely wrong.

Mike
19-01-2005, 03:45 PM
Sounds suspiciouly like a safety mechanism that has been activate/changed - like noclobber for cp in linux etc. Almost certainly in Solaris itself - not Samba or Windows. I do not know how Solaris implements this. Was anything changed in mid-Dec at the time this started happening? You say this also happens when you try to move/rename a file? Have you tried to overwrite a file? Try and tell us what happens.

I can rename files fine. I can move them, but instead of moving they just copy (eg the copy doesn't delete once it's moved). Overwriting the file works fine, as does opening and editing the contents of the file. I just can't remove the file.

Mike.

Graham L
19-01-2005, 04:16 PM
I have come across mentions of some special things which happen when a mv is between different file systems. A quick look at Google didn't refresh my vaguye memories.

A "move" in the same directory or in the same file system is just a rename, so is very quick. A move between file systems involves actual copying.

vinref
19-01-2005, 05:02 PM
I can rename files fine. I can move them, but instead of moving they just copy (eg the copy doesn't delete once it's moved). Overwriting the file works fine, as does opening and editing the contents of the file. I just can't remove the file.

Mike.

Well, now it is beginning to sound like you are only dealing with copies living in Samba when you are on your Windows box. The real files live in Solaris - deleating the Samba copies won't delete the real ones in Solaris. The write and copy/move/rename (i.e., these are echoed as simply write commands) functions would work OK on the Samba copies and get relayed to Solaris, but not delete. From memory a similar thing happens when trying to send a file living in Linux to be printed via a Samba print-server - you can only delete the Samba copy from the Windows box, but to delete the actual Linux file you have to do it from the console.

johnd
19-01-2005, 08:30 PM
Well, now it is beginning to sound like you are only dealing with copies living in Samba when you are on your Windows box. The real files live in Solaris - deleating the Samba copies won't delete the real ones in Solaris.

That doesn't sound right to me - SAMBA is SMB (Server Message Block) - emulating a real Windows host. I do not think that when you view a file on a UNIX or Linux server from a Windows PC that you are seeing a copy?

vinref
19-01-2005, 09:20 PM
That doesn't sound right to me - SAMBA is SMB (Server Message Block) - emulating a real Windows host. I do not think that when you view a file on a UNIX or Linux server from a Windows PC that you are seeing a copy?

Yeah, you may be right. But for writing, editing and printing files, isn't there some sort of temporary file generated somewhere always? Even in a one-OS case - editing a MS Word file comes to mind. Because of the behaviour described, I assumed this temporary file/copy might be in Samba. Hey it could even be in Windows.

dolby digital
20-01-2005, 08:57 PM
If you work for a reasonable size organisation, would they have some support agreement with the suppliers of the unix servers, or would you have to pay per incident.

Do the servers ever get rebooted? Although we are not talking Windows here, you never know, a reboot could clear it up.

Certainly very strange.

Mike
20-01-2005, 09:51 PM
If you work for a reasonable size organisation, would they have some support agreement with the suppliers of the unix servers, or would you have to pay per incident.

Do the servers ever get rebooted? Although we are not talking Windows here, you never know, a reboot could clear it up.

That's a good point, although I don't know if the maintenance contract covers software/setup issues rather than just hardware.

The server does get rebooted occasionally, and I think it has been rebooted as we try to solve this problem, but I can't guarantee it just this minute (seeing as I'm at home :p)

Mike.

Mike
21-01-2005, 04:07 PM
The server does get rebooted occasionally, and I think it has been rebooted as we try to solve this problem, but I can't guarantee it just this minute (seeing as I'm at home :p)

I was wrong - the server hasn't been rebooted for at least 4 months, so they'll do that on Tuesday night and we'll see...

Mike.

Graham L
22-01-2005, 02:47 PM
There is a command to check whether the Samba server is happy with its configuration file ... ./testparm in the appropriate directory.

Have a read of this article on Solaris samba installation (http://www.kempston.net/solaris/samba.html). It looks as if the person knows about it. There's a section on testing.

"Samba on Solaris" to Google finds that, and a fair few more links.

I was surprised to find that MSD wasn't solely guilty for SMB (http:samba.anu.edu.au/cifs/docs/what-is-smb.html) -- IBM (when they were still talking to MS) were always more interested in networks, and they produced the original PC LAN (and various versions of LAN Manager). Of course MS are responsible for its present form, and the fact that it is not documented. :( SAMBA was a result of reverse engineering ... Andrew T did lots of transfers and captured the messages. :D)