Host of issues stemming from too many symlink levels errors
Clash Royale CLAN TAG#URR8PPP
up vote
0
down vote
favorite
Ok. I understand the title can be misleading or confusing... so plz bear with me.
On an AWS EC2 instance, I was upgrading imagemagick. Current installation was 6.8.x
which is vulnerable, and I was moving it to 6.9.10-12
which if I read properly, I think it's patched.
Somewhere during the process, I stumbled upon the following error when executing a sudo command:
-bash sudo: Too many levels of symbolic links
[paraphrased]
This was when trying to add a new link onto /usr/bin/
.
So I had a look inside to see if there was something funky in there... and I found a bin
folder inside /usr/bin/
that was linked to /usr/bin//
During that time, I temporarily lost internet access, which was regained rather quickly, so I re-start my ssh connection to the ec2 instance and lo and behold....
$ sudo
The program 'sudo' can be found in the following packages:
* sudo
* sudo-ldap
Try: sudo apt install <selected package>
So... now my user lost access to sudo as well... any sort of command to fix any links inside /usr/bin
will need sudo access... installing sudo needs sudo access... going su -
to switch to root, seems to also need sudo access because it otherwise asks me for password for root, and aws does not give you that when launching an instance...
Would the steps detailed on this answer be my only way to fix this now? (If this can be fixed at all!?)
ubuntu symlink amazon-ec2 aws
New contributor
add a comment |Â
up vote
0
down vote
favorite
Ok. I understand the title can be misleading or confusing... so plz bear with me.
On an AWS EC2 instance, I was upgrading imagemagick. Current installation was 6.8.x
which is vulnerable, and I was moving it to 6.9.10-12
which if I read properly, I think it's patched.
Somewhere during the process, I stumbled upon the following error when executing a sudo command:
-bash sudo: Too many levels of symbolic links
[paraphrased]
This was when trying to add a new link onto /usr/bin/
.
So I had a look inside to see if there was something funky in there... and I found a bin
folder inside /usr/bin/
that was linked to /usr/bin//
During that time, I temporarily lost internet access, which was regained rather quickly, so I re-start my ssh connection to the ec2 instance and lo and behold....
$ sudo
The program 'sudo' can be found in the following packages:
* sudo
* sudo-ldap
Try: sudo apt install <selected package>
So... now my user lost access to sudo as well... any sort of command to fix any links inside /usr/bin
will need sudo access... installing sudo needs sudo access... going su -
to switch to root, seems to also need sudo access because it otherwise asks me for password for root, and aws does not give you that when launching an instance...
Would the steps detailed on this answer be my only way to fix this now? (If this can be fixed at all!?)
ubuntu symlink amazon-ec2 aws
New contributor
add a comment |Â
up vote
0
down vote
favorite
up vote
0
down vote
favorite
Ok. I understand the title can be misleading or confusing... so plz bear with me.
On an AWS EC2 instance, I was upgrading imagemagick. Current installation was 6.8.x
which is vulnerable, and I was moving it to 6.9.10-12
which if I read properly, I think it's patched.
Somewhere during the process, I stumbled upon the following error when executing a sudo command:
-bash sudo: Too many levels of symbolic links
[paraphrased]
This was when trying to add a new link onto /usr/bin/
.
So I had a look inside to see if there was something funky in there... and I found a bin
folder inside /usr/bin/
that was linked to /usr/bin//
During that time, I temporarily lost internet access, which was regained rather quickly, so I re-start my ssh connection to the ec2 instance and lo and behold....
$ sudo
The program 'sudo' can be found in the following packages:
* sudo
* sudo-ldap
Try: sudo apt install <selected package>
So... now my user lost access to sudo as well... any sort of command to fix any links inside /usr/bin
will need sudo access... installing sudo needs sudo access... going su -
to switch to root, seems to also need sudo access because it otherwise asks me for password for root, and aws does not give you that when launching an instance...
Would the steps detailed on this answer be my only way to fix this now? (If this can be fixed at all!?)
ubuntu symlink amazon-ec2 aws
New contributor
Ok. I understand the title can be misleading or confusing... so plz bear with me.
On an AWS EC2 instance, I was upgrading imagemagick. Current installation was 6.8.x
which is vulnerable, and I was moving it to 6.9.10-12
which if I read properly, I think it's patched.
Somewhere during the process, I stumbled upon the following error when executing a sudo command:
-bash sudo: Too many levels of symbolic links
[paraphrased]
This was when trying to add a new link onto /usr/bin/
.
So I had a look inside to see if there was something funky in there... and I found a bin
folder inside /usr/bin/
that was linked to /usr/bin//
During that time, I temporarily lost internet access, which was regained rather quickly, so I re-start my ssh connection to the ec2 instance and lo and behold....
$ sudo
The program 'sudo' can be found in the following packages:
* sudo
* sudo-ldap
Try: sudo apt install <selected package>
So... now my user lost access to sudo as well... any sort of command to fix any links inside /usr/bin
will need sudo access... installing sudo needs sudo access... going su -
to switch to root, seems to also need sudo access because it otherwise asks me for password for root, and aws does not give you that when launching an instance...
Would the steps detailed on this answer be my only way to fix this now? (If this can be fixed at all!?)
ubuntu symlink amazon-ec2 aws
ubuntu symlink amazon-ec2 aws
New contributor
New contributor
New contributor
asked 9 mins ago
EffectiX
101
101
New contributor
New contributor
add a comment |Â
add a comment |Â
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
EffectiX is a new contributor. Be nice, and check out our Code of Conduct.
EffectiX is a new contributor. Be nice, and check out our Code of Conduct.
EffectiX is a new contributor. Be nice, and check out our Code of Conduct.
EffectiX is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f475648%2fhost-of-issues-stemming-from-too-many-symlink-levels-errors%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password