michi Posted March 31, 2006 Posted March 31, 2006 Hi, I was getting a backup by the admin panel and got this warning: Warning: file_exists(): open_basedir restriction in effect. File(/usr/bin/gzip) is not within the allowed path(s): (/home/httpd/vhosts/netaiki.com.br/httpdocs:/tmp) in /home/httpd/vhosts/netaiki.com.br/httpdocs/loja/admin/backup.php on line 424 Warning: file_exists(): open_basedir restriction in effect. File(/usr/local/bin/zip) is not within the allowed path(s): (/home/httpd/vhosts/netaiki.com.br/httpdocs:/tmp) in /home/httpd/vhosts/netaiki.com.br/httpdocs/loja/admin/backup.php on line 425 I chmod 777 the admin/backup directory to give permission to generate the backup but couldn't get it. How can i do? Thanks all!
Guest Posted April 13, 2007 Posted April 13, 2007 Hi, I was getting a backup by the admin panel and got this warning: I chmod 777 the admin/backup directory to give permission to generate the backup but couldn't get it. How can i do? Thanks all! Hi I found this message and don't seem to find an answer. I have the same message displayed on my admin/backup panel. Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/bin/gzip) is not within the allowed path(s): (/home/user/:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/user/public_html/osc/admin/backup.php on line 424 Warning: file_exists() [function.file-exists]: open_basedir restriction in effect. File(/usr/local/bin/zip) is not within the allowed path(s): (/home/user/:/usr/lib/php:/usr/local/lib/php:/tmp) in /home/user/public_html/osc/admin/backup.php on line 425 Here belows are the lines 424 and 425 of backup.php: if (file_exists(LOCAL_EXE_GZIP)) $contents[] = array('text' => '<br>' . tep_draw_radio_field('compress', 'gzip') . ' ' . TEXT_INFO_USE_GZIP); if (file_exists(LOCAL_EXE_ZIP)) $contents[] = array('text' => tep_draw_radio_field('compress', 'zip') . ' ' . TEXT_INFO_USE_ZIP); What are solutions to remove the top two error messages? Is the solution displayed somewhere in this forum? Can anyone show me where to look for the solution? It would be a great help. BTW, I have already got admin/backups folder and it is storing the backup file. Thanks in advance. James Chan
♥Vger Posted April 13, 2007 Posted April 13, 2007 This is a hosting problem caused by running PHP in Safe Mode. What it is telling you is that (/usr/bin/gzip) is in a place which it is not allowed to operate from when PHP is running in Safe Mode. Only your hosts can sort that one out. Vger
spot_on Posted May 24, 2007 Posted May 24, 2007 This is a hosting problem caused by running PHP in Safe Mode. What it is telling you is that (/usr/bin/gzip) is in a place which it is not allowed to operate from when PHP is running in Safe Mode. Only your hosts can sort that one out. Vger I have the same error and have forwarded the link to this thread to them. I'll let you know how I get on! Spot_on
spot_on Posted May 24, 2007 Posted May 24, 2007 I have the same error and have forwarded the link to this thread to them. I'll let you know how I get on! Spot_on Well, my ISP says that safe mode if Off and "I have checked with our engineers and the use of gzip/zip from scripts is not supported on our servers." So, can anyone advise further. Do I need to unzip things?
rhtsouza Posted July 5, 2007 Posted July 5, 2007 If cut the 424 and 425 out, the error lines in admin/backup interface disappear.... but the option to save compressed database is lost too. If isn't a big store this will not be a problem. Renato
wotsupdoc Posted December 4, 2008 Posted December 4, 2008 I got the error msg only after my provider upgraded to PHP 5, so it is probably a problem with PHP 5 and OSC MS2 RC1
arames Posted December 4, 2008 Posted December 4, 2008 BTW, did you know that the name MICHI is a MAP played online for Age Of Empires THE CONQUERORS? Great game actually and great map :)
on9tom Posted January 1, 2009 Posted January 1, 2009 code in backup.php only looks if the file/executable of gzip and zip exist to determine if you can zip or gzip backups. Unfortunately, the open_basedir stuff was invented after that and while the file exists it won't allow you to use it. The remedy is to make sure backup.php thinks the file is not there. This is a bit hidden IMO, in admin/includes/application_top.php around line 40: CODE // Used in the "Backup Manager" to compress backups define('LOCAL_EXE_GZIP', '/usr/bin/gzip'); define('LOCAL_EXE_GUNZIP', '/usr/bin/gunzip'); define('LOCAL_EXE_ZIP', '/usr/local/bin/zip'); define('LOCAL_EXE_UNZIP', '/usr/local/bin/unzip'); If you change it (I think this should work) you won't have the problem anymore: CODE // Used in the "Backup Manager" to compress backups define('LOCAL_EXE_GZIP', 'gzip'); // originally: '/usr/bin/gzip'); define('LOCAL_EXE_GUNZIP', 'gunzip'); // originally '/usr/bin/gunzip'); define('LOCAL_EXE_ZIP', 'zip'); // originally: '/usr/local/bin/zip'); define('LOCAL_EXE_UNZIP', 'unzip'); // originally: '/usr/local/bin/unzip');
Kennith Posted December 19, 2011 Posted December 19, 2011 code in backup.php only looks if the file/executable of gzip and zip exist to determine if you can zip or gzip backups. Unfortunately, the open_basedir stuff was invented after that and while the file exists it won't allow you to use it. The remedy is to make sure backup.php thinks the file is not there. This is a bit hidden IMO, in admin/includes/application_top.php around line 40: CODE // Used in the "Backup Manager" to compress backups define('LOCAL_EXE_GZIP', '/usr/bin/gzip'); define('LOCAL_EXE_GUNZIP', '/usr/bin/gunzip'); define('LOCAL_EXE_ZIP', '/usr/local/bin/zip'); define('LOCAL_EXE_UNZIP', '/usr/local/bin/unzip'); If you change it (I think this should work) you won't have the problem anymore: CODE // Used in the "Backup Manager" to compress backups define('LOCAL_EXE_GZIP', 'gzip'); // originally: '/usr/bin/gzip'); define('LOCAL_EXE_GUNZIP', 'gunzip'); // originally '/usr/bin/gunzip'); define('LOCAL_EXE_ZIP', 'zip'); // originally: '/usr/local/bin/zip'); define('LOCAL_EXE_UNZIP', 'unzip'); // originally: '/usr/local/bin/unzip'); That did the trick for me, thanks
Recommended Posts
Archived
This topic is now archived and is closed to further replies.