"Terminal" opens on its own after starting my MBP

Discussion in 'Mac Basics and Help' started by Giantmike, Jun 7, 2009.

  1. Giantmike macrumors newbie

    Joined:
    Jan 4, 2009
    #1
    First of all, I'd like to apologize for my english...

    I have a problem since 2 weeks ago. Everytime I start my mac, a Terminal's window opens on its own, and the next sequence of commands starts to execute in themselves:

    Last login: Mon Jun 8 00:18:46 on console
    /System/Library/Frameworks/JavaVM.framework/Versions/A/Commands/java ; exit;
    MBP:~ miguelgonzalezherranz$ /System/Library/Frameworks/JavaVM.framework/Versions/A/Commands/java ; exit;
    Usage: java [-options] class [args...]
    (to execute a class)
    or java [-options] -jar jarfile [args...]
    (to execute a jar file)

    where options include:
    -d32 use a 32-bit data model if available
    -d64 use a 64-bit data model if available (implies -server, only for x86_64)
    -client to select the "client" VM
    -server to select the "server" VM
    -jvm is a synonym for the "client" VM [deprecated]
    -hotspot is a synonym for the "client" VM [deprecated]
    The default VM is client.

    -cp <class search path of directories and zip/jar files>
    -classpath <class search path of directories and zip/jar files>
    A : separated list of directories, JAR archives,
    and ZIP archives to search for class files.
    -D<name>=<value>
    set a system property
    -verbose[:class|gc|jni]
    enable verbose output
    -version print product version and exit
    -version:<value>
    require the specified version to run
    -showversion print product version and continue
    -jre-restrict-search | -jre-no-restrict-search
    include/exclude user private JREs in the version search
    -? -help print this help message
    -X print help on non-standard options
    -ea[:<packagename>...|:<classname>]
    -enableassertions[:<packagename>...|:<classname>]
    enable assertions
    -da[:<packagename>...|:<classname>]
    -disableassertions[:<packagename>...|:<classname>]
    disable assertions
    -esa | -enablesystemassertions
    enable system assertions
    -dsa | -disablesystemassertions
    disable system assertions
    -agentlib:<libname>[=<options>]
    load native agent library <libname>, e.g. -agentlib:hprof
    see also, -agentlib:jdwp=help and -agentlib:hprof=help
    -agentpath:<pathname>[=<options>]
    load native agent library by full pathname
    -javaagent:<jarpath>[=<options>]
    load Java programming language agent, see java.lang.instrument
    logout

    [Proceso completado]

    I've no idea of the cause of this problem, but i'm really scared about the possibility of being a virus, so I'd be very grateful if you give a hand with it.

    Thank you very much
     
  2. Jethryn Freyman macrumors 68020

    Jethryn Freyman

    Joined:
    Aug 9, 2007
    Location:
    Australia
    #2
    Go to System Preferences, Accounts, click your account, and go to Login Items. You'll probably find something in there.
     
  3. eleven7 macrumors regular

    Joined:
    Mar 14, 2009
    Location:
    Japan
    #3
    Don't think it's a virus so wouldn't worry too much about that.

    Did you install anything around the same time that it started to occur? Something that uses java?

    And is the terminal opening up or the console??

    Do what Jethryn suggested and check your login items, disable all login items and check if you get the same result. If you don't, enable each login application one by one and restart until the problem come back. Then you should find your problem app.
     
  4. sammich macrumors 601

    sammich

    Joined:
    Sep 26, 2006
    Location:
    Sarcasmville.
    #4
    You probably accidentally right-clicked on an application in the dock and selected "Open at Login" for what looks like a java based program.

    So yes, go to System Preferences -> Accounts -> Login Items; for your user.
     
  5. Giantmike thread starter macrumors newbie

    Joined:
    Jan 4, 2009
    #5
    Thank you very much for your answers. I really appreciate them.

    For Jethryn Freyman: exactly, i went where you told me, and you were right, there is "Unix Executable File" called Java, If I click on it, a Terminal window opens up and starts to execute the "famous" script.

    So the file is found. The problem is that i don't know if I have just to disable it or I have to delete it? What do you think, because apparently it's a script that does not work?

    For eleven7, maybe you're right about the origin of the problem. Recently, I have installed these applications:

    1Password
    Adobre Lightroom 2
    Aperture 2.1.3
    AppCleaner
    Coolris
    Diskaid
    iSerial Reader
    JDownloader
    Little Snitch
    MP3 Alarm Clock
    MPFreaker
    Paintbrush
    Toast 10 Titanium
    Transmission
    XTorrent

    ... so perhaps the problem is there. Actually, I remember that when installing one of them, I read somewhere a message saying: "You should have installed "Something" java", I don't remember neither the "something" nor the application in which the message opened up.

    It's a Terminal window.

    I don't understand what do you mean by this: "Do what Jethryn suggested and check your login items, disable all login items and check if you get the same result. If you don't, enable each login application one by one and restart until the problem come back. Then you should find your problem app."

    I reiterate you my gratitude
     
  6. wrldwzrd89 macrumors G5

    wrldwzrd89

    Joined:
    Jun 6, 2003
    Location:
    Solon, OH
    #6
    All the Login Items have checkboxes by them. You can find the list of Login Items in System Preferences -> Accounts. Uncheck them all, log out and back in, and see if the problem recurs. If it doesn't, check a few and repeat the process until the problem comes back. Then, uncheck them 1 by 1 from the group you checked most recently until the problem goes away. That last one you unchecked is your problem entry.
     
  7. sammich macrumors 601

    sammich

    Joined:
    Sep 26, 2006
    Location:
    Sarcasmville.
  8. Giantmike thread starter macrumors newbie

    Joined:
    Jan 4, 2009
    #8
    How can I uncheck/disable a login item? I have a box just on the left of each of them, but this is just for hiding it, not for disabling it.

    The other option is to delete it, but afterwards, I think I won't be able to re-add it, owing to the fact that this is a java file, and we can't access there.

    Maybe the "hiding" checkbox means just to disable... I don't know...
     
  9. sammich macrumors 601

    sammich

    Joined:
    Sep 26, 2006
    Location:
    Sarcasmville.
    #9
    Some of the apps in that list you're better off leaving alone, things like System Events. But things you downloaded that are 3rd party, can be removed without a problem. If you want to add anything back into that list just click the '+' and select it, or right click on the dock icon. If JDownloader is indeed in your login items list, you can remove it safely. Frankly, I don't see why it's even in there to begin with.

    All I have in there is GeekTool and iTunes.
     
  10. Giantmike thread starter macrumors newbie

    Joined:
    Jan 4, 2009
    #10
    As I said in my last post, in System Preferences -> Accounts -> Login Items, I have an "Unix Executable File" called Java, that when I click on, it opens a Terminal window and starts to execute the "famous" script.

    Do I have to delete it from the Login Items? If I do it, could I re-add it later?
     
  11. wrldwzrd89 macrumors G5

    wrldwzrd89

    Joined:
    Jun 6, 2003
    Location:
    Solon, OH
    #11
    You should delete it. Why would you want to re-add it? It's broken.

    That said, you might want to do some digging before you remove it, to find which application on your system may have put it there. Spotlight is enormously useful for this task.
     
  12. sammich macrumors 601

    sammich

    Joined:
    Sep 26, 2006
    Location:
    Sarcasmville.
    #12
    Oh, in that case, it's perfectly fine to get rid of it. I wouldn't imagine it does anything either.

    If you want to know what it is, right click on it, click reveal in Finder. Remember where it is, and then remove it from the login items
     
  13. wrldwzrd89 macrumors G5

    wrldwzrd89

    Joined:
    Jun 6, 2003
    Location:
    Solon, OH
    #13
    Ooh, didn't know you could do that Reveal in Finder trick. Thanks, I'm sure that'll come in handy for troubleshooting problems like this.

    That said, I second sammich's advice. If you need to, copy the path into a TextEdit document. One way to do this is to open the Terminal once you've revealed the item, drag it to the Terminal window and drop it (which will display its full path). Copy this path and paste it into TextEdit.
     
  14. Giantmike thread starter macrumors newbie

    Joined:
    Jan 4, 2009
    #14
    Could you explain to me how to find the "origin application" using spotlight or any other method you know?

    Thank you
     
  15. Giantmike thread starter macrumors newbie

    Joined:
    Jan 4, 2009
    #15
    The exact path is: /System/Library/Frameworks/JavaVM.framework/Versions/A/Commands/java

    What do you recommend me? To delete it from the hard disk, to delete it from "login items" or both?

    If I delete it from "login items", how could I manage to add it in the "login items" again? I mean, owing the path, it's impossible to access directly there, isn't it?

    Thank's a lot again
     
  16. wrldwzrd89 macrumors G5

    wrldwzrd89

    Joined:
    Jun 6, 2003
    Location:
    Solon, OH
    #16
    Do NOT delete that file from the hard disk. That will only make things worse. It's perfectly safe to remove the login item though.
     

Share This Page