Find the answer to your Linux question:
Results 1 to 5 of 5
Hello, Basically - how do I get linux to 're-read' my permissions when i've added myself to a group without having to log off and on again? I wanted access ...
  1. #1
    Linux Newbie
    Join Date
    Nov 2006
    Posts
    123

    very simple file permissions question

    Hello,
    Basically - how do I get linux to 're-read' my permissions when i've added myself to a group without having to log off and on again?
    I wanted access to webfiles so I did
    Code:
    groupadd webmodifiers
    chgrp -R webmodifiers /srv/www/htdocs
    usermod -Awebmodifiers ben
    then, user 'ben' should be able to write to htdocs, but can't until I log off and log on again.
    Any ideas?
    Ta

  2. #2
    Just Joined!
    Join Date
    Dec 2006
    Posts
    3
    chmod command
    chmod 777 the dir or file
    ex: chmod 777 /srv/www/htdocs

    this method is called the absolute method it changes all the permissions at once. 777 gives u read/write/execute permissions to the file or dir.

  3. #3
    Linux Guru smolloy's Avatar
    Join Date
    Apr 2005
    Location
    CA, but from N.Ireland
    Posts
    2,413
    Quote Originally Posted by Nvzabl
    this method is called the absolute method it changes all the permissions at once. 777 gives u read/write/execute permissions to the file or dir.
    This sounds like a bad bad bad idea. You don't want to have rwx permissions for everyone on a web server -- that's just asking for trouble.

    The original poster was asking how to "refresh" the permissions without restarting his login session, not how to give the world rwx permissions to his server!
    Registered Linux user #388328 || Registered LFS user #15880
    AMD 64 X2 4600+ :: 2X1GB DDR2 800 :: GeForce 9400 GT 512MB :: ASUS M2N32 Deluxe :: 4X250GB SATAII
    Need instant help? Try us on IRC -- #linuxforums on freenode

  4. #4
    Trusted Penguin Cabhan's Avatar
    Join Date
    Jan 2005
    Location
    Seattle, WA, USA
    Posts
    3,230
    Try running the 'newgrp' command with no parameters. If that doesn't work, you can try 'newgrp -'.

    Otherwise, the best solution may be to just logout and back in.
    DISTRO=Arch
    Registered Linux User #388732

  5. #5
    Just Joined!
    Join Date
    Jun 2006
    Location
    (.)
    Posts
    69
    Hi,

    Check the below mentioned URL:

    http://forums.linuxwebadmin.info/ind...opic,34.0.html

    if you are already logged in and you made some changes in environment variable in /etc/profile, $HOME/.bash_profile, /etc/bashrc, $HOME/.bashrc etc
    and you don't want to relogin for change effect, than run these all script with command "source"

    #source /etc/profile

    It will refresh your currunt environment..........

Posting Permissions

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