User Tools

Site Tools


dev:tricks:linux

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
dev:tricks:linux [2016/04/19 08:47] – [Useful tools to monitor linux] hackerzhoudev:tricks:linux [2017/10/12 14:49] – [Remove old kernel image] hackerzhou
Line 1: Line 1:
 ====== Linux Tricks ====== ====== Linux Tricks ======
 ===== Linux Common ===== ===== Linux Common =====
 +==== XML beautiful format command ====
 +<code bash>
 +cat xxx.xml |  xmllint --format -
 +</code>
 +
 ==== Remount filesystem as read-write ==== ==== Remount filesystem as read-write ====
 <code bash> <code bash>
Line 686: Line 691:
 <code bash> <code bash>
 kernelver=$(uname -r | sed -r 's/-[a-z]+//') kernelver=$(uname -r | sed -r 's/-[a-z]+//')
-ls /boot/{abi,vmlinuz,config,System.map,initrd.img}-[0-9\.-]*.* | grep -ve $kernelver | xargs rm -f +dpkg -l linux-{image,headers}-"[0-9]*" | awk '/ii/{print $2}' | grep -ve $kernelver | xargs dpkg --force-all -P
-#dpkg -l linux-{image,headers}-"[0-9]*" | awk '/ii/{print $2}' | grep -ve $kernelver | xargs apt-get purge -y+
 </code> </code>
 ==== Install Lyx ==== ==== Install Lyx ====
dev/tricks/linux.txt · Last modified: 2020/06/06 23:32 by 127.0.0.1