How to find out mount/partition a directory or file is on? (Linux Server) [closed]

元气小坏坏 提交于 2019-11-27 04:56:51

问题


Is there a Linux command to easily find out which partition/mount a directory or file is on?

(This is probably a RTM question, and I feel guilty for asking it, but somehow, I can't find a good answer on google just yet..)


回答1:


df -P file/goes/here | tail -1 | cut -d' ' -f 1


来源:https://stackoverflow.com/questions/3274354/how-to-find-out-mount-partition-a-directory-or-file-is-on-linux-server

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!