•  Home
  •  Dashboard
  •  Company
    • About Us
    • Blog
    • Careers
    • Contact Us
    • Data Centers
    • Looking Glass
    • Network
    • Reseller
  •  Hosting Services
    • Infrastructure
      • iColocation
    • Compute
      • cMetal
      • cVirtual
    • Storage
      • sObject
      • sBlock
    • Networking
      • nIP Transit
      • nWavelength
    • Protection
      • pBackup
      • pDDoS
  •  Solutions
    • Ecommerce
    • Finance
    • Gaming
    • Hosting
    • Management
    • Security
    • System Integrator
  •  Support
    • Community
    • Knowledge Base
    • Open A Ticket
  •  USA & Canada: 800-933-1517
  •  International: 626-549-2801
  •  Email: sales@psychz.net
  • Services
    • new-colocation-header-img
      Infrastructure
      • iColocation
    • new-compute-header-img
      Compute
      • cMetal
      • cVirtual
    • new-storage-header-img
      Storage
      • sObject
      • sBlock
    • new-networking-header-img
      Networking
      • nIP Transit
      • nWavelength
    • new-protection-header-img
      Protection
      • pBackup
      • pDDoS
  • Solutions
    • Ecommerce
    • Security
    • Gaming
    • Hosting
    • Management
    • Finance
    • System Integrator
  • Dashboard

如何在CentOS 7配置IP范围是多少?

  • Home
  • Client
  • Qa Forum
  • 如何在CentOS 7配置IP范围是多少?

Posted By: Alsatary | 1 Replies | Last Reply On: Sep 26, 2019 12:36:41

我不得不重新安装的Centos 7使用IPMI我的服务器上,我不上如何配置提供给我的服务器/ 29,你们肯定100%。你们能否提供关于如何配置我的CentOS 7服务器的/ 29 IP范围的步骤?

现在我的服务器有没有互联网,所以请大家帮忙。

Psychz - Bhaskar

Votes: 0Posted On: Sep 26, 2019 12:36:41
 

Since you have already accessed your server using IPMI and did a fresh install of CentOS 7 on your own, configuring IPs will a piece of cake for you. To do so, you will have to take control of your server again using an IPMI. Once you do so, the following steps will help you to configure an IP range for the system.

Prerequisites

  1. Operating system: CentOS 7
  2. Minimum of one Active network interface
  3. Root permission

Step 1 - Check the network interfaces by using the command:

# ifconfig

The network configuration file in CentOS 7 is stored in “/etc/sysconfig/network-scripts”. There are multiple network files under “network-scripts” directory depending on the number of interfaces configured. The following steps will show you how to bind a range of IPs.

Step 2 - Edit the network interface file to which you want the static IP assigned.

vi /etc/sysconfig/network-scripts/ifcfg-enp2s0

Note: This file can be edited using a VI editor to configure static IP in the server. The different parameters to be added are:

 

BOOTPROTO – It is the protocol to be implemented during Boot time. It has to be changed to “static” for static IP configuration.
IPADDR – Edit the IP address in the IPADDR field
PREFIX – Add the IP range that has to be configured.
NETWORK – Add the network IP of the IP range.
GATEWAY – Add the Gateway IP
DNS - Add the address of the DNS server.

Save and close the file.

Step 3 - Restart the network services by the command

# Systemctl restart network

 

This should configure the IP addresses on your machine.

Was this reply helpful?

Related topics

  • 云主机与专用服务器 - 你如何选择?
  • sObject - Configuring CORS and Bucket Policies Using S3 Browser
  • Scaling your Business with a Dedicated Server and Containers
  • Report Bug/Feature
  • Psychz网络推出名为“亚太地区的低延迟路线”新功能
  • Psychz公布的欧洲数据中心的伦敦和阿姆斯特丹启动
  • Private Network - Create
  • Minecraft Dedicated Server Hosting In Australia
  • Learn About Anycast And Some Of Its Advantages And Disadvantages
  • Is the bandwidth guaranteed for 1 Gbps Unmetered Server?
  • GDPR and its impact on hosting industry!
  • CDN Domains Intro
  • 1000 Gbps DDoS Protection
  • 1 Month Trial Dedicated Server
  • 1 Gigabit Unlimited Dedicated Server
Copyright © 2026 Psychz Networks,
A Profuse Solutions Inc Company
Hosting Services
  • Catalog
Infrastructure
  • iColocation
Compute
  • cMetal
  • cVirtual
Storage
  • sObject
  • sBlock
Networking
  • nIP Transit
  • nWavelength
Protection
  • pBackup
  • pDDoS
Company
  • About Us
  • Blog
  • Careers
  • Contact Us
  • Data Centers
  • Looking Glass
  • Network
  • Reseller
Policies
  • Acceptable Usage Policy
  • Privacy Policy
  • Service Level Agreement
  • Terms and Conditions
Support
  • Community
  • Knowledge Base
  • Open A Ticket
Get In Touch
  • Psychz Networks,
    A Profuse Solutions Company
    611 Wilshire Blvd #300
    Los Angeles,California 90017
    USA
  • US/Canada: 800-933-1517
  • International: 626-549-2801