Check profileing status:
db.getProfilingStatus()
db.getProfilingLevel()
More information: https://docs.mongodb.com/manual/tutorial/manage-the-database-profiler/
Find slow queries: https://gist.github.com/rantav/3433277
--- | |
apiVersion: v1 | |
kind: Namespace | |
metadata: | |
name: test | |
labels: | |
name: test | |
--- |
;; store all backup and autosave files in the tmp dir | |
(setq backup-directory-alist | |
`((".*" . ,temporary-file-directory))) | |
(setq auto-save-file-name-transforms | |
`((".*" ,temporary-file-directory t))) |
;;; $DOOMDIR/config.el -*- lexical-binding: t; -*- | |
;; Place your private configuration here! Remember, you do not need to run 'doom | |
;; sync' after modifying this file! | |
(setq exec-path (append '("~/bin" "~/.asdf/shims" "/usr/local/bin" "/usr/local/sbin") exec-path)) | |
(add-to-list 'load-path "/Volumes/iMacPro/Src/tern/emacs/") | |
(autoload 'tern-mode "tern.el" nil t) | |
;; Some functionality uses this to identify you, e.g. GPG configuration, email | |
;; clients, file templates and snippets. | |
(setq user-full-name "Kan" |
;;; $DOOMDIR/config.el -*- lexical-binding: t; -*- | |
;; Place your private configuration here! Remember, you do not need to run 'doom | |
;; sync' after modifying this file! | |
(setq exec-path (append '("~/bin" "~/.asdf/shims" "/usr/local/bin" "/usr/local/sbin") exec-path)) | |
(add-to-list 'load-path "/Volumes/iMacPro/Src/tern/emacs/") | |
(autoload 'tern-mode "tern.el" nil t) | |
;; Some functionality uses this to identify you, e.g. GPG configuration, email | |
;; clients, file templates and snippets. | |
(setq user-full-name "Kan" |
;;; $DOOMDIR/config.el -*- lexical-binding: t; -*- | |
;; Place your private configuration here! Remember, you do not need to run 'doom | |
;; sync' after modifying this file! | |
(setq exec-path (append '("~/bin" "~/.asdf/shims" "/usr/local/bin" "/usr/local/sbin") exec-path)) | |
(add-to-list 'load-path "/Volumes/iMacPro/Src/tern/emacs/") | |
(autoload 'tern-mode "tern.el" nil t) | |
;; Some functionality uses this to identify you, e.g. GPG configuration, email | |
;; clients, file templates and snippets. | |
(setq user-full-name "Kan" |
;;; $DOOMDIR/config.el -*- lexical-binding: t; -*- | |
;; Place your private configuration here! Remember, you do not need to run 'doom | |
;; sync' after modifying this file! | |
(setq exec-path (append '("~/bin" "~/.asdf/shims" "/usr/local/bin" "/usr/local/sbin") exec-path)) | |
;; Some functionality uses this to identify you, e.g. GPG configuration, email | |
;; clients, file templates and snippets. | |
(setq user-full-name "Kan" | |
user-mail-address "[email protected]") |
tmux is a "terminal multiplexer", it enables a number of terminals to be accessed and controlled from a single terminal. | |
If you use Debian/Ubuntu, you can just run apt-get install tmux, and voila. | |
Since the title was about centos 7, then do the following step to install tmux. | |
(1). tmux has a library dependency on libevent which, of course, isn’t installed by default. | |
$ wget https://github.com/downloads/libevent/libevent/libevent-2.0.21-stable.tar.gz | |
$ tar xzvf libevent-2.0.21-stable.tar.gz | |
$ cd libevent-2.0.21-stable |
Check profileing status:
db.getProfilingStatus()
db.getProfilingLevel()
More information: https://docs.mongodb.com/manual/tutorial/manage-the-database-profiler/
Find slow queries: https://gist.github.com/rantav/3433277
db.currentOp().inprog.forEach( | |
function(op) { | |
if(op.secs_running > 5 && op.op == 'query') printjson(op); | |
} | |
) |
db.currentOp().inprog.forEach( | |
function(op) { | |
if(op.secs_running > 5 && op.op == 'query') printjson(op); | |
} | |
) |