Skip to main content

Perl Script Slow

Comments

3 comments

  • GOT
    If your script has no php reliances (which is unlikely) then running php as fpm would not matter. You may want to look at your my.cnf on the old server vs. the new. You may have had a better config installed. The default cpanel config does not have a lot of optimization in place. its also possible that the IO is more constrained on the new VM. Run top while you are running your script. What does load go to and what does the IO or wa % indicate during the process?
    0
  • BobHoliday
    Thank you for the reply. I saw peaks of ~62% CPU and 0.2% Mem for the process. WA got to 4.0 briefly ( I don't have a clue what 'WA' is). I have tweaked the my.cnf somewhat based on suggestions from mysqltuner.pl. it's currently (and was when I saw the above results): [mysqld] default-storage-engine=MyISAM innodb_file_per_table=1 innodb_log_file_size=16M innodb_buffer_pool_instances=1 performance-schema=0 max_allowed_packet=268435456 open_files_limit=10000 local-infile=0 max_connections = 200 join_buffer_size=8M tmp_table_size=128M max_heap_table_size=128M performance_schema = ON query_cache_size=0 query_cache_type=0 query_cache_limit=8M key_buffer_size=32M On my old server it's different you're quite right - is this related to the speediness: [mysqld] performance-schema=0 max_allowed_packet=268435456 key_buffer_size=512M thread_concurrency=4 open_files_limit=10000 innodb_file_per_table=1 read_rnd_buffer_size=16M socket="/var/lib/mysql/mysql.sock" read_buffer_size=1M max_connections=80 port=3306 myisam_sort_buffer_size=64M skip-external-locking query_cache_type=1 query_cache_size=256M query_cache_limit=2M tmp_table_size=32M max_heap_table_size=32M bind-address=127.0.0.1 join_buffer_size=4M local-infile=0 innodb_buffer_pool_size=128M sort_buffer_size=1M table_open_cache=4096 thread_cache_size=8 server-id=1 default-storage-engine=MyISAM [myisamchk] sort_buffer_size=64M read_buffer=2M key_buffer_size=64M write_buffer=2M [mysql] no-auto-rehash
    0
  • cPanelLauren
    Hi @BobHoliday It could definitely be related. You might want to run something like mysql tuner for optimization suggestions. The thread here has some useful insights as well: Thanks!
    0

Please sign in to leave a comment.