[squid-users] installing Squid: /run dir creation

Amos Jeffries squid3 at treenet.co.nz
Tue Jan 29 12:05:52 UTC 2019


On 29/01/19 11:56 pm, Vieri wrote:
> Hi,
> 
> My Linux distro warns me that when trying to install Squid an attempt is made to write to a "volatile" dir.
> 
> The Makefile in the src subdir contains:
> 
>     $(mkinstalldirs) $(DESTDIR)`dirname $(DEFAULT_PID_FILE)`
> 
> The default PID file being /run/squid.pid, the above tries to make the /run dir.
> 
> Is it necessary to keep this in the Makefile?
> 

Yes. The path is configurable with --with-pidfile=PATH, so it can be
absolutely anywhere.


> Shouldn't the /run/* files be created at runtime anyway?
> 
> The /run dir is also created by the OS.

The Squid default path for this file is $localstatedir/run/squid.pid as
specified by older versions of FHS. It is not clear whether your local
state dir is '/' or the above option is being used to place it exactly.
Normally these would expand to /var/run/squid.pid.

It would help to have a hint about what OS you are using and what
./configure parameters you used.


Please be aware that Makefile are auto-generated. Only a small portion
of their contents is anything we wrote and attempts at patching can be
erased midway through a build by the toolchain detecting files as out of
sync with the actual source.


Amos


More information about the squid-users mailing list