3

I am running Ubuntu Linux 14.04 via Parallels (10.1.4) in Mac OS X 10.10.2 on a MacBook Pro. Today I received update notifications for Ubuntu (first) and then Parallels and stupidly installed them (I never learn; I have problems every time).

Now when I open gnome-terminal (not the Mac Terminal, the Ubuntu one), I have no command-line prompt. So I can't use gnome-terminal. I have tried reinstalling Parallels tools, but nothing changes.

I don't know whether the Parallels or Ubuntu update created the problem, but I suspect it was the Ubuntu update. After a few minutes, the following error appears in a terminal:

Unknown processor type for Linux 
bash : [: -eq: unary operator expected 
Your "" operating system is not supported by this release of
XXX.

XXX is a program I use via Parallels.

Is there a way to undo the update without having to reinstall the virtual machine and/or Ubuntu? I don't want to lose my current setup; it took ages to get right. I would be grateful for any advice.

3

That sounds like a syntax error in one of your shell's initialization files. The likeliest culprits are either ~/.bashrc or ~/.profile. The simplest solution is to make a backup of these two files and then overwrite them with the defaults.

  1. Make a new user. You will run the necessary commands as this user who, presumably, will have a working shell. Make sure you create the user as an administrator so you can run sudo commands.

  2. Log in as the new user and run this command (change parallels to the original user name, the one who has the problem):

     for i in .bashrc .profile; do 
       sudo mv ~parallels/$i ~parallels/$i.old
       sudo cp /etc/skel/$i ~parallels/
       sudo chown parallels:parallels ~parallels/$i
     done
    

That command will rename .bashrc to .bashrc.old and then copy the default over from /etc/skel. Finally, it changes the ownership of the file to parallels since it needs to be owned by the target user. It then does the same for .profile

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.