PTL test cannot setup user accounts for running testcases

Dear all,

I am also a beginner with PTL test, so when I run the sample testcase - SmokeTest. The error is:
setUpClassError: User pbsuser does not exist!

Therefore, I saw that PTLTestSuite impersonates some users for testing but when running this test, these user accounts do not exist. If so, do I need to create these accounts?

Please help me, thank you so much!

Yes. You will need to create the accounts for the various users that PTL uses.

@mr.ctminh : PTL needs specific users and groups.

Required users & groups are available

Users are advised to run "pbs_config --make-ug" to create the users and groups that PTL needs.
Run "pbs_config --check-ug" to verify that all the requisite users and groups are present.

https://pbspro.atlassian.net/wiki/spaces/DG/pages/13369353/PTL+Quick+Start+Guide#PTLQuickStartGuide-5.2Assumptions

Thank you so much, kjakkali!
However, when I run: pbs_config --make-ug, I have an error like this:
ERROR:ptl.utils.pbs_dshutils:err: [‘id: +: no such user’]
Traceback (most recent call last):
File “/home/ctminh/pbs/pbspro/test/fw/build/bin/pbs_config”, line 4, in
import(‘pkg_resources’).run_script(‘PbsTestLab==1.0.0’, ‘pbs_config’)
File “/usr/lib/python2.7/site-packages/setuptools-7.0-py2.7.egg/pkg_resources.py”, line 517, in run_script
return dist
File “/usr/lib/python2.7/site-packages/setuptools-7.0-py2.7.egg/pkg_resources.py”, line 1436, in run_script

File “/home/ctminh/pbs/pbspro/test/fw/build/lib/python2.7/site-packages/PbsTestLab-1.0.0-py2.7.egg/EGG-INFO/scripts/pbs_config”, line 438, in
rv = make_users_groups()
File “/home/ctminh/pbs/pbspro/test/fw/build/lib/python2.7/site-packages/PbsTestLab-1.0.0-py2.7.egg/EGG-INFO/scripts/pbs_config”, line 226, in make_users_groups
_, _, g_create, u_create = common_users_groups_ops()
File “/home/ctminh/pbs/pbspro/test/fw/build/lib/python2.7/site-packages/PbsTestLab-1.0.0-py2.7.egg/EGG-INFO/scripts/pbs_config”, line 192, in common_users_groups_ops
gm_actual = du.group_memberships(map(lambda g: str(g), PBS_GROUPS))
File “/home/ctminh/pbs/pbspro/test/fw/build/lib/python2.7/site-packages/PbsTestLab-1.0.0-py2.7.egg/ptl/utils/pbs_dshutils.py”, line 621, in group_memberships
for g in info[‘groups’]:
TypeError: ‘NoneType’ object is not iterable

Do you know what happens? Please help me. With this error, maybe I have to create PBS users or groups by myself on Linux System. As you said, I think this command is to make all of users or groups that we need, and don’t need to create anything else.

Thank you so much kjakkali!

Please pardon me when I post on two topics of mine and minghui, if you feel bothered, you can answer on this post.

@mr.ctminh : Did you install PTL before running pbs_config command?
If not follow the following link on how to install PTL.
link : https://pbspro.atlassian.net/wiki/spaces/DG/pages/13369353/PTL+Quick+Start+Guide

Run pbs_config as user (who has permission to create users ex: root)