Terminal asks for password for ubuntu user on sudo


#1

Ran these commands, now can’t get the application to run:

sudo apt-get install php7-curl

Got a warning, so then ran this:

sudo apt-get upgrade

Anyone have some advice?


#2

I’d generally avoid apt-get upgrade as it can cause issues.

The sudo password should be blank since you have to log into the workspace with your Cloud9 creds anyway. Can you try upgrading PHP without upgrading the OS to see if this helps out?


#3

Thanks for the message here Brady. Is there any way to get the root password for this workspace? Also…is there any way to get some premium/fast support to get us over this hurdle?


#4

Brady,
I’m working with rpetersn on the workstation in question. Thanks for the advise, but doesn’t seem to be around workstation space as indicated by “avoid apt-get upgrade link” . Instead the problem is now that apt-get upgrade has been run, we can’t run any other upgrade or install anything because the sudo asks for credentials we don’t have.

literally
rpetersn:~/workspace (master) $ sudo apt-get install php-soap [sudo] password for ubuntu: Sorry, try again. [sudo] password for ubuntu: Sorry, try again. [sudo] password for ubuntu: Sorry, try again..

It would seem that apt-get upgrade upgraded something about sudo. Without the sudo / root pass it seems we have no alternative but to start a new workstation. Sure would be nice to not have to do that.


#5

Well…we got it working on another workspace and then cloned things back to this particular one. Looks like we’re back in action here.

Brady, does C9 happen to have any plans for paid/faster support? In some cases I think that people (us) would be happy to shell out a bit to get a question answered asap. Any notes you can share on this?

Thx…Ross


#6

There is a premium support option, which you can get from purchasing a premium plan :slight_smile:


#7

Glad you got it working. We don’t currently have an SLA for support though we’re working on improving the process we have. On your end, it can be helpful to ping us in one place and stick with that. If you want to followup and put the heat on, just do so in the same request. If your original request was here on the forums, followup here, same thing for email or the premium support chat widget.


#8

@rpetersn curious what caused/fixed the issue you saw? I don’t think I’ve ever had this happen personally before but it’d be nice to know how to fix it in case.


#9

Can’t you just run “sudo su” and then apt-get install php-curl…


#10

Sudo su requires sudo, and would likely require the sudo password, so no, that probably wouldn’t work.


#11

My bad. I tried it on my side and it didn’t ask for a password. I wasn’t thinking.


#12

Like the gent in the post above, I am now asked for a password for the ubuntu workspace.

sudo su

sudo su -

etc, these do not work, so I am hoping someone from c9 might be able to reset my password for me. I am using this for the cs50x course.


#13

This is your environment that you operate so it’s not as simple as a Cloud9 team member reseting the password. Hopefully some other users that have seen this (and fixed it) can shed some light on this for you.


#14

Is there a way to interrupt the boot process on restart? That is how I’d do it on a physical machine, at which point I could boot into single user mode.


#15

As far as I know, there is no workaround for this. If this is blocking you, you’ll want to Download Your Files and then upload them into a new workspace where you have sudo access once again.

If anyone figures out a workaround for this, please post it here :slight_smile:


#16

I wrote a fix for this today, which is now deployed :ballot_box_with_check:

Most likely when upgrading openssh through apt you chose to overwrite the sudoers config file instead of the default option to keep the current one. Now we’ll re-write the sudoers file when a workspace is restarted, so choosing to restart the workspace should fix sudoers issues in the future.