Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6123769
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T16:03:19+00:00 2026-05-23T16:03:19+00:00

This issue has been bugging me for the past several days. I’ve been working

  • 0

This issue has been bugging me for the past several days.

I’ve been working on setting up a LAMP Server on Amazon EC2. The main issue is that I’m writing an application for a client that requires a lot of high-end processing, and Amazon EC2 seemed like a good choice.

Initially I started off with a basic AMI which really didn’t have anything. I tried using root access to log into SSH (using WinSCP) and I was told to use ec2-user.

I tried using ec2-user, and I was able to log in. However, I still didn’t have root access and couldn’t install apache. I did some reason and I found out about the “sudo” command, and pretty much every article I read on this issue said to either use root access, or log into ec2-user and user sudo.

I have since tried again with a different AMI where LAMP was already installed. I was able to get it working, set up a database and start running a website off of it. However, I still needed to install some extensions. Namely, an API I’m trying to use for this application requires SOAP to be installed.

Here’s my dilemma:

/$ whereis soap
soap:
/$ whereis yum
yum: /usr/bin/yum /etc/yum /etc/yum.conf /usr/share/man/man8/yum.8.gz
/$ yum install php-soap
Loaded plugins: fastestmirror, priorities, security
You need to be root to perform this command.
/$ sudo yum install php-soap
sudo: sorry, you must have a tty to run sudo

Command 'sudo yum install php-soap' failed with return code 1 and error message sudo: sorry, you must have a tty to run sudo

I can’t use yum because I don’t have root access, and whenever I log into root it either tells me to use ec2-user or provide a password I don’t have. The other alternative was to use sudo to make ec2-user act like root, but I always get the error ‘sorry, you must have a tty to run sudo.’ I’ve ran that error message online and that it seems I need to add a user to sudoers… which I can’t do without root access.

This exact same issue plagued me on two separate AMI’s. On the first I just received a message saying I had to log in as ec2-user (and I must have a tty to run sudo), while the second (with LAMP installed) required me to enter a password for root, and for user I got the same sudo error.

Here are the id’s of the AMI’s I used:

ami-8c1fece5
ami-6ae81503

I also tried a third AMI later that also had LAMP installed… I couldn’t even get into that one at all.

I did download my SSH key and used PuttyGen to convert it to a ppk file. I can log in successfully as ec2-user, but I cannot gain root access anywhere.

I have been looking around quite a bit for help on this, but every article I’ve read assumes that the user either has root access available or has sudo available on ec2-user. I don’t have either. Is it just that I need a new image?

Any help would be greatly appreciated…

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T16:03:20+00:00Added an answer on May 23, 2026 at 4:03 pm

    Use a real SSH client like PuTTY, not WinSCP, a file transfer client. All your problems will disappear.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

This one has been bugging me for a while now. Is there a way
I have an issue with log4net which has been bugging me for a while
I have an issue that's been bugging me this morning. I'm building an ASP.NET
I've had an issue with Visual Studio that has been bugging me for some
This issue has been very hard for me to debug. I am a pc
I hope someone can help... This issue has been discussed here and I have
I'm having a major issue which has been bugging me for a while now.
This is driving me crazy, and has been bugging me for weeks, I'm trying
Greetings all, I realize this issue has been posed before in other forms, and
Has anyone come across this issue? Seems MS have broken it with their own

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.