• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

How to change the default IP address of docker bridge

by admin

Question: what is the proper procedure to reconfigure the docker interface to use an address range (e.g., > 172.200) for the virtual interfaces it uses?

You can reconfigure the default bridge network by providing the bip option along with the desired subnet in the daemon.json (default location at /etc/docker/daemon.json ) file as follows:

# vi //cdn.thegeekdiary.com/etc/docker/daemon.json
{
  "bip": "172.200.0.1/16"
}

Then restart the docker daemon as root.

On CentOS/RHEL 6 use the service command to restart the docker service:

# service docker restart

On CentOS/RHEL 7, use the systemctl command to restart the docker service.

# systemctl restart docker

Filed Under: CentOS/RHEL 6, CentOS/RHEL 7, DevOps, Docker, Linux

Some more articles you might also be interested in …

  1. How To Add/Remove Locale Archive in CentOS/RHEL 5,6
  2. Basic vi commands (cheat sheet)
  3. paste Command Examples in Linux
  4. export: command not found
  5. How to use mdadm to create a software mirror on top of multipath devices
  6. Starting udev: udevd inotify_init failed: too many open files
  7. mv Command Examples in Linux
  8. colrm Command Examples in Linux
  9. YUM command examples to install, remove and upgrade packages
  10. How to disable “sudo su” for users in sudoers configuration file

You May Also Like

Primary Sidebar

Recent Posts

  • powertop Command Examples in Linux
  • powertop: command not found
  • powerstat: command not found
  • powerstat Command Examples in Linux

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright