Results 1 to 10 of 10

Thread: Why does SugarCRm have problems with apache user and group

  1. #1
    chucknb87122 is offline Sugar Community Member
    Join Date
    Mar 2005
    Posts
    55

    Default Why does SugarCRm have problems with apache user and group

    Hi,

    Why does the module installer have problems when the httpd user and group are set to 'apache' in http.conf. I finally got 4.0.1e to install (using the patches put out by SugarCRM) but I am still having problems installing modules. The installer stalls at 23% and it appears to be stalling when copying files to /var/www/html/crm/cache/uploads/upgrades/temp... even though I have set permisions on directories and files in 'cache' to 777. Sugarcrm appears to create a new directory with 655 rights and 'apahe' as the owner (since I have set apache as the user and group). Is there a work around for this or do I have to set the apache user and group to root (I really do not want to do this for security reasons)

    Thanks

  2. #2
    kbrill's Avatar
    kbrill is offline SugarCRM PS Engineer
    Join Date
    Jul 2004
    Location
    St Louis, MO
    Posts
    3,183

    Default Re: Why does SugarCRm have problems with apache user and group

    I have many installs with user set to apache so that can't be it. The files are unzipped in cache and then copied FROM there to other dirs. It's probably the permissions on those other directories that are the problem. What module are you trying to install?
    Kenneth Brill - Help Forum Moderator

    I do not respond to 'Private Messages'. Please email me directly instead

    When asking for help, PLEASE give us your Server Information and Version Numbers as asked for on the 'Post New Message' screen as well as any JavaScript errors shown at the bottom of the browser window.
    Help us Help You

  3. #3
    chucknb87122 is offline Sugar Community Member
    Join Date
    Mar 2005
    Posts
    55

    Default Re: Why does SugarCRm have problems with apache user and group

    Hi,

    I have tried the "photographic company director" and the "Callroom: Maps & Directions" and I am about to try the "resource module".

    Thanks

  4. #4
    chucknb87122 is offline Sugar Community Member
    Join Date
    Mar 2005
    Posts
    55

    Default Re: Why does SugarCRm have problems with apache user and group

    Hi,

    I just tried the "resource module" that just came out for 4.0.1e sugarcrm and I had the same problem. Do you know of a module that you have tried that works with SugarCRm 4.0.1e that I could try as a test.

    Thanks

  5. #5
    kbrill's Avatar
    kbrill is offline SugarCRM PS Engineer
    Join Date
    Jul 2004
    Location
    St Louis, MO
    Posts
    3,183

    Default Re: Why does SugarCRm have problems with apache user and group

    Quote Originally Posted by chucknb87122
    Hi,

    I have tried the "photographic company director" and the "Callroom: Maps & Directions" and I am about to try the "resource module".

    Thanks
    You might check your permissions on your modules directory. I bet somewhere in there you have a permission or user/group problem there. all directorys should be writable by apache.
    Kenneth Brill - Help Forum Moderator

    I do not respond to 'Private Messages'. Please email me directly instead

    When asking for help, PLEASE give us your Server Information and Version Numbers as asked for on the 'Post New Message' screen as well as any JavaScript errors shown at the bottom of the browser window.
    Help us Help You

  6. #6
    dakman1 is offline Sugar Community Member
    Join Date
    Mar 2006
    Posts
    24

    Angry Re: Why does SugarCRm have problems with apache user and group

    This command works well for me :

    chmod --recursive 777 sugarcrmdir/

  7. #7
    chucknb87122 is offline Sugar Community Member
    Join Date
    Mar 2005
    Posts
    55

    Default Re: Why does SugarCRm have problems with apache user and group

    Hi,

    Nope still the same problem. Here is the result from the install of the resource module:

    23%

    Display Log
    Rebuilding Include Modules...
    Merging application files for modules.ext.php in Ext/Include
    Copying .../patch/vcal_res_server.php to vcal_res_server.php
    Copy /var/www/html/crm/cache/upload//upgrades/temp/u8dPLw/patch/vcal_res_server.php
    Failed to copy /var/www/html/crm/cache/upload/upgrades/temp/u8dPLw/patch/vcal_res_server.php vcal_res_server.php

    Thanks

  8. #8
    absalom is offline Junior Member
    Join Date
    May 2006
    Location
    Sweden
    Posts
    1

    Default Re: Why does SugarCRm have problems with apache user and group

    I have a similar problem.
    When I upload a module (lang pack) the owner/group is set to httpd:httpd
    My host dosnīt allow me to change this and I have to request them to do it for me. (I guess they donīt have enogh to do)
    Even thogh this is changed I still get some permission errors caused by the temp dir it seems.
    I have tried CHMOD but it seems that the owner/group is set to httpd:httpd again.
    Is there some script or setting in the module that can be changed so it installs wit the rigth owner and permission?

  9. #9
    Cartika is offline Member
    Join Date
    Aug 2004
    Posts
    6

    Default Re: Why does SugarCRm have problems with apache user and group

    When I upload a module (lang pack) the owner/group is set to httpd:httpd
    This has very little to do with sugarcrm in particular, this is more a function of apache.

    Apache, for security reasons, runs its processes owned by a "special" user... often named nobody, or apache, or httpd, or any other name that your systems administrator names it in the conf file. When you upload your file to the php script. Php is running as an apache module, which is running in the apache process, therfore user httpd:httpd owns it. Because of this... when php says... move_uploaded_file() and saves the file yetSomethingElse.txt ... it will be owned by the user httpd. This isnt a bug or anything of the sort, this is just how the filesystem ownership works.

    In order to avoid this, you need to install these modules manually.

    For those of you with root or ssh access, you need the following command to return permissions to your user rather then apache

    chown -R user:user foldername

    Hope this helps...

  10. #10
    roastedbean's Avatar
    roastedbean is offline Sugar Community Member
    Join Date
    Mar 2007
    Location
    Gilbert, AZ
    Posts
    11

    Default Re: Why does SugarCRm have problems with apache user and group

    Quote Originally Posted by absalom
    Is there some script or setting in the module that can be changed so it installs with the right owner and permission?
    I'm using a shared hosting plan; PHP script files/folders written are owned by nobody:nobody so I can not work with the files/folders and must contact host for recursive ownership change. Is it possible to add code to the ModuleInstaller.php (or appropriate file) so that after the new folders/files are written that the server chown to my username?

    Your wisdom and generosity is humbling...

    Much thanks,

    Andrew

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

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