[squid-users] Can't store log in mysql 8.0 database (Amos Jeffries)

Francisco frizquierdo87 at gmail.com
Sat Mar 4 14:04:32 UTC 2023


Ohh, thanks!!!! libdbd-mysql-perl was not installed.
Work like a charm!!!

El sáb., 4 de mar. de 2023 7:43 a.m., <
squid-users-request at lists.squid-cache.org> escribió:

> Send squid-users mailing list submissions to
>         squid-users at lists.squid-cache.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
>         http://lists.squid-cache.org/listinfo/squid-users
> or, via email, send a message with subject or body 'help' to
>         squid-users-request at lists.squid-cache.org
>
> You can reach the person managing the list at
>         squid-users-owner at lists.squid-cache.org
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of squid-users digest..."
>
>
> Today's Topics:
>
>    1. Re: Missing translation directories und 'errors' in squid 5.8
>       (Amos Jeffries)
>    2. Re: Missing translation directories und 'errors' in squid 5.8
>       (Amos Jeffries)
>    3. Re: Can't store log in mysql 8.0 database (Amos Jeffries)
>    4. Re: Missing translation directories und 'errors' in squid 5.8
>       (Matthias Fischer)
>    5. Re: Understanding maximum outgoing HTTP CONNECT requests?
>       (divan.whelk.0u at icloud.com)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Sun, 5 Mar 2023 01:15:48 +1300
> From: Amos Jeffries <squid3 at treenet.co.nz>
> To: squid-users at lists.squid-cache.org
> Subject: Re: [squid-users] Missing translation directories und
>         'errors' in squid 5.8
> Message-ID: <c84158f3-159d-6fe8-d947-9aea9f63ebd8 at treenet.co.nz>
> Content-Type: text/plain; charset=UTF-8; format=flowed
>
>
> FYI, The missing files from 5.8 can be downloaded from here as a
> stand-alone package:
>  ? <http://www.squid-cache.org/Versions/langpack/>
>
> Cheers
> Amos
>
> On 3/03/2023 7:22 pm, Avram-Teodor Berindeie wrote:
> > A solution if the error messages in English are OK is to set this
> > directive in squid.conf:
> > error_directory /<path to>/squid/share/errors/templates
> > For error messages in other languages, information in this link
> > <https://wiki.squid-cache.org/Translations>.
> > This configuration options can also be used:
> > *--enable*/disable*-translation*
> > By default, Squid tries to present error and manual pages in a local
> > language. If we don't want this to happen, then we can use this option.
> > *--enable*/disable*-auto-locale*
> > Based on a client's request headers, Squid tries to automatically
> > provide localized error pages. We can use this option to disable
> > automatic localization. The error_directory tag in the Squid
> > configuration file must be configured if we use this option.
> >
> >
> > _______________________________________________
> > squid-users mailing list
> > squid-users at lists.squid-cache.org
> > http://lists.squid-cache.org/listinfo/squid-users
>
>
>
> ------------------------------
>
> Message: 2
> Date: Sun, 5 Mar 2023 01:16:08 +1300
> From: Amos Jeffries <squid3 at treenet.co.nz>
> To: squid-users at lists.squid-cache.org
> Subject: Re: [squid-users] Missing translation directories und
>         'errors' in squid 5.8
> Message-ID: <3e134177-1ed1-431e-bfc0-fe2ba1d8b52d at treenet.co.nz>
> Content-Type: text/plain; charset=UTF-8; format=flowed
>
> Ouch, sorry about that.
>
>
> FYI, The missing files from 5.8 can be downloaded from here as a
> stand-alone package:
>  ? <http://www.squid-cache.org/Versions/langpack/>
>
> Cheers
> Amos
>
>
> On 3/03/2023 6:40 am, Matthias Fischer wrote:
> > Hello,
> >
> > I'm a bit puzzled - sorry if I just overlooked something, but...:
> >
> > Since 'squid 5.8' there are no "translation directories" in the source
> > code anymore, only 'templates' and the usual scripts.
> >
> > No 'errors/af', 'errors/ar', 'errors/az' containing
> > '\squid-5.8\errors\af\ERR_ACCESS_DENIED' (e.g.).
> >
> > The TRANSLATORS are still listed but none of their files...
> >
> > Did I miss something?
> >
> > Regards,
> >
> > Matthias
> > _______________________________________________
> > squid-users mailing list
> > squid-users at lists.squid-cache.org
> > http://lists.squid-cache.org/listinfo/squid-users
>
>
>
> ------------------------------
>
> Message: 3
> Date: Sun, 5 Mar 2023 01:23:54 +1300
> From: Amos Jeffries <squid3 at treenet.co.nz>
> To: squid-users at lists.squid-cache.org
> Subject: Re: [squid-users] Can't store log in mysql 8.0 database
> Message-ID: <3a1726b6-4ca7-bf33-bedc-fe32e3a9420e at treenet.co.nz>
> Content-Type: text/plain; charset=UTF-8; format=flowed
>
> On 4/03/2023 8:22 am, Francisco wrote:
> > Hi, I\m trying to store logs in a mysql server 8.0 database from squid
> > 5.7 in Debian 11.
> >
> > My idea is store all logs in /var/log/squid/ dir, and logs from
> > specifics urls, domains and sites store in mysql database
> > ('access_log_internet' table) to restrict those users that overcuote
> > an specific amount of MB.
> >
> >
> > *The config:*
> > /access_log /var/log/squid/nav_basica-access.log squid dominios/
> > /access_log /var/log/squid/nav_basica-access.log squid dominios_parciales
> > /
> > /access_log /var/log/squid/nav_basica-access.log squid sitios
> > /
> > /access_log /var/log/squid/nav_basica-access.log squid dominio_cu/
> > /access_log /var/log/squid/internet-access.log squid !dominios
> > !dominios_parciales !sitios !dominio_cu/
> >
> > /logfile_daemon /usr/lib/squid/log_db_daemon/
> > /access_log
> > daemon:/
> 192.168.56.2:3306/squidmgr/access_log_internet/squidmgr/squidmgrsquid
> > <
> http://192.168.56.2:3306/squidmgr/access_log_internet/squidmgr/squidmgrsquid>
>
> > !dominios !dominios_parciales !sitios !dominio_cu/
> >
> > when try start squid, it's fail:
> >
> > /Dec 31 19:00:00 1969Use of uninitialized value $DBI::errstr in
> > concatenation (.) or string at /usr/lib/squid/log_db_daemon line 403.
> > Dec 31 19:00:00 1969Cannot connect to database: ?at
> > /usr/lib/squid/log_db_daemon line 403.
> > /
>
> What version of Perl do you have on this machine?
>
> Do you have both libdbd-mysql-perl and libdbi-perl packages installed?
>
>
> Cheers
> Amos
>
>
> ------------------------------
>
> Message: 4
> Date: Sat, 4 Mar 2023 13:34:23 +0100
> From: Matthias Fischer <matthias.fischer at ipfire.org>
> To: Amos Jeffries <squid3 at treenet.co.nz>,
>         squid-users at lists.squid-cache.org
> Subject: Re: [squid-users] Missing translation directories und
>         'errors' in squid 5.8
> Message-ID: <e903ea55-88eb-ee66-70d1-9220d9d90bac at ipfire.org>
> Content-Type: text/plain; charset=UTF-8
>
> Hello,
>
> On 04.03.2023 13:15, Amos Jeffries wrote:
> > FYI, The missing files from 5.8 can be downloaded from here as a
> > stand-alone package:
> >  ? <http://www.squid-cache.org/Versions/langpack/>
>
> Yep. In the meantime ( ;-) ) I've found them. I was just a bit puzzled,
> in 5.7 these files were still included in the source code.
>
> > Cheers
> > Amos
>
> Many thanks!
>
> Best,
> Matthias
>
>
>
> ------------------------------
>
> Message: 5
> Date: Sat, 4 Mar 2023 12:42:53 +0000
> From: divan.whelk.0u at icloud.com
> To: squid-users at lists.squid-cache.org
> Subject: Re: [squid-users] Understanding maximum outgoing HTTP CONNECT
>         requests?
> Message-ID: <9C815592-A998-4908-842A-A98412D6613F at kontos-home.com>
> Content-Type: text/plain; charset="utf-8"
>
>
> Thank you for the prompt reply!
>
> > - Squid can be configured to receive on up to 64 ports.
> >   Thus dst-port on **inbound** is 2^6.
>
> > outbound =  N * 2^6 * 2^128 * 2^16 = N * 2^150
>
> Would that be 2^6 dst-port on outbound, rather than inbound (ignoring
> Alt-Svc)? Or am misunderstand the theoretical limit formulae after?
>
> > Thus total theoretical limit of simultaneous connections Squid can be
> juggling is  N * 2^151.
>
> So, for example a single box HTTP CONNECT proxy might be listening on one
> IPv4 address and one IPv6 address, which would be making the outbound
> connections (and opening the TCP tunnel) and only able to make outbound
> connections to either port 80 or 443 (2^16 for each respective port,
> ignoring Alt-Svc).
>
> Whereas for incoming, listening on dst-port (3128) (2^16 incoming), with a
> theoretical limit of 2^32 IPv4 addresses or 2^128 IPv6 addresses (or do you
> use 2^128 including IPv4)?
>
> > Reality can be significantly different for any given installation, but
> is imposed by configuration choices and thus can be altered as needed.
>
> Understood, thanks! I think I?ve got a good idea now, with the
> clarifications.
>
> Alex
>
> > On 17 Feb 2023, at 20:18, Amos Jeffries <squid3 at treenet.co.nz> wrote:
> >
> > On 18/02/2023 12:14 am, divan.whelk.0u wrote:
> >> Hi there!
> >>
> >> I?m trying to understand what would the ?theoretical? maximum amount of
> outgoing connections with squid setup as a HTTP CONNECT forward proxy would
> be (hardware permitting)?
> >
> > As you likely know, each TCP/IP connection uses a 4-tuple identifier
> {src-IP, src-port, dst-IP, dst-port}.
> >
> > So at face value there is a protocol imposed cap of (2^128 * 2^16 *
> 2^128 * 2^16) = 2^288 connections.
> >
> > Being theoretical we have:
> >     * ignored reserved IP ranges,
> >     * ignored OS-specific ephemeral port reservations,
> >     * assumed IPv6 availability, and
> >     * assumed no access restrictions in Squid, network routing, nor
> firewall.
> >
> > The factors to consider are:
> >
> >  - Squid machine can be assigned multiple IP's.
> >     Thus src-IP on outbound and dst-IP on inbound are that N.
> >
> >  - Squid can be configured to receive on up to 64 ports.
> >    Thus dst-port on inbound is 2^6.
> >
> >  - DNS can provide any number of IPs for any given server name.
> >     Thus outbound dst-IP can be any 2^128 value.
> >
> >  - modern websites use use Alt-Svc to spread across ports.
> >     Thus outbound dst-port can be any 2^16 value.
> >
> > So for theoretical limit the math is:
> >
> >  inbound =    2^128 * 2^16 * N * 2^16  = N * 2^160
> >
> >  outbound =  N * 2^6 * 2^128 * 2^16 = N * 2^150
> >
> > Inbound and outbound are normally independent, but CONNECT is a special
> case where they are pinned 1:1.
> >
> > Thus total theoretical limit of simultaneous connections Squid can be
> juggling is  N * 2^151.
> >
> > Reality can be significantly different for any given installation, but
> is imposed by configuration choices and thus can be altered as needed.
> >
> >
> >> From the [squid-users] About bottlenecks (Max number of connections,
> etc.) thread, I saw mention of the following:
> >>
> >>> * The limit on number of connections any Squid can have attached is
> only limited by your configured FD limits and available server RAM. Squid
> uses ~64 KB per network socket for traffic state - which equates to around
> 2 GB of RAM just for I/O buffers at 20,000 concurrent client connections.
> >> I assume the same would not apply on outgoing connections, and that
> there would be a limit of 65,536 connections to a single IP, port pair? For
> example, if we had 1 million users making requests via HTTP CONNECT, only
> 65K of them would be able to access the same website at any one time?
> >
> > IIRC that quoted thread was discussing a Squid with more normal
> multiple-destination case hitting FD limits.  The 64K port limitation you
> refer to is a special case contingent on the "single destination with
> single IP:port" criteria - which itself is rarely true for a popular
> website. It assumes configuration restriction imposing that criteria
> somehow.
> >
> >
> > Cheers
> > Amos
> >
> > _______________________________________________
> > squid-users mailing list
> > squid-users at lists.squid-cache.org
> > http://lists.squid-cache.org/listinfo/squid-users
>
>
> ------------------------------
>
> Subject: Digest Footer
>
> _______________________________________________
> squid-users mailing list
> squid-users at lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
>
> ------------------------------
>
> End of squid-users Digest, Vol 103, Issue 6
> *******************************************
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squid-cache.org/pipermail/squid-users/attachments/20230304/2da5d5c4/attachment-0001.htm>


More information about the squid-users mailing list