Last modified: 2014-10-30 16:19:00 UTC
Our puppet config expects hhvm config files to be looked up in /etc/hhhvm but the latest build () is looking in /usr/etc/hhvm instead. `strace hhvm hello.php` shows: access("/usr/etc/hhvm/php.ini", R_OK) = -1 ENOENT (No such file or directory) access("/usr/etc/hhvm/config.hdf", R_OK) = -1 ENOENT (No such file or directory) This is causing the jobrunner to fail with this error in MediaWiki-Vagrant: Failed to initialize central HHBC repository: Failed to open /var/www/.hhvm.hhbc: 14 - unable to open database file This is because our config files aren't being read. It will probably break the production jobrunner in a similar way.
Partially fixed in 3.3.0-20140925+wmf2: $ strace php hello.php 2>&1 | grep '/etc/hhvm' access("/etc/hhvm/php.ini", R_OK) = 0 access("/etc/hhvm/config.hdf", R_OK) = 0 open("/etc/hhvm/php.ini", O_RDONLY) = 4 stat("/etc/hhvm/config.hdf", {st_mode=S_IFREG|0644, st_size=139, ...}) = 0 open("/etc/hhvm/config.hdf", O_RDONLY) = 4 open("/etc/hhvm/php.ini", O_RDONLY) = 4 open("/etc/hhvm/config.hdf", O_RDONLY) = 4 open("/etc/hhvm/php.ini", O_RDONLY) = 7 open("/etc/hhvm/config.hdf", O_RDONLY) = 7 $ strace hhvm hello.php 2>&1 | grep '/etc/hhvm' access("/usr/etc/hhvm/php.ini", R_OK) = -1 ENOENT (No such file or directory) access("/usr/etc/hhvm/config.hdf", R_OK) = -1 ENOENT (No such file or directory) In this test, `php` id /usr/bin/php -> /etc/alternatives/php -> /usr/bin/hhvm This should be enough to fix the jobrunner, but is still not completely optimal.
Retested with hhvm build 3.3.0+dfsg1-1+wm1: $ strace php hello.php 2>&1 | grep '/etc/hhvm' access("/etc/hhvm/php.ini", R_OK) = 0 access("/etc/hhvm/config.hdf", R_OK) = 0 open("/etc/hhvm/php.ini", O_RDONLY) = 4 stat("/etc/hhvm/config.hdf", {st_mode=S_IFREG|0644, st_size=139, ...}) = 0 open("/etc/hhvm/config.hdf", O_RDONLY) = 4 open("/etc/hhvm/php.ini", O_RDONLY) = 4 open("/etc/hhvm/config.hdf", O_RDONLY) = 4 open("/etc/hhvm/php.ini", O_RDONLY) = 8 open("/etc/hhvm/config.hdf", O_RDONLY) = 8 $ strace hhvm hello.php 2>&1 | grep '/etc/hhvm' access("/etc/hhvm/php.ini", R_OK) = 0 access("/etc/hhvm/config.hdf", R_OK) = 0 open("/etc/hhvm/php.ini", O_RDONLY) = 4 stat("/etc/hhvm/config.hdf", {st_mode=S_IFREG|0644, st_size=139, ...}) = 0 open("/etc/hhvm/config.hdf", O_RDONLY) = 4 open("/etc/hhvm/php.ini", O_RDONLY) = 4 open("/etc/hhvm/config.hdf", O_RDONLY) = 4 open("/etc/hhvm/php.ini", O_RDONLY) = 8 open("/etc/hhvm/config.hdf", O_RDONLY) = 8