These are mostly used linux commands I applied daily, I paste it here once it is useful for you.

1.

Permanently set the Environment Variables

classpath=” ”

export classpath

2.

To see the hardware configuration

cat /proc/cpuinfo

3.

Tar commands

tar –xvvzf myfile.tar.gz  // to leave the .tar.gz unchanged

tar –pczf myfile.tar.gz  /path/...  // to compress

gzip –c test.text>test.gz

tar –xvvf myfile.tar  // to extract

4.

To change the login user name

su username

5.

To see the size of file or directory

du –skh filename

6.

To show the disk space

df -h

6.

Copy files from one computer to another

scp myfile username@xxx.xxx.xxx:c:/

scp myfile username@xxx.xxx.xxx:/opt/   // where xxx is the hostname of target computer

7.

To see the CUP and Memory usage

top

8.

Vi commands

vi myfile.config  // to view the file

:q  // to exit

:q!  // to exit witout the change

:wq  // to exit with change

:cw  // change word

:cc  // change a line

9.

Make a backup file

cp –b myfile1 myfile2

10.

Create direcory

mkdir mydirectory

11.

Set file permission

chmod 777 mybatch.sh

12.

To check the OS

cat /etc/redhat-release

13.

Force to delete the directory

rm –rf direcory

14.

Search for a file name

find . –name myfile

15.

Start Xwin X server

Start Cygwin Bash Shell

cd /usr/x11R6/bin

./startxwin.bat

16.

View IP Address

hostname -i

17.

View and kill Processes

ps: to view processes

kill -9 process id

18.

Copy the entire directory

cp -R dir/ newdir/

19.

View port

Netstat –an | grep 9081

Netstat –an > /tmp/port.out

Some useful linux commands相关推荐

  1. The Linux commands you need!

    从网上看到的,还可以.挺基础的还有些技巧性的. After half a year of linux, I have some post-it memo's sticked to my monitor ...

  2. The 10 Most Important Linux Commands/10个最经常使用的命令行

    1. ls 命令:to show all of the major directiories filed under a given file system. for example: ls /app ...

  3. 执行在一行中组合多个Linux命令

    本文翻译自:Execute combine multiple Linux commands in one line I am trying to merge multiple linux comman ...

  4. linux一切皆文件之tty字符设备(深入理解sshd创建pty的过程) (五)

    一.知识准备 1.在linux中,一切皆为文件,所有不同种类的类型都被抽象成文件(比如:块设备,socket套接字,pipe队列) 2.操作这些不同的类型就像操作文件一样,比如增删改查等 3.块设备支 ...

  5. Linux基础书籍推荐

    学习Linux还是以Red Hat Enterprise Linux这一基础版本比较好,它的再编译版本CentOS在服务器操作系统中占很大的比重.而且现在很多软件都推出了虚拟机模板,大都是Red Ha ...

  6. S5PV210开发 -- Linux dd命令

    如需转载请注明出处:https://blog.csdn.net/qq_29350001/article/details/78475434 昨天群里有人询问,为什么破坏 BootLoader 破坏不掉. ...

  7. Linux命令Find实例

    转自: http://www.tecmint.com/35-practical-examples-of-linux-find-command/ 35 Practical Examples of Lin ...

  8. linux ls in*,35 ls Command Examples in Linux (The Complete Guide)

    Do you know how to list contents (files/directories) in Linux? It's straightforward. In this article ...

  9. linux实现shell,linux

    4.5M http://www.starbase-929.net/media/Calibre%20Library/Ken%20O.%20Bartch/Linux%20Shell%20Scription ...

最新文章

  1. 深度解读:人体防御病毒的免疫力究竟是什么?
  2. yum源的超级简单配置
  3. 关于微型计算机主板的描述错误的是,2016年9月计算机一级考试试题及答案「单选」...
  4. 愤怒的小鸟【$DP$优化】
  5. Java JDK11快速下载地址
  6. 内存区域的划分和分配
  7. CRM attachment read old API debug
  8. 扫地机器人隔板_【扫地机器人使用】_摘要频道_什么值得买
  9. thinkphp框架起步认识
  10. 【Python】实现输出成绩最高或最低分的学生姓名以及低于平均分的学生姓名
  11. 关于oracle的certview
  12. java中d怎样转换D,如何将ZonedDateTime转换为date?
  13. leetcode之回文链表
  14. android画图 旋转 地球*月球,unity3d怎么实现地球太阳月球转动-unity3d实现地球太阳月球转动的方法 - 河东软件园...
  15. mysql省市联动_sql全国 省市 联动级联
  16. WPF动画——故事板(Storyboard)
  17. Rocketmq广播消费模式怎么扩展消费者
  18. ionic自定义图标(ion-icon)
  19. cannot find -lnl
  20. ImageNet Classification with Deep Convolutional Neural Networks(AlexNet论文翻译(附原文))

热门文章

  1. 计算机网络管理存在薄弱环节,计算机网络管理思考
  2. Jmeter - JMeter监听器 -上篇(详解教程)
  3. 大唐杯5G练习题(二)
  4. K8S、kubernetes no resolver defined to resolve could not be resolved (3: Host not found) 问题解决
  5. Java如何获取IP属地 ip2region failed to create searcher with x:java.io.FileNotFoundException:( 系统找不到指定的路径)
  6. iphone长截图哪个软件好_亲身体验过13款滚动截屏App,谁才是最好用的iPhone长截屏工具?...
  7. Demo---progress-steps------ 2/50(详解)
  8. Antlr Tool与antlr runtime的版本一致性问题
  9. hashmap底层逻辑
  10. BCB数据库构件用法的总结