Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
scafold : Error: Unable to read existing migrations. Do you have an 'open_basedir' defined?
  • I've seen another post on the same error message, but all is ok for me. this is a screenshot of all the error message, and the configuration : my PHP Version => 5.4.5
    i work on archlinux. Is there a spacial php module to enable ?
  • Messages like that are usually rights related. Does the current logged on user have full access to the app folder (and all files/folders in there)?
  • Yes. I've try in root, and the error message is the same. It's on a local server, so i've set all permission on 777.
  • According to the code you get that error when APPPATH."/migrations" can not be read. Does that folder exist?
  • it exist, and it is writeable. i've tryied to install from the quick installation, but it's always the same thing :/
  • Can you start the oil console (php oil console) and at the console prompt type
    what is the response? If false, it could be because of a flaky behaviour of glob() when open_basedir is set. When set, and no migrations exist, it seems to return false ( indicating an error while there is none ) instead of an empty array.
    If this is the case, please create an issue for this at so it can be addressed.
  • php oil console
    Warning - ini_set(): open_basedir restriction in effect. File() is not within the allowed path(s): (/) in PKGPATH/oil/classes/console.php on line 31
    Fuel 1.2.1 - PHP 5.4.5 (cli) (Jul 19 2012 04:58:27) [Linux]
    >>> var_dump(glob(APPPATH."migrations/*"))
    bool(false) Thanks.
    How can i bypass this bug ?
  • The big question is if this is a bug (in FuelPHP). PHP is blocking you from accessing the migrations folder due to the open_basedir setting, which is the warning you are getting. However, since you have set the open_basedir to '/' (which is a bit pointless, but ok), the files requested are clearly inside the open_basedir defined. It seems to be a bug in PHP, which has been open a while, but still not fixed: Please add a issue on github for this, so someone can pick it up and create a workaround for it.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion