action #67126
closedcoordination #42854: [functional][y][epic] Introduce relevant installation validation test modules
[functional][y] Add validation module for nis mm tests
0%
Description
In order to verify that "yast nis_server" and "yast nis" configuration on nis mm tests, works properly, a new module can be created for each test with following steps:
NIS server:
(as root)
- useradd nis_user -> in the current test, /home/nis_user folder is created and shared via nfs, so in order to avoid extra steps, the user added should be "nis_user".
- passwd nis_user
- chmod nis_user:users /home/nis_user -> current owner of the folder is "root".
- cd /var/yp
- make -> nis database needs to be aware of the new user.
- Check if /etc/defaultdomain and /etc/idmapd.conf contain the nis domain (nis.openqa.suse.de). At maps setup of nis_server module, all entries are selected. There can be a check in /var/yp/nis.openqa.suse.de/ if entries correspond
NIS client:
(after above actions on nis server are completed)
- ypcat passwd | grep nis_user / ypmatch nis_user passwd / getent passwd nis_user -> one option out of three, in order to verify that the client connection to nis server database is successful and new user is visible.
- su - nis_user
- pwd -> verify home directory of nis_user is /home/nis_user
- echo "nis works"> file1 -> verify write
- grep "nis works" -> verify read
- Check if /etc/yp.conf exists and has the entry "ypserv"
- Check if /etc/nsswitch.conf has expected entries e.g. "netgroup: files nis"
- Check if /etc/defaultdomain contains the nis domain
We should also extract settings to use same value for configuration and validation.
Updated by syrianidou_sofia over 4 years ago
parent ticket: https://progress.opensuse.org/issues/65349
Updated by riafarov over 4 years ago
- Due date set to 2020-06-16
- Category set to Enhancement to existing tests
- Target version set to SLE 15 SP2
I would only add some validation for the nfs version, if is explicitly set. And maybe for the mount options and nis policy settings, wdyt?
Other than that looks good.
Updated by syrianidou_sofia over 4 years ago
Some additional options
Server:
- We could add checks for nfs e.g. if /etc/export nfs options include "rw" and "no_root_squash" as defined during yast configuration but this is verified already in the last step of nis_server. Also, in module nis_client the last step is to echo a string in a file in nfs folder, as root which would fail if rw and no_root_squat were not in the export parameters.
- Check if /etc/defaultdomain and /etc/idmapd.conf contain the nis domain (nis.openqa.suse.de). At maps setup of nis_server module, all entries are selected. There can be a check in /var/yp/nis.openqa.suse.de/ if entries correspond
Client:
- Check if /etc/yp.conf exists and has the entry "ypserv "
- Check if /etc/nsswitch.conf has expected entries e.g. "netgroup: files nis"
- Check if /etc/defaultdomain contains the nis domain
Updated by riafarov over 4 years ago
- Description updated (diff)
- Status changed from New to Workable
- Estimated time set to 8.00 h
Updated by syrianidou_sofia over 4 years ago
- Status changed from Workable to In Progress
- Assignee set to syrianidou_sofia
Updated by JERiveraMoya over 4 years ago
PR (on draft): Add validation of yast2 NIS configuration functionality
Updated by riafarov over 4 years ago
- Due date changed from 2020-06-16 to 2020-06-30
Updated by syrianidou_sofia over 4 years ago
- Status changed from In Progress to Feedback
PR: https://github.com/os-autoinst/os-autoinst-distri-opensuse/pull/10505
Not sure if I should run VRs for opensuse or remove the tests from development job group.
Updated by syrianidou_sofia over 4 years ago
- Status changed from Feedback to Resolved
Test modified for osd and o3. After new build in o3, passed ( https://openqa.opensuse.org/tests/1315191 ). Updated Test plan.