Permission error while uploading file to Amazon server

Asked

Viewed 978 times

3

I am trying to send some site changes to the client’s server on Amazon, only that by doing so it returns to me that I am not allowed to do so because the client’s website is not on /var/www/html and yes in /var/www . The user I am using does not know if it was the client that created or if it is already standard from Amazon, but it is the user Ubuntu.

I have no idea how to set/handle Amazon, so I need help. I’m using Filezilla to transfer the files via sFTP

  • Ubuntu user is default for Instances that contains the Ubuntu OS and ec2-user for other OS. you are trying to send or are editing the file directly in filezila? you need to check the folder permissions by terminal.

  • I right-click the file and click edit and open my text editor, after only the CTRL+S and click to send and this error. How do I open the Amazon terminal and execute the command ? I am an AWS layman.

  • you can download the file, edit it on your computer and upload or open the terminal on Ubuntu to access Amazon. If you use Windows you will need Putty to connect, which in my opinion is more laborious. If you are using Ubuntu: open the terminal and type ssh: -i your server ubuntu@ip key and navigate to the file folder and the appropriate write permissions.

  • Hi @Alissonacioli, Have you released the port for FTP access in the Security Group of your EC2 instance? If yes, you can create a new connection via Filezilla by "Website Manager", simply import your key into "settings"-> SFTP and later configure the connection to the target host.

  • Ideally, you should see the permission for the /var/www/html folder. You can check it using the "$ls -l" command. By default in the Ubuntu distribution, the owner must be the www-data user who owns a group of the same name. Add the user Ubuntu to the www-data group via the command: "sudo addgroup Ubuntu www-data". Must resolve.

1 answer

1

The ideal would be for you to see the permission of the /var/www/html folder. You can check using the command "$ls -l". By default in the Ubuntu distribution, the owner must be the www-data user who owns a group of the same name. Add the Ubuntu user to the www-data group via the command: "sudo addgroup ubuntu www-data".

Browser other questions tagged

You are not signed in. Login or sign up in order to post.