Results 1 to 10 of 10

Thread: Folder/File Rights /home/userID/documents

  1. #1

    Exclamation Folder/File Rights /home/userID/documents

    Brushing up on VI and had the following problem.

    vi /home/userID/documents/new.txt

    Input some text, and on :wq! received file write error.
    used file browser, and looked at properties of "/home/userID/documents" owner, group, others file rights could not be set to read/write.

  2. #2
    Join Date
    Jun 2008
    Location
    West Yorkshire, UK
    Posts
    3,431

    Default Re: Folder/File Rights /home/userID/documents

    'others' is not a standard group; normally it is 'users'; check whether you have created the group 'others' correctly.

    Normally you cannot create the first version of a file in another user's /home; the user has to create it and then change the properties to allow other users to write to it.
    Last edited by john_hudson; 15-Feb-2009 at 02:31. Reason: Additional comment

  3. #3
    Join Date
    Jul 2008
    Location
    Voorhout, Netherlands
    Posts
    262

    Default Re: Folder/File Rights /home/userID/documents

    iskko wrote:
    > Brushing up on VI and had the following problem.
    >
    > vi /home/userID/documents/new.txt
    >
    > Input some text, and on :wq! received file write error.
    > used file browser, and looked at properties of "/home/userID/documents"
    > owner, group, others file rights could not be set to read/write.


    It would help if you do:
    Code:
    $ id userID
    $ stat /home/userID/documents/new.txt
    for us.
    Most likely the file has been created by another user.

  4. #4
    Join Date
    Jul 2008
    Location
    Voorhout, Netherlands
    Posts
    262

    Default Re: Folder/File Rights /home/userID/documents

    john hudson wrote:
    > 'others' is not a standard group; normally it is 'users'; check whether
    > you have created the group 'others' correctly.


    <grin>
    See chmod(1)
    'others' is the set of users that are not in [owner,group]

    A combination of the letters ugoa controls which users' access to the
    file will be changed: the user who owns it (u), other users in the
    file's group (g), other users not in the file's group (o), or all users
    (a).


  5. #5

    Default Re: Folder/File Rights /home/userID/documents

    Quote Originally Posted by LittleRedRooster View Post
    iskko wrote:
    > Brushing up on VI and had the following problem.
    >
    > vi /home/userID/documents/new.txt
    >
    > Input some text, and on :wq! received file write error.
    > used file browser, and looked at properties of "/home/userID/documents"
    > owner, group, others file rights could not be set to read/write.


    It would help if you do:
    Code:
    $ id userID
    $ stat /home/userID/documents/new.txt
    for us.
    Most likely the file has been created by another user.
    On this machine i'm the only user, and was creating the file from scratch into my documents directory. I guess I have to touch it first?

  6. #6
    Join Date
    Jul 2008
    Location
    Voorhout, Netherlands
    Posts
    262

    Default Re: Folder/File Rights /home/userID/documents

    iskko wrote:
    > LittleRedRooster;1944802 Wrote:
    >> iskko wrote:
    >>> Brushing up on VI and had the following problem.
    >>>
    >>> vi /home/userID/documents/new.txt
    >>>
    >>> Input some text, and on :wq! received file write error.
    >>> used file browser, and looked at properties of

    >> "/home/userID/documents"
    >>> owner, group, others file rights could not be set to read/write.

    >> It would help if you do:

    > Code:
    > --------------------
    > > >

    > > $ id userID
    > > $ stat /home/userID/documents/new.txt
    > >

    > --------------------
    >> for us.
    >> Most likely the file has been created by another user.

    >
    > On this machine i'm the only user, and was creating the file from
    > scratch into my documents directory. I guess I have to touch it first?


    No, you don't.
    Still waiting for the output of the two cammands I requested.
    Btw: also check if the 'documents' directory has the write bit set for group
    users.


  7. #7

    Default Re: Folder/File Rights /home/userID/documents

    Quote Originally Posted by LittleRedRooster View Post
    iskko wrote:
    > LittleRedRooster;1944802 Wrote:
    >> iskko wrote:
    >>> Brushing up on VI and had the following problem.
    >>>
    >>> vi /home/userID/documents/new.txt
    >>>
    >>> Input some text, and on :wq! received file write error.
    >>> used file browser, and looked at properties of

    >> "/home/userID/documents"
    >>> owner, group, others file rights could not be set to read/write.

    >> It would help if you do:

    > Code:
    > --------------------
    > > >

    > > $ id userID
    > > $ stat /home/userID/documents/new.txt
    > >

    > --------------------
    >> for us.
    >> Most likely the file has been created by another user.

    >
    > On this machine i'm the only user, and was creating the file from
    > scratch into my documents directory. I guess I have to touch it first?


    No, you don't.
    Still waiting for the output of the two cammands I requested.
    Btw: also check if the 'documents' directory has the write bit set for group
    users.
    Out put as follow, i expected the file stat as the file dosen't exist yet.

    iskko@linux-vit5:~/Desktop> id iskko
    uid=1000(iskko) gid=100(users) groups=16(dialout),33(video),100(users)
    iskko@linux-vit5:~/Desktop> stat /home/iskko/documents/new.txt
    stat: cannot stat `/home/iskko/documents/new.txt': No such file or directory

    /home/iskko/documents directory
    drwxrwxr-x 2 iskko users 4096 2009-02-13 11:34 Documents

  8. #8
    Join Date
    Jul 2008
    Location
    Voorhout, Netherlands
    Posts
    262

    Default Re: Folder/File Rights /home/userID/documents

    iskko wrote:
    > LittleRedRooster;1944878 Wrote:
    >> iskko wrote:
    >>> LittleRedRooster;1944802 Wrote:
    >>>> iskko wrote:
    >>>>> Brushing up on VI and had the following problem.
    >>>>>
    >>>>> vi /home/userID/documents/new.txt
    >>>>>
    >>>>> Input some text, and on :wq! received file write error.
    >>>>> used file browser, and looked at properties of
    >>>> "/home/userID/documents"
    >>>>> owner, group, others file rights could not be set to read/write.
    >>>> It would help if you do:
    >>> Code:
    >>> --------------------
    >>> > >
    >>> > $ id userID
    >>> > $ stat /home/userID/documents/new.txt
    >>> >
    >>> --------------------
    >>>> for us.
    >>>> Most likely the file has been created by another user.
    >>> On this machine i'm the only user, and was creating the file from
    >>> scratch into my documents directory. I guess I have to touch it

    >> first?
    >>
    >> No, you don't.
    >> Still waiting for the output of the two cammands I requested.
    >> Btw: also check if the 'documents' directory has the write bit set for
    >> group
    >> users.

    >
    > Out put as follow, i expected the file stat as the file dosen't exist
    > yet.


    Ah, I thought it did but vi could write to the file.

    > iskko@linux-vit5:~/Desktop> id iskko
    > uid=1000(iskko) gid=100(users) groups=16(dialout),33(video),100(users)


    That looks ok.

    > iskko@linux-vit5:~/Desktop> stat /home/userID/documents/new.txt
    > stat: cannot stat `/home/userID/documents/new.txt': No such file or
    > directory
    >
    > /home/iskko/documents directory

    ^
    > drwxrwxr-x 2 iskko users 4096 2009-02-13 11:34 Documents

    ^

    Do you have maybe two directories, one called 'Documents' and one called
    'documents' (notice the upper/lower case first letter)?

    Remember that Unices are case-sensitive, names have to be followed exact.

  9. #9

    Default Re: Folder/File Rights /home/userID/documents

    Quote Originally Posted by LittleRedRooster View Post
    iskko wrote:
    > LittleRedRooster;1944878 Wrote:
    >> iskko wrote:
    >>> LittleRedRooster;1944802 Wrote:
    >>>> iskko wrote:
    >>>>> Brushing up on VI and had the following problem.
    >>>>>
    >>>>> vi /home/userID/documents/new.txt
    >>>>>
    >>>>> Input some text, and on :wq! received file write error.
    >>>>> used file browser, and looked at properties of
    >>>> "/home/userID/documents"
    >>>>> owner, group, others file rights could not be set to read/write.
    >>>> It would help if you do:
    >>> Code:
    >>> --------------------
    >>> > >
    >>> > $ id userID
    >>> > $ stat /home/userID/documents/new.txt
    >>> >
    >>> --------------------
    >>>> for us.
    >>>> Most likely the file has been created by another user.
    >>> On this machine i'm the only user, and was creating the file from
    >>> scratch into my documents directory. I guess I have to touch it

    >> first?
    >>
    >> No, you don't.
    >> Still waiting for the output of the two cammands I requested.
    >> Btw: also check if the 'documents' directory has the write bit set for
    >> group
    >> users.

    >
    > Out put as follow, i expected the file stat as the file dosen't exist
    > yet.


    Ah, I thought it did but vi could write to the file.

    > iskko@linux-vit5:~/Desktop> id iskko
    > uid=1000(iskko) gid=100(users) groups=16(dialout),33(video),100(users)


    That looks ok.

    > iskko@linux-vit5:~/Desktop> stat /home/userID/documents/new.txt
    > stat: cannot stat `/home/userID/documents/new.txt': No such file or
    > directory
    >
    > /home/iskko/documents directory

    ^
    > drwxrwxr-x 2 iskko users 4096 2009-02-13 11:34 Documents

    ^

    Do you have maybe two directories, one called 'Documents' and one called
    'documents' (notice the upper/lower case first letter)?

    Remember that Unices are case-sensitive, names have to be followed exact.

    Now you see what three year away from UNIX does. You got it, I missed the case on the Documents directory. Thanks.

  10. #10
    Join Date
    Jul 2008
    Location
    Voorhout, Netherlands
    Posts
    262

    Default Re: Folder/File Rights /home/userID/documents

    iskko wrote:
    > LittleRedRooster;1945063 Wrote:
    >> iskko wrote:

    [..]
    >>> /home/iskko/documents directory

    >> ^
    >>> drwxrwxr-x 2 iskko users 4096 2009-02-13 11:34 Documents

    >> ^
    >>
    >> Do you have maybe two directories, one called 'Documents' and one
    >> called
    >> 'documents' (notice the upper/lower case first letter)?
    >>
    >> Remember that Unices are case-sensitive, names have to be followed
    >> exact.

    >
    >
    > Now you see what three year away from UNIX does. You got it, I missed
    > the case on the Documents directory. Thanks.


    :-)
    Good of you to report back here, thanks, and good to know it's solved.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •