{"id":1527,"date":"2021-02-12T08:36:32","date_gmt":"2021-02-12T13:36:32","guid":{"rendered":"https:\/\/cyburityllc.com\/?p=1527"},"modified":"2025-02-11T14:52:20","modified_gmt":"2025-02-11T19:52:20","slug":"useful-commands-to-manage-everyday-tasks-on-asterisk-vicidial-servers","status":"publish","type":"post","link":"https:\/\/dialer.one\/index.php\/useful-commands-to-manage-everyday-tasks-on-asterisk-vicidial-servers\/","title":{"rendered":"Useful Commands to manage everyday tasks on Asterisk\/Vicidial Servers"},"content":{"rendered":"\n<h2 class=\"wp-block-heading\">Useful Commands to manage everyday tasks on Asterisk\/Vicidial Servers<\/h2>\n\n\n\n<center><a href=\"https:\/\/www.kqzyfj.com\/click-101361115-15836239\" target=\"_blank\" rel=\"noopener\">\n<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.tqlkg.com\/image-101361115-15836239\" width=\"468\" height=\"60\" alt=\"\" border=\"0\" title=\"\"><\/a><\/center>\n\n\n\n<p>I wanted to put together a list of commands that I use often or daily that may help other people manage their days easier. If you have anything you use or think others would find useful, please comment below and I will add them with credit to you and your website or blog if you&#8217;d like. Ok so these commands will go over things for services such as Apache, MySQL, Vicidial, Asterisk, and more.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">MySQL Commands and examples:<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>### repair a broken Database Table\nrepair table vicidial_live_agents use_frm;\n\n\n### get level 9 users in vicidial\nmysql asterisk -u cron -p1234 -e \"select user,pass,active from vicidial_users where user_level='9'\"\n\n### check and repair mysql\nmysqlcheck -p --auto-repair --all-databases\n\n### show what IP's are in the Dynamic Portal IP set\nuse asterisk;\nselect computer_ip from vicidial_user_log where event = 'VICIBOX' group by computer_ip;\n\n\n### reset a user whos locked out due to too many login attempts through mysql instead of GUI (Thanks Venkat from vicidial.sh)\nmysql -e \"use asterisk; update vicidial_users set failed_login_count='0' where user='6666'\";\n\n\n### How to create a user in mysql - change user(cron) and pass(1234)\nCREATE USER 'cron'@'localhost' IDENTIFIED BY '1234';\nGRANT SELECT,INSERT,UPDATE,DELETE,LOCK TABLES on asterisk.* TO cron@'%' IDENTIFIED BY '1234';\nGRANT SELECT,INSERT,UPDATE,DELETE,LOCK TABLES on asterisk.* TO cron@localhost IDENTIFIED BY '1234';\nGRANT RELOAD ON *.* TO cron@'%';\nGRANT RELOAD ON *.* TO cron@localhost;\n\n### change root password(to delete it leave it BY '')\nALTER USER 'root'@'localhost' IDENTIFIED BY 'password';\n\n### check a user groups permissions(replace 'ADMIN' accordingly)\nmysql -u cron -p1234 asterisk -e \"select * from vicidial_user_groups where user_group='ADMIN'\\G\"\n\n####### if leads wont load or you get \"no one in your session\"\nnano \/etc\/my.cnf\nLook for sql_mode and change it to sqlmode=\"\"<\/code><\/pre>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"616\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" src=\"https:\/\/cyburityllc.com\/wp-content\/uploads\/2021\/02\/image-5-1024x616.png\" alt=\"\" class=\"wp-image-1531\" title=\"\" srcset=\"https:\/\/dialer.one\/wp-content\/uploads\/2021\/02\/image-5-1024x616.png 1024w, https:\/\/dialer.one\/wp-content\/uploads\/2021\/02\/image-5-600x361.png 600w, https:\/\/dialer.one\/wp-content\/uploads\/2021\/02\/image-5-300x181.png 300w, https:\/\/dialer.one\/wp-content\/uploads\/2021\/02\/image-5-768x462.png 768w, https:\/\/dialer.one\/wp-content\/uploads\/2021\/02\/image-5-500x301.png 500w, https:\/\/dialer.one\/wp-content\/uploads\/2021\/02\/image-5-800x482.png 800w, https:\/\/dialer.one\/wp-content\/uploads\/2021\/02\/image-5.png 1108w\" \/><figcaption class=\"wp-element-caption\">mysql -u cron -p1234 asterisk -e &#8220;select * from vicidial_user_groups where user_group=&#8217;ADMIN&#8217;\\G&#8221;<\/figcaption><\/figure>\n<\/div>\n\n\n<center><a href=\"https:\/\/www.tkqlhce.com\/click-101361114-15836241\" target=\"_top\" rel=\"noopener\">\n<img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.ftjcfx.com\/image-101361114-15836241\" width=\"300\" height=\"250\" alt=\"\" border=\"0\" title=\"\"><\/a><\/center>\n\n\n\n<h3 class=\"wp-block-heading\">Other useful commands<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>### watch asterisk messages thru linux cli ######\ntail -f \/var\/log\/asterisk\/messages\n\n\n####### apache tools ############\ncheck web connections: netstat -tuna | grep \":80\" | wc -l\n\n\n##### Useful Vicidial Commands for Linux ##########\n\/usr\/share\/astguiclient\/ADMIN_keepalive_ALL.pl --cu3way\n\/usr\/share\/astguiclient\/AST_manager_listen.pl --debugX\n\/usr\/share\/AST_DB_action.pl --debugX\n\n#### Check if Dahdi(Meetme\/Vicidial Conferences) is running ####\ndahdi_cfg -vv\nIf its not run this command: \nmodprobe dahdi\n\n\n### check keepalives\ncat \/etc\/astguiclient.conf | grep VARactive_keepalives\n\n\n\n##### viciphone time for autologin \n$webphone_call_seconds = '5 ; in options.php in agc dir\n\n\n\n### upgrade vici ####\ncd \/usr\/src\/astguiclient\nsvn checkout svn:\/\/svn.eflo.net:3690\/agc_2-X\/trunk\ncd trunk\nperl install.pl\n\nmysql -p -f --database=asterisk &lt; \/usr\/src\/astguiclient\/trunk\/extras\/upgrade_2.14.sql\n\n\n### certbot renewal command #####\ncertbot certonly --cert-name cyburityllc.com -d sunfun.cyburityllc.com -d mail.cyburityllc.com -d sunfunnow.cyburityllc.com -d cyburity.ml -d cyburity.ga -d cyburity.gq -d cyburity.cf -d informationtechnology.gq -d cyburityllc.com -d www.cyburityllc.com -d cyburhack.com -d cyburhacker.com -d cyburshield.com -d cyberdialer.net -d www.cyburdial.com -d www.cyberdialer.net -d cyburphone.com -d dialer.one -cyburdialer.com -d contactcentersrus.com -d fldream.cyburityllc.com -d www.contactcentersrus.com -d portal.contactcentersrus.com -d cyburdialer.com-d cyburdial.com\n\n\n\n### to check whats eating all the ram\nps aux | awk '{print $2, $4, $11}' | sort -k2rn | head -n 20\n\n#### cpu usage\nps -eo pcpu,pid,user,args | sort -k 1 -r | head -11\n\n## check HDD space\ndf -h\n\n### find the largest files and folders on your linux server(good to see whats taking up space) - This will find the top 20 files and folders, try it from \/\ndu -ah | sort -hr | head -n 20\n\n### check processors\ngrep processor \/proc\/cpuinfo | wc -l\n\n### tcp dump for ports(change accordingly) #####\ntcpdump -nttv -s 0 -i eth0 port 80\n\n#### check connections to a port ##########\nnetstat -tuna | grep \":5038\" | wc -l\n\n\n###clear dns cache\n\/etc\/init.d\/nscd restart\n\n###For a \"live\" view showing the logic involved in dialing:\nscreen -r ASTVDauto\n\nctrl-a - ctrl-d to get out of it.\n\n###perl install based on asterisk version\nperl install.pl --copy_sample_conf_files --asterisk_version=11.X\n\n### start up asterisk\n\/usr\/share\/astguiclient\/start_asterisk_boot.pl\n\n\/usr\/share\/astguiclient\/ADMIN_keepalive_ALL.pl --cu3way\n\n\n\n###VOLUME FOR AST13########\nWith Asterisk 13, the mechanism in Asterisk that allowed for volume changes and muting of meetme participants had been causing random crashes in Asterisk. We now disable this functionality by default, but if you want to enable it, all you have to do is use the agc\/options.php setting of \"$ast13_volume_override = '1';\"\n\n    \n\n####USEFUL SVN TOOLS#######\n\n\nBeware of the version in system settings. To be absolutely certain to version match:\n\nSVN is used to manage the \"install directory\" (\/usr\/src\/astguiclient\/trunk)\n\nThe install directory has a group of sql files that are used to upgrade from the first version to NOW (based on the svn revision level presently in THAT directory).\n\nWhen your last sql upgrade file has a last line indicating that the db schema value should be what is presently shown in your System Settings ... you have a match. All your code will match your entire DB if you run install.pl with that version loaded.\n\nAnything else is more of a \"sort of\" match. That's the only truly reliable method. How you get there is a matter of experience and knowledge of svn. But upgrading\/downgrading that svn repository until you get lucky and it matches is the easiest amateur way to get a lock-on match of your present db schema.\n\nstart here:\n\nCODE: \ntail \/usr\/src\/astguiclient\/trunk\/extras\/upgrade_2.14.sql | grep db_schema_version\nmysql -u cron -p1234 asterisk -e \"select * from system_settings\\G\" | grep schema\ncd \/usr\/src\/astguiclient\/trunk\nsvn info | grep Revision\n\nCompare the db schema in system settings to the db schema in the upgrade.sql file.\nNote the svn revision level.\nIncrease or decrease the svn revision level with \"svn up -r ####\" and ... try again until the db schema in the sql file and system settings match. Example:\n\nsvn up -r 2946\n\nThen run perl install.pl. Example:\nCODE: SELECT ALL\ncd \/usr\/src\/astguiclient\/trunk\nperl install.pl --copy_sample_conf_files\n\n\nNote that --copy_sample_conf_files will overwrite the .conf files presently in the system. Any that you have edited will need to be re-edited. Such as externip=xxx.xx.xx.x in sip.conf. While updating these isn't always necessary, NOT updating them has been known to blow an entire workday for simple \"missed\" change that's very difficult to find otherwise. Skip copy_sample_conf_files at your own risk. 8-)\n\n### for webrtc phone issue with chrome 87 update\nzypper in ncurses-devel libxml2-devel sqlite-devel libsrtp-devel libuuid-devel openssl-devel\n \n\n\n<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Useful Commands to manage everyday tasks on Asterisk\/Vicidial Servers I wanted to put together a list of commands that I use often or daily that may help other people manage their days easier. If you have anything you use or think others would find useful, please comment below and I will add them with credit [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":1528,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"content-type":"","_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[96],"tags":[],"class_list":["post-1527","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-vicidial"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/dialer.one\/wp-content\/uploads\/2021\/02\/image-4.png","jetpack-related-posts":[{"id":4086,"url":"https:\/\/dialer.one\/index.php\/how-to-setup-a-vicidial-cluster-with-scratch-installs\/","url_meta":{"origin":1527,"position":0},"title":"How to &#8211; Setup a ViciDial Cluster with scratch installs","author":"carpenox","date":"January 27, 2024","format":false,"excerpt":"How to - Setup a ViciDial Cluster with scratch installs This article is going to go over the steps I suggest to take in order to setup a ViciDial Cluster when using scratch install methods. I do things a little different when it comes to this to prepare for worst\u2026","rel":"","context":"In &quot;CyburDial&quot;","block_context":{"text":"CyburDial","link":"https:\/\/dialer.one\/index.php\/category\/cyburdial\/"},"img":{"alt_text":"Vicidial cluster","src":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2023\/12\/image-2.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2023\/12\/image-2.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2023\/12\/image-2.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2023\/12\/image-2.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":2394,"url":"https:\/\/dialer.one\/index.php\/how-to-setup-a-vicidial-cluster\/","url_meta":{"origin":1527,"position":1},"title":"How to &#8211; Setup a ViciDial Cluster","author":"carpenox","date":"March 12, 2022","format":false,"excerpt":"How to - Setup a ViciDial Cluster This article is going to go over the steps I suggest to take in order to setup a ViciDial Cluster. I do things a little different when it comes to this to prepare for worst case scenario that a server may have problems\u2026","rel":"","context":"In &quot;CyburDial&quot;","block_context":{"text":"CyburDial","link":"https:\/\/dialer.one\/index.php\/category\/cyburdial\/"},"img":{"alt_text":"ViciDial Cluster","src":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2022\/03\/image-4.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2022\/03\/image-4.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2022\/03\/image-4.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2022\/03\/image-4.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":2496,"url":"https:\/\/dialer.one\/index.php\/how-to-add-conferences-for-add-on-servers-to-a-cluster\/","url_meta":{"origin":1527,"position":2},"title":"How to &#8211; Add conferences for add on servers to a cluster","author":"carpenox","date":"May 21, 2022","format":false,"excerpt":"How to - Add conferences for add on servers to a cluster This article will show you how to add additional servers to your cluster and make sure all the conferences are also added. Its just a few simple steps needed to have it done for you. Step 1 -\u2026","rel":"","context":"In &quot;Vicidial&quot;","block_context":{"text":"Vicidial","link":"https:\/\/dialer.one\/index.php\/category\/vicidial\/"},"img":{"alt_text":"vicidial conferences","src":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2022\/05\/image.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2022\/05\/image.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2022\/05\/image.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2022\/05\/image.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":1913,"url":"https:\/\/dialer.one\/index.php\/how-to-install-asterisk-16-on-vicidial\/","url_meta":{"origin":1527,"position":3},"title":"How to &#8211; Install Asterisk 16 on Vicidial","author":"carpenox","date":"April 7, 2021","format":false,"excerpt":"How to - Install Asterisk 16 on Vicidial In this article, I will demonstrate Install Asterisk 16 on Vicidial aka vicibox 9. In theory it should also work for you CentOS lovers (bleh) too, but just change the zypper commands to yum. Step 1 - Remove Asterisk 13 & install\u2026","rel":"","context":"With 5 comments","block_context":{"text":"With 5 comments","link":"https:\/\/dialer.one\/index.php\/how-to-install-asterisk-16-on-vicidial\/#comments"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2021\/04\/image-4.png?resize=350%2C200&ssl=1","width":350,"height":200},"classes":[]},{"id":2216,"url":"https:\/\/dialer.one\/index.php\/security-vulnerability-in-vicidial-codebase-update-now\/","url_meta":{"origin":1527,"position":4},"title":"Security vulnerability in Vicidial codebase &#8211; Update now!","author":"carpenox","date":"October 2, 2021","format":false,"excerpt":"Security vulnerability in Vicidial codebase - Update now! There is a major security hole in the vicidial codebase for any SVN version below 3509. Please see the email below. Vicidial exploit Please make sure you update your SVN and your OS, to update your SVN run these commands: cd \/usr\/src\/astguiclient\/trunksvn\u2026","rel":"","context":"Similar post","block_context":{"text":"Similar post","link":""},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2021\/10\/image.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2021\/10\/image.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2021\/10\/image.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2021\/10\/image.png?resize=700%2C400&ssl=1 2x"},"classes":[]},{"id":1512,"url":"https:\/\/dialer.one\/index.php\/how-to-update-your-vicidial-version-with-subversion\/","url_meta":{"origin":1527,"position":5},"title":"How to &#8211; Update your Vicidial version with subversion","author":"carpenox","date":"February 4, 2021","format":false,"excerpt":"The version number shows in the top right corner. Updating Vicidial This is a pretty simple process. Only a few commands needs to be run in order to update your vicidial\/cyburdial version via the Linux Command Line Interface(CLI) cd \/usr\/src\/astguiclient svn checkout svn:\/\/svn.eflo.net:3690\/agc_2-X\/trunk cd trunk perl install.pl Then you may\u2026","rel":"","context":"With 2 comments","block_context":{"text":"With 2 comments","link":"https:\/\/dialer.one\/index.php\/how-to-update-your-vicidial-version-with-subversion\/#comments"},"img":{"alt_text":"SVN Update","src":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2021\/02\/versionupdate.png?resize=350%2C200&ssl=1","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2021\/02\/versionupdate.png?resize=350%2C200&ssl=1 1x, https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2021\/02\/versionupdate.png?resize=525%2C300&ssl=1 1.5x, https:\/\/i0.wp.com\/dialer.one\/wp-content\/uploads\/2021\/02\/versionupdate.png?resize=700%2C400&ssl=1 2x"},"classes":[]}],"jetpack_likes_enabled":true,"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/dialer.one\/index.php\/wp-json\/wp\/v2\/posts\/1527","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/dialer.one\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dialer.one\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dialer.one\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dialer.one\/index.php\/wp-json\/wp\/v2\/comments?post=1527"}],"version-history":[{"count":0,"href":"https:\/\/dialer.one\/index.php\/wp-json\/wp\/v2\/posts\/1527\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/dialer.one\/index.php\/wp-json\/wp\/v2\/media\/1528"}],"wp:attachment":[{"href":"https:\/\/dialer.one\/index.php\/wp-json\/wp\/v2\/media?parent=1527"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dialer.one\/index.php\/wp-json\/wp\/v2\/categories?post=1527"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dialer.one\/index.php\/wp-json\/wp\/v2\/tags?post=1527"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}