最近使用hyper-V安装了好几个测试机,都是基于Linux的环境,如果想远程访问需要本机IP进行网络绑定公网设备,下面来聊聊Linux怎么获取本机IP,大概分下面几种

ip addr

linux.png

hostname

linux.png

ifconfig

linux.png

提示找不到命令行,执行安装net-tools

PLAINTEXT
##安装net-tools
yum install net-tools
##更新系统
yum update
##查询网络
ifconfig
点击展开查看更多

版权声明

作者: JunYan`Blog

链接: https://www.jinjun.top/posts/cf1a/

许可证: CC BY-NC-SA 4.0

This work is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. Please attribute the source, use non-commercially, and maintain the same license.

评论

开始搜索

输入关键词搜索文章内容

↑↓
ESC
⌘K 快捷键