Find duplicate executables files

by on May 16, 2006 · 3 comments· LAST UPDATED May 17, 2006

in

Sometime duplicate executable files or alias creates tons of confusion. To find out duplicated executables files you can use chkdupexe command.

It will scan the union of $PATH and a hardcoded list of common locations for binaries. It will report dangling symlinks and duplicately-named binaries.

Examples

$ chkdupexe

Output:

Dangling symlink: /usr/bin/rmic
Dangling symlink: /usr/bin/jar
-rwxr-xr-x 1 root root  38936 Sep 23  2004 /usr/bin/nsupdate
-rwxr-xr-x 1 root root 203960 Jan 26  2005 /usr/sbin/nsupdate
-rwxr-xr-x 1 root root  15139 Apr  6 01:48 /sbin/grub-install
-rwxr-xr-x 1 root root   6453 Apr  1 18:38 /usr/sbin/grub-install

As you see, it is quite easy to identify all those duplicates executables files. There is also some good discussion going on about PATH and aliases.

See also:

Updated for accuracy.



If you would like to be kept up to date with our posts, you can follow us on Twitter, Facebook, Google+, or even by subscribing to our RSS Feed.


{ 3 comments… read them below or add one }

1 stereonerd May 17, 2006 at 4:12 pm

Excuse me, does ‘hkdupexe’ command exist in GNU/Linux? I doesn’t seem to find it.

Thanks

Reply

2 stereonerd May 17, 2006 at 4:14 pm

oh, sorry for my poor english, I mean: I don’t seem to find it.

Regards

Reply

3 Vivek Gite May 17, 2006 at 6:07 pm

Command name is chkdupexe and not hkdupexe. It was typo :(

Sorry, and post is updated for accuracy.

Reply

Leave a Comment

You can use these HTML tags and attributes for your code and commands: <strong> <em> <ol> <li> <u> <ul> <blockquote> <pre> <a href="" title="">
What is 2 + 2 ?
Please leave these two fields as-is:
Solve the simple math so we know that you are a human and not a bot.

Previous post:

Next post: