🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: alt.privacy.anon-server
Article #302287

Re: What are these journals in var/log

#302287
From: Carlos E.R.
Date: Tue, 05 Feb 2019 22:23
105 lines
4969 bytes
On 05/02/2019 16.47, Bit Twister wrote:
> On Tue, 5 Feb 2019 15:43:25 +0100, Carlos E.R. wrote:
>> On 05/02/2019 14.06, Bit Twister wrote:
>>> On Tue, 5 Feb 2019 12:48:16 +0100, Carlos E.R. wrote:
>>>
>>>> I say it is inefficient because on the machines where I keep both
>>>> journal and syslog files, the later are much smaller, and keep a longer
>>>> period of time.
>>>>
>>>> I say it is inefficient because trying to dump the logs to text to
>>>> search for something takes hours on rotating rust. It is fast on SSD.
>>>
>>> Well size of journal has an impact on your process.
>>> Personally I have never dumped the log to text for searching.
>>>
>>> I just hit up arrow and add to previous grep of journalctl.
>>
>> A plain "journalctl" command dumps the journal to text. Look:
>>
>> cer       4553  0.0  0.1  21524 10736 pts/19   Ss   13:55   0:00              |   \_ bash
>> cer       9062  0.0  0.0  74500  5828 pts/19   S+   15:02   0:00              |   |   \_ journalctl
>> cer       9063  0.0  0.0   7092  2212 pts/19   S+   15:02   0:00              |   |       \_ less
>>
> 
> 
> I would like to see results from the following command:
>   type journalctl

Telcontar:~ # type journalctl
journalctl is hashed (/usr/bin/journalctl)
Telcontar:~ #

Tried two computers.

Isengard:~ # rpm -qf /usr/bin/journalctl
systemd-234-lp150.20.9.1.x86_64
Isengard:~ #

> 
>>
>> I hit "end" to see the current entries, and it takes over two minutes.
> 
> Well that plain sucks. Running on spinning rust.

It was on SSD.

> Currently running
> beta2 Mageia Release 7 and after numerous updates this morning
> I deleted all logs. rotated journal and rebooted. Let's see stats
> on dumping about 4 hours of logging.
> 
> $ time journalctl > a
> 
> real    0m0.028s
> user    0m0.025s
> sys     0m0.003s
> 
> 
> $ wc -l < a
> 2498

Ah, but that's cheating. I keep months of journals. And years of syslogs
(because I can).

>> In syslog, I simply rotate the news logs after a few days, but in the journal I can't.
> 
> I do it every time I reboot the system and want new logs.
> 
> Suggestion:    journalctl --help | grep -i rotate

No, that's not it. By far.

I refer to the ability of a good syslog implementation to, for instance,
delete daily the nntp logs older than a week, while keep mail log for
three years. For example.

Or, delete the nntp debug logs older than a week, while keeping the
information logs for 3 months, and keeping the warning logs for three years.

Journal can do nothing of that, intentionally. They claim that
everything that happens in the computer is important, everything has to
be kept. They have a point, it is possible that a failure in some email
not sent was because a disk error.


>>> I do plan to look in how I can reduce the noise from sensord.
>>> I want to tell it to quit logging INFO messages.
>>
>> Impossible in journal. It is all or nothing. No filtering whatsoever. We looked.
> 
> Yep, I spent a few minutes looking in the past. What I decided at the
> time was to look into /etc/syslog.conf to see how/if I can manager it
> at the application level.

Yes, you can limit the data logged at the application level, if its
configuration allows, or if you edit the sources. But once the
application sends a log entry, the journal keeps it. But on syslog, you
can adjust how much you keep in very fine detail. That's a big difference.

With syslog you can, for instance, separate the sensor data to a
separate file and keep that for years.


-- 
Cheers, Carlos.
Technical Details
Message-ID: <ivepif-ec8.ln1@Telcontar.valinor>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!apf1.newsdeef.eu!not-for-mail
References: <q38sor$vac$1@news.neodome.i2p> <q39det$qlk$1@news.mixmin.net> <33slif-n5n.ln1@Telcontar.valinor> <q39s84$uf9$4@dont-email.me> <0p9oif-8mj.ln1@Telcontar.valinor> <slrnq5j2hr.hcg.BitTwister@wb.home.test> <d1koif-9cb.ln1@Telcontar.valinor> <slrnq5jbvo.veu.BitTwister@wb.home.test>

Show Full Headers
Complete Article Headers
Message-ID: <ivepif-ec8.ln1@Telcontar.valinor>
Subject: Re: What are these journals in var/log
Date: Tue, 5 Feb 2019 23:23:14 +0100
From: "Carlos E.R." <robin_listas@es.invalid>
References: <q38sor$vac$1@news.neodome.i2p> <q39det$qlk$1@news.mixmin.net> <33slif-n5n.ln1@Telcontar.valinor> <q39s84$uf9$4@dont-email.me> <0p9oif-8mj.ln1@Telcontar.valinor> <slrnq5j2hr.hcg.BitTwister@wb.home.test> <d1koif-9cb.ln1@Telcontar.valinor> <slrnq5jbvo.veu.BitTwister@wb.home.test>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!i2pn2.pugleaf.net!archive.newsdeef.eu!apf1.newsdeef.eu!not-for-mail
X-Received: by 2002:a1c:dc82:: with SMTP id t124mr65199wmg.0.1549405446717; Tue, 05 Feb 2019 14:24:06 -0800 (PST)
Newsgroups: alt.privacy.anon-server,alt.os.linux,comp.os.linux.misc
Lines: 105
Mime-Version: 1.0
X-Trace: individual.net 5QX+3nuNe8BBwdd1XHps8QLiRz2J4joGynnnbieYJps9GK2CUG
X-Orig-Path: Telcontar.valinor!not-for-mail
Cancel-Lock: sha1:6f8TZa2y26LpDQpCFIwoy87ccuc=
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.3.0
In-Reply-To: <slrnq5jbvo.veu.BitTwister@wb.home.test>
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit
Content-Language: en-CA