[squid-users] Howto make Squid config dependent on hostname?

Alex Rousskov rousskov at measurement-factory.com
Sat Sep 17 16:05:33 UTC 2022


On 9/17/22 05:37, Hildegard Meier wrote:
>> It is a poorly worded reference to "#line" directives used by some
>> programming languages for documenting the original location of lines in
>> preprocessed files. Here are the corresponding C++ preprocessor docs,
>> for example: https://en.cppreference.com/w/cpp/preprocessor/line
> 
> I guess it would be helpful to add this explanation to the doc.

Agreed.


>>> /usr/sbin/squid -k reconfigure -f '|/usr/local/script/squid/pre_process_squid_config_file.sh'
>>>
>>> gives the following line in /var/log/squid/cache.log
>>> FATAL: parseConfigFile: '|/usr/local/script/squid/pre_process_squid_config_file.sh' failed with exit code -1
>>> Squid Cache (Version 3.5.27): Terminated abnormally.
>>
>>  > is that a bug?

> I found out that has nothing to do with the -f
> "|pre_processing_script.sh" syntax, it happens with the standard -f
> "/etc/squid/squid.conf" syntax the same.

The "terminated abnormally" message is a generic message common to many 
fatal problems. However, the "FATAL: parseConfigFile: ... failed with 
exit code..." error is specific to the pipeline configuration syntax. I 
realize that you do not care about the latter anymore, but wanted to add 
this clarification in case somebody else does.

Glad you found a solution that works well for you.

Alex.


More information about the squid-users mailing list