Bug 586742 - RFE: "w" should have "-n" flag to suppress reverse name resolution of IP addresses
Summary: RFE: "w" should have "-n" flag to suppress reverse name resolution of IP addr...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: procps
Version: 5.7
Hardware: All
OS: Linux
low
low
Target Milestone: rc
: ---
Assignee: Jaromír Cápík
QA Contact: Martin Kyral
URL:
Whiteboard:
Depends On:
Blocks: 1123311
TreeView+ depends on / blocked
 
Reported: 2010-04-28 09:49 UTC by David Tonhofer
Modified: 2016-02-01 01:54 UTC (History)
5 users (show)

Fixed In Version: procps-3.2.7-19
Doc Type: Enhancement
Doc Text:
Clone Of:
: 1123311 (view as bug list)
Environment:
Last Closed: 2013-01-08 07:31:41 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2013:0062 0 normal SHIPPED_LIVE procps bug fix and enhancement update 2013-01-07 15:27:39 UTC

Description David Tonhofer 2010-04-28 09:49:07 UTC
Description of problem:

Run "w". See:

[root@gendo log]# w
 11:44:19 up 91 days, 18:55,  1 user,  load average: 1.65, 2.56, 3.56
USER     TTY      FROM              LOGIN@   IDLE   JCPU   PCPU WHAT
root     pts/0    ip-88-207-241-12 11:17    0.00s  0.14s  0.12s -bash



It would be better if this was possible (with -n similar to the netstat option)

[root@gendo log]# w -n
 11:44:19 up 91 days, 18:55,  1 user,  load average: 1.65, 2.56, 3.56
USER     TTY      FROM              LOGIN@   IDLE   JCPU   PCPU WHAT
root     pts/0    88.207.241.129    11:17    0.00s  0.14s  0.12s -bash



Version-Release number of selected component (if applicable):

procps-3.2.7-11.1.el5


Additional info:

Should go upstream I guess. I might look into the code myself if I have some time (as if)

Comment 1 Jaromír Cápík 2011-06-14 10:42:03 UTC
Hello David.

I'm just trying to discuss this feature with upstream and if the guys have no objections, I'll implement this feature.

I'll let You know about important news related to this topic.

Thanks for reporting.

Regards,
Jaromir.

Comment 2 Jaromír Cápík 2012-04-04 16:42:08 UTC
Hello David.

Sorry for no response for long time.
I sent a patch several months ago, but it wasn't accepted by other procps-ng members in it's very first form. Let me explain what the main issue is. In fact there's no reverse name resolution in the 'w' command. The information is taken directly from the proc filesystem and often contains additional info like screen numbers. My patch just used a different field of the structure (containing the IP address only). In some cases there was no IP address at all (= 0.0.0.0) whilst the domain name was present and guys didn't like the information loss in such cases. I proposed a change, that a missing IP (= 0.0.0.0) could be replaced with domain name and if the IP is present, then the screen numbers could be taken from the original field and concatenated with the IP address. Unfortunately I got no response. I'll try to resurrect this topic once again, but I can't promise it's gonna be accepted.

Regards,
Jaromir.

Comment 3 David Tonhofer 2012-04-10 08:49:59 UTC
Hi Jaromir.

That sounds organically hairy. Thank you very much for the updates. Hopefully this goes through.

Best regards,
-- David

Comment 4 Jaromír Cápík 2012-05-22 16:44:03 UTC
Hello David.

I just reimplemented the feature based on the latest procps-ng upstream sources and sent the patch to other procps-ng members for a review. We'll se if this goes through or not. I'll let you know once I have any feedback.

Regards,
Jaromir.

Comment 5 David Tonhofer 2012-05-23 09:01:27 UTC
Thank you.

Comment 6 Jaromír Cápík 2012-05-29 13:59:01 UTC
Hello David.

The feature has been accepted and I'm going to backport the change into the legacy version.

Regards,
Jaromir.

Comment 7 David Tonhofer 2012-05-30 18:48:02 UTC
Great stuff. Thanks.

Comment 13 errata-xmlrpc 2013-01-08 07:31:41 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2013-0062.html


Note You need to log in before you can comment on or make changes to this bug.