Bienvenue, Invité
Nom d'utilisateur : Mot de passe :


For issues related to the current stable release please use it's own Help forum.
IMPORTANT:Please read this before using an git or nightly build version: wiki.webtrees.net/en/GIT

Before asking for help please read "How to request help" by clicking on that tab above here.

SUJET : [SOLVED] 2.0.0-beta.3 - Server Warning

2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #1

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
In webtrees 2, installed in a shared webspace environment (PHP-version 7.3.6), i get the following warning...

The server’s temporary folder cannot be accessed.
sys_get_temp_dir() = "/tmp"
ini_get("open_basedir") = "/var/www/vhosts/PATH/WEBTREESFOLDER/:/tmp/:/var/lib/php5/sessions:/var/www/vhosts/PATH/tmp"

However, it seems, that anything is doing well.

Is there anything what I can do in webtrees to avoid this warning? I have no direct access to the php.ini.
L'administrateur a désactivé l'accès en écriture pour le public.

2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #2

  • fisharebest
  • Portrait de fisharebest
  • en ligne
  • Administrator
  • Messages : 11465
there is an example custom module included with webtrees which shows how to fix this.

i am on holiday without my laptop so cannot help further until next week
Greg Roach - Cette adresse e-mail est protégée contre les robots spammeurs. Vous devez activer le JavaScript pour la visualiser. - fisharebest.webtrees.net
L'administrateur a désactivé l'accès en écriture pour le public.

2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #3

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
Thanks, that's a good approach. I'll give it a try and if I'm stuck, I'll get back to you.
Have a nice holiday!
L'administrateur a désactivé l'accès en écriture pour le public.

2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #4

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
JPS écrit:
Thanks, that's a good approach. I'll give it a try and if I'm stuck, I'll get back to you.
Have a nice holiday!

Quick win!

This entry is working well...

    /**
     * Modify the PHP environment variables.
     */
    private function phpEnvironment(): void
    {
        // Some servers block access to the system temporary folder using open_basedir...
        //
        // Create a temporary folder somewhere we have read/write access, and tell PHP to use it.
        //putenv('TMPDIR=' . $tmp);
        $tmp = __DIR__ . '/var/www/vhosts/PATH/NEW WEBTREES TEMP FOLDER';
        //if (!is_dir($tmp)) {
        //   mkdir($tmp);
        //}
        putenv('TMPDIR=' . $tmp);
    }

Thanks for support and again, enjoy your vacation.
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #5

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
Problem solved.
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #6

  • jprause
  • Portrait de jprause
  • Hors Ligne
  • Junior
  • Messages : 132
I have the same issue like JPS:

The server’s temporary folder cannot be accessed.
sys_get_temp_dir() = "/tmp"
ini_get("open_basedir") = "/hosting/www/jprodina.cz/:/hosting/public/:/tmp/:/hosting/session/jprodina.cz/"

May I ask for more detailed way of solution, please?
Josef

local desktop:-- webtrees 1.7.14, PHP version 7.2.19, MySQL 5.7.25, Apache2 2.4.29, Linux Ubuntu 18.04 64bit
webhosting:-- webtrees 1.7.14, PHP version 7.2.19, MySQL 5.7.21
testing webtrees 2.0.0-beta.3
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #7

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
jprause écrit:
I have the same issue like JPS:

The server’s temporary folder cannot be accessed.
sys_get_temp_dir() = "/tmp"
ini_get("open_basedir") = "/hosting/www/jprodina.cz/:/hosting/public/:/tmp/:/hosting/session/jprodina.cz/"

May I ask for more detailed way of solution, please?

Hello Josef,

the problem is probably, that your temp-folder is write protected by your hoster.

My solution was to use the demo module "example-server-configuration.disable". I first renamed it to "server-configuration" and activated it. Then I added an individualual "webtreestemp" folder in the root directory which is writable and changed the module.php as shown above. Your entry has to be your individual direct path to the "webtreestemp" folder.

However, I recognized the following problems:

1. When I add this...

if (!is_dir($tmp)) {
mkdir($tmp);
}

...I get this errorcode:

mkdir(): No such file or directory …/modules_v4/server-configuration/module.php:112
#0 [internal function]: Fisharebest\Webtrees\Webtrees::Fisharebest\Webtrees\{closure}(2, 'mkdir(): No suc...', '/var/www/vhosts...', 112, Array)
#1 …/modules_v4/server-configuration/module.php(112): mkdir('/var/www/vhosts...')
#2 …/modules_v4/server-configuration/module.php(74): class@anonymous->phpEnvironment()
#3 [internal function]: class@anonymous->boot(Object(Fisharebest\Webtrees\Services\ServerCheckService))
#4 …/app/Application.php(45): ReflectionMethod->invoke(Object(class@anonymous), Object(Fisharebest\Webtrees\Services\ServerCheckService))
#5 …/app/Http/Middleware/BootModules.php(55): Fisharebest\Webtrees\Application->dispatch(Object(class@anonymous), 'boot')
#6 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\BootModules->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#7 …/app/Http/Middleware/UseTransaction.php(44): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#8 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseTransaction->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#9 …/app/Http/Middleware/CheckCsrf.php(63): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#10 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\CheckCsrf->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#11 …/app/Http/Middleware/DoHousekeeping.php(76): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#12 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\DoHousekeeping->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#13 …/app/Http/Middleware/UseTheme.php(70): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#14 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseTheme->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#15 …/app/Http/Middleware/CheckForMaintenanceMode.php(49): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#16 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\CheckForMaintenanceMode->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#17 …/app/Http/Middleware/UseLocale.php(51): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#18 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseLocale->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#19 …/app/Http/Middleware/UseTree.php(59): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#20 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseTree->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#21 …/app/Http/Middleware/UseSession.php(58): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#22 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseSession->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#23 …/app/Http/Middleware/UseFilesystem.php(49): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#24 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseFilesystem->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#25 …/app/Http/Middleware/UseCache.php(44): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#26 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseCache->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#27 …/app/Http/Middleware/UpdateDatabaseSchema.php(56): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#28 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UpdateDatabaseSchema->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#29 …/app/Http/Middleware/UseDebugbar.php(64): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#30 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseDebugbar->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#31 …/app/Http/Middleware/UseDatabase.php(85): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#32 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseDatabase->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#33 …/app/Http/Middleware/ReadConfigIni.php(62): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#34 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\ReadConfigIni->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#35 …/app/Http/Middleware/HandleExceptions.php(54): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#36 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\HandleExceptions->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#37 …/app/Http/Middleware/EmitResponse.php(52): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#38 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\EmitResponse->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#39 …/app/Http/Middleware/PhpEnvironment.php(46): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#40 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\PhpEnvironment->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#41 …/vendor/oscarotero/middleland/src/Dispatcher.php(118): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#42 …/index.php(40): Middleland\Dispatcher->dispatch(Object(Nyholm\Psr7\ServerRequest))
#43 {main}

With this...

if (!is_dir($tmp)) {
//mkdir($tmp);
}

...the above error and the message "The server’s temporary folder cannot be accessed." are disappeared.

However, when I use the "Place hierarchy" and select a location with 635 individuals I get this error...

fwrite(): Unable to create temporary file, Check permissions in temporary files directory. …/vendor/nyholm/psr7/src/Stream.php:71
#0 [internal function]: Fisharebest\Webtrees\Webtrees::Fisharebest\Webtrees\{closure}(2, 'fwrite(): Unabl...', '/var/www/vhosts...', 71, Array)
#1 …/vendor/nyholm/psr7/src/Stream.php(71): fwrite(Resource id #2538, '\n<!DOCTYPE html...')
#2 …/vendor/nyholm/psr7/src/Factory/Psr17Factory.php(28): Nyholm\Psr7\Stream::create('\n<!DOCTYPE html...')
#3 …/app/Helpers/functions.php(133): Nyholm\Psr7\Factory\Psr17Factory->createStream('\n<!DOCTYPE html...')
#4 …/app/Http/ViewResponseTrait.php(54): response('\n<!DOCTYPE html...', 200)
#5 …/app/Http/Controllers/PlaceHierarchyController.php(128): Fisharebest\Webtrees\Http\Controllers\AbstractBaseController->viewResponse('places-page', Array)
#6 …/app/Module/PlaceHierarchyListModule.php(81): Fisharebest\Webtrees\Http\Controllers\PlaceHierarchyController->show(Object(Nyholm\Psr7\ServerRequest), Object(Fisharebest\Webtrees\Tree), Object(Fisharebest\Webtrees\Services\SearchService))
#7 [internal function]: Fisharebest\Webtrees\Module\PlaceHierarchyListModule->getListAction(Object(Nyholm\Psr7\ServerRequest), Object(Fisharebest\Webtrees\Tree), Object(Fisharebest\Webtrees\User))
#8 …/app/Application.php(45): ReflectionMethod->invoke(Object(Fisharebest\Webtrees\Module\PlaceHierarchyListModule), Object(Nyholm\Psr7\ServerRequest), Object(Fisharebest\Webtrees\Tree), Object(Fisharebest\Webtrees\User))
#9 …/app/Http/RequestHandlers/ModuleAction.php(90): Fisharebest\Webtrees\Application->dispatch(Object(Fisharebest\Webtrees\Module\PlaceHierarchyListModule), 'getListAction')
#10 …/app/Http/Middleware/RequestRouter.php(77): Fisharebest\Webtrees\Http\RequestHandlers\ModuleAction->handle(Object(Nyholm\Psr7\ServerRequest))
#11 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\RequestRouter->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#12 …/app/Http/Middleware/ModuleMiddleware.php(75): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#13 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\ModuleMiddleware->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#14 …/app/Http/Middleware/BootModules.php(58): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#15 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\BootModules->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#16 …/app/Http/Middleware/UseTransaction.php(44): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#17 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseTransaction->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#18 …/app/Http/Middleware/CheckCsrf.php(63): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#19 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\CheckCsrf->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#20 …/app/Http/Middleware/DoHousekeeping.php(76): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#21 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\DoHousekeeping->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#22 …/app/Http/Middleware/UseTheme.php(70): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#23 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseTheme->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#24 …/app/Http/Middleware/CheckForMaintenanceMode.php(49): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#25 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\CheckForMaintenanceMode->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#26 …/app/Http/Middleware/UseLocale.php(51): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#27 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseLocale->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#28 …/app/Http/Middleware/UseTree.php(59): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#29 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseTree->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#30 …/app/Http/Middleware/UseSession.php(58): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#31 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseSession->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#32 …/app/Http/Middleware/UseFilesystem.php(49): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#33 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseFilesystem->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#34 …/app/Http/Middleware/UseCache.php(44): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#35 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseCache->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#36 …/app/Http/Middleware/UpdateDatabaseSchema.php(56): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#37 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UpdateDatabaseSchema->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#38 …/app/Http/Middleware/UseDebugbar.php(64): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#39 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseDebugbar->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#40 …/app/Http/Middleware/UseDatabase.php(85): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#41 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\UseDatabase->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#42 …/app/Http/Middleware/ReadConfigIni.php(62): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#43 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\ReadConfigIni->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#44 …/app/Http/Middleware/HandleExceptions.php(54): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#45 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\HandleExceptions->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#46 …/app/Http/Middleware/EmitResponse.php(52): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#47 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\EmitResponse->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#48 …/app/Http/Middleware/PhpEnvironment.php(46): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#49 …/vendor/oscarotero/middleland/src/Dispatcher.php(136): Fisharebest\Webtrees\Http\Middleware\PhpEnvironment->process(Object(Nyholm\Psr7\ServerRequest), Object(Middleland\Dispatcher))
#50 …/vendor/oscarotero/middleland/src/Dispatcher.php(118): Middleland\Dispatcher->handle(Object(Nyholm\Psr7\ServerRequest))
#51 …/index.php(40): Middleland\Dispatcher->dispatch(Object(Nyholm\Psr7\ServerRequest))
#52 {main}

When I deactivate the "Server configuration" module, I get the message "The server’s temporary folder cannot be accessed." again but everything is working fine.

So I am not sure if I could really solve this problem. My present solution is to let the module deactivated.

Jens
Dernière édition: il y a 3 mois 1 semaine par JPS.
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #8

  • fisharebest
  • Portrait de fisharebest
  • en ligne
  • Administrator
  • Messages : 11465
> 1. When I add this...

Perhaps you specified a path with lots of subfolders?
The command mkdir('a/b/c') will only work if the folder 'a/b' already exists.

Perhaps you chose a folder where you do not have write permission?
The command mkdir('a/b/c') will only work if the folder 'a/b' has write permission.

> However, when I use the "Place hierarchy" and select a location with 635 individuals I get this error...

webtrees is asking PHP for some temporary storage.
When a small amount of storage is needed, PHP uses memory.
When a large amount of storage is needed, PHP uses a file - in the "sys_temp_dir" folder.

If you can set a temporary folder, then this error should disappear.
Greg Roach - Cette adresse e-mail est protégée contre les robots spammeurs. Vous devez activer le JavaScript pour la visualiser. - fisharebest.webtrees.net
L'administrateur a désactivé l'accès en écriture pour le public.
Avez-vous besoin d'une solution d'hébergement web pour votre site webtrees ?
Si vous préférez un hébergeur spécialisé de webtrees, la page suivante en liste quelques-uns capables de vous offrir ce type de service :

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #9

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
fisharebest écrit:
> 1. When I add this...

Perhaps you specified a path with lots of subfolders?
The command mkdir('a/b/c') will only work if the folder 'a/b' already exists.

Perhaps you chose a folder where you do not have write permission?
The command mkdir('a/b/c') will only work if the folder 'a/b' has write permission.

Mmmh, I don't think so, this is my present tmp folder (in root)...



The permissions are set to 0777.
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #10

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
fisharebest écrit:
>

> However, when I use the "Place hierarchy" and select a location with 635 individuals I get this error...

webtrees is asking PHP for some temporary storage.
When a small amount of storage is needed, PHP uses memory.
When a large amount of storage is needed, PHP uses a file - in the "sys_temp_dir" folder.

If you can set a temporary folder, then this error should disappear.

So I think I have no problems without the tmp folder because my hosting is quite powerfull:

Guaranteed usable RAM: 8192 MB
PHP Memory Limit: 1024 MB
PHP Upload Filesize: 256 MB
PHP Execution Time: 180 s
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #11

  • fisharebest
  • Portrait de fisharebest
  • en ligne
  • Administrator
  • Messages : 11465
> Mmmh, I don't think so, this is my present tmp folder (in root)...

Instead of the root folder, try a subfolder inside the webtrees data folder?
Greg Roach - Cette adresse e-mail est protégée contre les robots spammeurs. Vous devez activer le JavaScript pour la visualiser. - fisharebest.webtrees.net
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #12

  • fisharebest
  • Portrait de fisharebest
  • en ligne
  • Administrator
  • Messages : 11465
> So I think I have no problems without the tmp folder because my hosting is quite powerfull:

This size/power of the server makes no difference.
The problem is the configuration.
Greg Roach - Cette adresse e-mail est protégée contre les robots spammeurs. Vous devez activer le JavaScript pour la visualiser. - fisharebest.webtrees.net
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #13

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
fisharebest écrit:
> Mmmh, I don't think so, this is my present tmp folder (in root)...

Instead of the root folder, try a subfolder inside the webtrees data folder?

exactly the same behavior
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #14

  • fisharebest
  • Portrait de fisharebest
  • en ligne
  • Administrator
  • Messages : 11465
The TMPDIR variable is only used when there is no value specified in the php.ini.

But your server did specify a folder (/tmp) in the php.ini.

Are you allowed to use .htaccess files to modify your server configuration?
If so, then you can use this to set the sys_temp_dir.
If not, then I can't think of a solution to fix this.

Perhaps you need to raise a support ticket with your webhost.
Say that the settings for sys_temp_dir and open_basedir are incompatible.
Greg Roach - Cette adresse e-mail est protégée contre les robots spammeurs. Vous devez activer le JavaScript pour la visualiser. - fisharebest.webtrees.net
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 1 semaine #15

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
fisharebest écrit:
Perhaps you need to raise a support ticket with your webhost.

Thanks so far, I will check this with my hoster and come back.

Good night
Jens
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 6 jours #16

  • jprause
  • Portrait de jprause
  • Hors Ligne
  • Junior
  • Messages : 132
Here is my solution which seems to clear the issue (note: putenv(...) is uncommented, too):
/**
     * Modify the PHP environment variables.
     */
    private function phpEnvironment(): void
    {
        // Some servers block access to the system temporary folder using open_basedir...
        //
        // Create a temporary folder somewhere we have read/write access, and tell PHP to use it.
        $tmp = __DIR__ . '/data/tmp4wt';
        if (!is_dir($tmp)) {
        //    mkdir($tmp);
        }
        putenv('TMPDIR=' . $tmp);
    }

At least the warning "The server’s temporary folder cannot be accessed..." at Control Panel disappeared.
Thank you Jens & Greg.
Josef

local desktop:-- webtrees 1.7.14, PHP version 7.2.19, MySQL 5.7.25, Apache2 2.4.29, Linux Ubuntu 18.04 64bit
webhosting:-- webtrees 1.7.14, PHP version 7.2.19, MySQL 5.7.21
testing webtrees 2.0.0-beta.3
Dernière édition: il y a 3 mois 6 jours par jprause. Raison: typo
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 6 jours #17

  • jprause
  • Portrait de jprause
  • Hors Ligne
  • Junior
  • Messages : 132
Now as to my previous post:
Though as I said the mentioned system warning disappeared from Control Panel, but now all media are seen as red coloured box with 500 in it.
The website error log shows

"error Cannot create thumbnail tempnam(): file created in the system's temporary directory".

Any idea please?
Josef

local desktop:-- webtrees 1.7.14, PHP version 7.2.19, MySQL 5.7.25, Apache2 2.4.29, Linux Ubuntu 18.04 64bit
webhosting:-- webtrees 1.7.14, PHP version 7.2.19, MySQL 5.7.21
testing webtrees 2.0.0-beta.3
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 6 jours #18

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
JPS écrit:
Thanks so far, I will check this with my hoster and come back.

So, this is, what my hoster says...

Please note that you only have the choice of 2 directories where you can apply open_basedir. These can be adjusted in your webhosting control panel under the -> PHP settings of the affected domain.

Please check the settings stored there and then try again.

What I can chose is this...




DOCROOT is my webtrees folder, WEBSPACEROOT my standard folder (root/httpdocs), which is unused...




I checked several setups with own temp-folders in the httpdocs-folder and the webtrees-folder. I also tryed to use the httpdocs-folder and the webtrees-folder without subfolders and again to use the root/tmp.

All setups show the same behavior als schown above.

Here are the other php-setup patameters...






Any further idea?
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 6 jours #19

  • JPS
  • Portrait de JPS
  • Hors Ligne
  • New
  • Messages : 12
jprause écrit:
but now all media are seen as red coloured box with 500 in it.
The website error log shows

"error Cannot create thumbnail tempnam(): file created in the system's temporary directory".

I think your problem has a similar cause as my problem..
L'administrateur a désactivé l'accès en écriture pour le public.

[SOLVED] 2.0.0-beta.3 - Server Warning il y a 3 mois 5 jours #20

  • jprause
  • Portrait de jprause
  • Hors Ligne
  • Junior
  • Messages : 132
File app/Services/ServerCheckService.php
private function checkSystemTemporaryFolder(): string {

sys_get_temp_dir() = "/tmp"
open_basedir contains "/tmp/" among others

The following hotfix solves the issue:
private function checkSystemTemporaryFolder(): string
    {
        $open_basedir  = ini_get('open_basedir');
        $open_basedirs = explode(PATH_SEPARATOR, $open_basedir);
        $sys_temp_dir  = sys_get_temp_dir()."/";       // <------------------jprause/ONEbit hotfix
 
        if ($open_basedir === '' || Str::startsWith($sys_temp_dir, $open_basedirs)) {
            return '';
        }
 
        $message = I18N::translate('The server’s temporary folder cannot be accessed.');
        $message .= '<br>sys_get_temp_dir() = "' . e($sys_temp_dir) . '"';
        $message .= '<br>ini_get("open_basedir") = "' . e($open_basedir) . '"';
 
        return $message;
    }

Greg, can you comment?
Thanks, Josef
Josef

local desktop:-- webtrees 1.7.14, PHP version 7.2.19, MySQL 5.7.25, Apache2 2.4.29, Linux Ubuntu 18.04 64bit
webhosting:-- webtrees 1.7.14, PHP version 7.2.19, MySQL 5.7.21
testing webtrees 2.0.0-beta.3
L'administrateur a désactivé l'accès en écriture pour le public.
Propulsé par Kunena