0

If I do so, will something, such as a service, break?

2
  • It's safe provided you also remove any plist in Application Support and Preferences folders that reference /usr/bin/java. Commented Feb 16, 2013 at 1:29
  • 3
    Why would you need/want to remove it?
    – MattDMo
    Commented Feb 16, 2013 at 3:08

1 Answer 1

3

Mac App Store apps and OS X core applications and services don't depend on Java, but some 3rd party applications (like LibreOffice) do, and they will break if you delete /usr/bin/java.

Since /usr/bin/java is a symlink:

/usr/bin/java -> /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands/java

if you notice that an application complains about missing Java or fails to start after deleting /usr/bin/java simply recreate it like this:

  1. Open Applications>Utilities>Terminal

  2. Make the symlink (type your password if asked):

    $ sudo ln -s /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands/java /usr/bin/java
    
3
  • However removing just /usr/bin/java will not add to any form of security as many apps use the /System/.../java path
    – mmmmmm
    Commented Mar 7, 2013 at 14:21
  • It is still unclear why the OP wants to remove /usr/bin/java, but if it is security related and many apps use the /System/Library/... path as you say (could you provide some more information about that? is it an Apple recommendation?), then no, it won't increase security much.
    – jaume
    Commented Mar 8, 2013 at 17:26
  • FWIW it is not a symlink on 12.6
    – Pointy
    Commented Oct 12, 2022 at 19:09

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .