Sponsored Content
Top Forums UNIX for Advanced & Expert Users Negative values for peer inodes in ss -x output Post 303046271 by Skrynesaver on Wednesday 29th of April 2020 07:45:11 AM
Old 04-29-2020
Negative values for peer inodes in ss -x output

Hi all,

Long time no see, love what you've done with the place, been a while and asked this in the wrong forum initially...

I'm wondering how to interpret negative values for local and peer inode values for Unix sockets?

Code:
Netid  State      Recv-Q Send-Q Local Address:Port                 Peer Address:Port
...
u_str  ESTAB      0      0      /var/run/docker.sock -1847002447           * -1846996756

I can trace the local/peer relationship in the ss -xpan output for example...
grepping out known a negative inode id I get
Code:
# ss -xp | grep --  -1841560902
u_str  ESTAB      0      0      /var/run/docker.sock -1841556763           * -1841560902           users:(("dockerd",pid=29490,fd=276))
u_str  ESTAB      0      0      *                    -1841560902           * -1841556763           users:(("metricbeat",pid=5712,fd=94)

Then looking at the proc entry for the metricbeat process I get a non-negative inode for fd 94.
Code:
# ls -l /proc/5712/fd/
...
lrwx------ 1 root root 64 Apr 28 12:00 94 -> socket:[2453406394]

I'm curious as to the relationship (if any) between the "real" inode value and the negative value used for the inode in the ss output , what circumstances this value is used in (despite there being an inode for the symlink in /proc ) and general wisdom on the subject.

Thanks, Skrynesaver
 

8 More Discussions You Might Find Interesting

1. SCO

Help with negative inodes on sco 6

Hello. I just installed a SCO Openserver 6 box and it's suckin' mud. sar -v (see below) shows something that has me quite concerned... after time, it shows that the number of inodes being used as a negative value. When this happens, the server runs extremely slow until I reboot. The server... (0 Replies)
Discussion started by: debtman3535
0 Replies

2. IP Networking

Firewall stopping Peer to Peer File sharing

I am looking for advice on a router. I am new to Linux and am trying to use Limewire and Ktorent and can make no connection. Limewire indicates I have a firewall. I have a Linksys router WRK54G and my guess is that is the problem. I have spent hours upon hours trying to get it to work using info... (0 Replies)
Discussion started by: Paul K
0 Replies

3. Shell Programming and Scripting

Sorting positive and negative values

Hello, I have a list like this : 1 2 -4 0 -3 -7 5 6 etc. Is there a way to remove all the positive values and print only the negative values, without using grep, sed or awk? Thanks, Prasanna (4 Replies)
Discussion started by: prasanna1157
4 Replies

4. IP Networking

Problem with Static route through peer to peer connection

Hi, I am trying to add a static route in one of 3 server (S3) so that I can access the main application server (S1). But problem is, the server (S3) where I am trying to add static route is connected with another server (S2) which is in same private network of application server (S1). I have... (9 Replies)
Discussion started by: ImranBD
9 Replies

5. Shell Programming and Scripting

Awk+colpos+negative if for 20 values

Hi All, i have 20 Obligors when ever i dont find all of them on particular row/line from each in put i need to print it in different file. using below command but it is not working please help at earliest. Steps: set -A FILENAME $( cat... (10 Replies)
Discussion started by: rajubollas
10 Replies

6. Shell Programming and Scripting

Conavert negative values to Zeros

Can anyone please assist me? Please find the attached input and output file for ur reference. a)Incase if i get negative value (ex:-000100) in the 11th column then i have to convert the value to 0000000(7 zeros-length is 7) and then print the entire record. b)Incase if there is no... (2 Replies)
Discussion started by: vinus
2 Replies

7. Shell Programming and Scripting

How to sum the value with negative values?

Hi Gurus, I have requirement need to sum the value, the logic is if the value is negative then time -1, I tried below two ways. one is failed, another one doesn't work. awk -F"," '{if($8< 0 $8*-1 else $8) sum+=$8}{print sum, $8} END{printf("%.2f\n",sum)}' awk -F","... (4 Replies)
Discussion started by: ken6503
4 Replies

8. UNIX for Beginners Questions & Answers

Negative values for peer inodes in ss -x output

Hi all, Long time no see, love what you've done with the place! I'm wondering how to interpret negative values for local and peer inode values for Unix sockets? Netid State Recv-Q Send-Q Local Address:Port Peer Address:Port ... u_str ESTAB 0 0 ... (0 Replies)
Discussion started by: Skrynesaver
0 Replies
XFMTYPE(1)								XFM								XFMTYPE(1)

NAME
xfmtype - xfm file type tester SYNOPSIS
xfmtype -m magic_file [-f] filename ... DESCRIPTION
The xfmtype program reads a magic configuration file and tests each file in its command line to tell its type according to the configura- tion file. The format of the configuration file is the similar to magic(5) with the differences described in 0 OPTIONS
-f file Consider the following argument as a file, even if it begins with `-'. -m file Specifies a configuration file. You can specify more than one configuration file with several -m flags. They are read in the order in which they are found. Configuration files do not have effect until they are encountered in the command line. So, files to test in the command line before that switch will not be affected by it. BUILT IN TYPES
If no rule matches a specified field or the type cannot be determined because of other reasons, one of the following built in types is returned: inode/x-unreadable The file could not be read. inode/x-empty File size is zero. text/plain The file looks like ACSII. xfm will look into xfm_mime.type(5) for more guessing. application/octet-stream Other regular file. xfm will look into xfm_mime.type(5) for more guessing. inode/directory A directory. inode/chardevice A character device. inode/blockdevice A block device. inode/pipe A names pipe (fifo). inode/socket A socket. inode/default None of the above. BUGS
Bad configuration lines cause undefined behavior. In general they are silently ignored, but that is not guaranteed. There are no warning or error message except for the regular expression syntax. There should be a syntax checking mode. All of the above apply to xfm too. SEE ALSO
xfm(1), xfm_magic(5), file(1), magic(5). COPYRIGHT
Copyright (c) 1995 CNM-US Copyright (c) 1995 Juan D. Martin AUTHOR
Juan D. Martin (juando@cnm.us.es) (but modified heavily by Bernhard R. Link) xfm 20 April, 2006 XFMTYPE(1)
All times are GMT -4. The time now is 04:19 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy