Useful linux commands

0

Full article

I'll leave below also a cheat sheet :)

Create a soft or symbolic link?
sudo ln -s /path/to/source/file

Note: this works if you both nodes are below you in the same tree. You can use relative notation

-s command makes it a symbolic link
-n makes it possible de create a folder-type symlink

Note that wherever you currently are is where the shortcut will be created.

Find a document on the server:
sudo find / -name foo.txt (foo.txt is the file to search)

Switch to root:
sudo -i

Switch user between terminals:
su - user2

Remove directory:
sudo rm -rf folderName

Permissions

linux-cheat-sheet







Comments