Safari and iTunes will not update from App Store on OS X and are not updating properly

My issue was that the OS X App Store on my MacBook was showing Updates available for both iTunes and Safari. I would click UPDATE and they would download and then say installing. But after supposedly installing, the new version was not available. When I ran Safari or iTunes it was still the old version. And then within a short period of time, they would both appear in the App Store again as an available Update.

So not sure what is causing the issue, but for whatever reason the updates are not being installed properly. So after going thru the update process several times I finally decided to look for another solution.

I found another way to do updates is to use the command line in Terminal.

First you can type this to get a list of available downloads (NOTE: that is a dash then a lower case L which stands for list):

 softwareupdate -v -l

This may take awhile, but will eventually return a list (if any) of available updates. Mine came back with this:

 Finding available software
  Software Update found the following new or updated software:
   * iTunesX-12.3
   iTunes (12.3), 238528K [recommended]

Now to install any specific update from the list you can type:

softwareupdate -v -i iTunesX-12.3

Or to install all the updates you can type:

softwareupdate -v -i -a

With the method above I was succesful at getting Safari to upgrade, but iTunes was still giving me a really hard time, and would not upgrade. You can not just delete iTunes and re-install it either as it is a protected file. But we can delete it from Terminal if we need to and then try re-installing it.

To Delete iTunes, type this in Terminal:

cd /Applications/

Then type the following (and enter your admin password if it asks):

sudo rm -rf iTunes.app/

Once you have deleted it, use the softwareupdate command above and try it again!