Free Downloads, Community Forum,
FAQs and Developer Resources


Make /Tools Your Home | Link to us

Today's posts | Posts since last visit | Most Active Topics

All Forums Register Login Search Subscriptions My Profile Inbox
Tool Warehouse FAQs Resources Help Member List Address Book Logout

Strange issue with permissions and VIM

 
Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [SFU / Interix / SUA Technology] >> Interix Advanced Forum >> Strange issue with permissions and VIM Page: [1]
Login
Message << Older Topic   Newer Topic >>
Strange issue with permissions and VIM - Apr. 13, '06, 3:54:07 AM   
caledfwlch

 

Posts: 2
Joined: Sep. 20, '05,
Status: offline
I am having some very odd issues with VIM and file permissions.

I am running on Windows XP (but the same problems show up on Windows 2003) as a non-Administrator account but a member of the +Administrators group.

All of the files in the SFU directory are owned by the user with a group of either +Administrators or +SYSTEM (I can't work out why there is a mix).

Running VIM with syntax enabled didn't result in any highlighting. Thinking I'd forgotted something else I did a ':help'.
This produced an error message saying that /usr/local/share/vim/vim63/doc/help.txt didn't exist.
I checked - it does exist.
Curious, I tried to load the file directly and succeeded.

I have also noticed that autocompletion of filenames on the VIM command line doesn't work, nor does the TreeExplorer.

This problem does not seem to affect normal commands, e.g. ls and cd.

As a further point of interest, when trying to remove a directory with 'rm -rf' some files and directories couldn't be deleted. However, I could change the owner of these files and then remove them. The files were created by a Windows process running as a service.

Hmm, on a hunch, I just chown'd the entire VIM directory and subdirectories to the *same* user as the current owner and now everything is working again!

Can anyone explain what is happening?

Thank you,

Dave.
Post #: 1
RE: Strange issue with permissions and VIM - Apr. 13, '06, 10:37:07 AM   
woehlkmp

 

Posts: 102
Status: offline
quote:

All of the files in the SFU directory are owned by the user with a group of either +Administrators or +SYSTEM (I can't work out why there is a mix).
If by "the SFU directory", you mean '/', I can guess at the "why"... it looks like folders that were originally created by the installer are group='+Administrators', whereas anything created by 'mkdir' is group='+SYSTEM'. At least that's what seems to have happened on my computer (where 'mkdir' does create dirs with group='+SYSTEM').

quote:

Can anyone explain what is happening?
It certainly sounds like problem with permissions... do you know what the old permission set and owner/group were? My guess would be something funny about the permissions on some folder, unless your VIM happens to be setuid.

(in reply to caledfwlch)
Post #: 2
RE: Strange issue with permissions and VIM - Apr. 13, '06, 1:21:30 PM   
Rodney

 

Posts: 3714
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
The group on all of the file should be "Administrators" and the owner
should be the user that installed (either the local Administrator or
the member of the Administrators group). There shouldn't be anything
in (for example) /bin that has +SYSTEM. File/directory permissions are
to be "write" for both owner and group (it's the Windows model so that
members of the Administrators group can do installs/uninstalls).

Vim shouldn't be (and doesn't need to be) setuid.

Ideally the entire "/" tree and everything under it should be kept with
Unix permissions only. There should be no one going into it with a Win32
tool and setting/changing permissions. There's a FAQ entry on this (1.12).
It causes pain There's no need for any Win32 Service to be in this tree.
Which service was doing this?

(in reply to woehlkmp)
Post #: 3
RE: Strange issue with permissions and VIM - Apr. 13, '06, 6:20:20 PM   
woehlkmp

 

Posts: 102
Status: offline
So, on a somewhat related note, should I be worried that any new diretories I make in '/' (and oddly, only '/') show up with group='+SYSTEM'? So far I don't think it's hurt anything, but it's a little strange .

Were these 'mixed' folders just in '/', or deeper in the tree as well?

(in reply to Rodney)
Post #: 4
RE: Strange issue with permissions and VIM - Apr. 13, '06, 10:06:03 PM   
Rodney

 

Posts: 3714
Joined: Jul. 9, '02,
From: /Tools lab
Status: offline
> So, on a somewhat related note, should I be worried that any new diretories I make in '/' (and oddly, only '/') show up with group='+SYSTEM'?

"/" is special. It doesn't exist in the same sense as "/" on other systems.
On other systems "/" really is the top of the disk tree. With Interix it can
be located anywhere. So it's somewhat virtual. There used to be many virtual
directories (Interix 2.2) but it was switched to have on-disk data backing
them up (i.e. character special files for the terminals). "/" is the one of
the last still special (/net & /proc are the others).

However, that all stated those that are +SYSTEM as group really should have
been +Administrators. Not causing harm per se; the MSI install should have
had it different; you can change it.

(in reply to woehlkmp)
Post #: 5
RE: Strange issue with permissions and VIM - Apr. 18, '06, 7:22:18 AM   
caledfwlch

 

Posts: 2
Joined: Sep. 20, '05,
Status: offline
quote:

ORIGINAL: Rodney

Ideally the entire "/" tree and everything under it should be kept with
Unix permissions only. There should be no one going into it with a Win32
tool and setting/changing permissions. There's a FAQ entry on this (1.12).
It causes pain There's no need for any Win32 Service to be in this tree.
Which service was doing this?


O.K. having checked, the directory with the files created by a service was actually a symlink to a standard Windows directory.

I'm still confused as to why doing a chown to the same user cured the VIM problem. However, there does appear to be other things wrong with my main PC (some related to file permissions), whose drive is going to be replaced with a new XP image so the problem will probably go away

(in reply to Rodney)
Post #: 6
Page:   [1]
All Forums >> [SFU / Interix / SUA Technology] >> Interix Advanced Forum >> Strange issue with permissions and VIM Page: [1]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts


Search All Forums -

Advanced search


SPONSORS



Forum Software © ASPPlayground.NET Advanced Edition 2.5 ANSI

0.047