Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

memory: Increase guest memory to 4G #5397

Merged
merged 1 commit into from
Feb 22, 2024

Conversation

hs0210
Copy link
Contributor

@hs0210 hs0210 commented Jan 19, 2024

The previous guest memory setting was 2G, but the half memory test would fail because 1G was not enough to maintain the normal operation of the guest.

Before:

(1/1) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domid.dom_opt_size_opt.no_cmd_flag: ERROR: Login timeout expired    (output: "exceeded 240 s timeout, last failure: Login timeout expired    (output: '')") (419.32 s)

After:

(1/1) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domid.dom_opt_size_opt.no_cmd_flag: PASS (72.23 s)

Copy link
Contributor

@cliping cliping left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGMT

@hs0210
Copy link
Contributor Author

hs0210 commented Jan 20, 2024

All setmem cases passed.

# /usr/local/bin/avocado run --vt-type libvirt --test-runner=runner --vt-machine-type arm64-mmio virsh.setmem --vt-connect-uri qemu:///system                                                                    
                                                                        
JOB ID     : ee04d1728c772b94bf0c64dd864db921e0023cec                                                                                                                                                                                         
JOB LOG    : /var/lib/avocado/job-results/job-2024-01-19T02.46-ee04d17/job.log                                                                                                                                                                
 (001/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.half_mem.domname.dom_arg_size_arg.cmd_flag_config: PASS (99.70 s)                                                                                     
 (002/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.half_mem.domname.dom_arg_size_arg.cmd_flag_current.manipulate_action.none.no_action: PASS (102.81 s)                                                  
 (003/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.half_mem.domname.dom_opt_size_opt.cmd_flag_config: PASS (101.97 s)                                                                                    
 (004/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.half_mem.domname.dom_opt_size_opt.cmd_flag_current.manipulate_action.none.no_action: PASS (103.12 s)                                                  
 (005/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.half_mem.domuuid.dom_arg_size_arg.cmd_flag_config: PASS (103.71 s)                                                                                    
 (006/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.half_mem.domuuid.dom_arg_size_arg.cmd_flag_current.manipulate_action.none.no_action: PASS (104.63 s)                                                  
 (007/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.half_mem.domuuid.dom_opt_size_opt.cmd_flag_config: PASS (101.93 s)                                                                                    
 (008/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.half_mem.domuuid.dom_opt_size_opt.cmd_flag_current.manipulate_action.none.no_action: PASS (101.52 s)                                                  
 (009/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.same_mem.domname.dom_arg_size_arg.cmd_flag_config: PASS (106.73 s)                                                                                    
 (010/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.same_mem.domname.dom_arg_size_arg.cmd_flag_current.manipulate_action.none.no_action: PASS (99.11 s)                                                   
 (011/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.same_mem.domname.dom_opt_size_opt.cmd_flag_config: PASS (103.41 s)                                                                                    
 (012/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.same_mem.domname.dom_opt_size_opt.cmd_flag_current.manipulate_action.none.no_action: PASS (103.40 s)                                                  
 (013/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.same_mem.domuuid.dom_arg_size_arg.cmd_flag_config: PASS (100.78 s)                                                                                    
 (014/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.same_mem.domuuid.dom_arg_size_arg.cmd_flag_current.manipulate_action.none.no_action: PASS (101.17 s)                                                  
 (015/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.same_mem.domuuid.dom_opt_size_opt.cmd_flag_config: PASS (100.63 s)                                                                                    
 (016/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.inactive.same_mem.domuuid.dom_opt_size_opt.cmd_flag_current.manipulate_action.none.no_action: PASS (99.02 s)                                                   
 (017/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domid.dom_arg_size_arg.no_cmd_flag: PASS (72.79 s)                                                                                            
 (018/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domid.dom_arg_size_arg.cmd_flag_live: PASS (71.33 s)                                                                                          
 (019/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domid.dom_arg_size_arg.cmd_flag_current.manipulate_action.none.no_action: PASS (68.99 s)                                                      
 (020/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domid.dom_opt_size_opt.no_cmd_flag: PASS (68.79 s)                                                                                            
 (021/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domid.dom_opt_size_opt.cmd_flag_live: PASS (66.68 s)                                                                                          
 (022/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domid.dom_opt_size_opt.cmd_flag_current.manipulate_action.none.no_action: PASS (68.10 s)                                                      
 (023/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domname.dom_arg_size_arg.no_cmd_flag: PASS (72.95 s)                                                                                          
 (024/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domname.dom_arg_size_arg.cmd_flag_live: PASS (69.48 s)                                                                                        
 (025/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domname.dom_arg_size_arg.cmd_flag_current.manipulate_action.none.no_action: PASS (70.05 s)                                                    
 (026/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domname.dom_arg_size_arg.cmd_flag_current.manipulate_action.save.before_setmem: PASS (72.38 s)                                                
 (027/180) type_specific.io-github-autotest-libvirt.virsh.setmem.valid_options.running.half_mem.domname.dom_arg_size_arg.cmd_flag_current.manipulate_action.save.after_setmem: PASS (80.46 s)
......
 (170/180) type_specific.io-github-autotest-libvirt.virsh.setmem.invalid_options.addtional_args.double_mem.nonsense_name: PASS (57.62 s)
 (171/180) type_specific.io-github-autotest-libvirt.virsh.setmem.invalid_options.addtional_args.double_mem.outrange_domid: PASS (57.37 s)
 (172/180) type_specific.io-github-autotest-libvirt.virsh.setmem.invalid_options.addtional_args.double_mem.bad_domuuid: PASS (59.60 s)
 (173/180) type_specific.io-github-autotest-libvirt.virsh.setmem.invalid_options.addtional_args.missing_size.missing_name: PASS (58.83 s)
 (174/180) type_specific.io-github-autotest-libvirt.virsh.setmem.invalid_options.addtional_args.missing_size.blank_name: PASS (60.28 s)
 (175/180) type_specific.io-github-autotest-libvirt.virsh.setmem.invalid_options.addtional_args.missing_size.nonsense_name: PASS (61.69 s)
 (176/180) type_specific.io-github-autotest-libvirt.virsh.setmem.invalid_options.addtional_args.missing_size.outrange_domid: PASS (60.88 s)
 (177/180) type_specific.io-github-autotest-libvirt.virsh.setmem.invalid_options.addtional_args.missing_size.bad_domuuid: PASS (60.43 s)
 (178/180) type_specific.io-github-autotest-libvirt.virsh.setmem.invalid_old_libvirt.dom_opt_size_arg: PASS (64.76 s)
 (179/180) type_specific.io-github-autotest-libvirt.virsh.setmem.invalid_old_libvirt.dom_arg_size_opt: PASS (64.58 s)
 (180/180) type_specific.io-github-autotest-libvirt.virsh.setmem.readonly: PASS (60.99 s)
RESULTS    : PASS 180 | ERROR 0 | FAIL 0 | SKIP 0 | WARN 0 | INTERRUPT 0 | CANCEL 0
JOB HTML   : /var/lib/avocado/job-results/job-2024-01-19T02.46-ee04d17/results.html
JOB TIME   : 12260.09 s

@@ -251,6 +251,10 @@ def print_debug_stats(original_inside_mem, original_outside_mem,
vmxml = vm_xml.VMXML.new_from_inactive_dumpxml(vm_name)
backup_xml = vmxml.copy()

vm_attrs = eval(params.get('vm_attrs'))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps, we may add some pre-check for host whether there is 4G memory available at that time. Otherwise just skip this case

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done, PTAL.

dzhengfy
dzhengfy previously approved these changes Feb 21, 2024
Copy link
Contributor

@dzhengfy dzhengfy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dzhengfy dzhengfy dismissed their stale review February 21, 2024 05:30

one left comment

@@ -17,6 +17,7 @@
# expected to fail on older libvirt.
setmem_old_libvirt_fail = "no"
take_regular_screendumps = no
vm_attrs = {'memory': 4, 'memory_unit': 'GiB', 'current_mem': 4, 'current_mem_unit': 'GiB'}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The virsh_cmd folder will be deprecated. We plan to make inside cases into corresponding feature folder. So could you please move the cfg and py files into libvirt/tests/cfg/memory/ and libvirt/tests/src/memory/ folders?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. PTAL.

The previous guest memory setting was 2G, but the half memory test
would fail because 1G was not enough to maintain the normal operation
of the guest.

Signed-off-by: Hu Shuai <[email protected]>
Copy link
Contributor

@dzhengfy dzhengfy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

@chunfuwen chunfuwen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@chunfuwen chunfuwen merged commit 70e4871 into autotest:master Feb 22, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants