Wie lösche ich eine Anwendung vollständig und verhindere dies?

568
Ivona

Mein Mac führt immer noch Prozesse aus einem Programm aus, das ich gelöscht habe. Wie lösche ich eine Anwendung vollständig und verhindere dies? Mein Mac führt immer noch Prozesse aus einem Programm aus, das ich gelöscht habe

4
Es ist nicht möglich, dass ein Betriebssystem einen Prozess ausführt, in dem die Datei tatsächlich nicht vorhanden ist. Diese Frage macht keinen Sinn. Ramhound vor 11 Jahren 0
@Ramhound Einige Anwendungen behalten ausführbare Dateien für Hilfsprozesse im Ordner Application Support. user495470 vor 11 Jahren 1
@ Ramhound Natürlich ist es das. Wenn Sie einen Prozess starten und die ausführbare Datei löschen, wird das Programm trotzdem ausgeführt. Bis Sie den Prozess stoppen oder neu starten, wird er weiter ausgeführt. Matteo vor 11 Jahren 0
@Matteo - Ihr Beispiel ist dumm, denn wenn der Prozess der ausführbaren Datei ausgeführt wird, können Sie die Datei selbst nicht löschen, da sie von einem Prozess verwendet würde. Ramhound vor 11 Jahren 0
@Ramhound You can delete the executable without any problem: `cp /usr/bin/yes . ; ./yes > /dev/null & ; rm yes`. File deleted, process still running. Matteo vor 11 Jahren 0

2 Antworten auf die Frage

1
Gary W. Longsine

There are several different ways that applications can be automatically started on Mac OS X. Some applications install some of their components, which may themselves be executable, in locations other than the main application folder. Tracking these down can be somewhat difficult if you don't know they exist, but once you do it's reasonably straightforward.

If the application doesn't have a built-in uninstall option, then you're left with tracking down the files and startup detritus. You can use the handy GUI application:

/Applications/Utilities/Activity Monitor

  • Launch the Activity Monitor, then select the process of interest;
  • click the blue (i) button to inspect it;
  • select the Open Files and Ports tab;
  • then click the "Sample" button to get a list of open files used by the process, which should show you its configuration and startup files, as well as the application executable itself, and potentially many other files).

    % lsof

If you prefer a UNIX command line, you can use the unix command lsof in a Terminal.app shell window. (Google lsof examples for details on lsof).

Other handy tips:

When you find the application configuration file, read it. This may have hints which will help you track down the non-typical locations of application components.

See if the application has a log file, and look in that log file or in the system log for hints about the location of startup configuration or files. Use the Console.app, or poke around in the directories and files with the unix command line. Most application logs will be in one of these places, on Mac OS X Mountain Lion.

  • ~/Library/Logs
  • /Library/Logs
  • /var/log

Knowing a little about the various startup methods can help you, too. Keywords to help in Google searches:

  • cron ("crontab -l" in a Terminal.app window, to show a user's crontab)
  • launchd ("launchctl list" in a Terminal.app window to show a list)
  • SystemStarter (deprecated, the binary is not present on Mountain Lion)

Some but probably not all locations where startup scripts or configuration files may be found:

  • /System/Library/LaunchAgents
  • /System/Library/LaunchDaemons
  • /Library/LaunchDaemons
  • /Library/LaunchAgents
  • ~/Library/LaunchAgents
  • /Library/StartupItems
  • /System/Library/StartupItems
  • ~/Library/StartupItems
0
jrc03c

Normalerweise verwende ich AppCleaner, um Mac-Anwendungen zu deinstallieren. Es ist ziemlich gut, sich alle Dateien anzueignen, die eine App benötigt. Möglicherweise müssen Sie nach einer Deinstallation einen Neustart durchführen, um die Auswirkungen zu sehen.

Wenn dies nicht funktioniert, können Sie immer den Aktivitätsmonitor (oder die Befehlszeile) verwenden, um den anstößigen Prozess rm -rf /usr/bin/offending_fileabzubrechen. Führen Sie dann eine kleine Aktion aus und starten Sie ihn dann neu. Leider ist diese Option nicht sehr elegant. Ich würde es nicht empfehlen, wenn Sie keine andere Methode haben, um den Schurkenprozess zu beenden.