cancel
Showing results for 
Search instead for 
Did you mean: 
TPeters
Flight Engineer
Flight Engineer
  • 1,297 Views

Error cleaning up lab exercise 9.8 "system-storage"

I don't know if it has been reported yet, but:

 

[student@workstation ~]$ lab finish system-storage

Finishing lab.

· Checking lab systems ........................................................................................................................................... SUCCESS
· Cleaning up exercise ........................................................................................................................................... FAIL
- Playbook failed: finish.yml
- servera: Remove the apache-vg volume group: Refuse to remove non-empty volume group apache-vg without force=yes
- Cannot continue finishing lab

 

6 Replies
Chetan_Tiwary_
Community Manager
Community Manager
  • 1,290 Views

Hello @TPeters !

I am unable to reproduce the issue from my side :

Chetan_Tiwary__0-1703694473922.png

In case you are facing this - you can create a fresh lab and check again. If that happens again in a fresh lab - raise a support case - it will be checked and verified by our team from backend.

0 Kudos
TPeters
Flight Engineer
Flight Engineer
  • 1,238 Views

Chetan,

Thank you for your response.

I do not have time to redo entire labs.

I stopped but kept my lab environment. I restarted it (not reset the host servera), I did do a new `lab start system-storage`, installed the rhel_system_roles collection there, and ran the get_storage.yml. Now even the `mount` command does not work. And the finish.yml that apparently is ran by `lab finish system-storage` still cannot remove the VG.

I'll reset servera and move on to the next lab.

%<---

[student@workstation ~]$ lab start system-storage

Starting lab.

· Checking lab systems .................................................................................................................................................... SUCCESS
· Adding exercise content ................................................................................................................................................. SUCCESS
· Ensuring required packages are installed ................................................................................................................................ SUCCESS

[student@workstation ~]$ cd system-storage

[student@workstation system-storage]$ ls -l
total 808
-rw-r--r--. 1 student student 192 Dec 28 04:26 ansible.cfg
drwxrwxr-x. 2 student student 22 Dec 28 04:26 collections
-rw-r--r--. 1 student student 1186 Dec 28 04:26 get-storage.yml
-rw-r--r--. 1 student student 37 Dec 28 04:26 inventory
-rw-r--r--. 1 student student 808333 Dec 28 04:26 redhat-rhel_system_roles-1.19.3.tar.gz

[student@workstation system-storage]$ ansible-galaxy collection install -p collections/ redhat-rhel_system_roles-1.19.3.tar.gz
Starting galaxy collection install process
Process install dependency map
Starting collection install process
Installing 'redhat.rhel_system_roles:1.19.3' to '/home/student/system-storage/collections/ansible_collections/redhat/rhel_system_roles'
redhat.rhel_system_roles:1.19.3 was installed successfully

[student@workstation system-storage]$ ansible-navigator run -m stdout get-storage.yml

PLAY [View storage configuration] **********************************************

TASK [Gathering Facts] *********************************************************
ok: [servera.lab.example.com]

TASK [Retrieve physical volumes] ***********************************************
changed: [servera.lab.example.com]

TASK [Display physical volumes] ************************************************
ok: [servera.lab.example.com] => {
"msg": [
" PV VG Fmt Attr PSize PFree ",
" /dev/vdb apache-vg lvm2 a-- 1020.00m 892.00m"
]
}

TASK [Retrieve volume groups] **************************************************
changed: [servera.lab.example.com]

TASK [Display volume groups] ***************************************************
ok: [servera.lab.example.com] => {
"msg": [
" VG #PV #LV #SN Attr VSize VFree ",
" apache-vg 1 1 0 wz--n- 1020.00m 892.00m"
]
}

TASK [Retrieve logical volumes] ************************************************
changed: [servera.lab.example.com]

TASK [Display logical volumes] *************************************************
ok: [servera.lab.example.com] => {
"msg": [
" LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert",
" log-lv apache-vg -wi-a----- 128.00m "
]
}

TASK [Retrieve mounted logical volumes] ****************************************
fatal: [servera.lab.example.com]: FAILED! => {"changed": true, "cmd": "mount | grep lv", "delta": "0:00:00.006597", "end": "2023-12-28 04:44:33.736392", "msg": "non-zero return code", "rc": 1, "start": "2023-12-28 04:44:33.729795", "stderr": "", "stderr_lines": [], "stdout": "", "stdout_lines": []}

PLAY RECAP *********************************************************************
servera.lab.example.com : ok=7 changed=3 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
Please review the log for errors.

[student@workstation system-storage]$ cd ..
[student@workstation ~]$ lab finish system-storage

Finishing lab.

· Checking lab systems .................................................................................................................................................... SUCCESS
· Cleaning up exercise .................................................................................................................................................... FAIL
- Playbook failed: finish.yml
- servera: Remove the apache-vg volume group: Refuse to remove non-empty volume group apache-vg without force=yes
- Cannot continue finishing lab

--->%

 

Chetan_Tiwary_
Community Manager
Community Manager
  • 1,233 Views

Ok @TPeters Please raise this issue along with the screenshot of the error via support case - I will check the issue from backend provide a resolution ( support case is required here ).

Also, in my previous reply - I requested to delete the entire lab and recreate fresh lab ( not just resetting a particular VM ) and recheck - no issues just raise the support case and it will be re-verified in your lab.

0 Kudos
ric
Flight Engineer Flight Engineer
Flight Engineer
  • 616 Views

Hi everyone,

For what is worth, today (4th August 2024), I'm having a similar error to what @TPeters was experiencing on 27th December 2023 (when TPeters started this topic), when I run the lab finish system-storage command (related to the "Section 9.8: Guided Exercise: Managing Storage" of "Chapter 9: Automating Linux Administration Tasks" of the RH294 - "Red Hat Enterprise Linux Automation with Ansible" online learning course -  https://rol.redhat.com/rol/app/courses/rh294-9.0/pages/ch09s08 ).

Here's the output that appears when I run lab finish system-storage :

[student@workstation ~]$ lab finish system-storage

Finishing lab.

· Checking lab systems .............................................................................. SUCCESS
· Cleaning up exercise .............................................................................. FAIL
- Playbook failed: finish.yml
- servera: Remove the content-lv and logs-lv logical volumes: One or more items failed
- Cannot continue finishing lab

In case it's useful, here is the output of the ansible-navigator run -m stdout get-storage.yml command that I executed just before running the lab finish system-storage command :

[student@workstation system-storage]$ ansible-navigator run -m stdout get-storage.yml

PLAY [View storage configuration] **********************************************

TASK [Gathering Facts] *********************************************************
ok: [servera.lab.example.com]

TASK [Retrieve physical volumes] ***********************************************
changed: [servera.lab.example.com]

TASK [Display physical volumes] ************************************************
ok: [servera.lab.example.com] => {
"msg": [
" PV VG Fmt Attr PSize PFree ",
" /dev/vdb apache-vg lvm2 a-- 1020.00m 828.00m"
]
}

TASK [Retrieve volume groups] **************************************************
changed: [servera.lab.example.com]

TASK [Display volume groups] ***************************************************
ok: [servera.lab.example.com] => {
"msg": [
" VG #PV #LV #SN Attr VSize VFree ",
" apache-vg 1 2 0 wz--n- 1020.00m 828.00m"
]
}

TASK [Retrieve logical volumes] ************************************************
changed: [servera.lab.example.com]

TASK [Display logical volumes] *************************************************
ok: [servera.lab.example.com] => {
"msg": [
" LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert",
" content-lv apache-vg -wi-ao---- 64.00m ",
" logs-lv apache-vg -wi-ao---- 128.00m "
]
}

TASK [Retrieve mounted logical volumes] ****************************************
changed: [servera.lab.example.com]

TASK [Display mounted logical volumes] *****************************************
ok: [servera.lab.example.com] => {
"msg": [
"/dev/mapper/apache--vg-content--lv on /var/www type xfs (rw,relatime,seclabel,attr2,inode64,logbufs=8,logbsize=32k,noquota)",
"/dev/mapper/apache--vg-logs--lv on /var/logs/httpd type xfs (rw,relatime,seclabel,attr2,inode64,logbufs=8,logbsize=32k,noquota)"
]
}

TASK [Retrieve /etc/fstab contents] ********************************************
changed: [servera.lab.example.com]

TASK [Display /etc/fstab contents] *********************************************
ok: [servera.lab.example.com] => {
"msg": [
"UUID=5e75a2b9-1367-4cc8-bb38-4d6abc3964b8\t/boot\txfs\tdefaults\t0\t0",
"UUID=fb535add-9799-4a27-b8bc-e8259f39a767\t/\txfs\tdefaults\t0\t0",
"UUID=7B77-95E7\t/boot/efi\tvfat\tdefaults,uid=0,gid=0,umask=077,shortname=winnt\t0\t2",
"/dev/mapper/apache--vg-content--lv /var/www xfs defaults 0 0",
"/dev/mapper/apache--vg-logs--lv /var/logs/httpd xfs defaults 0 0"
]
}

PLAY RECAP *********************************************************************
servera.lab.example.com : ok=11 changed=5 unreachable=0 failed=0 skipped=0 rescued=0 ignored=0

 

Chetan_Tiwary_
Community Manager
Community Manager
  • 535 Views

@ric I just tried the lab of v9 and I could not reproduce the error :

Screenshot from 2024-08-07 00-21-11.png

You can retry in a freshly created lab environment or raise a support case so that we can check and help you.

ric
Flight Engineer Flight Engineer
Flight Engineer
  • 483 Views

Hi, @Chetan_Tiwary_ 

Thanks for having checked for me the Lab exercise 9.8 "system-storage" of the RH294 course and for your reply. I've tried to DELETE the entire Lab environment and CREATE it again and I've tried again this Lab exercise 9.8 "system-storage" and I confirm that, this time, the "lab finish system-storage" command returned SUCCESS for both "Checking lab systems" and the "Cleaning up exercise" steps (so, it's no longer failing in the "Cleaning up exercise" step).

Thanks again.

0 Kudos
Join the discussion
You must log in to join this conversation.