Drush and user permissions I see that my user is a member of the apache group. I added and confirmed via the following

$ sudo usermod -a -G apache `whoami`  # add my user to apache group
$ sudo chmod -R g+w .                 # permit group members to write 
$ groups `whoami`                     # confirm I'm in the apache group


However, when I attempt to run a drush update core or even drush cron

$ drush cc all

unlink(sites/default/files/css/css_71ba7c25a8d3c47c68a8e05608ae525c.css):[warning]
Permission denied file.inc:482




And the CSS cache in this situation looks like 

$ ll
total 1536
drwxrwxr-x.  2 apache apache  12288 Nov 26 10:12 .
drwxrwxr-x. 11 apache apache   4096 Nov 24 20:35 ..
-rw-rw-r--   1 apache apache 162269 Nov 26 10:06 css_00d5f4d7c5c92cd4f.css
-rw-rw-r--   1 apache apache 158090 Nov 26 10:02 css_0605989692a2119d305.css
-rw-rw-r--   1 apache apache 162269 Nov 26 10:02 css_0779dcac71ee9aa8e02d9e.css




I would assume that my user account, which has sudo access, should be a group member of apache (or www-data) and that the file tree should permit group write access. Any help or points in the right direction would be much appreciated.
Arguably, a much more straightforward approach is to not muck with your user's group assignments at all and instead run drush as the web server user (ie: apache, www-data).

Use sudo:

sudo -u apache drush


or on debian/ubuntu:

sudo -u www-data drush


Create a command alias:

Then, to ensure that you always run drush like that, add an alias:

echo "alias drush='sudo -u apache drush'" &gt;&gt; ~/.bash_aliases 


or on debian/ubuntu:

echo "alias drush='sudo -u www-data drush'" &gt;&gt; ~/.bash_aliases 


Now when running any drush command, you'll be prompted for your password by sudo, and the command will run as the web server user. No more permissions problem reading and writing files.