How can I access the etc, var and www directories?

Linode Staff

I reset the root password, then logged in via ssh as root. The only directory I see is postgresql.

Where are the etc, var and www folders? How to access those folders?

1 Reply

To see your etc and var directories you can use the cd command to navigate to your root directory, as follows:

root@localhost:~# cd /
root@localhost:/#

From here you should be able to see your var and etc directories with the ls command. Here's an example of what this would look like:

root@localhost:/# ls
bin  boot  dev    etc  home  initrd.img  lib  lib64  lost+found  
media  mnt  opt    proc  root  run  sbin  srv  sys  tmp  usr  var   
vmlinuz  wordpress.tar.gz

As for your www directory, you should be able to see this in your var directory as follows:

root@localhost:/# cd var/
root@localhost:/var# ls
backups  cache    lib  local  lock  log  mail  opt  run  spool  
tmp  www

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct