Previous 1 2 Next 17 Replies Latest reply: Apr 10, 2010 6:24 PM by -U!
-U! Level 1 (0 points)
Hi! Whenever I launch terminal,I can't type anything and it only shows this message:
*login: illegal option -- u*
*usage: login [-pq] [-h hostname] [username]*
*login -f [-lpq] [-h hostname] [username [prog [arg ...]]]*

*[Proceso completado]*
Already tried both dumping the Terminal preferences and reintalling the package with Pacifist and the Snow Leopard install DVD.Nothing have worked so far.
Any help please?

Thanks in advance.

Mac OS X (10.6.3)
  • ericmeyers Level 4 (1,410 points)
    Create a new user account and let us know if they problem is there as well.
  • -U! Level 1 (0 points)
    Okay,I've created the new user and Terminal does respond there.
    Still doesn't in the original user account.
  • ericmeyers Level 4 (1,410 points)
    OK. That's good.

    Did you happen to create a .bash_profile (or .profile) file in your home directory, or maybe something else did? If there is one rename it (or move it) temporarily than try to launch terminal.
  • -U! Level 1 (0 points)
    I don't remember creating any of those files (could've been created when installing Snow Leopard though) and anyway can't see them anywhere —at least both Finder and Transmit don't show them.
  • etresoft Level 7 (27,848 points)
    The OS doesn't not create those files. You did somehow and at some point. You won't be able to see these files using anything except the terminal. Make sure that other user is an admin user, log in as the other user, do "sudo bash" to get a root shell, then go over to your original account's home directory and delete/fix your .bash_profile.
  • ericmeyers Level 4 (1,410 points)
    You can look for them like Etre suggests, or install a trial copy of PathFinder. It's similar to Finder and you can view hidden files (it's free for 30 days.)

  • -U! Level 1 (0 points)
    Already tried Pathfinder and 'sudo bash' on the 2nd account.The files simply don't exist —if it's any help,here's a screenshot:
  • ericmeyers Level 4 (1,410 points)
    You speak the truth.

    Etre, you have any idea what's amiss?
  • etresoft Level 7 (27,848 points)
    Curious. Perhaps some application you installed has hacked up your account. See if you can find out the full path to your shell. I think you can find that in System Preferences > Accounts > Advanced.
  • BobHarris Level 6 (17,734 points)

    Has anyone been playing with




    These files may or may not exist, but if they do, you should investigate them.

    For example, my /etc/profile looks like

    # System-wide .profile for sh(1)

    if [ -x /usr/libexec/path_helper ]; then
    eval `/usr/libexec/path_helper -s`

    if [ "${BASH-no}" != "no" ]; then
    [ -r /etc/bashrc ] && . /etc/bashrc

    and my /etc/bashrc looks like

    # System-wide .bashrc file for interactive bash(1) shells.
    if [ -z "$PS1" ]; then

    PS1='h:W u$ '
    # Make bash check its window size after a process completes
    shopt -s checkwinsize

    I would look at Terminal -> Preferences -> Startup and see what "Shells open with" is set to.

    Has the /usr/bin/login program been replaced with a script or a different version.

    At anytime in the past, did you use Terminal -> File -> Use Settings as Default?

    I know I'm playing 20 questions, and just fishing for a likely cause.

    Message was edited by: BobHarris
  • M4R4G4T0 Level 1 (10 points)
    Sorry to ask, but is your user account on your Mac also called "-U!"? I'm not sure, but I wonder if it has anything to do with the "-u" parameter your terminal is complaining about.
  • ericmeyers Level 4 (1,410 points)
    Oh that's a good thought!
  • M4R4G4T0 Level 1 (10 points)
    You could try creating another account with a similar name, say "-V!" and see if it has the same problem.
  • -U! Level 1 (0 points)
    Well,the files '/etc/profile' and '/etc/bashrc' are fine.
    Terminal preferences on the main account are set to '/usr/bin/login'.
    'echo $SHELL' on the 2nd account shows '/bin/tcsh'.

    Terminal on the third account with the '-V!' username indeed has the same problem but with a '-v' parameter.However,eliminating the hypen and the exclamation mark on the username of the 1st account doesn't work.
Previous 1 2 Next