dmidecode |grep -A20 "Memory Device$"|sed -n -e'/Locator/p' -e '/Size/p'|grep -v "Bank Locator"

看内存分布

[真机]# dmidecode |grep -A20 "Memory Device$"|sed -n -e'/Locator/p' -e '/Size/p'|grep -v "Bank Locator"

        Size: 4096 MB

        Locator: DIMM0

        Size: 4096 MB

        Locator: DIMM1

        Size: 4096 MB

        Locator: DIMM2

        Size: 4096 MB

        Locator: DIMM3





[虚拟机]#  dmidecode |grep -A20 "Memory Device$"|sed -n -e'/Locator/p' -e '/Size/p'|grep -v "Bank Locator"

        Size: 1024 MB

        Locator: RAM slot #0

        Size: 512 MB

        Locator: RAM slot #1

        Size: 256 MB

        Locator: RAM slot #2

        Size: 128 MB

        Locator: RAM slot #3

        Size: 64 MB

        Locator: RAM slot #4

        Size: 16 MB

        Locator: RAM slot #5

        Size: No Module Installed

        Locator: RAM slot #6

        Size: No Module Installed

        Locator: RAM slot #7

        Size: No Module Installed

        Locator: RAM slot #8

        Size: No Module Installed

        Locator: RAM slot #9

        Size: No Module Installed

        Locator: RAM slot #10

        Size: No Module Installed

        Locator: RAM slot #11

        Size: No Module Installed

        Locator: RAM slot #12

        Size: No Module Installed

        Locator: RAM slot #13

        Size: No Module Installed

        Locator: RAM slot #14

-------》内存分布不均匀

---直接看产品名

 dmidecode |grep "Product"





[root@lixora ~]#  dmidecode |grep "Product"

        Product Name: VMware Virtual Platform

        Product Name: 440BX Desktop Reference Platform





[root@oracle sysbench-0.4.12]#  dmidecode |grep "Product"

        Product Name: System Product Name

        Product Name: P8Z68-V LX





------观察硬件设备。假设看到VMware 类似字符基本为虚拟机了



[虚拟机】lspci -b|grep VMware

00:07.7 System peripheral: VMware Virtual Machine Communication Interface (rev 10)

00:0f.0 VGA compatible controller: VMware SVGA II Adapter

00:11.0 PCI bridge: VMware PCI bridge (rev 02)

00:15.0 PCI bridge: VMware PCI Express Root Port (rev 01)

00:15.1 PCI bridge: VMware PCI Express Root Port (rev 01)

00:15.2 PCI bridge: VMware PCI Express Root Port (rev 01)

00:15.3 PCI bridge: VMware PCI Express Root Port (rev 01)

00:15.4 PCI bridge: VMware PCI Express Root Port (rev 01)

怎样推断server为虚拟机还是物理真机?的更多相关文章

  1. VMware给虚拟机绑定物理网卡

    前言: 桥接模式:就是使用真实的IP地址 NAT模式:使用以VMnet 8所指定的子网中分配的IP地址,在外网信息交互中不存在这样的IP. 仅主机模式:仅用于虚拟机与真机之间的信息交互. 操作步骤: ...

  2. [转帖]如何禁止VirtualBox虚拟机和物理机之间的时间同步

    如何禁止VirtualBox虚拟机和物理机之间的时间同步 乐者为王 2014-11-02 706 阅读   http://ju.outofmemory.cn/entry/97301 验证了下 修改注册 ...

  3. Azure Backup (1) 将SQL Server 2012虚拟机中数据库备份到Azure Storage

    <Windows Azure Platform 系列文章目录> 本文介绍的是由国内世纪互联运维的China Azure,相比国外的Global Azure.主要区别是存储账号的DNS地址不 ...

  4. 如何在VMWare Workstation实现虚拟机与真机的文件共享

    1.进入虚拟机的配置选项 进入方法有三种,一种是使用快捷键Ctrl+D,第二种是先右键点击虚拟机再选择Settings选项,第三种是点击快捷栏中的VM后选择Settings选项,后两种方法的截图如下. ...

  5. Vmware虚拟机网络模式及虚拟机与物理机通信方法

    [转]http://www.cqeis.com/news_detail/newsId=1477.html Vmware虚拟机软件是一个“虚拟PC”软件,它使你可以在一台机器上同时运行二个或更多Wind ...

  6. Androidclient推断server是否开启 HttpHostException解决方式

    Android推断服务器是否开启,试了非常多方法都不行(若server未开启会卡在HttpResponse那),有人说高版本号的Android程序不同意在主线程中訪问网络(主线程中能够读写网络流)有待 ...

  7. 开启真机的View Server引入HierarchyViewer/By写monkeyrunner自动化测试脚本

    其实相关文章网上也有不少了,不过在真机上开启View Server的中文文章好像只有一篇,前段时间按照这篇文章的内容,并结合英文源文去hack我的Nexus S(4.1.2)也走了一点弯路.现在总结一 ...

  8. 【Linux基础】判断当前机器是虚拟机还是物理机

    1.使用dmidecode命令查看(root权限) DMI (Desktop Management Interface, DMI)的主要组成部分是Management InformationForma ...

  9. ESP32搭建2.虚拟机与物理机实现文件传输

    为后期操作方便,搭建实现虚拟机和物理机的文件直传. 1.     将安装好的虚拟机打开,点击VMware的虚拟机标签中的更新VMware Tools,等待一小会,虚拟CD盘中弹出文件 2.将压缩包Co ...

随机推荐

  1. 在Visual studio 2010中为C#的“///”注释内容生成XML文档 .

    实际上该方法适合于所有版本的Visual studio,方法很简单,设置一下Visual studio的项目属性和工具选项即可. 1.在菜单栏的“Project”中选择当前项目的“*** Proper ...

  2. Introducing “Razor” – a new view engine for ASP.NET

    原文发布时间为:2011-03-24 -- 来源于本人的百度文章 [由搬家工具导入] Razor :  cshtml扩展名,用@代替了那些复杂的“耳朵” <% %>  ne of the ...

  3. 【Visual Studio】Visual Studio 2010 "LNK1123: 转换到 COFF 期间失败: 文件无效或损坏" 的解决方法

    1.将 项目|项目属性|配置属性|连接器|清单文件|嵌入清单 “是”改为“否”. 2.找到 C:\Windows\winsxs\x86_netfx-cvtres_for_vc_and_vb_b03f5 ...

  4. LeetCode OJ--Linked List Cycle **

    https://oj.leetcode.com/problems/linked-list-cycle/ 判断一个链表是否为循环链表(这个链表可能是 1 2 3 4 然后4指向2) 巧妙的方法:设置两个 ...

  5. Codeforces Gym101522 A. Ambiguous Dates (La Salle-Pui Ching Programming Challenge 培正喇沙編程挑戰賽 2017)

    A. Ambiguous Dates There are two popular formats for representing a date: day/month/year or month/da ...

  6. Shell 括号辨识(转http://blog.csdn.net/taiyang1987912/article/details/39551385)

    一.小括号,圆括号() 1.单小括号 ()    ①命令组.括号中的命令将会新开一个子shell顺序执行,所以括号中的变量不能够被脚本余下的部分使用.括号中多个命令之间用分号隔开,最后一个命令可以没有 ...

  7. svn安装配置使用小总结

    1svn:版本控制系统服务端与客户端协作服务端:subversion客户端:eclipse_svn_site-1.10.5.zip插件1安装问题:    1subversion版本过高    会出现版 ...

  8. n!在k进制下的后缀0

    问n! 转化成k进制后的位数和尾数的0的个数.[UVA 10061 How many zeros and how many digits?] Given a decimal integer numbe ...

  9. 2018年东北农业大学春季校赛 B wyh的矩阵【找规律】

    链接:https://www.nowcoder.com/acm/contest/93/B来源:牛客网 题目描述 给你一个n*n矩阵,按照顺序填入1到n*n的数,例如n=5,该矩阵如下 1 2 3 4 ...

  10. Network | Cookie and Session

    Cookies are arbitrary pieces of data chosen by the web server and sent to the browser. The browser r ...