[ https://issues.apache.org/jira/browse/AURORA-1988?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16526919#comment-16526919 ]
Jing Chen commented on AURORA-1988: ----------------------------------- I agree with what [~rdelvalle] told here, the reason why we could run example is that we have <role> www-data in our local vagrant box. You'd better set your role to whoever has permission to run python script at the target place. obs = [ Service(cluster = 'devcluster', environment = 'devel', role = -{color:#FF0000}'www-data',{color}- name = 'hello_world', task = hello_world_task) ] In addition, I guess you will be good if you just run command line {color:#FF0000}'echo "---gang-hello aurora------";'{color} instead of running python script. > Report "[Errno 13] Permission denied" when run hello world when follow latest > doc > ---------------------------------------------------------------------------------- > > Key: AURORA-1988 > URL: https://issues.apache.org/jira/browse/AURORA-1988 > Project: Aurora > Issue Type: Bug > Components: Executor > Affects Versions: 0.20.0 > Environment: Mesos Version: 1.6.0 > Aurora Version: 0.20.0 > Aurora RPM: > aurora-scheduler-0.20.0-1.el7.centos.aurora.x86_64.rpm > aurora-executor-0.20.0-1.el7.centos.aurora.x86_64.rpm > Reporter: Geng Gang > Priority: Blocker > Labels: beginner > Attachments: screen1.jpg > > > Hi > I am new user for aurora. When I follow latest hello world doc > ([http://aurora.apache.org/documentation/latest/getting-started/tutorial/)] > to run first hello world aurora job, I meet below issues: > D0605 16:17:01.721896 8320 process.py:155] [process: 8320=hello_world]: Error > trying to execute hello_world: {color:#FF0000}[Errno 13] Permission > denied{color}: > How to solve this issue? > > +_*The below is "thermos_runner.DEBUG" log in Mesos Agent:*_+ > D0605 16:17:01.721050 8320 process.py:445] Wrapped cmdline: ['/bin/bash', > '-c', u'echo "----gang---hello aurora-------";'] > D0605 16:17:01.721333 8320 process.py:455] ENV is: \{'HOME': > '/var/lib/mesos/slaves/65c1f16f-4292-464f-954c-3471fafdc988-S0/frameworks/b6da6477-5047-4d02-a323-101dd2e6d8b6-0000/executors/thermos-www-data-devel-hello_world-0-1d35ab50-a8eb-42da-a4f0-1de0bfbcd8fe/runs/b1d09fc1-ff87-4ec3-9341-85b21040f304/sandbox', > 'LOGNAME': 'www-data', 'USER': 'www-data', 'PATH': > '/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin'} > D0605 16:17:01.721896 8320 process.py:155] [process: 8320=hello_world]: Error > trying to execute hello_world: {color:#FF0000}[Errno 13] Permission > denied{color}: > '/var/lib/mesos/slaves/65c1f16f-4292-464f-954c-3471fafdc988-S0/frameworks/b6da6477-5047-4d02-a323-101dd2e6d8b6-0000/executors/thermos-www-data-devel-hello_world-0-1d35ab50-a8eb-42da-a4f0-1de0bfbcd8fe/runs/b1d09fc1-ff87-4ec3-9341-85b21040f304/sandbox' > D0605 16:17:01.722104 8320 process.py:155] [process: 8320=hello_world]: > Coordinator exiting. > > > +_*The below is /etc/aurora/clusters.json:*_+ > [root@cloudpoc3 ~]# more /etc/aurora/clusters.json > [ > { > "auth_mechanism": "UNAUTHENTICATED", > "name": "devcluster", > "scheduler_zk_path": "/aurora/scheduler", > "slave_root": "/var/lib/mesos", > "slave_run_directory": "latest", > "zk": "127.0.0.1" > } > ] > +_*The below is hello_world.aurora file:*_+ > pkg_path = '/opt/aurora_test/hello_world.py' > # we use a trick here to make the configuration change with > # the contents of the file, for simplicity. in a normal setting, packages > would be > # versioned, and the version number would be changed in the configuration. > import hashlib > with open(pkg_path, 'rb') as f: > pkg_checksum = hashlib.md5(f.read()).hexdigest() > # copy hello_world.py into the local sandbox > install = Process( > name = 'fetch_package', > cmdline = 'cp %s . && echo %s && chmod +x hello_world.py' % (pkg_path, > pkg_checksum)) > # run the script > # cmdline = 'python -u hello_world.py' > {color:#FF0000}hello_world = Process({color} > {color:#FF0000} name = 'hello_world',{color} > {color:#FF0000} cmdline = 'echo "----gang---hello aurora-------";'){color} > # describe the task > hello_world_task = SequentialTask( > processes = [hello_world], > resources = Resources(cpu = 2, ram = 4096*MB, disk=4096*MB)) > jobs = [ > Service(cluster = 'devcluster', > environment = 'devel', > role = 'www-data', > name = 'hello_world', > task = hello_world_task) > ] > +_*From Mesos WebUI, it seems normal:*_+ > Please see attached screen1.jpg > > -- This message was sent by Atlassian JIRA (v7.6.3#76005)