{"id":40828,"date":"2025-05-30T11:16:11","date_gmt":"2025-05-30T03:16:11","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/40828.html"},"modified":"2025-05-30T11:16:11","modified_gmt":"2025-05-30T03:16:11","slug":"linux%e8%bf%9b%e7%a8%8b%e6%a6%82%e5%bf%b5","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/40828.html","title":{"rendered":"Linux\u8fdb\u7a0b\u6982\u5ff5"},"content":{"rendered":"<h2>\u4e00.\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784<\/h2>\n<p>\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u662f\u5f53\u4ee3\u8ba1\u7b97\u673a\u7684\u57fa\u672c\u7ed3\u6784&#xff0c;\u5b83\u4e3b\u8981\u5305\u62ec\u51e0\u4e2a\u677f\u5757&#xff0c;<span style=\"color:#fe2c24\">\u8f93\u5165\u8bbe\u5907&#xff0c;\u8f93\u51fa\u8bbe\u5907&#xff0c;\u5b58\u50a8\u5668&#xff0c;\u8fd0\u7b97\u5668\u548c\u63a7\u5236\u5668\u3002<\/span><\/p>\n<p>\u4e0b\u9762\u662f\u7b80\u7565\u7248\u7684\u56fe\u89e3\u6790&#xff1a;<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031607-683922f7ebdc0.png\" \/><\/p>\n<p>\u8f93\u5165\u8bbe\u5907\u4e3b\u8981\u5305\u542b\u9f20\u6807&#xff0c;\u952e\u76d8&#xff0c;\u8bdd\u7b52\u7b49\u4e3b\u8981\u8fdb\u884c\u6570\u636e\u7684\u4f20\u8f93&#xff1b;\u5b58\u50a8\u5668\u5373\u5185\u5b58\u7528\u4e8e\u5c06\u63a5\u53d7\u8f93\u5165\u8bbe\u5907\u7684\u6570\u636e&#xff0c;\u4e3a\u6570\u636e\u8fdb\u884c\u6392\u961f\u540e\u4ea4\u7ed9CPU\u5904\u7406&#xff0c;\u5728CPU\u6570\u636e\u8fd4\u56de\u540e\u518d\u4f20\u7ed9\u8f93\u51fa\u8bbe\u5907&#xff0c;\u56e0\u6b64\u5185\u5b58\u662f\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u6700\u91cd\u8981\u7684\u90e8\u5206&#xff1b;\u63a5\u7740\u662fCPU&#xff0c;\u8fd0\u7b97\u5668\u548c\u63a7\u5236\u5668\u7ed3\u5408\u6784\u6210\u4e86CPU&#xff0c;\u8fd0\u7b97\u5668\u4e3b\u8981\u8d1f\u8d23\u8fdb\u884c\u4ee3\u7801\u7684\u903b\u8f91\u8fd0\u7b97\u548c\u7b97\u6570\u8fd0\u7b97&#xff0c;\u63a7\u5236\u5668\u4e3b\u8981\u8d1f\u8d23\u5bf9\u4ee3\u7801\u8fdb\u884c\u63a7\u5236&#xff1b;\u6700\u540e\u662f\u8f93\u51fa\u8bbe\u5907&#xff0c;\u4e3b\u8981\u662f\u663e\u793a\u5668&#xff0c;\u5587\u53ed\u7b49\u8d1f\u8d23\u6570\u636e\u7684\u8f93\u51fa\u3002<\/p>\n<p>\u4e3e\u4e2a\u4f8b\u5b50&#xff0c;\u5f53\u6211\u4eec\u4f7f\u7528\u5fae\u4fe1\u53d1\u4fe1\u606f\u7ed9\u670b\u53cb\u65f6&#xff0c;\u9996\u5148\u6211\u4eec\u5c06\u6587\u5b57\u901a\u8fc7\u952e\u76d8\u8bfb\u53d6\u5230\u5b58\u50a8\u5668\u4e2d&#xff0c;\u5b58\u50a8\u5668\u5c06\u6570\u636e\u4ea4\u7ed9CPU\u8fdb\u884c\u8fd0\u7b97\u5904\u7406&#xff0c;\u968f\u540e\u8fd4\u56de\u6570\u636e\u7ed9\u5b58\u50a8\u5668&#xff0c;\u6700\u540e\u5c06\u6570\u636e\u4f20\u7ed9\u8f93\u51fa\u8bbe\u5907\u7f51\u5361&#xff0c;\u4f60\u7684\u7f51\u5361\u5c06\u6570\u636e\u4f20\u5230\u4ed6\u7684\u7f51\u5361\u4e2d&#xff0c;\u4ed6\u7684\u7f51\u5361\u4f5c\u4e3a\u8f93\u5165\u8bbe\u5907\u5c06\u6570\u636e\u4f20\u7ed9\u4ed6\u7684\u5b58\u50a8\u5668\u8fdb\u884c\u5904\u7406\u540e\u8fd4\u56de\u6570\u636e\u5230\u4f60\u7684\u5c4f\u5e55\u4e0a&#xff0c;\u5b8c\u6210\u4e86\u4fe1\u606f\u4f20\u9012\u3002<\/p>\n<p>\u7efc\u4e0a\u6240\u8ff0&#xff0c;\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u4e2d&#xff0c;CPU\u5728\u6570\u636e\u5c42\u9762&#xff0c;\u4e0d\u4f1a\u548c\u5916\u8bbe\u6253\u4ea4\u9053&#xff0c;\u53ea\u4f1a\u548c\u5185\u5b58\u6253\u4ea4\u9053&#xff1b;\u5176\u4e2d\u6700\u91cd\u8981\u7684\u7ed3\u6784\u5c31\u662f\u5b58\u50a8\u5668\u7ed3\u6784&#xff0c;\u5b58\u50a8\u5668\u5904\u7406\u6570\u636e\u7684\u5feb\u6162\u51b3\u5b9a\u4e86\u8ba1\u7b97\u673a\u8fd0\u884c\u7684\u6548\u7387\u9ad8\u4f4e\u3002<\/p>\n<h2>\u4e8c.\u64cd\u4f5c\u7cfb\u7edf\u7684\u7406\u89e3<\/h2>\n<p>\u6709\u4e86\u4e0a\u8ff0\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u7684\u7406\u89e3&#xff0c;\u6211\u4eec\u53ef\u4ee5\u5f97\u77e5\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u5c31\u662f\u4e00\u5806\u7ba1\u7406\u6570\u636e\u5904\u7406\u6570\u636e\u7684\u786c\u4ef6&#xff0c;\u786c\u4ef6\u5728\u88f8\u673a\u64cd\u4f5c\u4e0a\u5b58\u5728\u590d\u6742\u6027\u4e0e\u5c40\u9650\u6027&#xff0c;\u56e0\u6b64\u6709\u4e86\u64cd\u4f5c\u7cfb\u7edf\u65b9\u4fbf\u4e0e\u66f4\u597d\u7684\u64cd\u4f5c\u8fd9\u5957\u4f53\u7cfb\u7ed3\u6784\u3002<span style=\"color:#fe2c24\">\u7528\u901a\u4fd7\u7684\u6bd4\u55bb\u6765\u8bf4&#xff0c;\u51af\u8bfa\u4f9d\u66fc\u662f\u4e00\u4e2a\u4eba\u7684\u8089\u4f53&#xff0c;\u90a3\u4e48\u64cd\u4f5c\u7cfb\u7edf\u5c31\u662f\u8fd9\u4e2a\u4eba\u7684\u7075\u9b42\u3002<\/span><\/p>\n<p>\u64cd\u4f5c\u7cfb\u7edf&#xff08;operator system&#xff09;\u5373OS&#xff0c;\u5206\u4e3a\u5916\u58f3\u548c\u5185\u6838\u3002\u5185\u6838\u4e3b\u8981\u662f\u63a7\u5236\u786c\u4ef6&#xff08;\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784&#xff09;&#xff0c;\u800c\u5916\u58f3\u4e3b\u8981\u662f\u7528\u4e8e\u4e0e\u7528\u6237\u8fdb\u884c\u4ea4\u4e92\u3002\u6240\u4ee5\u8bf4OS\u642d\u5efa\u8d77\u4e86\u6211\u4eec\u4eba\u4e0e\u5e95\u5c42\u786c\u4ef6\u4e4b\u95f4\u7684\u6865\u6881&#xff0c;\u8d77\u5230\u4e86\u627f\u4e0a\u542f\u4e0b\u7684\u4f5c\u7528\u3002<span style=\"color:#fe2c24\">\u5bf9\u4e0a&#xff0c;\u4e3a\u7528\u6237\u7a0b\u5e8f\u5f88\u597d\u7684\u4e0e\u7528\u6237\u8fdb\u884c\u4ea4\u4e92&#xff1b;\u5bf9\u4e0b&#xff0c;\u4e0e\u786c\u4ef6\u4ea4\u4e92&#xff0c;\u7ba1\u7406\u6240\u6709\u7684\u8f6f\u786c\u4ef6\u8d44\u6e90\u3002\u00a0<\/span><\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031608-683922f83c564.png\" \/><\/p>\n<p>\u5176\u4e2d\u7528\u6237\u90e8\u5206\u5c31\u5c5e\u4e8e\u5916\u58f3&#xff0c;\u7cfb\u7edf\u8f6f\u4ef6\u90e8\u5206\u4e3aLinux\u7684\u5185\u6838\u90e8\u5206\u3002<\/p>\n<p>\u4e0b\u9762\u6211\u4eec\u5c31\u6765\u8be6\u7ec6\u4ecb\u7ecdLinux\u7684\u5185\u6838\u90e8\u5206\u3002<\/p>\n<p>Linux\u5185\u6838\u662f\u4e00\u4e2a\u7ba1\u7406\u5e95\u5c42\u786c\u4ef6\u7684\u7ba1\u7406\u8005&#xff0c;\u7c7b\u4f3c\u4e8e\u516c\u53f8\u7684\u8001\u677f&#xff0c;\u8001\u677f\u901a\u5e38\u53ea\u53c2\u4e0e\u4e00\u4e9b\u51b3\u7b56\u6027\u7684\u5de5\u4f5c&#xff0c;\u7ed9\u8c01\u52a0\u85aa\u88c1\u54ea\u4e2a\u5458\u5de5\u7b49\u3002\u90a3\u4e48\u8001\u677f\u662f\u901a\u8fc7\u4ec0\u4e48\u6765\u5f97\u77e5\u8be5\u505a\u4ec0\u4e48\u51b3\u7b56\u5462&#xff1f;\u901a\u8fc7\u79d8\u4e66\u5bf9\u6bcf\u4e00\u4f4d\u5458\u5de5\u7684\u8868\u73b0\u8fdb\u884c\u6570\u636e\u5904\u7406\u5f97\u77e5\u3002\u90a3\u4e48&#xff0c;\u6211\u4eec\u53ef\u4ee5\u628a\u6bcf\u4e00\u4e2a\u786c\u4ef6\u62bd\u8c61\u4e3a\u6bcf\u4e00\u4e2a\u5458\u5de5&#xff0c;\u8001\u677f\u5219\u662fLinux\u5185\u6838\u64cd\u4f5c\u7cfb\u7edf&#xff0c;\u64cd\u4f5c\u7cfb\u7edf\u901a\u8fc7\u5bf9\u786c\u4ef6\u7684\u5404\u79cd\u63cf\u8ff0\u5bf9\u5176\u4f5c\u51fa\u76f8\u5e94\u51b3\u7b56\u3002\u800c\u63cf\u8ff0\u7684\u5185\u5bb9\u81ea\u7136\u9700\u8981\u7528\u6570\u636e\u7ed3\u6784\u8fdb\u884c\u5b58\u50a8\u3002<span style=\"color:#fe2c24\">\u6240\u4ee5\u8bf4&#xff0c;\u5728\u64cd\u4f5c\u7cfb\u7edf\u4e0a&#xff0c;\u6bcf\u4e00\u4e2a\u786c\u4ef6\u90fd\u53ef\u4ee5\u62bd\u8c61\u63cf\u8ff0\u6210\u4e00\u4e2a\u4e2astruct\u7ed3\u6784\u4f53&#xff0c;\u7531\u8001\u677f\u64cd\u4f5c\u7cfb\u7edf\u8fdb\u884c\u7ec4\u7ec7\u3002<\/span><\/p>\n<h2>\u4e09.\u8fdb\u7a0b<\/h2>\n<h3>3.1 \u8fdb\u7a0b\u57fa\u672c\u6982\u5ff5\u4e0e\u64cd\u4f5c<\/h3>\n<p>\u8fdb\u7a0b\u5c31\u662f\u7a0b\u5e8f\u6267\u884c\u7684\u4e00\u4e2a\u8fc7\u7a0b&#xff0c;\u7a0b\u5e8f\u6267\u884c\u9700\u8981\u8f6f\u786c\u4ef6\u7684\u8d44\u6e90\u4fe1\u606f&#xff0c;\u8fd9\u4e9b\u8d44\u6e90\u4fe1\u606f\u88ab\u50a8\u5b58\u5728PCB&#xff08;Process Control Block&#xff09;\u8fdb\u7a0b\u63a7\u5236\u5757\u4e2d\u3002\u5728Linux\u4e0b&#xff0c;\u8fdb\u7a0b\u63a7\u5236\u5757\u5c31\u662f&#xff1a;struct task_struct \u7684\u4e00\u4e2a\u7ed3\u6784\u4f53\u3002<span style=\"color:#fe2c24\">task_struct \u5bf9\u5305\u542b\u8fdb\u7a0b\u7684\u4fe1\u606f\u5bf9\u8fdb\u7a0b\u8fdb\u884c\u4e86\u63cf\u8ff0&#xff0c;\u901a\u8fc7\u5bf9task_struct\u7684\u589e\u5220\u67e5\u6539\u6765\u5bf9\u8fdb\u7a0b\u8fdb\u884c\u7ec4\u7ec7\u64cd\u4f5c\u3002<\/span><\/p>\n<p>\u90a3\u4e48task_struct\u91cc\u5e94\u5f53\u5305\u542b\u54ea\u4e9b\u5185\u5bb9\u5462&#xff1f;<\/p>\n<p style=\"text-align:center\">\u00a0<img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031608-683922f856136.png\" \/><\/p>\n<p>\u00a0\u6807\u8bc6\u7b26\u7528\u6765\u8bb0\u5f55\u5f53\u524d\u8fdb\u7a0b\u7684pid&#xff0c;\u7236\u8fdb\u7a0bppid&#xff0c;\u4ee5\u53ca\u7528\u6237uid\u4fe1\u606f&#xff08;\u540e\u7eed\u8be6\u7ec6\u8bb2\u89e3&#xff09;\u3002\u8fdb\u7a0b\u7684\u72b6\u6001&#xff0c;\u4f8b\u5982\u8fd0\u884c&#xff0c;\u963b\u585e&#xff0c;\u7ec8\u6b62\u7b49\u3002\u4f18\u5148\u7ea7\u5c31\u662f\u6bcf\u4e2a\u8fdb\u7a0b\u90fd\u6709\u81ea\u5df1\u7684\u4f18\u5148\u7ea7\u7cfb\u6570&#xff0c;\u4f18\u5148\u7ea7\u9ad8\u7684\u4f1a\u5148\u6267\u884c\u3002\u7a0b\u5e8f\u8ba1\u6570\u5668\u5c31\u662f\u5f53\u8be5\u8fdb\u7a0b\u6682\u65f6\u6302\u8d77\u65f6&#xff0c;\u4f1a\u5148\u5c06\u4ee3\u7801\u5b58\u50a8\u5230\u5bc4\u5b58\u5668\u4e2d&#xff0c;\u5f53\u518d\u6b21\u8fd0\u884c\u5230\u8be5\u7a0b\u5e8f\u65f6&#xff0c;\u901a\u8fc7\u5730\u5740\u5c31\u80fd\u518d\u6b21\u627e\u56de\u3002\u5185\u5b58\u7ba1\u7406\u4fe1\u606f&#xff0c;\u91cc\u9762\u50a8\u5b58\u4ee3\u7801\u6bb5&#xff0c;\u6570\u636e\u6bb5&#xff0c;\u5806\u6808\u4e0a\u7684\u4fe1\u606f&#8230;&#8230;&#8230;&#8230;.<\/p>\n<p>\u90a3\u4e48\u8be5\u5982\u4f55\u67e5\u770b\u8fdb\u7a0b\u5462&#xff1f;<\/p>\n<p><span style=\"color:#fe2c24\">\u901a\u8fc7\u6307\u4ee4 ls \/proc\u00a0 \u53ef\u4ee5\u67e5\u770b\u7cfb\u7edf\u6587\u4ef6\u7684\u6240\u6709\u8fdb\u7a0b\u3002<\/span>\u8fd9\u91cc\u6211\u4eec\u5199\u4e86\u4e00\u4e2a\u6587\u4ef6\u7528\u4e8e\u8f93\u51fa\u5f53\u524d\u8fdb\u7a0b\u7684pid\u5e76\u4e14\u65e0\u9650\u5faa\u73af\u3002<\/p>\n<p style=\"text-align:center\"><img loading=\"lazy\" decoding=\"async\" alt=\"\" class=\"left\" height=\"252\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031608-683922f879a6d.png\" width=\"286\" \/><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"236\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031608-683922f892a9a.png\" width=\"329\" \/>\u00a0<\/p>\n<p>\u00a0\u5982\u56fe\u5f53\u524d\u8fdb\u7a0b\u7684pid\u4e3a109988\u00a0 \u00a0<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031608-683922f8ac084.png\" \/><\/p>\n<p>\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7 ls \/proc \u5728\u7cfb\u7edf\u4e2d\u67e5\u8be2\u5230\u3002\u5f53\u8fdb\u7a0b\u7ed3\u675f\u65f6&#xff0c;\u5c31\u65e0\u6cd5\u67e5\u8be2\u5230\u5f53\u524d\u8fdb\u7a0b \u3002<\/p>\n<p>\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7\u00a0 ps\u00a0 aux\u00a0 |\u00a0 \u00a0grep\u00a0 &#043;\u00a0 \u00a0\u6587\u4ef6\u7684\u65b9\u5f0f\u67e5\u770b\u7279\u5b9a\u6587\u4ef6\u7684\u8fdb\u7a0b\u3002<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031608-683922f8bf17d.png\" \/><\/p>\n<p>\u5f53\u8fdb\u7a0b\u8fd0\u884c\u65f6\u4ecePCB\u4e0a\u83b7\u53d6\u8be5\u8fdb\u7a0b\u7684pid\u3002<\/p>\n<h3>3.2 \u8fdb\u7a0b\u72b6\u6001\u00a0<\/h3>\n<p>\u4ec0\u4e48\u662f\u8fdb\u7a0b\u72b6\u6001&#xff1f;\u8fdb\u7a0b\u72b6\u6001\u6709\u4ec0\u4e48\u7528&#xff1f;<\/p>\n<p>\u8fdb\u7a0b\u72b6\u6001\u901a\u4fd7\u8bb2\u7c7b\u4f3c\u4e8e\u6211\u4eec\u5de5\u4f5c\u4e0a\u73ed&#xff0c;\u6709\u5de5\u4f5c&#xff0c;\u4f11\u606f&#xff0c;\u6709\u4e8b\u5916\u51fa\u7b49\u4e0d\u540c\u7684\u72b6\u6001\u3002\u8fdb\u7a0b\u4e5f\u662f\u540c\u7406&#xff0c;\u4f1a\u6709\u8fd0\u884c&#xff0c;\u5c31\u7eea&#xff0c;\u6302\u8d77&#xff0c;\u7ec8\u6b62\u7b49\u72b6\u6001\u3002<span style=\"color:#fe2c24\">\u5728PCB\u4e2d&#xff0c;\u6211\u4eec\u7528\u4e0d\u540c\u7684\u6570\u5b57\u6765\u8868\u793a\u4e0d\u540c\u7684\u72b6\u6001&#xff0c;\u53cd\u4e4b\u5185\u5b58\u901a\u8fc7\u4e0d\u540c\u7684\u6570\u5b57\u5c31\u80fd\u8bc6\u522b\u51fa\u5f53\u524d\u8fdb\u7a0b\u7684\u5404\u79cd\u72b6\u6001\u4f5c\u51fa\u4e0d\u540c\u7684\u8fd0\u7b97\u5904\u7406\u3002<\/span><\/p>\n<p>\u4e0b\u9762\u653e\u4e0a\u4e00\u5f20\u8fdb\u7a0b\u72b6\u6001\u56fe&#xff1a;<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031608-683922f8d0e4c.png\" \/><\/p>\n<p>\u8fdb\u7a0b\u5728\u521d\u59cb\u9636\u6bb5\u5206\u914d\u8d44\u6e90\u521b\u5efa\u53d8\u91cf\u65f6\u4e3a<span style=\"color:#fe2c24\">\u521b\u5efa\u72b6\u6001<\/span>&#xff0c;\u8fdb\u7a0b\u521b\u5efa\u597d\u4e86&#xff0c;CPU\u8fd0\u884c\u5f53\u524d\u8fdb\u7a0b\u5c5e\u4e8e<span style=\"color:#fe2c24\">\u8fd0\u884c\u72b6\u6001<\/span>&#xff1b;\u800c\u5176\u4ed6\u8fdb\u7a0b\u6392\u961f\u7b49\u5f85\u524d\u9762\u7684\u8fdb\u7a0b\u8fd0\u884c\u5b8c\u6bd5\u53eb\u505a<span style=\"color:#fe2c24\">\u5c31\u7eea\u72b6\u6001<\/span>&#xff1b;\u5f53\u6211\u4eec\u9700\u8981\u5bf9\u952e\u76d8\u8f93\u5165\u6570\u636e\u65f6&#xff0c;\u8fdb\u7a0b\u8fdb\u5165<span style=\"color:#fe2c24\">\u963b\u585e\u72b6\u6001<\/span>&#xff0c;\u5f53\u8f93\u5165\u5b8c\u6210\u540e\u53c8\u91cd\u65b0\u8fdb\u5165<span style=\"color:#fe2c24\">\u5c31\u7eea\u72b6\u6001<\/span>&#xff1b;\u8fd0\u884c\u5b8c\u6210\u540e\u7ed3\u675f\u3002<\/p>\n<p>\u8fdb\u7a0b\u8fd0\u884c\u65f6task_struct\u8fdb\u5165\u961f\u5217\u4e2d&#xff0c;\u5728\u6392\u961f\u7684\u8fc7\u7a0b\u5904\u4e8e\u5c31\u7eea\u72b6\u6001&#xff1b;\u5f53\u9700\u8981\u8fdb\u7a0b\u8fdb\u5165\u963b\u585e\u72b6\u6001\u65f6&#xff0c;\u4ee3\u7801\u548c\u6570\u636e\u4ecd\u4f1a\u5728\u5185\u5b58\u4e2d\u4fdd\u7559&#xff0c;\u82e5\u6b64\u65f6\u5185\u5b58\u7a7a\u95f4\u4e0d\u8db3\u65f6&#xff0c;\u4f1a\u5c06task_struct\u4e2d\u7684\u4ee3\u7801\u548c\u6570\u636e\u8fc1\u79fb\u5230\u78c1\u76d8\u4e2d&#xff0c;\u8fdb\u5165\u6302\u8d77\u72b6\u6001\u3002\u76f4\u5230\u5b8c\u6210\u8f93\u5165\u540e\u624d\u4f1a\u91cd\u65b0\u8fdb\u5165\u5c31\u7eea\u72b6\u6001\u3002<\/p>\n<p>\u4e0b\u9762\u662fLinux\u6e90\u7801\u4e2d\u7684\u4e0d\u540c\u72b6\u6001<\/p>\n<p>  <span style=\"color:#986801\">static const char <\/span><br \/>\n  <span style=\"color:#2b2f36\">*<\/span><br \/>\n  <span style=\"color:#986801\">const <\/span><br \/>\n  <span style=\"color:#2b2f36\">task_state_array[] &#061; { <\/span> <\/p>\n<p>  <span style=\"color:#50a14f\">&#034;R (running)&#034;<\/span><br \/>\n  <span style=\"color:#2b2f36\">, <\/span><br \/>\n  <span style=\"color:#a0a1a7\">\/*0 *\/ <\/span> <\/p>\n<p>  <span style=\"color:#50a14f\">&#034;S (sleeping)&#034;<\/span><br \/>\n  <span style=\"color:#2b2f36\">, <\/span><br \/>\n  <span style=\"color:#a0a1a7\">\/*1 *\/ <\/span> <\/p>\n<p>  <span style=\"color:#50a14f\">&#034;D (disk sleep)&#034;<\/span><br \/>\n  <span style=\"color:#2b2f36\">, <\/span><br \/>\n  <span style=\"color:#a0a1a7\">\/*2 *\/ <\/span> <\/p>\n<p>  <span style=\"color:#50a14f\">&#034;T (stopped)&#034;<\/span><br \/>\n  <span style=\"color:#2b2f36\">, <\/span><br \/>\n  <span style=\"color:#a0a1a7\">\/*4 *\/ <\/span> <\/p>\n<p>  <span style=\"color:#50a14f\">&#034;t (tracing stop)&#034;<\/span><br \/>\n  <span style=\"color:#2b2f36\">, <\/span><br \/>\n  <span style=\"color:#a0a1a7\">\/*8 *\/ <\/span> <\/p>\n<p>  <span style=\"color:#50a14f\">&#034;X (dead)&#034;<\/span><br \/>\n  <span style=\"color:#2b2f36\">, <\/span><br \/>\n  <span style=\"color:#a0a1a7\">\/*16 *\/ <\/span> <\/p>\n<p>  <span style=\"color:#50a14f\">&#034;Z (zombie)&#034;<\/span><br \/>\n  <span style=\"color:#2b2f36\">, <\/span><br \/>\n  <span style=\"color:#a0a1a7\">\/*32 *\/ <\/span> <\/p>\n<p>  <span style=\"color:#2b2f36\">};<\/span> <\/p>\n<p>\u00a0<span style=\"color:#fe2c24\">running<\/span> \u5bf9\u5e94\u5c31\u7eea\u72b6\u6001\u8fd0\u884c\u72b6\u6001&#xff1b;<span style=\"color:#fe2c24\">sleeping<\/span> \u4e3a\u7761\u7720\u72b6\u6001&#xff0c;\u5bf9\u5e94\u4e8e\u963b\u585e\u72b6\u6001&#xff0c;\u4f8b\u5982\u9700\u8981\u6570\u636e\u8f93\u5165\u7b49&#xff0c;\u6b64\u65f6\u8fdb\u7a0b\u662f\u53ef\u4ee5\u88ab\u5524\u9192\u7684&#xff1b;<span style=\"color:#fe2c24\">disk sleep <\/span>\u6df1\u5ea6\u7761\u7720\u72b6\u6001&#xff0c;\u6b64\u65f6\u8fdb\u7a0b\u65e0\u6cd5\u88ab\u5524\u9192&#xff0c;\u6570\u636e\u5b58\u50a8\u5728\u78c1\u76d8\u4e2d&#xff1b;<span style=\"color:#fe2c24\">stopped <\/span>\u72b6\u6001&#xff0c;\u6b64\u65f6\u8fdb\u7a0b\u505c\u6b62\u8fd0\u884c&#xff0c;\u8fdb\u7a0b\u7684\u4e0a\u4e0b\u6587\u4f1a\u88ab\u4fdd\u5b58\u8d77\u6765&#xff0c;\u9700\u8981\u5916\u90e8\u4fe1\u53f7\u91cd\u65b0\u5f00\u59cb&#xff1b;<span style=\"color:#fe2c24\">tracing stop<\/span> \u5f53\u5185\u5b58\u8d44\u6e90\u4e0d\u8db3\u65f6&#xff0c;\u4f1a\u5f3a\u884c\u7ec8\u6b62\u8fdb\u7a0b\u8fd0\u884c\u3002<span style=\"color:#fe2c24\">zombie<\/span>\u72b6\u6001&#xff0c;\u4e3a\u50f5\u5c38\u72b6\u6001&#xff0c;\u5f53\u5b50\u8fdb\u7a0b\u7ed3\u675f\u540e&#xff0c;<span style=\"color:#fe2c24\">\u7236\u8fdb\u7a0b\u6ca1\u6709\u5bf9\u5b50\u8fdb\u7a0b\u72b6\u6001\u8fdb\u884c\u8bfb\u53d6<\/span>&#xff0c;\u5b50\u8fdb\u7a0b\u8fdb\u5165\u50f5\u5c38\u8fdb\u7a0b&#xff0c;\u7c7b\u4f3c\u4e8e\u8c03\u7528\u4e86\u8d44\u6e90\u786e\u6ca1\u6709\u56de\u6536\u4ea7\u751f\u5185\u5b58\u6cc4\u6f0f\u3002<\/p>\n<p>\u4e0e\u50f5\u5c38\u8fdb\u7a0b\u7c7b\u4f3c\u7684<span style=\"color:#fe2c24\">\u5b64\u513f\u8fdb\u7a0b<\/span>&#xff0c;\u5b64\u513f\u8fdb\u7a0b\u5c31\u662f\u7236\u8fdb\u7a0b\u5148\u9000\u51fa\u7684\u60c5\u51b5&#xff0c;<span style=\"color:#fe2c24\">\u6b64\u65f6\u5b50\u8fdb\u7a0b\u65e0\u6cd5\u88ab\u56de\u6536&#xff0c;\u5c31\u4f1a\u75311\u53f7\u8fdb\u7a0b\u8fdb\u884c\u9886\u517b\u56de\u6536\u3002<\/span><\/p>\n<h3>3.3 \u8fdb\u7a0b\u4f18\u5148\u7ea7\u00a0<\/h3>\n<p>CPU\u8d44\u6e90\u5206\u914d\u7684\u5148\u540e\u987a\u5e8f&#xff0c;\u5c31\u662f\u8fdb\u7a0b\u7684\u4f18\u5148\u6743\u3002\u4f18\u5148\u6743\u9ad8\u7684\u53ef\u4ee5\u5148\u6267\u884c&#xff0c;\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7 ps -l \u7684\u6307\u4ee4\u6765\u67e5\u770b\u7cfb\u7edf\u8fdb\u7a0b&#xff0c;\u5176\u4e2dPRI\u4e3a\u4f18\u5148\u7ea7&#xff0c;NI\u4e3anice\u503c&#xff0c;nice\u503c\u548cPRI\u7684\u548c\u5c31\u662f\u6700\u7ec8\u7684\u4f18\u5148\u7ea7\u5927\u5c0f\u3002\u8fd9\u4e2a\u6570\u8d8a\u5c0f&#xff0c;\u7a0b\u5e8f\u6267\u884c\u7684\u8d8a\u65e9\u3002<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031609-683922f905fd7.png\" \/><\/p>\n<p>\u00a0nice\u503c\u7684\u53d6\u503c\u8303\u56f4\u5728-19 \u5230 20\u4e4b\u95f4&#xff0c;\u4e00\u517140\u4e2a\u6863\u4f4d\u3002<\/p>\n<p>\u8fdb\u7a0b\u8fd0\u884c\u6709\u5e76\u53d1\u548c\u5e76\u884c\u4e24\u79cd\u6a21\u5f0f&#xff0c;\u5e76\u53d1\u5c31\u662f\u540c\u65f6\u53d1\u751f&#xff0c;\u901a\u8fc7CPU\u4e0d\u505c\u7684\u5207\u6362\u8fdb\u7a0b\u4f7f\u8fdb\u7a0b\u540c\u65f6\u8fd0\u884c&#xff1b;\u5e76\u884c\u5c31\u662f\u5171\u540c\u8fd0\u884c&#xff0c;\u6709\u4e24\u4e2a\u6216\u4ee5\u4e0a\u7684CPU\u540c\u65f6\u5904\u7406\u3002<\/p>\n<p>\u5728\u5e76\u53d1\u60c5\u51b5\u4e0b&#xff0c;\u6bcf\u4e2a\u8fdb\u7a0b\u90fd\u6709\u81ea\u5df1\u5bf9\u5e94\u7684\u65f6\u95f4\u7247&#xff0c;\u65f6\u95f4\u7247\u6d88\u8017\u5b8c\u5c31\u4f1a\u5207\u6362\u8fdb\u7a0b&#xff0c;\u800c\u5f53\u524d\u8fdb\u7a0b\u7684\u4e0a\u4e0b\u6587\u6570\u636e\u5c31\u4f1a\u6682\u65f6\u4fdd\u5b58&#xff08;\u62f7\u8d1d&#xff09;\u5728CPU\u7684\u5bc4\u5b58\u5668\u5f53\u4e2d&#xff0c;\u5f53\u4e0b\u4e00\u6b21\u8fd0\u884c\u5230\u8be5\u8fdb\u7a0b\u65f6\u518d\u62ff\u51fa\u6765\u3002<\/p>\n<h3>3.4 \u8fdb\u7a0b\u8c03\u5ea6<\/h3>\n<p>\u8fdb\u7a0b\u8c03\u5ea6\u7531\u8fdb\u7a0b\u7684\u4f18\u5148\u7ea7\u548c\u72b6\u6001\u51b3\u5b9a&#xff0c;\u5728Linux\u4e2d\u8fdb\u7a0b\u8c03\u5ea6\u6709\u8fdb\u7a0b\u8c03\u5ea6\u961f\u5217 run_queue \u7ba1\u7406\u4fe1\u606f\u3002\u961f\u5217\u91cc\u5305\u542b\u5404\u4e2a\u8fdb\u7a0btask_struct\u7684\u5730\u5740\u6307\u9488&#xff0c;\u7528\u4e8e\u8bc6\u522b\u8be5\u8fdb\u7a0b\u7684\u4f18\u5148\u7ea7\u4ee5\u53ca\u72b6\u6001\u3002<\/p>\n<p>run_queue\u4e2d\u7684\u4e09\u4e2a\u53c2\u6570 nr_active &#xff0c;bitmap\u30105\u3011&#xff0c;queue\u3010140\u3011\u3002nr_active\u662f\u6307\u9488&#xff0c;queue\u961f\u5217\u7528\u6765\u5b58\u50a8\u4e0d\u540c\u4f18\u5148\u7ea7\u7684\u8fdb\u7a0b\u6307\u9488\u5730\u5740&#xff0c;\u6570\u5b57\u4e0b\u6807\u5c31\u5bf9\u5e94\u4e86\u5b83\u7684\u4f18\u5148\u7ea7\u7cfb\u6570&#xff1b;\u800cbitmap\u4f4d\u56fe\u5c31\u662f\u8bb0\u5f55\u4e0d\u540c\u7684\u4f18\u5148\u7ea7\u4e0b\u662f\u5426\u5b58\u5728\u6709\u8fdb\u7a0b\u3002\u8fd9\u6837\u5c31\u5bf9\u8fdb\u7a0b\u8fdb\u884c\u4e86\u6392\u961f\u64cd\u4f5c&#xff0c;\u6b64\u65f6\u6211\u4eec\u518d\u6765\u4e00\u5957\u8fd9\u6837\u7684\u7ed3\u6784&#xff0c;\u5c06\u8fd0\u884c\u5b8c\u7684\u8fdb\u7a0b\u653e\u5165\u7b2c\u4e8c\u4e2a\u7ed3\u6784\u4e2d\u8fdb\u884c\u6392\u961f\u64cd\u4f5c&#xff0c;\u5f53\u7b2c\u4e00\u4e2a\u7ed3\u6784\u4e2d\u7684\u8fdb\u7a0b\u5168\u90e8\u8fd0\u884c\u5b8c\u6210\u540e&#xff0c;\u5c06\u4e24\u8005\u7684nr_active\u6307\u9488\u5185\u5bb9\u4e92\u6362&#xff0c;\u8fd9\u6837\u5c31\u5b8c\u6210\u4e86\u6392\u961f\u3002<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031609-683922f91427c.png\" \/><\/p>\n<h2>\u56db. \u73af\u5883\u53d8\u91cf<\/h2>\n<p>\u73af\u5883\u53d8\u91cf\u662f\u64cd\u4f5c\u7cfb\u7edf\u7279\u5b9a\u7528\u9014\u7684\u53d8\u91cf&#xff0c;\u8fd9\u4e9b\u4fe1\u606f\u53ef\u4ee5\u88ab\u64cd\u4f5c\u7cfb\u7edf\u3001\u5e94\u7528\u7a0b\u5e8f\u6216\u7528\u6237\u8fdb\u7a0b\u8bbf\u95ee\u548c\u4f7f\u7528&#xff0c;\u4ee5\u5f71\u54cd\u8f6f\u4ef6\u7684\u8fd0\u884c\u884c\u4e3a\u3001\u8def\u5f84\u67e5\u627e\u3002\u5e38\u89c1\u7684\u73af\u5883\u53d8\u91cf\u6709 <span style=\"color:#fe2c24\">PATH \u7cfb\u7edf\u8fd0\u884c\u65f6\u67e5\u627e\u53ef\u6267\u884c\u6587\u4ef6\u7684\u8def\u5f84<\/span>&#xff1b;<span style=\"color:#fe2c24\">HOME \u5f53\u524d\u7528\u6237\u7684\u4e3b\u76ee\u5f55<\/span>&#xff0c;\u5e38\u7528\u4e8e\u9ed8\u8ba4\u8def\u5f84&#xff1b;<span style=\"color:#fe2c24\">USER \u5f53\u524d\u64cd\u4f5c\u4eba<\/span>&#xff1b;<span style=\"color:#fe2c24\">PWD \u5f53\u524d\u76ee\u5f55<\/span>\u3002<\/p>\n<p>\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7<span style=\"color:#fe2c24\"> echo &#043; $\u53d8\u91cf\u540d<\/span> \u6765\u67e5\u8be2\u5230\u73af\u5883\u53d8\u91cf\u5728\u54ea\u4e2a\u76ee\u5f55\u4e0b\u3002<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031609-683922f93765e.png\" \/><\/p>\n<p><span style=\"color:#fe2c24\">env <\/span>\u53ef\u4ee5\u67e5\u8be2\u5230\u5f53\u524d\u7cfb\u7edf\u4e2d\u6240\u6709\u7684\u73af\u5883\u53d8\u91cf\u3002<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031609-683922f94c4b7.png\" \/><\/p>\n<p><span style=\"color:#fe2c24\">set \u548c unse<\/span>t \u662f\u7528\u4e8e\u8bbe\u7f6e\u548c\u6e05\u9664\u73af\u5883\u53d8\u91cf\u7684\u64cd\u4f5c &#xff0c;unset \u5220\u9664\u540e\u7684\u73af\u5883\u53d8\u91cf\u91cd\u542f\u540e\u4ecd\u4f1a\u5b58\u5728\u3002<\/p>\n<p>\u73af\u5883\u53d8\u91cf\u662f\u7528\u4e8e\u63cf\u8ff0\u7cfb\u7edf\u73af\u5883\u7684&#xff0c;\u800c\u73af\u5883\u8868\u662f\u5c06\u73af\u5883\u7ec4\u7ec7\u8d77\u6765\u7684\u6570\u636e\u7ed3\u6784\u3002\u73af\u5883\u8868\u4e2d\u5305\u542b\u4e86\u5404\u4e2a\u73af\u5883\u53d8\u91cf\u7684\u952e\u503c&#xff0c;\u901a\u8fc7\u952e\u503c\u67e5\u627e\u5c31\u80fd\u627e\u5230\u8be5\u73af\u5883\u53d8\u91cf\u3002\u73af\u5883\u8868\u4f1a\u4ece\u7236\u8fdb\u7a0b\u4e0a\u7ee7\u627f\u5230\u5b50\u8fdb\u7a0b\u4e0a\u3002<\/p>\n<h2>\u4e94. \u7a0b\u5e8f\u5730\u5740\u7a7a\u95f4&#xff08;\u865a\u62df\u5730\u5740\u7a7a\u95f4&#xff09;<\/h2>\n<p>\u00a0\u6211\u4eec\u5148\u6765\u770b\u4e00\u4e0b\u7a0b\u5e8f\u5730\u5740\u7a7a\u95f4\u662f\u5982\u4f55\u5206\u5e03\u7684\u3002<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031609-683922f9ba494.png\" \/><\/p>\n<p>\u6211\u4eec\u901a\u8fc7\u4ee3\u7801\u6765\u67e5\u770b\u4e00\u4e0b\u5730\u5740\u4fe1\u606f\u3002<\/p>\n<p> #include &lt;stdio.h&gt;<br \/>\n#include &lt;unistd.h&gt;<br \/>\n#include &lt;stdlib.h&gt;<br \/>\nint g_unval;<br \/>\nint g_val &#061; 100;<br \/>\nint main(int argc, char* argv[], char* env[])<br \/>\n{<br \/>\nconst char* str &#061; &#034;helloworld&#034;;<br \/>\nprintf(&#034;code addr: %p\\\\n&#034;, main);<br \/>\nprintf(&#034;init global addr: %p\\\\n&#034;, &amp;g_val);<br \/>\nprintf(&#034;uninit global addr: %p\\\\n&#034;, &amp;g_unval);<br \/>\nstatic int test &#061; 10;<br \/>\nchar* heap_mem &#061; (char*)malloc(10);<br \/>\nchar* heap_mem1 &#061; (char*)malloc(10);<br \/>\nchar* heap_mem2 &#061; (char*)malloc(10);<br \/>\nchar* heap_mem3 &#061; (char*)malloc(10);<br \/>\nprintf(&#034;heap addr: %p\\\\n&#034;, heap_mem); \/\/heap_mem(0), &amp;heap_mem(1)<br \/>\nprintf(&#034;heap addr: %p\\\\n&#034;, heap_mem1); \/\/heap_mem(0), &amp;heap_mem(1)<br \/>\n    printf(&#034;heap addr: %p\\\\n&#034;, heap_mem2); \/\/heap_mem(0), &amp;heap_mem(1)<br \/>\nprintf(&#034;heap addr: %p\\\\n&#034;, heap_mem3); \/\/heap_mem(0), &amp;heap_mem(1)<br \/>\n    printf(&#034;test static addr: %p\\\\n&#034;, &amp;test); \/\/heap_mem(0), &amp;heap_mem(1)<br \/>\nprintf(&#034;stack addr: %p\\\\n&#034;, &amp;heap_mem); \/\/heap_mem(0), &amp;heap_mem(1)<br \/>\nprintf(&#034;stack addr: %p\\\\n&#034;, &amp;heap_mem1); \/\/heap_mem(0), &amp;heap_mem(1)<br \/>\nprintf(&#034;stack addr: %p\\\\n&#034;, &amp;heap_mem2); \/\/heap_mem(0), &amp;heap_mem(1)<br \/>\nprintf(&#034;stack addr: %p\\\\n&#034;, &amp;heap_mem3); \/\/heap_mem(0), &amp;heap_mem(1)<\/p>\n<p>printf(&#034;read only string addr: %p\\\\n&#034;, str);<br \/>\nfor (int i &#061; 0; i &lt; argc; i&#043;&#043;)<br \/>\n{<br \/>\nprintf(&#034;argv[%d]: %p\\\\n&#034;, i, argv[i]);<br \/>\n}<br \/>\nfor (int i &#061; 0; env[i]; i&#043;&#043;)<br \/>\n{<br \/>\n printf(&#034;env[%d]: %p\\\\n&#034;, i, env[i]);<br \/>\n}<br \/>\nreturn 0;<br \/>\n} <\/p>\n<p>\u4e0b\u9762\u662f\u8fd0\u884c\u7ed3\u679c&#xff1a;<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031609-683922f9d0dd9.png\" \/>\u00a0<\/p>\n<p>\u00a0\u6211\u4eec\u53ef\u4ee5\u901a\u8fc7\u8fd0\u884c\u4ee3\u7801\u7ed3\u679c\u6765\u53cd\u63a8\u7a0b\u5e8f\u5730\u5740\u7a7a\u95f4\u7684\u6b63\u786e\u6027\u3002<\/p>\n<p>\u6211\u4eec\u53ef\u4ee5\u89c2\u5bdf\u51fa\u53d8\u91cf\u5730\u5740 <span style=\"color:#fe2c24\">\u5df2\u521d\u59cb\u5316\u53d8\u91cf &lt; \u672a\u521d\u59cb\u5316\u53d8\u91cf &lt; \u5806 &lt; \u6808 &lt; \u73af\u5883\u53d8\u91cf<\/span>\u00a0&#xff0c;\u5176\u4e2d\u5728\u5806\u4e0e\u6808\u4e4b\u95f4\u5730\u5740\u9ad8\u5ea6\u76f8\u5dee\u8f83\u5927&#xff0c;\u8fd9\u6bb5\u7a7a\u95f4\u5c31\u662f\u6211\u4eec\u7684\u5171\u4eab\u533a\u3002\u56e0\u6b64\u6211\u4eec\u7684\u5806\u548c\u6808\u662f<span style=\"color:#fe2c24\">\u76f8\u5bf9\u800c\u751f<\/span>\u7684&#xff0c;\u5806\u4ece\u4f4e\u5730\u5740\u5411\u9ad8\u5730\u5740\u7d2f\u52a0&#xff0c;\u6808\u4ece\u9ad8\u5730\u5740\u5411\u4f4e\u5730\u5740\u6302\u8d77\u3002<\/p>\n<p>\u4e0b\u9762\u6211\u4eec\u518d\u6765\u770b\u4e00\u7ec4\u4ee3\u7801<\/p>\n<p> #include &lt;stdio.h&gt;<br \/>\n#include &lt;unistd.h&gt;<br \/>\n#include &lt;stdlib.h&gt;<br \/>\nint g_val &#061; 0;<br \/>\nint main()<br \/>\n{<br \/>\npid_t id &#061; fork();<br \/>\nif(id &lt; 0){<br \/>\nperror(&#034;fork&#034;);<br \/>\nreturn 0;<br \/>\n}<br \/>\nelse if(id &#061;&#061; 0){ \/\/child,\u2f26\u8fdb\u7a0b\u80af\u5b9a\u5148\u8dd1\u5b8c&#xff0c;\u4e5f\u5c31\u662f\u2f26\u8fdb\u7a0b\u5148\u4fee\u6539&#xff0c;\u5b8c\u6210\u4e4b\u540e&#xff0c;\u2f57\u8fdb\u7a0b\u518d<br \/>\n\u8bfb\u53d6<br \/>\ng_val&#061;100;<br \/>\nprintf(&#034;child[%d]: %d : %p\\\\n&#034;, getpid(), g_val, &amp;g_val);<br \/>\n}else{ \/\/parent<br \/>\nsleep(3);<br \/>\nprintf(&#034;parent[%d]: %d : %p\\\\n&#034;, getpid(), g_val, &amp;g_val);<br \/>\n}<br \/>\nsleep(1);<br \/>\nreturn 0;<br \/>\n} <\/p>\n<p style=\"text-align:center\"><img loading=\"lazy\" decoding=\"async\" alt=\"\" height=\"107\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031609-683922f9e6553.png\" width=\"597\" \/><\/p>\n<p>\u00a0\u6211\u4eec\u53d1\u73b0\u7236\u5b50\u8fdb\u7a0b\u8f93\u51fa\u7684\u5730\u5740\u662f\u4e00\u81f4\u7684&#xff0c;\u4f46\u662f\u8f93\u51fa\u7684\u53d8\u91cf\u786e\u4e0d\u4e00\u6837&#xff0c;\u8fd9\u662f\u4e3a\u4ec0\u4e48\u5462&#xff1f;<\/p>\n<p>\u8bf4\u660e\u8f93\u51fa\u7684\u53d8\u91cf\u5e76\u4e0d\u662f\u540c\u4e00\u4e2a\u53d8\u91cf&#xff0c;\u5b83\u4eec\u5728\u7269\u7406\u7a7a\u95f4\u4e0a\u7684\u5730\u5740\u4e0d\u4e00\u6837\u3002\u56e0\u6b64&#xff0c;\u5e76\u4e0d\u5b58\u5728\u6240\u8c13\u7684\u7a0b\u5e8f\u5730\u5740\u7a7a\u95f4&#xff0c;\u5728Linux\u4e0b&#xff0c;\u88ab\u79f0\u4e3a\u865a\u62df\u5730\u5740\u7a7a\u95f4\u3002<\/p>\n<p>\u5728\u865a\u62df\u5730\u5740\u7a7a\u95f4\u4e0a&#xff0c;\u6bcf\u4e2a\u8fdb\u7a0b\u90fd\u88ab\u8bb8\u8bfa\u6709\u53ef\u4ee5\u4f7f\u7528\u5185\u5b58\u5927\u5c0f\u7684\u7a7a\u95f4&#xff0c;\u4f46\u5b9e\u9645\u4e0a\u5e76\u4e0d\u4f1a\u7528\u5230\u8fd9\u4e48\u591a\u7684\u7a7a\u95f4\u3002\u4e0d\u540c\u8fdb\u7a0b\u4e4b\u95f4\u5373\u4f7f\u865a\u62df\u5730\u5740\u540d\u4e00\u81f4&#xff0c;\u4f46\u5b83\u4eec\u5728<span style=\"color:#fe2c24\">\u5e95\u5c42\u7684\u7269\u7406\u5730\u5740\u5e76\u4e0d\u662f\u540c\u4e00\u5757<\/span>&#xff0c;\u8fd9\u6837\u5373\u4f7f\u8fdb\u7a0b\u4e0d\u540c&#xff0c;\u4e5f\u4e0d\u4f1a\u5f71\u54cd\u5404\u4e2a\u8fdb\u7a0b\u4f7f\u7528\u81ea\u5df1\u7684\u5730\u5740\u7a7a\u95f4\u3002\u5728task_struct\u4e2d\u5b58\u5728\u4e00\u4e2a\u6210\u5458\u53d8\u91cf mm_struct \u7684\u5730\u5740\u6307\u9488&#xff0c;mm_struct \u4e2d\u6709\u7c7b\u4f3cstart end\u4e24\u4e2a\u6307\u9488\u6765\u4e3a\u865a\u62df\u5730\u5740\u5212\u5206\u5b9e\u9645\u7684\u7269\u7406\u7a7a\u95f4\u3002\u518d\u901a\u8fc7\u4e00\u5f20<span style=\"color:#fe2c24\">\u9875\u8868\u5c06\u5b9e\u9645\u5730\u5740\u4e0e\u865a\u62df\u5730\u5740\u505a\u952e\u503c\u5bf9\u5e94<\/span>&#xff0c;\u8fd9\u624d\u662f\u64cd\u4f5c\u7cfb\u7edf\u5b9e\u9645\u7684\u5185\u5b58\u5206\u914d\u3002<\/p>\n<p style=\"text-align:center\"><img decoding=\"async\" alt=\"\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031610-683922fa00969.png\" \/><\/p>\n<hr \/>\n<p>\u5e0c\u671b\u5404\u4f4d\u5927\u4f6c\u591a\u591a\u652f\u6301&#xff01;&#xff01;&#xff01;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb604\u6b21\uff0c\u70b9\u8d5e42\u6b21\uff0c\u6536\u85cf34\u6b21\u3002\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u662f\u5f53\u4ee3\u8ba1\u7b97\u673a\u7684\u57fa\u672c\u7ed3\u6784\uff0c\u5b83\u4e3b\u8981\u5305\u62ec\u51e0\u4e2a\u677f\u5757\uff0c\u8f93\u5165\u8bbe\u5907\uff0c\u8f93\u51fa\u8bbe\u5907\uff0c\u5b58\u50a8\u5668\uff0c\u8fd0\u7b97\u5668\u548c\u63a7\u5236\u5668\u3002\u4e0b\u9762\u662f\u7b80\u7565\u7248\u7684\u56fe\u89e3\u6790\uff1a\u8f93\u5165\u8bbe\u5907\u4e3b\u8981\u5305\u542b\u9f20\u6807\uff0c\u952e\u76d8\uff0c\u8bdd\u7b52\u7b49\u4e3b\u8981\u8fdb\u884c\u6570\u636e\u7684\u4f20\u8f93\uff1b\u5b58\u50a8\u5668\u5373\u5185\u5b58\u7528\u4e8e\u5c06\u63a5\u53d7\u8f93\u5165\u8bbe\u5907\u7684\u6570\u636e\uff0c\u4e3a\u6570\u636e\u8fdb\u884c\u6392\u961f\u540e\u4ea4\u7ed9CPU\u5904\u7406\uff0c\u5728CPU\u6570\u636e\u8fd4\u56de\u540e\u518d\u4f20\u7ed9\u8f93\u51fa\u8bbe\u5907\uff0c\u56e0\u6b64\u5185\u5b58\u662f\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u6700\u91cd\u8981\u7684\u90e8\u5206\uff1b\u63a5\u7740\u662fCPU\uff0c\u8fd0\u7b97\u5668\u548c\u63a7\u5236\u5668\u7ed3\u5408\u6784\u6210\u4e86CPU\uff0c\u8fd0\u7b97\u5668\u4e3b\u8981\u8d1f\u8d23\u8fdb\u884c\u4ee3\u7801\u7684\u903b\u8f91\u8fd0\u7b97\u548c\u7b97\u6570\u8fd0\u7b97\uff0c\u63a7\u5236\u5668\u4e3b\u8981\u8d1f\u8d23\u5bf9\u4ee3\u7801\u8fdb\u884c\u63a7\u5236\uff1b\u6700\u540e\u662f\u8f93\u51fa\u8bbe\u5907\uff0c\u4e3b\u8981\u662f\u663e\u793a\u5668\uff0c\u5587\u53ed\u7b49\u8d1f\u8d23\u6570\u636e\u7684\u8f93\u51fa\u3002<\/p>\n","protected":false},"author":2,"featured_media":40812,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[58,43,44],"topic":[],"class_list":["post-40828","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-server","tag-linux","tag-43","tag-44"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Linux\u8fdb\u7a0b\u6982\u5ff5 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/40828.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Linux\u8fdb\u7a0b\u6982\u5ff5 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb604\u6b21\uff0c\u70b9\u8d5e42\u6b21\uff0c\u6536\u85cf34\u6b21\u3002\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u662f\u5f53\u4ee3\u8ba1\u7b97\u673a\u7684\u57fa\u672c\u7ed3\u6784\uff0c\u5b83\u4e3b\u8981\u5305\u62ec\u51e0\u4e2a\u677f\u5757\uff0c\u8f93\u5165\u8bbe\u5907\uff0c\u8f93\u51fa\u8bbe\u5907\uff0c\u5b58\u50a8\u5668\uff0c\u8fd0\u7b97\u5668\u548c\u63a7\u5236\u5668\u3002\u4e0b\u9762\u662f\u7b80\u7565\u7248\u7684\u56fe\u89e3\u6790\uff1a\u8f93\u5165\u8bbe\u5907\u4e3b\u8981\u5305\u542b\u9f20\u6807\uff0c\u952e\u76d8\uff0c\u8bdd\u7b52\u7b49\u4e3b\u8981\u8fdb\u884c\u6570\u636e\u7684\u4f20\u8f93\uff1b\u5b58\u50a8\u5668\u5373\u5185\u5b58\u7528\u4e8e\u5c06\u63a5\u53d7\u8f93\u5165\u8bbe\u5907\u7684\u6570\u636e\uff0c\u4e3a\u6570\u636e\u8fdb\u884c\u6392\u961f\u540e\u4ea4\u7ed9CPU\u5904\u7406\uff0c\u5728CPU\u6570\u636e\u8fd4\u56de\u540e\u518d\u4f20\u7ed9\u8f93\u51fa\u8bbe\u5907\uff0c\u56e0\u6b64\u5185\u5b58\u662f\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u6700\u91cd\u8981\u7684\u90e8\u5206\uff1b\u63a5\u7740\u662fCPU\uff0c\u8fd0\u7b97\u5668\u548c\u63a7\u5236\u5668\u7ed3\u5408\u6784\u6210\u4e86CPU\uff0c\u8fd0\u7b97\u5668\u4e3b\u8981\u8d1f\u8d23\u8fdb\u884c\u4ee3\u7801\u7684\u903b\u8f91\u8fd0\u7b97\u548c\u7b97\u6570\u8fd0\u7b97\uff0c\u63a7\u5236\u5668\u4e3b\u8981\u8d1f\u8d23\u5bf9\u4ee3\u7801\u8fdb\u884c\u63a7\u5236\uff1b\u6700\u540e\u662f\u8f93\u51fa\u8bbe\u5907\uff0c\u4e3b\u8981\u662f\u663e\u793a\u5668\uff0c\u5587\u53ed\u7b49\u8d1f\u8d23\u6570\u636e\u7684\u8f93\u51fa\u3002\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/40828.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2025-05-30T03:16:11+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031607-683922f7ebdc0.png\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/40828.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/40828.html\",\"name\":\"Linux\u8fdb\u7a0b\u6982\u5ff5 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2025-05-30T03:16:11+00:00\",\"dateModified\":\"2025-05-30T03:16:11+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/40828.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/40828.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/40828.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Linux\u8fdb\u7a0b\u6982\u5ff5\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Linux\u8fdb\u7a0b\u6982\u5ff5 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/40828.html","og_locale":"zh_CN","og_type":"article","og_title":"Linux\u8fdb\u7a0b\u6982\u5ff5 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb604\u6b21\uff0c\u70b9\u8d5e42\u6b21\uff0c\u6536\u85cf34\u6b21\u3002\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u662f\u5f53\u4ee3\u8ba1\u7b97\u673a\u7684\u57fa\u672c\u7ed3\u6784\uff0c\u5b83\u4e3b\u8981\u5305\u62ec\u51e0\u4e2a\u677f\u5757\uff0c\u8f93\u5165\u8bbe\u5907\uff0c\u8f93\u51fa\u8bbe\u5907\uff0c\u5b58\u50a8\u5668\uff0c\u8fd0\u7b97\u5668\u548c\u63a7\u5236\u5668\u3002\u4e0b\u9762\u662f\u7b80\u7565\u7248\u7684\u56fe\u89e3\u6790\uff1a\u8f93\u5165\u8bbe\u5907\u4e3b\u8981\u5305\u542b\u9f20\u6807\uff0c\u952e\u76d8\uff0c\u8bdd\u7b52\u7b49\u4e3b\u8981\u8fdb\u884c\u6570\u636e\u7684\u4f20\u8f93\uff1b\u5b58\u50a8\u5668\u5373\u5185\u5b58\u7528\u4e8e\u5c06\u63a5\u53d7\u8f93\u5165\u8bbe\u5907\u7684\u6570\u636e\uff0c\u4e3a\u6570\u636e\u8fdb\u884c\u6392\u961f\u540e\u4ea4\u7ed9CPU\u5904\u7406\uff0c\u5728CPU\u6570\u636e\u8fd4\u56de\u540e\u518d\u4f20\u7ed9\u8f93\u51fa\u8bbe\u5907\uff0c\u56e0\u6b64\u5185\u5b58\u662f\u51af\u8bfa\u4f9d\u66fc\u4f53\u7cfb\u7ed3\u6784\u6700\u91cd\u8981\u7684\u90e8\u5206\uff1b\u63a5\u7740\u662fCPU\uff0c\u8fd0\u7b97\u5668\u548c\u63a7\u5236\u5668\u7ed3\u5408\u6784\u6210\u4e86CPU\uff0c\u8fd0\u7b97\u5668\u4e3b\u8981\u8d1f\u8d23\u8fdb\u884c\u4ee3\u7801\u7684\u903b\u8f91\u8fd0\u7b97\u548c\u7b97\u6570\u8fd0\u7b97\uff0c\u63a7\u5236\u5668\u4e3b\u8981\u8d1f\u8d23\u5bf9\u4ee3\u7801\u8fdb\u884c\u63a7\u5236\uff1b\u6700\u540e\u662f\u8f93\u51fa\u8bbe\u5907\uff0c\u4e3b\u8981\u662f\u663e\u793a\u5668\uff0c\u5587\u53ed\u7b49\u8d1f\u8d23\u6570\u636e\u7684\u8f93\u51fa\u3002","og_url":"https:\/\/www.wsisp.com\/helps\/40828.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2025-05-30T03:16:11+00:00","og_image":[{"url":"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/05\/20250530031607-683922f7ebdc0.png"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"4 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/40828.html","url":"https:\/\/www.wsisp.com\/helps\/40828.html","name":"Linux\u8fdb\u7a0b\u6982\u5ff5 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2025-05-30T03:16:11+00:00","dateModified":"2025-05-30T03:16:11+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/40828.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/40828.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/40828.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"Linux\u8fdb\u7a0b\u6982\u5ff5"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/40828","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=40828"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/40828\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media\/40812"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=40828"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=40828"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=40828"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=40828"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}