Discussions
Categories
- 17.9K All Categories
- 3.4K Industry Applications
- 3.3K Intelligent Advisor
- 63 Insurance
- 535.7K On-Premises Infrastructure
- 138.1K Analytics Software
- 38.6K Application Development Software
- 5.6K Cloud Platform
- 109.3K Database Software
- 17.5K Enterprise Manager
- 8.8K Hardware
- 71K Infrastructure Software
- 105.2K Integration
- 41.5K Security Software
process open file

Hi,
I like to see the open files by sshd and i dont understand what files are open,what is
0: S_IFCHR mode:0666 dev:16381,0 ino:61865992 uid:0 gid:3 rdev:118,2
O_RDWR|O_LARGEFILE
/devices/pseudo/[email protected]:null
offset:0
ps -ef|grep ssh
root 460 1 0 13:13:03 ? 0:00 /usr/lib/ssh/sshd
root 1203 1195 0 13:17:14 pts/1 0:00 grep ssh
root 1191 460 1 13:16:09 ? 0:00 /usr/lib/ssh/sshd -R
[email protected]:~# pfiles 460
460: /usr/lib/ssh/sshd
Current rlimit: 256 file descriptors
0: S_IFCHR mode:0666 dev:16381,0 ino:61865992 uid:0 gid:3 rdev:118,2
O_RDWR|O_LARGEFILE
/devices/pseudo/[email protected]:null
offset:0
1: S_IFCHR mode:0666 dev:16381,0 ino:61865992 uid:0 gid:3 rdev:118,2
O_RDWR|O_LARGEFILE
/devices/pseudo/[email protected]:null
offset:0
2: S_IFCHR mode:0666 dev:16381,0 ino:61865992 uid:0 gid:3 rdev:118,2
O_RDWR|O_LARGEFILE
/devices/pseudo/[email protected]:null
offset:0
3: S_IFSOCK mode:0666 dev:16377,0 ino:27192 uid:0 gid:0 size:0
O_RDWR|O_NONBLOCK FD_CLOEXEC
sockname: AF_INET6 :: port: 22
SOCK_STREAM
SO_REUSEADDR,SO_ACCEPTCONN,SO_SNDBUF(49152),SO_RCVBUF(256000)
listen backlog: 128
congestion control: newreno
4: S_IFSOCK mode:0666 dev:16377,0 ino:5070 uid:0 gid:0 size:0
O_RDWR|O_NONBLOCK FD_CLOEXEC
sockname: AF_INET 0.0.0.0 port: 22
SOCK_STREAM
SO_REUSEADDR,SO_ACCEPTCONN,SO_SNDBUF(49152),SO_RCVBUF(256000)
listen backlog: 128
congestion control: newreno
then
ls -al /proc/460/fd
total 4
dr-x------ 2 root root 272 Jan 10 13:13 .
dr-xr-xr-x 7 root root 1088 Jan 10 13:13 ..
c--------- 1 root sys 118, 2 Jan 10 13:17 0
c--------- 1 root sys 118, 2 Jan 10 13:17 1
c--------- 1 root sys 118, 2 Jan 10 13:17 2
s--------- 0 root root 0 Jan 1 1970 3
s--------- 0 root root 0 Jan 1 1970 4
I like to see those files with their name.
Thank you
Answers
-
Hi.
What version of Solaris ?
Try:
ls -la /proc/<pid>/path
Regards,
Nik