|
| 1 | +# OpenROAD Docker Software Package Quickstart Guide |
| 2 | + |
| 3 | +# Setup Guide |
| 4 | + |
| 5 | +This setup guide covers machine and software package installation instructions for use with the OpenROAD and OpenROAD Autotuner products. It is intended to be a reference for those setting up a machine to run OpenROAD on. |
| 6 | + |
| 7 | +# Host Machine Requirements |
| 8 | + |
| 9 | +We suggest running a Ubuntu 22.04 or Red Hat Enterprise Linux 8 image with at least 32 CPUs, 128 GB memory, and 500 GB disk. |
| 10 | + |
| 11 | +# Software Packages |
| 12 | + |
| 13 | +The following are software packages that need to be installed to run OpenROAD or OpenROAD Autotuner using docker. |
| 14 | + |
| 15 | +## Docker Installation |
| 16 | + |
| 17 | +We will use Docker to create and run an image that contains everything you need to run the OpenROAD flow. If you already have Docker installed on your cloud machine, you can skip this step. |
| 18 | + |
| 19 | +### Ubuntu Installation |
| 20 | + |
| 21 | +To install Docker: |
| 22 | + |
| 23 | +``` |
| 24 | +sudo snap install docker |
| 25 | +sudo groupadd docker |
| 26 | +``` |
| 27 | + |
| 28 | +The docker group needs to be created in order to access the pipe used by docker. |
| 29 | + |
| 30 | +### Red Hat Enterprise Linux Installation |
| 31 | + |
| 32 | +To install Docker: |
| 33 | + |
| 34 | +``` |
| 35 | +sudo dnf install dnf-plugins-core -y |
| 36 | +sudo dnf config-manager --add-repo https://download.docker.com/linux/rhel/docker-ce.repo |
| 37 | +sudo dnf install --allowerasing -y docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin sudo systemctl start docker |
| 38 | +``` |
| 39 | + |
| 40 | +The RHEL docker installation automatically adds the docker group to the system, so you can skip the next step. |
| 41 | + |
| 42 | +### Adding the Docker Group to your User |
| 43 | + |
| 44 | +Add the docker group to your user to it, so that you have access to the docker pipe: |
| 45 | + |
| 46 | +``` |
| 47 | +sudo usermod -aG docker $USER |
| 48 | +``` |
| 49 | + |
| 50 | +Note that you might either need to log out/log back in or reboot in order for the group change to take effect. |
| 51 | + |
| 52 | +To test that docker is working: |
| 53 | + |
| 54 | +``` |
| 55 | +docker run hello-world |
| 56 | +``` |
| 57 | + |
| 58 | +## Podman-Docker Installation |
| 59 | +Note: These instructions might only be applicable to RHEL only |
| 60 | + |
| 61 | +Alternatively, you can install podman instead of docker. On RHEL systems, podman might already be installed. To emulate the docker CLI using podman, install the podman-docker package: |
| 62 | + |
| 63 | +``` |
| 64 | +sudo yum install podman-docker |
| 65 | +``` |
| 66 | + |
| 67 | +To quiet the docker compatibility message: |
| 68 | + |
| 69 | +``` |
| 70 | +sudo touch /etc/containers/nodocker |
| 71 | +``` |
| 72 | + |
| 73 | +## VNC Installation |
| 74 | + |
| 75 | +If you are interested in using the OpenROAD GUI to track the run or view the results, you’ll need to install VNC on the cloud machine. If you have these already installed on the host machine, you can skip this step. |
| 76 | + |
| 77 | +### Ubuntu Installation |
| 78 | + |
| 79 | +To install: |
| 80 | + |
| 81 | +``` |
| 82 | +sudo apt update |
| 83 | +sudo apt upgrade -y |
| 84 | +sudo apt install tigervnc-standalone-server tigervnc-xorg-extension tigervnc-viewer -y |
| 85 | +sudo apt install xfce4-goodies xfce4 -y |
| 86 | +``` |
| 87 | + |
| 88 | +Start a vncserver session on the cloud machine and connect the VNC client to it. |
| 89 | + |
| 90 | +### Red Hat Enterprise Linux Installation |
| 91 | + |
| 92 | +To install: |
| 93 | + |
| 94 | +``` |
| 95 | +sudo dnf update -y |
| 96 | +sudo dnf install tigervnc-server tigervnc-server-module -y |
| 97 | +sudo dnf groupinstall "Server with GUI" -y |
| 98 | +``` |
| 99 | + |
| 100 | +Start a vncserver session on the cloud machine and connect the VNC client to it. |
| 101 | + |
| 102 | +## XHost Access |
| 103 | + |
| 104 | +In order for the docker container to display the GUI, you must enable docker containers access to the X11 display on the cloud machine. To enable access: |
| 105 | + |
| 106 | +``` |
| 107 | +xhost +local:docker |
| 108 | +touch /tmp/.docker.xauth |
| 109 | +``` |
| 110 | + |
| 111 | +## Git Installation |
| 112 | +Note: These instructions are applicable to RHEL only |
| 113 | + |
| 114 | +To install git: |
| 115 | + |
| 116 | +``` |
| 117 | +sudo dnf install git-core -y |
| 118 | +``` |
| 119 | + |
| 120 | +## Firefox Installation |
| 121 | +Note: These instructions are applicable to Ubuntu only |
| 122 | + |
| 123 | +Firefox (or your favorite browser) enables you to view the OpenROAD AutoTuner results via TensorBoard. If you have already installed firefox on the cloud machine, you can skip this step. |
| 124 | + |
| 125 | +To install firefox: |
| 126 | + |
| 127 | +``` |
| 128 | +sudo snap install firefox |
| 129 | +``` |
| 130 | + |
| 131 | +## TensorBoard Installation |
| 132 | + |
| 133 | +### Ubuntu Installation |
| 134 | + |
| 135 | +If you want to run TensorBoard on the cloud machine, type the following to install it: |
| 136 | + |
| 137 | +``` |
| 138 | +sudo apt install python3-pip -y |
| 139 | +sudo pip install tensorboard |
| 140 | +``` |
| 141 | + |
| 142 | +### Red Hat Enterprise Linux Installation |
| 143 | + |
| 144 | +If you want to run TensorBoard on the cloud machine, type the following to install it: |
| 145 | + |
| 146 | +``` |
| 147 | +sudo dnf install python3-pip -y |
| 148 | +sudo dnf install redhat-rpm-config -y |
| 149 | +sudo dnf install python3-devel |
| 150 | +sudo dnf groupinstall “Development Tools” -y |
| 151 | +sudo pip3 install tensorboard |
| 152 | +``` |
| 153 | + |
| 154 | +# Choosing The ORFS Version |
| 155 | + |
| 156 | +The OpenROAD team frequently releases new versions of ORFS and publishes them on [Docker Hub](https://hub.docker.com/r/openroad/orfs/tags)). Based upon your needs, you can choose which version to use in your flow. |
| 157 | + |
| 158 | +Each version has a listing, which includes the ORFS tag: |
| 159 | + |
| 160 | + |
| 161 | + |
| 162 | +In our example above, the tag is v3.0-2144-gd8465608, where 2144 is the build number and gd8465608 is a hash that is related to the corresponding commit tag in the Git OpenROAD-flow-scripts repository. |
| 163 | + |
| 164 | +## Locating the Commit in the OpenROAD-flow-scripts Repository |
| 165 | + |
| 166 | +Locating the commit in the OpenROAD-flow-scripts repository is important in this flow to ensure that the ORFS scripts and the ORFS tools are aligned. It can also be helpful in case you require a specific feature or fix in your flow. |
| 167 | + |
| 168 | +The ORFS Git commit tag version is similar to the Docker Hub tag, but might not be exact. Generally-speaking the Docker Hub tag is the ORFS Git commit tag with a “g” prepended to it and possibly another digit at the end. For the example below, the ORFS Git commit tag is d846560 and the Docker Hub tag is gd8465608. |
| 169 | + |
| 170 | +Please consult the [ORFS git history](https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts/commits/master/) to find the commit tag that most closely matches the Docker version tag. The commit tag is listed on the right side of each commit (d846560): |
| 171 | + |
| 172 | + |
| 173 | + |
| 174 | +# Workspace Creation |
| 175 | + |
| 176 | +We want to store all of our design’s artifacts on the cloud machine’s filesystem, so that all OpenROAD tool invocations can use the same artifacts. |
| 177 | + |
| 178 | +## Clone the ORFS Flow Directory |
| 179 | + |
| 180 | +The easiest way to create the workspace is to clone out the OpenROAD-flow-scripts repository from git onto our host machine and then share it with Docker. In order to ensure that there’s compatibility between the OpenROAD tool and the flow scripts, we’ll want to access the same ORFS version as what we are using in the Docker container defined in the “Locating the Commit in the OpenROAD-flow-scripts Repository” section above (e.g. version d846560) |
| 181 | + |
| 182 | +To clone the repository: |
| 183 | + |
| 184 | +``` |
| 185 | +git clone --recursive https://github.com/The-OpenROAD-Project/OpenROAD-flow-scripts.git |
| 186 | +cd OpenROAD-flow-scripts |
| 187 | +git checkout d846560 |
| 188 | +``` |
| 189 | + |
| 190 | +Note that if we change the version of the ORFS tools we are using, we will also need to run “git pull” followed by a “git checkout” with the corresponding Git commit tag. |
0 commit comments