How to exclude existent line in config file of squid?

Hey there guys,

I wanted to customize squid, so that the log’s timestamps are in more humand readable form. I therefore added two lines to “/var/ipfire/proxy/advanced/acls/include.acl”.

logformat simple bla bla bla
access_log stdio:/var/log/squid/access.log logformat=simple

With the first one, I defined my own logformat. With the second one, I told squid to use this logformat.

Worked pretty good. Only problem is, there already is the line

access_log stdio:/var/log/squid/access.log

in the squid.conf. Because of that, squid now prints every entry twice, one with the standard format the other one with my logformat.

How can I “delete” the first entry via the “include.acl” or maybe just add “logformat=simple” behind this entry and spare the second one?

Thanks in advance and have a nice evening.

Alex

Maybe you can disable the logging entirely from squid.conf by changing the Web User Interface. Then your directive in include.acl would be the only one present?

1 Like

Damn, why didn’t I think of that? :smiley:

Sounds like a pretty good idea, I will test this and see if it works.

Thanks a lot! :slight_smile:

1 Like

Mr. cfusco, consider you hugged! Works like a charm! :ok_hand:

Thanks again and have a nice one. :slight_smile:

3 Likes

Only for information:
It is possible to do those customisations, but you should document them very precisely.
The standard way in IPFire is ‘do configuration in the WUI, save generates the program configs’. An update may change this generation process, deleting user configs. Therefore you must check your modifications after each upgrade touching the specific program ( in your case squid ).

2 Likes