{"id":254,"date":"2010-09-12T12:20:01","date_gmt":"2010-09-12T01:20:01","guid":{"rendered":"http:\/\/howden.net.au\/thowden\/?p=254"},"modified":"2010-09-12T12:20:01","modified_gmt":"2010-09-12T01:20:01","slug":"sme-server-httpd-conf-open_basedir-path-to-include-tmp","status":"publish","type":"post","link":"https:\/\/howden.net.au\/thowden\/2010\/09\/sme-server-httpd-conf-open_basedir-path-to-include-tmp\/","title":{"rendered":"SME Server httpd.conf open_basedir path to include \/tmp"},"content":{"rendered":"<p>Working with SugarCRM at the moment with a dev install on my SME Server 8.0b5 in an ibay.<\/p>\n<p>Trying to upload some updates using the SugarCRM admin tool Upgrade Wizard but I kept getting an error stating that &#8216;Missing a Temporary Folder&#8217;. Which is kind of cryptic and Sugar could do well to include the missing folder name that it thinks it needs as that would shorten the research process.<\/p>\n<p>Anywho, the issue can be tracked in the appropriate meesages file, \/var\/log\/messages in the case of SME Server.<\/p>\n<p>The log indicates that Sugar is wanting access to the \/tmp directory for the upload and that this directory is outside the open_basedir restrictions that SME Server configures for iBays.<\/p>\n<p>The quick steps for this are:<\/p>\n<blockquote><p>\nserver#mkdir -p \/etc\/e-smith\/templates-custom\/etc\/httpd\/conf\/httpd.conf\/<br \/>\nserver#cd \/etc\/e-smith\/templates-custom\/etc\/httpd\/conf\/httpd.conf\/<br \/>\nserver#cp \/etc\/e-smith\/templates\/etc\/httpd\/conf\/httpd.conf\/95AddType00PHP2ibays .<br \/>\nserver#mcedit 95AddType00PHP2ibays\n<\/p><\/blockquote>\n<p>I use mcedit for editing, but you might be a vi guru, just substitute mcedit for your favourite editor.<br \/>\nOnce you are editing the file look for the output line near the end, it should look like this<\/p>\n<blockquote>\n<p>                my $basedir = $ibay-&gt;prop(&#8216;PHPBaseDir&#8217;)<br \/>\n                    || (&#8220;\/home\/e-smith\/files\/ibays\/&#8221; . $ibay-&gt;key . &#8220;\/&#8221;);<br \/>\n                $OUT .= &#8221;    php_admin_value open_basedir $basedirn&#8221;;<br \/>\n                $OUT .= &#8220;n&#8221;;\n<\/p><\/blockquote>\n<p>and you need to modify the first .OUT line to include the \/tmp directory<\/p>\n<blockquote>\n<p>                my $basedir = $ibay-&gt;prop(&#8216;PHPBaseDir&#8217;)<br \/>\n                    || (&#8220;\/home\/e-smith\/files\/ibays\/&#8221; . $ibay-&gt;key . &#8220;\/&#8221;);<br \/>\n                $OUT .= &#8221;    php_admin_value open_basedir $basedir:\/tmpn&#8221;;<br \/>\n                $OUT .= &#8220;n&#8221;;\n<\/p><\/blockquote>\n<p>Save that file and rebuild the template, restart apache and the uploads should now be ok. Note that this modification does apply this to ALL iBays. Which suits me.<\/p>\n<blockquote><p>\nserver#\/sbin\/e-smith\/expand-template \/etc\/httpd\/conf\/httpd.conf<br \/>\nserver#apachectl restart\n<\/p><\/blockquote>\n<p>and that is done.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Adding the \/tmp directory to the open_basedir setting in httpd.conf rather than php.ini in SME Server 8.0<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[5,18],"tags":[],"class_list":["post-254","post","type-post","status-publish","format-standard","hentry","category-linux-servers-and-software","category-sugarcrm"],"_links":{"self":[{"href":"https:\/\/howden.net.au\/thowden\/wp-json\/wp\/v2\/posts\/254","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/howden.net.au\/thowden\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/howden.net.au\/thowden\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/howden.net.au\/thowden\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/howden.net.au\/thowden\/wp-json\/wp\/v2\/comments?post=254"}],"version-history":[{"count":0,"href":"https:\/\/howden.net.au\/thowden\/wp-json\/wp\/v2\/posts\/254\/revisions"}],"wp:attachment":[{"href":"https:\/\/howden.net.au\/thowden\/wp-json\/wp\/v2\/media?parent=254"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/howden.net.au\/thowden\/wp-json\/wp\/v2\/categories?post=254"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/howden.net.au\/thowden\/wp-json\/wp\/v2\/tags?post=254"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}