Scofield Peng 发布的文章

任意一个即可,有钱了还是支持正版吧,开发不易~~~

5355-8639-1594-7229-2052
1049-9124-2397-1049-9348
5879-1361-3993-7957-2280
5632-5511-4451-4377-0570
2996-5429-2757-5021-3876
5585-9274-2947-1819-0912
1764-5459-4214-5301-3306
5535-8164-3057-6117-2109
3552-5593-2519-7145-0399
5915-4695-8052-7362-5757
4765-1931-5954-8501-2223
9365-5935-8651-7052-8664

先获取到该进程号,然后执行:

ls -l /proc/xxx/fd

xxx为具体的进程号,输出例入下:

total 0
lr-x------ 1 namer namer 64 Jul 14 21:41 0 -> pipe:[271495439]
l-wx------ 1 namer namer 64 Jul 14 21:41 1 -> pipe:[271495440]
lr-x------ 1 namer namer 64 Jul 14 21:41 10 -> anon_inode:inotify
lrwx------ 1 namer namer 64 Jul 18 07:00 11 -> socket:[274231623]
l-wx------ 1 namer namer 64 Jul 16 17:27 12 -> /workspace/door-god/log/2017-07-18.log
l-wx------ 1 namer namer 64 Jul 17 23:05 13 -> /workspace/door-god/log/2017-07-18.log
lrwx------ 1 namer namer 64 Jul 18 11:30 14 -> socket:[274230820]
lrwx------ 1 namer namer 64 Jul 18 15:16 15 -> socket:[274234729]
lr-x------ 1 namer namer 64 Jul 16 07:36 16 -> /dev/urandom
l-wx------ 1 namer namer 64 Jul 14 21:41 2 -> pipe:[271495441]
lrwx------ 1 namer namer 64 Jul 14 21:41 3 -> socket:[274235127]
lrwx------ 1 namer namer 64 Jul 14 21:41 4 -> socket:[271495456]
lr-x------ 1 namer namer 64 Jul 14 21:41 5 -> anon_inode:inotify
lr-x------ 1 namer namer 64 Jul 14 21:41 7 -> anon_inode:inotify
lrwx------ 1 namer namer 64 Jul 14 21:41 8 -> anon_inode:[eventpoll]
lrwx------ 1 namer namer 64 Jul 14 21:41 9 -> socket:[271495458]

则为打开的文件数量,如果要快速获取文件数量,则可以:

ls -l /proc/xxx/fd|wc -l

Windows

All the files are located under this directory by default:

Windows Vista, 7, 8, 10:

<SYSTEM DRIVE>\Users\<USER ACCOUNT NAME>\.<PRODUCT><VERSION>

Windows XP:

<SYSTEM DRIVE>\Documents and Settings\<USER ACCOUNT NAME>\.<PRODUCT><VERSION>

Sample paths for different products

Under this directory you'll find the following sub-directories

config: configuration (idea.config.path)

configplugins: plugins (idea.plugins.path)

system: caches, local history, etc (idea.system.path)

systemlog: logs and thread dumps (idea.log.path)

You can find more details about what is stored in each folder in the Project and IDE Settings documentation section.

Linux and other Unix systems

Product directory starting with dot can be found in your user home directory, the pattern is:

 ~/.<PRODUCT><VERSION>

~ is an alias for the home directory, for example /home/john.

Mac OS X

Configuration (idea.config.path):

~/Library/Preferences/<PRODUCT><VERSION>

Caches (idea.system.path):

~/Library/Caches/<PRODUCT><VERSION>

Plugins (idea.plugins.path):

~/Library/Application Support/<PRODUCT><VERSION>

Logs (idea.log.path):

~/Library/Logs/<PRODUCT><VERSION>