Permission denied in export all courses/libraries

Hello, dear all,
I want to export all courses and import. How can I get?
When I used this command and shown this permission denied error? How can I fix? pls

$ ./manage.py cms export_all_courses /your/output/path

edxapp@Edx-VM-DB:~/edx-platform$ ./manage.py cms export_all_courses /home/
WARNING:py.warnings:/edx/app/edxapp/edx-platform/lms/djangoapps/courseware/__ini                                                                                                             t__.py:5: DeprecationWarning: Importing 'lms.djangoapps.courseware' as 'coursewa                                                                                                             re' is no longer supported
  warnings.warn("Importing 'lms.djangoapps.courseware' as 'courseware' is no lon                                                                                                             ger supported", DeprecationWarning)

2022-06-28 23:59:25,816 WARNING 8317 [enterprise.utils] utils.py:50 - Could not                                                                                                              import Registry from third_party_auth.provider
2022-06-28 23:59:25,816 WARNING 8317 [enterprise.utils] utils.py:51 - cannot imp                                                                                                             ort name EnterpriseCustomerUser
2022-06-28 23:59:31,261 WARNING 8317 [py.warnings] __init__.py:1564 - /edx/app/e                                                                                                             dxapp/venvs/edxapp/local/lib/python2.7/site-packages/pkg_resources/__init__.py:1                                                                                                             145: DeprecationWarning: Use of .. or absolute path in a resource path is not al                                                                                                             lowed and will raise exceptions in a future release.
  self, resource_name

Traceback (most recent call last):
  File "./manage.py", line 123, in <module>
    execute_from_command_line([sys.argv[0]] + django_args)
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/django/co                                                                                                             re/management/__init__.py", line 364, in execute_from_command_line
    utility.execute()
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/django/co                                                                                                             re/management/__init__.py", line 356, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/django/co                                                                                                             re/management/base.py", line 283, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/django/co                                                                                                             re/management/base.py", line 330, in execute
    output = self.handle(*args, **options)
  File "/edx/app/edxapp/edx-platform/cms/djangoapps/contentstore/management/comm                                                                                                             ands/export_all_courses.py", line 27, in handle
    courses, failed_export_courses = export_courses_to_output_path(options['outp                                                                                                             ut_path'])
  File "/edx/app/edxapp/edx-platform/cms/djangoapps/contentstore/management/comm                                                                                                             ands/export_all_courses.py", line 45, in export_courses_to_output_path
    courses = module_store.get_courses()
  File "/edx/app/edxapp/edx-platform/common/lib/xmodule/xmodule/modulestore/mixe                                                                                                             d.py", line 89, in inner
    retval = func(field_decorator=strip_key_collection, *args, **kwargs)
  File "/edx/app/edxapp/edx-platform/common/lib/xmodule/xmodule/modulestore/mixe                                                                                                             d.py", line 317, in get_courses
    for course in store.get_courses(**kwargs):
  File "/edx/app/edxapp/edx-platform/common/lib/xmodule/xmodule/modulestore/spli                                                                                                             t_mongo/split_draft.py", line 99, in get_courses
    return super(DraftVersioningModuleStore, self).get_courses(ModuleStoreEnum.B                                                                                                             ranchName.draft, **kwargs)
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/mongodb_p                                                                                                             roxy.py", line 53, in wrapper
    return func(*args, **kwargs)
  File "/edx/app/edxapp/edx-platform/common/lib/xmodule/xmodule/modulestore/spli                                                                                                             t_mongo/split.py", line 1021, in get_courses
    return self._get_structures_for_branch_and_locator(branch, self._create_cour                                                                                                             se_locator, **kwargs)
  File "/edx/app/edxapp/edx-platform/common/lib/xmodule/xmodule/modulestore/spli                                                                                                             t_mongo/split.py", line 981, in _get_structures_for_branch_and_locator
    structures_list = self._load_items(envelope, [root], depth=0, **kwargs)
  File "/edx/app/edxapp/edx-platform/common/lib/xmodule/xmodule/modulestore/spli                                                                                                             t_mongo/split.py", line 822, in _load_items
    runtime = self.create_runtime(course_entry, lazy)
  File "/edx/app/edxapp/edx-platform/common/lib/xmodule/xmodule/modulestore/spli                                                                                                             t_mongo/split.py", line 3455, in create_runtime
    services=services,
  File "/edx/app/edxapp/edx-platform/common/lib/xmodule/xmodule/modulestore/spli                                                                                                             t_mongo/caching_descriptor_system.py", line 64, in __init__
    root.makedirs_p()  # create directory if it doesn't exist
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/path.py",                                                                                                              line 1220, in makedirs_p
    self.makedirs(mode)
  File "/edx/app/edxapp/venvs/edxapp/local/lib/python2.7/site-packages/path.py",                                                                                                              line 1213, in makedirs
    os.makedirs(self, mode)
  File "/edx/app/edxapp/venvs/edxapp/lib/python2.7/os.py", line 150, in makedirs
    makedirs(head, mode)
  File "/edx/app/edxapp/venvs/edxapp/lib/python2.7/os.py", line 157, in makedirs
    mkdir(name, mode)
OSError: [Errno 13] Permission denied: '/edx/var/edxapp/data/New_testing_cousres/OPRD-MSO-190202'                                                    

I have given chmod permission but It didn’t fix. pls advice me

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.