You just need to add one extra argument
# tar -xzvf file.tar.gz -C /destination/path
# tar -czvf test.tar.gz test/
So, now our test directory is compressed. let us extract it inside /tmp staying under /home
[root@test home]# tar -xzvf test.tar.gz -C /tmp/
# ls -l
drwx------. 4 test test 4096 Sep 28 12:46 test
Follow the below links for more tutorials
Tutorial for Monitoring Tools SAR and KSAR with examples in Linux
How to configure Samba 4 Secondary Domain Controller
RHEL: Kernel will not boot, system freeze at 'starting udev'
How to secure Apache web server in Linux using password (.htaccess)
How to register Red Hat Linux with RHN (Red Hat Network )
Red hat Enterprise Linux 5.5 Installation Guide (Screenshots)
15 tips to enhance security of your Linux machine
Why is Linux more secure than windows and any other OS
What is the difference between "su" and "su -" in Linux?
What is swappiness and how do we change its value?
How to log iptables messages in different log file
What is virtual memory, paging and swap space?