3

How do I find out which (apt-get-installed) package a particular file came from?

Braiam
  • 67,791
  • 32
  • 179
  • 269
kjo
  • 1,187
  • 6
  • 23
  • 31

2 Answers2

5

Use dpkg -S, as in dpkg -S /path/to/file.

For sorting list in column, Follow:

dpkg -S /usr/share | tr " ," "\n" | sort 
Pandya
  • 35,771
  • 44
  • 128
  • 188
fkraiem
  • 12,555
  • 4
  • 35
  • 40
1

You can also find out the package path from the package name:

$dpkg -L <package name>

e.g.

$dpkg -L zip
Prakash V Holkar
  • 2,561
  • 7
  • 22
  • 29