code: func getRbdDevFromImageAndPool(pool string, image string) (string, bool) {
  	// /sys/bus/rbd/devices/X/name and /sys/bus/rbd/devices/X/pool
  	sys_path := "/sys/bus/rbd/devices"
  	if dirs, err := ioutil.ReadDir(sys_path); err == nil {
  		for _, f := range dirs {
  			// Pool and name format:
  			// see rbd_pool_show() and rbd_name_show() at
  			// https://github.com/torvalds/linux/blob/master/drivers/block/rbd.c
  			name := f.Name()
  			// First match pool, then match name.
  			poolFile := filepath.Join(sys_path, name, "pool")
  			poolBytes, err := ioutil.ReadFile(poolFile)
  			if err != nil {
  				klog.V(4).Infof("error reading %s: %v", poolFile, err)
  				continue
  			}
  			if strings.TrimSpace(string(poolBytes)) != pool {
  				klog.V(4).Infof("device %s is not %q: %q", name, pool, string(poolBytes))
  				continue
  			}
  			imgFile := filepath.Join(sys_path, name, "name")
  			imgBytes, err := ioutil.ReadFile(imgFile)
  			if err != nil {
  				klog.V(4).Infof("error reading %s: %v", imgFile, err)
  				continue
  			}
  			if strings.TrimSpace(string(imgBytes)) != image {
  				klog.V(4).Infof("device %s is not %q: %q", name, image, string(imgBytes))
  				continue
  			}
  			// Found a match, check if device exists.
  			devicePath := "/dev/rbd" + name
  			if _, err := os.Lstat(devicePath); err == nil {
  				return devicePath, true
  			}
  		}
  	}
  	return "", false
  }
docs: // Search /sys/bus for rbd device that matches given pool and image.