Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I cant find out what the parent package of the file command is. Need it installed on a Centos 6 OS.



share|improve this question

migrated from stackoverflow.com Jun 12 '12 at 5:08

This question came from our site for professional and enthusiast programmers.

1 Answer 1

The following command should answer your question

 rpm -q --whatprovides `which file`

In RedHat and derived distributions the name of the package is file

 $ rpm -q --whatprovides `which file`

Edit As @Miquel reminds in Debian and Ubuntu one can use dpkg-query -S:

 $ dpkg-query -S `which file`
 file: /usr/bin/file
share|improve this answer
Replace rpm -q with dpkg -S in debian/ubuntu/derivates –  Miquel Jun 11 '12 at 14:11
@Miquel Thank you! –  Dmitri Chubarov Jun 11 '12 at 14:32

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.