I created this post just to have a place where to keep all those linux things I always forget 😉 Hope you’ll find it useful for you as well.

How to change file/direcotry owner

chown -R user:group file

How to change file/directory attrubutes

chmod -R user-group-other file

where user/group/other:
7 full
6 read and write
5 read and execute
4 read only
3 write and execute
2 write only
1 execute only
0 none

How to find httpd.conf location

find / -name httpd.conf

my is in /etc/apache2/

How to restart Apache

apachectl -k graceful

How to remove a directory with all its content

rm -rf /directory

Scheduling with crontab


Mirroring files from other server via FTP

wget -nH –cut-dirs=3 -m ftp://user:password@ftp.website.com/a/b/c/

should be run in the rarget directory (–cut-dirs={a,b,c} count)