]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/ceph-disk/ceph_disk/main.py
update sources to 12.2.10
[ceph.git] / ceph / src / ceph-disk / ceph_disk / main.py
index 0058f1ac2d977514d446ad92d2f12ae2becb3421..73f26ce17d7ab19e61870e5ba8fdd0e76ef09c8b 100644 (file)
@@ -898,8 +898,8 @@ def is_mounted(dev):
     """
     Check if the given device is mounted.
     """
-    dev = os.path.realpath(dev)
-    with open(PROCDIR + '/mounts', 'rb') as proc_mounts:
+    dev = os.path.realpath(_bytes2str(dev))
+    with open(PROCDIR + '/mounts', 'r') as proc_mounts:
         for line in proc_mounts:
             fields = line.split()
             if len(fields) < 3: