In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-19 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/03 Report--
10 configuration is to change the node file, 11 is completely different, can not be achieved by modifying the file, you must use commands.
11 introduced two new commands to manage the network manually: dladm and ipadm, which can be used in combination to replace ifconfig. Unlike ifconfig, changes made by dladm and ipadm are persisted after reboot. They have a common, consistent command format, and unlike ifconfig, their output can be parsed so that they can be used in scripts.
Dladm performs data link (layer 2) management, configuring physical links, aggregations, VLAN, IP tunnels, and InfiniBand partitions. It also manages link layer properties.
Ipadm can configure the IP interface, IP address, and TCP/IP protocol properties. It can also replace ndd for network layer and transport layer tuning.
In addition, Oracle Solaris 11 adds the ability to automatically configure the network using network profiles. The configuration file is managed by two administrative commands, netadm and netcfg, and uses an entity to describe the configuration of network interfaces, name services, routing, and IP filters and IPsec policies.
Oracle Solaris 11 uses profile-based network configuration, which has two configuration modes: manual configuration and automatic configuration, DefaultFixed Network profile (NCP), or Automatic NCP.
If it is automatic, DHCP is used. The default is automatic, and manual command is required:
Netadm enable-p ncp DefaultFixed
And then take a look.
Netadm listnetadm: DefaultFixed NCP is enabled; automatic network management is not available.'netadm list' is only supported when automatic network management is active.
If you want to change it to automatic
Netadm enable-p ncp Automatic
After changing to manual, you need to confirm the physical network card.
Dladm show-phys
You may see the following list
LINK MEDIA STATE SPEED DUPLEX DEVICEnet0 Ethernet up 1000 full e1000g0net1 Ethernet unknown 0 unknown pcn0
Take a look at the link.
Dladm show-link
LINK CLASS MTU STATE OVER
Net1 phys 1500 up--
Net0 phys 1500 up--
Establish an ip link for the net0 network interface
Ipadm create-ip net0 take a look at the situation ipadm show-ifIFNAME CLASS STATE ACTIVE OVERlo0 loopback ok yes-net0 ip down no-you can see that net0 has been created a link for ip, but the current state is down and is not active, which should be the reason why there is no IP. Configure the IP address. Ipadm create-addr-T static-a 192.168.1.20 net0/v4-T static 24 is static,-an is the address, followed by the ip address, and the mask is also written directly in prefix. / 24Line0 is for that interface, followed by / v4 is just a description. Take a look at the situation ipadm show-ifIFNAME CLASS STATE ACTIVE OVERlo0 loopback ok yes-net0 ip ok yes
Sure enough, everything is all right.
Look at the configured IP address
Ipadm show-addrADDROBJ TYPE STATIC ADDRlo0/v4 static ok 127.0.0.1/8net0/v4 static ok 192.168.1.20/24lo0/v6 static ok:: 1/128
Add a default route
Route-p add default 192.168.1.1route-p showSMF service svc:/network/dns/client management, configuration information that used to be in / etc/resolv.conf. SMF service svc:/system/name-service/switch management, configuration information that used to be in / etc/nsswitch.conf. In both cases, configuration information is also stored in legacy files to be compatible with other applications that may read them. These old-fashioned documents should not be edited directly. Changes to properties are reflected in legacy files only after the service is refreshed, restarted, or enabled. Svccfg-s svc:/network/dns/client setprop config/search=' ("xu.shen.com"shen.com") 'svccfg-s svc:/network/dns/client listprop config/searchconfig/search astring "xu.shen.com" shen.com "svccfg-s svc:/network/dns/client setprop config/nameserver=net_address:' (10.167.162.20 10.167.162.36) 'svccfg-s svc:/network/dns/client listprop config/nameserverconfig/nameserver net_ Address 10.167.162.20 10.167.162.36
It needs to be refreshed when it's over.
Svcadm refresh svc:/network/dns/client svcadm restart svc:/network/dns/client
If you ping, you will find
Send to Network is unreachable
When you switch from Automatic NCP to DefaultFixed NCP for the first time, there will be something wrong with the network. It's bug.
Refresh
Svcadm refresh svc:/network/location:default
Or just turn it off.
Svcadm disable svc:/network/location:default
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.