code: func (cgc *containerGC) evictPodLogsDirectories(allSourcesReady bool) error {
  	osInterface := cgc.manager.osInterface
  	if allSourcesReady {
  		// Only remove pod logs directories when all sources are ready.
  		dirs, err := osInterface.ReadDir(podLogsRootDirectory)
  		if err != nil {
  			return fmt.Errorf("failed to read podLogsRootDirectory %q: %v", podLogsRootDirectory, err)
  		}
  		for _, dir := range dirs {
  			name := dir.Name()
  			podUID := parsePodUIDFromLogsDirectory(name)
  			if !cgc.podStateProvider.IsPodDeleted(podUID) {
  				continue
  			}
  			err := osInterface.RemoveAll(filepath.Join(podLogsRootDirectory, name))
  			if err != nil {
  				klog.Errorf("Failed to remove pod logs directory %q: %v", name, err)
  			}
  		}
  	}
  
  	// Remove dead container log symlinks.
  	// TODO(random-liu): Remove this after cluster logging supports CRI container log path.
  	logSymlinks, _ := osInterface.Glob(filepath.Join(legacyContainerLogsDir, fmt.Sprintf("*.%s", legacyLogSuffix)))
  	for _, logSymlink := range logSymlinks {
  		if _, err := osInterface.Stat(logSymlink); os.IsNotExist(err) {
  			err := osInterface.Remove(logSymlink)
  			if err != nil {
  				klog.Errorf("Failed to remove container log dead symlink %q: %v", logSymlink, err)
  			}
  		}
  	}
  	return nil
  }
docs: // evictPodLogsDirectories evicts all evictable pod logs directories. Pod logs directories
  // are evictable if there are no corresponding pods.