Skip to content
This repository was archived by the owner on Dec 22, 2023. It is now read-only.
This repository was archived by the owner on Dec 22, 2023. It is now read-only.

Fails when running as root #38

Description

sudo python
Python3.10.10 (main, Mar52023, 22:26:53) [GCC12.2.120230201] onlinuxType"help", "copyright", "credits"or"license"formoreinformation.
>>>importpychroot>>>withpychroot.Chroot('/mnt/gentoo'):
... print('test')
... Traceback (mostrecentcalllast):
File"/usr/lib/python3.10/site-packages/pychroot/utils.py", line109, inbindmount(source=src, target=dest, fstype=fstype,
File"/usr/lib/python3.10/site-packages/snakeoil/osutils/__init__.py", line99, in_wrapperreturnf(*args, **kwargs)
File"/usr/lib/python3.10/site-packages/snakeoil/osutils/mount.py", line52, inmountraiseOSError(e, os.strerror(e))
OSError: [Errno16] DeviceorresourcebusyDuringhandlingoftheaboveexception, anotherexceptionoccurred:
Traceback (mostrecentcalllast):
File"/usr/lib/python3.10/site-packages/snakeoil/contexts.py", line133, in__enter__self._child_setup()
File"/usr/lib/python3.10/site-packages/pychroot/base.py", line105, in_child_setupself._mount()
File"/usr/lib/python3.10/site-packages/pychroot/base.py", line137, in_mountbind(src=source, dest=chrmount, chroot=self.path, log=self.log, **opts)
File"/usr/lib/python3.10/site-packages/pychroot/utils.py", line118, inbindraiseChrootMountError(
pychroot.exceptions.ChrootMountError: failedmounting: mount-tsysfssysfs/mnt/gentoo/sys: Deviceorresourcebusy
[2]+Stoppedsudopython

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions