I have done a terrible deed while linking javac to /usr/bin
I accidentally pasted wrong command line and now I cannot use sudo anymore and thus, I can't access any file or folder which needs permission.
It says
bash: /usr/bin/sudo: Too many levels of symbolic links
The command line which I wrongly paseted is
sudo ln -f -s sudo ln -f -s /opt/jdk1.8.0_151/bin/javac /usr/bin
But it should be
sudo ln -f -s /opt/jdk1.8.0_151/bin/javac /usr/bin
But I already messed up. So, please, if anyone have any idea of how I can fix that, I'll be very thankful.
grub
menu at boot time? You can start a root shell from there (recovery mode → root shell). The filesystems will be read-only at first but you can remount them read-write (mount -o rw,remount /
) and then fix your brokensudo
. – PerlDuck Jan 07 '18 at 13:44