On Mon, Jul 22, 2024 at 11:10 AM George at Clug <c...@goproject.info> wrote: > > On Monday, 22-07-2024 at 22:15 Henning Follmann wrote: > > > > > On Jul 22, 2024, at 08:08, cor...@free.fr wrote: > > > > > > I found that after I rebooted the system, the dir /var/run/*** > > > disappeared. > > > > Yes, > > /var/run > > is a symlink to /run > > And /run is a tmpfs > > > > > I put my app's web sessions under /var/run. so they got lost. > > > > Well that was a bad idea if you wanted to have persistent session ids. > > Would it be appropriate to use the /opt directory?
For my Apache LAMP installation, I use /var/lib/php/tmp for temporary files (like uploads) and /var/lib/php/sessions for session data. Then I set this in php.ini: `open_basedir="/var/www/html/:/var/lib/php/"`. > https://eitca.org/cybersecurity/eitc-is-lsa-linux-system-administration/linux-filesystem/filesystem-layout-continued/examination-review-filesystem-layout-continued/what-is-the-significance-of-the-opt-directory-in-the-linux-filesystem-layout/ You should read the Filesystem Hierarchy Standard, <https://refspecs.linuxfoundation.org/FHS_3.0/fhs-3.0.pdf>. > To summarize, the "/opt" directory holds significant importance in the Linux > filesystem layout. It provides a designated location for optional software > installations, separating them from the core operating system components. > This separation enhances system management, security, and integrity. > > https://linuxhandbook.com/linux-directory-structure/ > /opt – Optional software > Traditionally, the /opt directory is used for installing/storing the files of > third-party applications that are not available from the distribution’s > repository. > The normal practice is to keep the software code in opt and then link the > binary file in the /bin directory so that all the users can run it. Jeff