Wednesday, 31 October 2018

linux_commands


/*************************************linux***************************************/

who --find who are in network
which ---ex. Which vsim,which alint
Whoami
write username
cat /etc/os-release   -->it shows the version and distribution of linux

ps -aux |grep gnome
ps --process status
echo "hi how are you"|write praveen
ps -elf |grep gnome --process status
ps -ef |less
ps -aux |less
ps ax
ps aux
ps -u user_name
ps -u -p 26218
pstree user_name
Tree  -->it shows the directory tree structure
top -u user_name
top |grep alint
last user_name

df _filesystem
df . -h ---it will give current directory space
df -h –disk_space_human_readable
df -k—kilo_bytes
df -kh
df -m – mega_bytes
du .  -->it shows current directory size
du -a | sort -n -r | head -n 5
killall gnome-panel----carefull
killall gnome-shell----carefull
su lokesh
Su

grep -rn pattern name –it will give where that pattern with line no in subfolders also
cat example.v – it will show content of the file
cat data_type_1/src/data_types_1.v |grep module
grep pattern data_types_1.v
grep -in pattern * ---it greps the pattern inside the file with line number also --star means whole directory
grep -rn pattern * --it greps the pattern inside the file with recursively
grep -n pattern data_types_1.v  --it shows the numbers of pattern
grep -c pattern data_types_1.v ---it shows the count
zgrep -i   "pattern" file.v--- finding zip files

cp file_name ../destination_path-- cp file.v ../tb/.
mv old_name new_name ---mv old.v new.v
find . -name mux
find /home/commonfolder/common_dora/verilog_spec -name mux
find uvm_labs |grep pattern
find . |grep pattern
find . -type d |grep -i folder—it shows only directories
find . -type f |grep -i folder – it shows only files
find . -name \*.cfg -type f -delete
find . -name \work -type d -exec rm -fr {} \;
find dora/ |grep -i video –it  ignore the case sensitive

ls -l |grep folder_pattern
ls -d */*/*/---listing the directories in hierarchical model
ls *.rc | wc  --->it will show the count w.r.t .rc_file
ll  |grep -i folder_pattern
ls |wc -l   -->it show no.of files
ln -s /nfs/site/home/mdorabax/my_work/experiments/user3 my_child  --create the soft links
ln /nfs/site/home/mdorabax/my_work/experiments/user3/ex.v my_ex.v  --it will create hard links (be carefull, if you change one place It will reflect everywhere).
 sudo ln -sf /usr/share/zoneinfo/Asia/Calcutta /etc/localtime  -->it is for time changes to localtime
ls */run/*.do
ls */run/*.do > flist_do
wc filename.v-- shows the word count

chmod 777 file.v
chmod u+wrx g+xr <file.v or directory>  --changing the permissions
chmod ug+wrx
chmod uga+wr

tar -xvf tests.tar.gz
zip dora.v dora
unzip dora.v
Chc -->it changes the terminal color

echo "my text" | tee -a *.php --adding the text
HISTTIMEFORMAT="%d/%m/%y %T "

No comments:

Post a Comment

What do 10 nm and 15 nm stand for in VLSI? nm=nano meter                     So, 10nm means in digital elections perspective the dist...

Design verification Engineer