0

I changed my PATH environment variables when i was trying to install Java on my pc, then i tried restoring the old PATH by completely uninstalling java from my pc which caused google-chrome to stop working. I tried doing some exports in order to remedy the situation to no avail. Nothing happens when i click the google-chrome icon and i get the following errors when i try launching chrome from the terminal with google-chrome command

/usr/bin/google-chrome: line 8: readlink: command not found
/usr/bin/google-chrome: line 24: mkdir: command not found
/usr/bin/google-chrome: line 45: exec: cat: not found
/usr/bin/google-chrome: line 46: exec: cat: not found

The result of echo $PATH is /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin/usr/games:/usr/local/games:/snap/bin

Please help. I use Ubuntu 18.04

4
  • 1
    Your PATH is probably still messed up. Please add the output of echo $PATH to your original posting.
    – ubfan1
    Jan 27, 2023 at 18:33
  • The result of echo $PATH is /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin/usr/games:/usr/local/games:/snap/bin Jan 28, 2023 at 22:23
  • 1
    The "/bin/usr/games" seems wrong. Should be /bin:/usr/games
    – ubfan1
    Jan 28, 2023 at 22:29
  • The default PATH is from /etc/environment and user modifications are usually made in .profile. Looks like your /etc/environment file may have the problem -- did you change it?
    – ubfan1
    Jan 29, 2023 at 17:50

1 Answer 1

0

The problem is bin is not in your path, which is why readlink, mkdir, and cat, are not able to be found. The problem seems to be right there:

/bin/usr/games:/usr/local/games:

I would first check to see if you have a directory /bin/usr/games and if you don't then change that part in your path to

/bin:/usr/games:/usr/local/games:

If you do have that directory then just add this to the end of your path

:/bin
2

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .