Unix Study--Solaris 10修改主机IP和主
发表于:2025-12-02 作者:千家信息网编辑
千家信息网最后更新 2025年12月02日,Unix Study--Solaris 10修改主机IP和主机名对于Solaris系统,是通过一系列配置文件(文本)来存储和管理主机ip和主机名信息,通过编辑器修改这些配置文件就可以完成相关的配置。一
千家信息网最后更新 2025年12月02日Unix Study--Solaris 10修改主机IP和主
Unix Study--Solaris 10修改主机IP和主机名
对于Solaris系统,是通过一系列配置文件(文本)来存储和管理主机ip和主机名信息,通过编辑器修改这些配置文件就可以完成相关的配置。
一、修改主机ip
1、配置hosts文件
[root@solaris186:/]# cat /etc/hosts# Internet host table::1 localhost 127.0.0.1 localhost 192.168.8.11 solaris186 loghost[root@solaris186:/]# hostnamesolaris186[root@solaris186:/]# vi /etc/hosts# Internet host table#::1 localhost127.0.0.1 localhost192.168.8.11 node1 loghost
2、查看网卡信息
[root@solaris186:/]# ifconfig -alo0: flags=2001000849mtu 8232 index 1 inet 127.0.0.1 netmask ff000000 e1000g0: flags=1000843 mtu 1500 index 2 inet 192.168.8.11 netmask ffffff00 broadcast 192.168.8.255 ether 8:0:27:28:b1:8c
3、修改hostname.e1000g0
[root@solaris186:/]# cat /etc/hostname.e1000g0 solaris186[root@solaris186:/]# vi /etc/hostname.e1000g0 node1[root@solaris186:/]# cat /etc/hostname.e1000g0 node1
4、修改netmasks(子网掩码)
[root@solaris186:/]# cat /etc/netmasks## The netmasks file associates Internet Protocol (IP) address# masks with IP network numbers.# # network-number netmask## The term network-number refers to a number obtained from the Internet Network# Information Center.## Both the network-number and the netmasks are specified in# "decimal dot" notation, e.g:## 128.32.0.0 255.255.255.0#192.168.8.0 255.255.255.0
5、修改网关配置
[root@solaris186:/]# vi /etc/defaultrouter192.168.8.1[root@solaris186:/]# cat /etc/defaultrouter 192.168.8.1[root@solaris186:/]# netstat -nrRouting Table: IPv4 Destination Gateway Flags Ref Use Interface -------------------- -------------------- ----- ----- ---------- --------- 192.168.8.0 192.168.8.11 U 1 1 e1000g0 224.0.0.0 192.168.8.11 U 1 0 e1000g0 127.0.0.1 127.0.0.1 UH 1 50 lo0
总结:
和主机ip有关的配置文件
/etc/hosts
/etc/hostname.xxxx(网卡名)
/etc/netmaks
/etc/defaultrouter
/etc/inet/ipnodes
二、修改主机名
1、配置hosts文件
[root@solaris186:/]# cat /etc/hosts# Internet host table::1 localhost 127.0.0.1 localhost 192.168.8.11 node1 loghost
2、修改hostname.e1000g0
[root@solaris186:/]# cat /etc/hostname.e1000g0 solaris186[root@solaris186:/]# vi /etc/hostname.e1000g0 node1[root@solaris186:/]# cat /etc/hostname.e1000g0 node1
3、修改nodename
[root@solaris186:/]# cat /etc/nodenamesolaris186[root@solaris186:/]# vi /etc/nodenamenode1[root@solaris186:/]# cat /etc/nodenamenode1
4、查看ipnodes
[root@solaris186:/]# cat /etc/inet/ipnodes ## Internet host table#::1 localhost 127.0.0.1 localhost 192.168.8.11 node1 loghost
总结:
和主机名有关的配置文件
/etc/hosts
/etc/hostname.xxxx(网卡名)
/etc/nodename
/etc/inet/ipnodes
主机
配置
文件
网卡
信息
有关
文本
系统
编辑器
网关
e.g
子网
存储
管理
数据库的安全要保护哪些东西
数据库安全各自的含义是什么
生产安全数据库录入
数据库的安全性及管理
数据库安全策略包含哪些
海淀数据库安全审计系统
建立农村房屋安全信息数据库
易用的数据库客户端支持安全管理
连接数据库失败ssl安全错误
数据库的锁怎样保障安全
哪些院校有网络安全专业
分布式数据库部署架构
软件开发指导工作室
网易服务器是什么样子的
网络安全大嘴青蛙协议
数据库中怎么默认性别为女
文件管理服务器怎么安装
绿叶数据库
安卓获取数据库值
花网络安全工程师穿搭
南京安卓应用软件开发流程
网络翻译软件开发
湛江卫星软件开发批发价格
为危害网络安全活动提供帮助案
广西企业软件开发
西安网络安全宣传周活动
河南光讯网络技术
核心数据库缩写
软件开发论文前言
数据库查询上半年出生的学生
汇星海智能分析服务器
中国的商品条码和数据库是什么
如何看待现在的网络安全行业
龙珠改服务器
外国法信息网络安全
河北雄安归途互联网科技有限公司
青浦区市场软件开发管理方法
游戏数据库怎么到服务器
服务器的管理口叫什么
网络安全连续考核第一