[Feature Request] mention hostname on -v

0 views
Skip to first unread message

Philipp Marek

unread,
Sep 11, 2023, 5:50:38 AM9/11/23
to openssh-...@mindrot.org
I've got a usecase right now where I've got to use a few
intermediate ProxyJump hosts, and it would help debugging
via -v tremendously if the debug lines would have a prefix
of the originating host, so that they can be easily associated.


The FQDN might be too long, though -- perhaps just the PID
with an additional line associating it with the host would be
a better fit?


Thanks!
_______________________________________________
openssh-unix-dev mailing list
openssh-...@mindrot.org
https://lists.mindrot.org/mailman/listinfo/openssh-unix-dev

Damien Miller

unread,
Sep 11, 2023, 11:45:58 PM9/11/23
to Philipp Marek, openssh-...@mindrot.org
On Mon, 11 Sep 2023, Philipp Marek wrote:

> I've got a usecase right now where I've got to use a few
> intermediate ProxyJump hosts, and it would help debugging
> via -v tremendously if the debug lines would have a prefix
> of the originating host, so that they can be easily associated.
>
> The FQDN might be too long, though -- perhaps just the PID
> with an additional line associating it with the host would be
> a better fit?

it's a bit of a hack, but you can get PID in debug messages right now
using LogVerbose=*, though you'll probably need to set it in ssh_config
if you're using ProxyJump as options from the command-line are mostly
not passed to the subordinate ssh processes.

-d

Philipp Marek

unread,
Sep 12, 2023, 1:46:25 AM9/12/23
to Damien Miller, openssh-...@mindrot.org
>> I've got a usecase right now where I've got to use a few
>> intermediate ProxyJump hosts, and it would help debugging
>> via -v tremendously if the debug lines would have a prefix
>> of the originating host, so that they can be easily associated.
>>
>> The FQDN might be too long, though -- perhaps just the PID
>> with an additional line associating it with the host would be
>> a better fit?
>
> it's a bit of a hack, but you can get PID in debug messages right now
> using LogVerbose=*, though you'll probably need to set it in ssh_config
> if you're using ProxyJump as options from the command-line are mostly
> not passed to the subordinate ssh processes.

Thanks for the idea -- but that means having write access to sshd_config
and (potentially) disturbing all other users on the machines.


Well, how about the general idea of including the PID?
If it's at the end like [1234] it's okay as well,
highlighting strings in an editor is easy enough.

Martin Hecht

unread,
Sep 12, 2023, 8:48:41 AM9/12/23
to openssh-...@mindrot.org
Hi,

On 12/09/2023 07:43, Philipp Marek wrote:
>>> I've got a usecase right now where I've got to use a few
>>> intermediate ProxyJump hosts, and it would help debugging
>>> via -v tremendously if the debug lines would have a prefix
>>> of the originating host, so that they can be easily associated.
>>>
>>> The FQDN might be too long, though -- perhaps just the PID
>>> with an additional line associating it with the host would be
>>> a better fit?
>>
>> it's a bit of a hack, but you can get PID in debug messages right now
>> using LogVerbose=*, though you'll probably need to set it in ssh_config
>> if you're using ProxyJump as options from the command-line are mostly
>> not passed to the subordinate ssh processes.
>
> Thanks for the idea -- but that means having write access to sshd_config
> and (potentially) disturbing all other users on the machines.

Note that Damien wrote ssh_config[1], not sshd_config.
You can have a ~/.ssh/config to override system defaults.

Best regards, Martin

[1] https://man.openbsd.org/ssh_config#LogVerbose

Philipp Marek

unread,
Sep 12, 2023, 10:48:55 AM9/12/23
to Martin Hecht, openssh-...@mindrot.org
> Note that Damien wrote ssh_config[1], not sshd_config.
> You can have a ~/.ssh/config to override system defaults.

Ah yeah, right. Sorry, I misread.
Reply all
Reply to author
Forward
0 new messages