Re: [Nix-dev] Redirect SDDM/LightDM (X.0.log & .xsession-errors) to JournalCTL

2016-01-28 Thread Roger Qiu
GDM apparently does this: 
http://worldofgnome.org/in-gnome-3-12-systemd-will-track-xorg-logs/

But I'm not familiar with the source code.

On 29/01/2016 6:07 AM, Tuomas Tynkkynen wrote:
> 2016-01-28 20:47 GMT+02:00 Vladimír Čunát :
>> On 01/28/2016 12:21 PM, Roger Qiu wrote:
>>> But any ideas on how to redirect X.0.log?
>> X has -logfile option which seems like it only accepts paths. It should
>> be possible to hack around that via a named pipe, though that's not a
>> very nice solution. But maybe someone else was doing this already?
>>
> Maybe passing `-logfile /dev/stderr` could work (placing the output to
> display-manager.service's journal category)?

-- 
Founder of Matrix AI
https://matrix.ai/
+61420925975

___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] Redirect SDDM/LightDM (X.0.log & .xsession-errors) to JournalCTL

2016-01-28 Thread Tuomas Tynkkynen
2016-01-28 20:47 GMT+02:00 Vladimír Čunát :
> On 01/28/2016 12:21 PM, Roger Qiu wrote:
>> But any ideas on how to redirect X.0.log?
>
> X has -logfile option which seems like it only accepts paths. It should
> be possible to hack around that via a named pipe, though that's not a
> very nice solution. But maybe someone else was doing this already?
>

Maybe passing `-logfile /dev/stderr` could work (placing the output to
display-manager.service's journal category)?
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] Redirect SDDM/LightDM (X.0.log & .xsession-errors) to JournalCTL

2016-01-28 Thread Vladimír Čunát
On 01/28/2016 12:21 PM, Roger Qiu wrote:
> But any ideas on how to redirect X.0.log?

X has -logfile option which seems like it only accepts paths. It should
be possible to hack around that via a named pipe, though that's not a
very nice solution. But maybe someone else was doing this already?

--Vladimir




smime.p7s
Description: S/MIME Cryptographic Signature
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] Redirect SDDM/LightDM (X.0.log & .xsession-errors) to JournalCTL

2016-01-28 Thread Roger Qiu
I'll look into it and submit a PR.

But any ideas on how to redirect X.0.log?

On 28/01/2016 4:40 PM, Vladimír Čunát wrote:
> On 01/28/2016 06:29 AM, Roger Qiu wrote:
>> I see, do I need to fork nixpkgs to override that bash fragment?
> Why not create an option to also log to journalctl, perhaps even on by
> default?
>
> --Vladimir
>
>

-- 
Founder of Matrix AI
https://matrix.ai/
+61420925975

___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] Redirect SDDM/LightDM (X.0.log & .xsession-errors) to JournalCTL

2016-01-27 Thread Vladimír Čunát
On 01/28/2016 06:29 AM, Roger Qiu wrote:
> I see, do I need to fork nixpkgs to override that bash fragment?

Why not create an option to also log to journalctl, perhaps even on by
default?

--Vladimir




smime.p7s
Description: S/MIME Cryptographic Signature
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] Redirect SDDM/LightDM (X.0.log & .xsession-errors) to JournalCTL

2016-01-27 Thread Roger Qiu
I see, do I need to fork nixpkgs to override that bash fragment?

On 28/01/2016 4:26 PM, Vladimír Čunát wrote:
> On 01/28/2016 04:34 AM, Roger Qiu wrote:
>> Are you referring to the ~/.xsession-errors? This is a text file
>> containing the error logs of X applications, where would you place your
>> bash fragment?
> Somewhere here, I believe
> https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/services/x11/display-managers/default.nix#L50
>
> --Vladimir
>
>

-- 
Founder of Matrix AI
https://matrix.ai/
+61420925975

___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] Redirect SDDM/LightDM (X.0.log & .xsession-errors) to JournalCTL

2016-01-27 Thread Vladimír Čunát
On 01/28/2016 04:34 AM, Roger Qiu wrote:
> Are you referring to the ~/.xsession-errors? This is a text file
> containing the error logs of X applications, where would you place your
> bash fragment?

Somewhere here, I believe
https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/services/x11/display-managers/default.nix#L50

--Vladimir




smime.p7s
Description: S/MIME Cryptographic Signature
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] Redirect SDDM/LightDM (X.0.log & .xsession-errors) to JournalCTL

2016-01-27 Thread Roger Qiu
Are you referring to the ~/.xsession-errors? This is a text file 
containing the error logs of X applications, where would you place your 
bash fragment?


On 28/01/2016 7:23 AM, zimbatm wrote:
I don't know about X.0.log but since .xsession is just a bash script 
you could use something like:


|#!/usr/bin/env bash |
|exec &> | logger & |
|# the usual stuff |


On Tue, 26 Jan 2016 at 05:01 Roger Qiu > wrote:


Hi,

How does one redirect the logs (X.0.log) and (~/.xsession-errors) to
journalctl?

Apparently GDM
(http://worldofgnome.org/in-gnome-3-12-systemd-will-track-xorg-logs/)
now does this, but SDDM doesn't.

I would prefer to be able to centalise all logs into journalctl.

Thanks,
Roger

--
Founder of Matrix AI
https://matrix.ai/
+61420925975

___
nix-dev mailing list
nix-dev@lists.science.uu.nl 
http://lists.science.uu.nl/mailman/listinfo/nix-dev



--
Founder of Matrix AI
https://matrix.ai/
+61420925975

___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


Re: [Nix-dev] Redirect SDDM/LightDM (X.0.log & .xsession-errors) to JournalCTL

2016-01-27 Thread zimbatm
I don't know about X.0.log but since .xsession is just a bash script you
could use something like:

#!/usr/bin/env bash

exec &> | logger &

# the usual stuff



On Tue, 26 Jan 2016 at 05:01 Roger Qiu  wrote:

> Hi,
>
> How does one redirect the logs (X.0.log) and (~/.xsession-errors) to
> journalctl?
>
> Apparently GDM
> (http://worldofgnome.org/in-gnome-3-12-systemd-will-track-xorg-logs/)
> now does this, but SDDM doesn't.
>
> I would prefer to be able to centalise all logs into journalctl.
>
> Thanks,
> Roger
>
> --
> Founder of Matrix AI
> https://matrix.ai/
> +61420925975
>
> ___
> nix-dev mailing list
> nix-dev@lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>
___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev


[Nix-dev] Redirect SDDM/LightDM (X.0.log & .xsession-errors) to JournalCTL

2016-01-25 Thread Roger Qiu
Hi,

How does one redirect the logs (X.0.log) and (~/.xsession-errors) to 
journalctl?

Apparently GDM 
(http://worldofgnome.org/in-gnome-3-12-systemd-will-track-xorg-logs/) 
now does this, but SDDM doesn't.

I would prefer to be able to centalise all logs into journalctl.

Thanks,
Roger

-- 
Founder of Matrix AI
https://matrix.ai/
+61420925975

___
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev