Jump to content

I just turned one of my old laptops into some of a VPS with Ubuntu Server; just to mess around on. But im having an issue...

I'd like to trasnfer some files over using FileZilla (SFTP), but using my normal login with wont work as it wont let me upload files without root access.

I've tried using passwd -u root, and it comes back with it has been successfuly unlocked and i changed the password to just "test" for now. But its still not working...

I can login with root on the laptop itself, but using SSH or SFTP it still says "access denied" or "Authentication failed.".

Any help?

Im fairly new to all this linux-based server stuff, so sorry if this is a given and im just dumb... 

Just a wannabe linux admin that works on block game servers. 

Link to comment
https://linustechtips.com/topic/695743-ubuntu-server-1604-root-user-access/
Share on other sites

Link to post
Share on other sites

Just now, Electronics Wizardy said:

File permissions.

 

Use su to switche to root.

This helps with using putty to access things, which i can already sudo with. But that doesn't solve the problem of not having access to use SFTP to transfer over files. 

Just a wannabe linux admin that works on block game servers. 

Link to post
Share on other sites

Just now, Nuxxy said:

This helps with using putty to access things, which i can already sudo with. But that doesn't solve the problem of not having access to use SFTP to transfer over files. 

Don't use root to copy files to, ever.

 

You need to change the file permissions to give you write access.

Link to post
Share on other sites

1 minute ago, Electronics Wizardy said:

Don't use root to copy files to, ever.

 

You need to change the file permissions to give you write access.

Can how does one do this? once again, im kinda new to this linux server stuff. Thats why im doing this on an old home machine to just mess around.

Just a wannabe linux admin that works on block game servers. 

Link to post
Share on other sites

Just now, Nuxxy said:

Can how does one do this? once again, im kinda new to this linux server stuff. Thats why im doing this on an old home machine to just mess around on get to learn it. 

chown -R USERNAMEHERE

 

 

Link to post
Share on other sites

In Ubuntu you're not meant to make a root login thats why SSH wont allow it by default. Creating a password for root, only allows you to login locally.

try this

chown -R username:username /folderpath

             ☼

ψ ︿_____︿_ψ_   

Link to post
Share on other sites

3 minutes ago, Electronics Wizardy said:

oh yea.You need the folder to change the permissions of.

That worked! Thanks for the help. I now see root is a big no no in the ubuntu world. 

Just a wannabe linux admin that works on block game servers. 

Link to post
Share on other sites

1 minute ago, SCHISCHKA said:

I should clarify the above

 

chown -R userName:groupName folder

 

changes ownership recursivly. The group name on ubuntu is typically the username

Meh fuck it 

 

chmod -R 777 /

 

No don't do that. it won't boot as some services don't like there files being read write for all users.

Link to post
Share on other sites

1 minute ago, Nuxxy said:

That worked! Thanks for the help. I now see root is a big no no in the ubuntu world. 

it defeats the usefulness of sudo. Sudo records more than what would happen if you log in as root. If you do get sick of writing sudo before every command you can  run "sudo su" to login in as root, but this also looses the logging abilities of sudo; if its just your machine it shouldnt be a problem

             ☼

ψ ︿_____︿_ψ_   

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×