Linux reminders

Mount

showmount -e <remote_machine_ip>

#mount /var/tmp in our machine

mkdir /mnt/kenobiNFS
mount machine_ip:/var /mnt/kenobiNFS
ls -la /mnt/kenobiNFS

SSH with key

chmod 600 id_rsa
ssh -i id_rsa <user>@<ip>

SUID / SGID / Sticky Bit

Permission

On Files

On Directories

SUID Bit

User executes the file with permissions of the file owner

/

SGID Bit

User executes the file with the permission of the group owner

File created in directory gets the same group owner

Sticky Bit

No meaning

Users are prevented from deleting files from other users

File descriptors

Integer value

Name

<unistd.h> symbolic constant

<stdio.h> file stream

0

STDIN_FILENO

stdin

1

STDOUT_FILENO

stdout

2

STDERR_FILENO

stderr

Last updated

Was this helpful?