Unix
- dmidecode -s system-product-name;lspci | grep -i vmware
- dos2unix
- yum update -x kernel
- df -Ph
- lsb_release -a
- nohup ./script.sh & (continuously run)
- stat file or ls -il file for inode
- script -a /tmp/filename
- ntpq -pn l ntpupdate
- rpcinfo -p
- ntsysv --level3
- modprobe ;lsmod;modinfo
- W;tty
- ldd (packages dependencies)
- rpm2cpio *.rpm |cpio -ivd
- rpm -Uvh --rollback '1 hour ago'
- rpm -Uvh --rollback 'March 20'
- yum history rollback 46
- yum history info 46
- yum history undo 46
- yum history repeat 46
Remotely Force a Reboot:
If you need to remotely hard-reset your Linux system because of a read-only file system, try Magic SysRq:
If you need to remotely hard-reset your Linux system because of a read-only file system, try Magic SysRq:
# echo 1 >/proc/sys/kernel/sysrq ; echo b >/proc/sysrq-trigger
This will enable SYSRQ and power cycle the system, like hitting the reset button. This is obviously a last resort, only when a clean shutdown will not work.
Windows
1.wmic os get osarchitecture ; wmic os get Name ;msinfo32
2.wmic os where primary= true call reboot ; shutdown -r -t 10
3.systeminfo |find /I "system type"
systeminfo | findstr /C:"Total Physical Memory"
4.mstsc /v:0.0.0.0 /f /console ;mstsc /v:0.0.0.0 /f /admin
5. Remove dir older than 7 days:
c:\bin\UnixUtils\find -maxdepth 1 -type d -mtime +6 -exec c:\bin\unixutils\rm -rfv {} ;
0 comments:
Post a Comment