Fopen(/tmp/ip_ses...): Failed to open stream: Permission denied

Hi, this error appear after config file ipconfig.php and first line with #
after error below i have image of /index.php/setup/language if you continue button only remain on he same page.

Am using cloudpanel with php 8.1

kind help please

A PHP Error was encountered

Severity: Warning

Message: fopen(/tmp/ip_sessionee8e2d6a81e33871246b31b6fa6971fbfvjcabncmpiafp6d3sngnet6i1nljg61): Failed to open stream: Permission denied

Filename: drivers/Session_files_driver.php

Line Number: 177

Backtrace:
(Unimportant, the error occurred in the session handler)

Don’t execute yet, just put it in your bookmarks. It has 2 solutions: php - Error Session File Driver in CodeIgniter 3 - Stack Overflow

In your InvoicePlane you’ll have a directory called 'application and within that directory with a name ‘config’.

Open config.php in that directory.

Look for:

$config['sess_driver'] = env('SESS_DRIVER', 'files');
$config['sess_table_name'] = env('SESS_DRIVER', 'ip_sessions');
$config['sess_cookie_name'] = env('SESS_DRIVER', 'ip_session');
$config['sess_expiration'] = env('SESS_EXPIRATION', 864000);
$config['sess_save_path'] = sys_get_temp_dir();
$config['sess_match_ip'] = env('SESS_MATCH_IP', true);
$config['sess_time_to_update'] = 300;
$config['sess_regenerate_destroy'] = FALSE;

The problem is this piece:
$config['sess_save_path'] = sys_get_temp_dir();

On your host it goes to /tmp/ and they don’t let you write files there

Try to change it to a different path

1 Like