Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Last login: Thu Jan 10 21:36:46 on ttys002
- MacBook-Air:~ rolando$ pwd
- /Users/rolando
- MacBook-Air:~ rolando$ cd m
- m001/
- m103-vagrant-env/
- mobile.ovpn
- mongo.js
- mongodb-osx-x86_64-enterprise-4.0.4/
- mongodb-osx-x86_64-enterprise-4.0.4.tar
- myfile.js
- mymac.ovpn
- MacBook-Air:~ rolando$ cd m103-vagrant-env/
- MacBook-Air:m103-vagrant-env rolando$ ls
- MacBook-Air:m103-vagrant-env rolando$ ls
- MacBook-Air:m103-vagrant-env rolando$ ls
- MacBook-Air:m103-vagrant-env rolando$ cd ..
- MacBook-Air:~ rolando$ ls
- Applications land.ovpn
- Applications (Parallels) law
- Desktop letsencrypt.log
- Documents lighttpd.conf
- Downloads lighttpd.pem
- Library log
- Movies m001
- Music m103-vagrant-env
- Nextcloud mobile.ovpn
- Nextcloud2 mongo.js
- Parallels mongodb-osx-x86_64-enterprise-4.0.4
- Pictures mongodb-osx-x86_64-enterprise-4.0.4.tar
- Public myfile.js
- VirtualBox VMs mymac.ovpn
- WebstormProjects newsapi
- boa.ovpn node-weather
- dano.ovpn node-weather2
- db-1540681831922.json node_modules
- db.json nodejs
- eagle.ovpn ownCloud
- elasticsearch package-lock.json
- familylaw phonepad.ovpn
- frog.gif prico.ovpn
- ipad.ovpn program.js
- iphone.ovpn udemy
- javascripting university
- json-server-api
- MacBook-Air:~ rolando$ cd university/
- .DS_Store m103/
- MacBook-Air:~ rolando$ cd university/m103/
- .DS_Store m103-vagrant-env/
- MacBook-Air:~ rolando$ cd university/m103/m103-vagrant-env/
- MacBook-Air:m103-vagrant-env rolando$ ls
- Vagrantfile provision-mongod
- dataset shared
- MacBook-Air:m103-vagrant-env rolando$ vagrant up
- Bringing machine 'mongod-m103' up with 'virtualbox' provider...
- ==> mongod-m103: Clearing any previously set forwarded ports...
- ==> mongod-m103: Clearing any previously set network interfaces...
- ==> mongod-m103: Preparing network interfaces based on configuration...
- mongod-m103: Adapter 1: nat
- mongod-m103: Adapter 2: hostonly
- ==> mongod-m103: Forwarding ports...
- mongod-m103: 22 (guest) => 2222 (host) (adapter 1)
- ==> mongod-m103: Running 'pre-boot' VM customizations...
- ==> mongod-m103: Booting VM...
- ==> mongod-m103: Waiting for machine to boot. This may take a few minutes...
- mongod-m103: SSH address: 127.0.0.1:2222
- mongod-m103: SSH username: vagrant
- mongod-m103: SSH auth method: private key
- ==> mongod-m103: Machine booted and ready!
- ==> mongod-m103: Checking for guest additions in VM...
- mongod-m103: The guest additions on this VM do not match the installed version of
- mongod-m103: VirtualBox! In most cases this is fine, but in rare cases it can
- mongod-m103: prevent things such as shared folders from working properly. If you see
- mongod-m103: shared folder errors, please make sure the guest additions within the
- mongod-m103: virtual machine match the version of VirtualBox you have installed on
- mongod-m103: your host and reload your VM.
- mongod-m103:
- mongod-m103: Guest Additions Version: 4.3.36
- mongod-m103: VirtualBox Version: 5.2
- ==> mongod-m103: Setting hostname...
- ==> mongod-m103: Configuring and enabling network interfaces...
- ==> mongod-m103: Mounting shared folders...
- mongod-m103: /shared => /Users/rolando/university/m103/m103-vagrant-env/shared
- mongod-m103: /dataset => /Users/rolando/university/m103/m103-vagrant-env/dataset
- mongod-m103: /vagrant => /Users/rolando/university/m103/m103-vagrant-env
- ==> mongod-m103: Machine already provisioned. Run `vagrant provision` or use the `--provision`
- ==> mongod-m103: flag to force provisioning. Provisioners marked to run always will still run.
- MacBook-Air:m103-vagrant-env rolando$ vagrant ssh
- Welcome to Ubuntu 14.04.5 LTS (GNU/Linux 3.13.0-164-generic x86_64)
- * Documentation: https://help.ubuntu.com/
- System information as of Fri Jan 11 22:09:11 UTC 2019
- System load: 0.74 Processes: 94
- Usage of /: 6.4% of 39.34GB Users logged in: 0
- Memory usage: 7% IP address for eth0: 10.0.2.15
- Swap usage: 0% IP address for eth1: 192.168.103.100
- Graph this data and manage this system at:
- https://landscape.canonical.com/
- Get cloud support with Ubuntu Advantage Cloud Guest:
- http://www.ubuntu.com/business/services/cloud
- New release '16.04.5 LTS' available.
- Run 'do-release-upgrade' to upgrade to it.
- Last login: Fri Jan 11 02:52:45 2019 from 10.0.2.2
- vagrant@m103:~$ mongod --port 3000 --dbpath first_mongod --logpath first_mongod/mongod.log --fork
- about to fork child process, waiting until server is ready for connections.
- forked process: 1954
- child process started successfully, parent exiting
- vagrant@m103:~$ exit
- logout
- Connection to 127.0.0.1 closed.
- MacBook-Air:m103-vagrant-env rolando$ vagrant halt
- ==> mongod-m103: Attempting graceful shutdown of VM...
- MacBook-Air:m103-vagrant-env rolando$ ls
- Vagrantfile provision-mongod
- dataset shared
- MacBook-Air:m103-vagrant-env rolando$ pwd
- /Users/rolando/university/m103/m103-vagrant-env
- MacBook-Air:m103-vagrant-env rolando$ ls
- Vagrantfile provision-mongod
- dataset shared
- MacBook-Air:m103-vagrant-env rolando$ pwd
- /Users/rolando/university/m103/m103-vagrant-env
- MacBook-Air:m103-vagrant-env rolando$ ls
- Vagrantfile provision-mongod
- dataset shared
- MacBook-Air:m103-vagrant-env rolando$ vagrant up
- Bringing machine 'mongod-m103' up with 'virtualbox' provider...
- ==> mongod-m103: Clearing any previously set forwarded ports...
- ==> mongod-m103: Clearing any previously set network interfaces...
- ==> mongod-m103: Preparing network interfaces based on configuration...
- mongod-m103: Adapter 1: nat
- mongod-m103: Adapter 2: hostonly
- ==> mongod-m103: Forwarding ports...
- mongod-m103: 22 (guest) => 2222 (host) (adapter 1)
- ==> mongod-m103: Running 'pre-boot' VM customizations...
- ==> mongod-m103: Booting VM...
- ==> mongod-m103: Waiting for machine to boot. This may take a few minutes...
- mongod-m103: SSH address: 127.0.0.1:2222
- mongod-m103: SSH username: vagrant
- mongod-m103: SSH auth method: private key
- ==> mongod-m103: Machine booted and ready!
- ==> mongod-m103: Checking for guest additions in VM...
- mongod-m103: The guest additions on this VM do not match the installed version of
- mongod-m103: VirtualBox! In most cases this is fine, but in rare cases it can
- mongod-m103: prevent things such as shared folders from working properly. If you see
- mongod-m103: shared folder errors, please make sure the guest additions within the
- mongod-m103: virtual machine match the version of VirtualBox you have installed on
- mongod-m103: your host and reload your VM.
- mongod-m103:
- mongod-m103: Guest Additions Version: 4.3.36
- mongod-m103: VirtualBox Version: 5.2
- ==> mongod-m103: Setting hostname...
- ==> mongod-m103: Configuring and enabling network interfaces...
- ==> mongod-m103: Mounting shared folders...
- mongod-m103: /shared => /Users/rolando/university/m103/m103-vagrant-env/shared
- mongod-m103: /dataset => /Users/rolando/university/m103/m103-vagrant-env/dataset
- mongod-m103: /vagrant => /Users/rolando/university/m103/m103-vagrant-env
- ==> mongod-m103: Machine already provisioned. Run `vagrant provision` or use the `--provision`
- ==> mongod-m103: flag to force provisioning. Provisioners marked to run always will still run.
- MacBook-Air:m103-vagrant-env rolando$ vagrant ssh
- Welcome to Ubuntu 14.04.5 LTS (GNU/Linux 3.13.0-164-generic x86_64)
- * Documentation: https://help.ubuntu.com/
- System information as of Fri Jan 11 22:36:32 UTC 2019
- System load: 0.37 Processes: 89
- Usage of /: 6.4% of 39.34GB Users logged in: 0
- Memory usage: 6% IP address for eth0: 10.0.2.15
- Swap usage: 0% IP address for eth1: 192.168.103.100
- Graph this data and manage this system at:
- https://landscape.canonical.com/
- Get cloud support with Ubuntu Advantage Cloud Guest:
- http://www.ubuntu.com/business/services/cloud
- New release '16.04.5 LTS' available.
- Run 'do-release-upgrade' to upgrade to it.
- vagrant@m103:~$ mongod --port 2700 --dbpath data/db/ --logpath data/mongod.log --fork --bind_ip "127.0.0.1,192.168.1.100 --auth
- > ^C
- vagrant@m103:~$ mongod --port 2700 --dbpath data/db/ --logpath data/mongod.log --fork --bind_ip "127.0.0.1,192.168.1.100" --auth
- about to fork child process, waiting until server is ready for connections.
- forked process: 1954
- ERROR: child process failed, exited with error number 100
- To see additional information in this output, start without the "--fork" option.
- vagrant@m103:~$ mongod --port 2700 --dbpath data/db/ --logpath data/mongod.log --bind_ip "127.0.0.1,192.168.1.100" --auth --fork
- about to fork child process, waiting until server is ready for connections.
- forked process: 1959
- ERROR: child process failed, exited with error number 100
- To see additional information in this output, start without the "--fork" option.
- vagrant@m103:~$ mongod --port 2700 --dbpath data/db/ --logpath data/mongod.log --bind_ip "127.0.0.1,192.168.1.100" --auth
- 2019-01-11T22:43:41.963+0000 I CONTROL [main] log file "/home/vagrant/data/mongod.log" exists; moved to "/home/vagrant/data/mongod.log.2019-01-11T22-43-41".
- vagrant@m103:~$ clear
- vagrant@m103:~$ mongod --port 2700 --dbpath data/db/ --logpath data/mongod.log --bind_ip "127.0.0.1,192.168.1.100" --auth
- 2019-01-11T22:43:55.198+0000 I CONTROL [main] log file "/home/vagrant/data/mongod.log" exists; moved to "/home/vagrant/data/mongod.log.2019-01-11T22-43-55".
- vagrant@m103:~$ mongod --port 2700 --dbpath data/db/ --fork --bind_ip "127.0.0.1,192.168.1.100" --auth
- BadValue: --fork has to be used with --logpath or --syslog
- try 'mongod --help' for more information
- vagrant@m103:~$ mongod --port 2700 --dbpath data/db/ --bind_ip "127.0.0.1,192.168.1.100" --auth
- 2019-01-11T22:45:24.023+0000 I CONTROL [initandlisten] MongoDB starting : pid=1971 port=2700 dbpath=data/db/ 64-bit host=m103
- 2019-01-11T22:45:24.023+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:45:24.024+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:45:24.025+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:45:24.025+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:45:24.026+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:45:24.026+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:45:24.027+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:45:24.028+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:45:24.028+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:45:24.029+0000 I CONTROL [initandlisten] options: { net: { bindIp: "127.0.0.1,192.168.1.100", port: 2700 }, security: { authorization: "enabled" }, storage: { dbPath: "data/db/" } }
- 2019-01-11T22:45:24.030+0000 I STORAGE [initandlisten] exception in initAndListen: NonExistentPath: Data directory data/db/ not found., terminating
- 2019-01-11T22:45:24.031+0000 I CONTROL [initandlisten] now exiting
- 2019-01-11T22:45:24.031+0000 I CONTROL [initandlisten] shutting down with code:100
- vagrant@m103:~$ mongod --port 2700 --dbpath data/db/ --bind_ip "127.0.0.1,192.168.1.100" --auth
- 2019-01-11T22:47:51.696+0000 I CONTROL [initandlisten] MongoDB starting : pid=1975 port=2700 dbpath=data/db/ 64-bit host=m103
- 2019-01-11T22:47:51.697+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:47:51.697+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:47:51.697+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:47:51.697+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:47:51.697+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:47:51.697+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:47:51.697+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:47:51.698+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:47:51.698+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:47:51.698+0000 I CONTROL [initandlisten] options: { net: { bindIp: "127.0.0.1,192.168.1.100", port: 2700 }, security: { authorization: "enabled" }, storage: { dbPath: "data/db/" } }
- 2019-01-11T22:47:51.698+0000 I STORAGE [initandlisten] exception in initAndListen: NonExistentPath: Data directory data/db/ not found., terminating
- 2019-01-11T22:47:51.698+0000 I CONTROL [initandlisten] now exiting
- 2019-01-11T22:47:51.698+0000 I CONTROL [initandlisten] shutting down with code:100
- vagrant@m103:~$ ls
- data first_mongod
- vagrant@m103:~$ mongod --port 2700 --dbpath /data/db/ --bind_ip "127.0.0.1,192.168.1.100" --auth
- 2019-01-11T22:48:27.776+0000 I CONTROL [initandlisten] MongoDB starting : pid=1979 port=2700 dbpath=/data/db/ 64-bit host=m103
- 2019-01-11T22:48:27.778+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:48:27.779+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:48:27.779+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:48:27.780+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:48:27.780+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:48:27.782+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:48:27.783+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:48:27.783+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:48:27.783+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:48:27.783+0000 I CONTROL [initandlisten] options: { net: { bindIp: "127.0.0.1,192.168.1.100", port: 2700 }, security: { authorization: "enabled" }, storage: { dbPath: "/data/db/" } }
- 2019-01-11T22:48:27.788+0000 E STORAGE [initandlisten] Failed to set up listener: SocketException: Cannot assign requested address
- 2019-01-11T22:48:27.789+0000 I CONTROL [initandlisten] now exiting
- 2019-01-11T22:48:27.789+0000 I CONTROL [initandlisten] shutting down with code:48
- vagrant@m103:~$ ifconfig
- eth0 Link encap:Ethernet HWaddr 08:00:27:84:45:09
- inet addr:10.0.2.15 Bcast:10.0.2.255 Mask:255.255.255.0
- inet6 addr: fe80::a00:27ff:fe84:4509/64 Scope:Link
- UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
- RX packets:2276 errors:0 dropped:0 overruns:0 frame:0
- TX packets:1405 errors:0 dropped:0 overruns:0 carrier:0
- collisions:0 txqueuelen:1000
- RX bytes:210071 (210.0 KB) TX bytes:180816 (180.8 KB)
- eth1 Link encap:Ethernet HWaddr 08:00:27:da:c4:35
- inet addr:192.168.103.100 Bcast:192.168.103.255 Mask:255.255.255.0
- inet6 addr: fe80::a00:27ff:feda:c435/64 Scope:Link
- UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
- RX packets:0 errors:0 dropped:0 overruns:0 frame:0
- TX packets:18 errors:0 dropped:0 overruns:0 carrier:0
- collisions:0 txqueuelen:1000
- RX bytes:0 (0.0 B) TX bytes:1596 (1.5 KB)
- lo Link encap:Local Loopback
- inet addr:127.0.0.1 Mask:255.0.0.0
- inet6 addr: ::1/128 Scope:Host
- UP LOOPBACK RUNNING MTU:65536 Metric:1
- RX packets:0 errors:0 dropped:0 overruns:0 frame:0
- TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
- collisions:0 txqueuelen:0
- RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
- vagrant@m103:~$ mongod --port 2700 --dbpath /data/db/ --bind_ip "127.0.0.1,192.168.1.103" --auth
- 2019-01-11T22:48:50.352+0000 I CONTROL [initandlisten] MongoDB starting : pid=1984 port=2700 dbpath=/data/db/ 64-bit host=m103
- 2019-01-11T22:48:50.353+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:48:50.353+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:48:50.354+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:48:50.354+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:48:50.355+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:48:50.356+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:48:50.356+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:48:50.356+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:48:50.357+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:48:50.359+0000 I CONTROL [initandlisten] options: { net: { bindIp: "127.0.0.1,192.168.1.103", port: 2700 }, security: { authorization: "enabled" }, storage: { dbPath: "/data/db/" } }
- 2019-01-11T22:48:50.361+0000 E STORAGE [initandlisten] Failed to set up listener: SocketException: Cannot assign requested address
- 2019-01-11T22:48:50.362+0000 I CONTROL [initandlisten] now exiting
- 2019-01-11T22:48:50.362+0000 I CONTROL [initandlisten] shutting down with code:48
- vagrant@m103:~$ ifconfig
- eth0 Link encap:Ethernet HWaddr 08:00:27:84:45:09
- inet addr:10.0.2.15 Bcast:10.0.2.255 Mask:255.255.255.0
- inet6 addr: fe80::a00:27ff:fe84:4509/64 Scope:Link
- UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
- RX packets:2360 errors:0 dropped:0 overruns:0 frame:0
- TX packets:1464 errors:0 dropped:0 overruns:0 carrier:0
- collisions:0 txqueuelen:1000
- RX bytes:215861 (215.8 KB) TX bytes:186678 (186.6 KB)
- eth1 Link encap:Ethernet HWaddr 08:00:27:da:c4:35
- inet addr:192.168.103.100 Bcast:192.168.103.255 Mask:255.255.255.0
- inet6 addr: fe80::a00:27ff:feda:c435/64 Scope:Link
- UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
- RX packets:0 errors:0 dropped:0 overruns:0 frame:0
- TX packets:18 errors:0 dropped:0 overruns:0 carrier:0
- collisions:0 txqueuelen:1000
- RX bytes:0 (0.0 B) TX bytes:1596 (1.5 KB)
- lo Link encap:Local Loopback
- inet addr:127.0.0.1 Mask:255.0.0.0
- inet6 addr: ::1/128 Scope:Host
- UP LOOPBACK RUNNING MTU:65536 Metric:1
- RX packets:0 errors:0 dropped:0 overruns:0 frame:0
- TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
- collisions:0 txqueuelen:0
- RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
- vagrant@m103:~$ ip
- Usage: ip [ OPTIONS ] OBJECT { COMMAND | help }
- ip [ -force ] -batch filename
- where OBJECT := { link | addr | addrlabel | route | rule | neigh | ntable |
- tunnel | tuntap | maddr | mroute | mrule | monitor | xfrm |
- netns | l2tp | tcp_metrics | token }
- OPTIONS := { -V[ersion] | -s[tatistics] | -d[etails] | -r[esolve] |
- -f[amily] { inet | inet6 | ipx | dnet | bridge | link } |
- -4 | -6 | -I | -D | -B | -0 |
- -l[oops] { maximum-addr-flush-attempts } |
- -o[neline] | -t[imestamp] | -b[atch] [filename] |
- -rc[vbuf] [size]}
- vagrant@m103:~$ ip aadr
- Object "aadr" is unknown, try "ip help".
- vagrant@m103:~$ mongod --port 2700 --dbpath /data/db/ --bind_ip "127.0.0.1,192.168.1.103" --auth
- 2019-01-11T22:49:55.433+0000 I CONTROL [initandlisten] MongoDB starting : pid=1990 port=2700 dbpath=/data/db/ 64-bit host=m103
- 2019-01-11T22:49:55.434+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:49:55.435+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:49:55.435+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:49:55.436+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:49:55.436+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:49:55.437+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:49:55.437+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:49:55.438+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:49:55.439+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:49:55.440+0000 I CONTROL [initandlisten] options: { net: { bindIp: "127.0.0.1,192.168.1.103", port: 2700 }, security: { authorization: "enabled" }, storage: { dbPath: "/data/db/" } }
- 2019-01-11T22:49:55.441+0000 E STORAGE [initandlisten] Failed to set up listener: SocketException: Cannot assign requested address
- 2019-01-11T22:49:55.442+0000 I CONTROL [initandlisten] now exiting
- 2019-01-11T22:49:55.442+0000 I CONTROL [initandlisten] shutting down with code:48
- vagrant@m103:~$ mongod --port 2700 --dbpath /data/db/ --bind_ip "localhost ,192.168.1.103" --auth
- 2019-01-11T22:50:34.372+0000 I CONTROL [initandlisten] MongoDB starting : pid=1994 port=2700 dbpath=/data/db/ 64-bit host=m103
- 2019-01-11T22:50:34.373+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:50:34.373+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:50:34.373+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:50:34.373+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:50:34.373+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:50:34.373+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:50:34.373+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:50:34.373+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:50:34.373+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:50:34.373+0000 I CONTROL [initandlisten] options: { net: { bindIp: "localhost ,192.168.1.103", port: 2700 }, security: { authorization: "enabled" }, storage: { dbPath: "/data/db/" } }
- 2019-01-11T22:50:34.375+0000 E STORAGE [initandlisten] Failed to set up listener: SocketException: Cannot assign requested address
- 2019-01-11T22:50:34.375+0000 I CONTROL [initandlisten] now exiting
- 2019-01-11T22:50:34.375+0000 I CONTROL [initandlisten] shutting down with code:48
- vagrant@m103:~$ mongod --port 2700 --dbpath /data/db/ --bind_ip "192.168.1.103" --auth
- 2019-01-11T22:50:47.207+0000 I CONTROL [initandlisten] MongoDB starting : pid=1997 port=2700 dbpath=/data/db/ 64-bit host=m103
- 2019-01-11T22:50:47.208+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:50:47.209+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:50:47.210+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:50:47.211+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:50:47.211+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:50:47.212+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:50:47.212+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:50:47.212+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:50:47.213+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:50:47.214+0000 I CONTROL [initandlisten] options: { net: { bindIp: "192.168.1.103", port: 2700 }, security: { authorization: "enabled" }, storage: { dbPath: "/data/db/" } }
- 2019-01-11T22:50:47.215+0000 E STORAGE [initandlisten] Failed to set up listener: SocketException: Cannot assign requested address
- 2019-01-11T22:50:47.215+0000 I CONTROL [initandlisten] now exiting
- 2019-01-11T22:50:47.215+0000 I CONTROL [initandlisten] shutting down with code:48
- vagrant@m103:~$ mongod --port 2700 --dbpath /data/db/ --bind_ip "192.168.1.103"
- 2019-01-11T22:50:57.250+0000 I CONTROL [initandlisten] MongoDB starting : pid=2000 port=2700 dbpath=/data/db/ 64-bit host=m103
- 2019-01-11T22:50:57.250+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:50:57.250+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:50:57.250+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:50:57.250+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:50:57.250+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:50:57.250+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:50:57.250+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:50:57.250+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:50:57.250+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:50:57.251+0000 I CONTROL [initandlisten] options: { net: { bindIp: "192.168.1.103", port: 2700 }, storage: { dbPath: "/data/db/" } }
- 2019-01-11T22:50:57.251+0000 E STORAGE [initandlisten] Failed to set up listener: SocketException: Cannot assign requested address
- 2019-01-11T22:50:57.251+0000 I CONTROL [initandlisten] now exiting
- 2019-01-11T22:50:57.251+0000 I CONTROL [initandlisten] shutting down with code:48
- vagrant@m103:~$ mongod --port 27000 --dbpath /data/db/ --bind_ip "127.0.0.1,192.168.1.103" --auth
- 2019-01-11T22:51:31.682+0000 I CONTROL [initandlisten] MongoDB starting : pid=2003 port=27000 dbpath=/data/db/ 64-bit host=m103
- 2019-01-11T22:51:31.684+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:51:31.685+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:51:31.685+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:51:31.685+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:51:31.686+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:51:31.686+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:51:31.686+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:51:31.686+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:51:31.686+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:51:31.686+0000 I CONTROL [initandlisten] options: { net: { bindIp: "127.0.0.1,192.168.1.103", port: 27000 }, security: { authorization: "enabled" }, storage: { dbPath: "/data/db/" } }
- 2019-01-11T22:51:31.686+0000 E STORAGE [initandlisten] Failed to set up listener: SocketException: Cannot assign requested address
- 2019-01-11T22:51:31.687+0000 I CONTROL [initandlisten] now exiting
- 2019-01-11T22:51:31.687+0000 I CONTROL [initandlisten] shutting down with code:48
- vagrant@m103:~$ ifconfig
- eth0 Link encap:Ethernet HWaddr 08:00:27:84:45:09
- inet addr:10.0.2.15 Bcast:10.0.2.255 Mask:255.255.255.0
- inet6 addr: fe80::a00:27ff:fe84:4509/64 Scope:Link
- UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
- RX packets:2935 errors:0 dropped:0 overruns:0 frame:0
- TX packets:1808 errors:0 dropped:0 overruns:0 carrier:0
- collisions:0 txqueuelen:1000
- RX bytes:257427 (257.4 KB) TX bytes:218064 (218.0 KB)
- eth1 Link encap:Ethernet HWaddr 08:00:27:da:c4:35
- inet addr:192.168.103.100 Bcast:192.168.103.255 Mask:255.255.255.0
- inet6 addr: fe80::a00:27ff:feda:c435/64 Scope:Link
- UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
- RX packets:0 errors:0 dropped:0 overruns:0 frame:0
- TX packets:18 errors:0 dropped:0 overruns:0 carrier:0
- collisions:0 txqueuelen:1000
- RX bytes:0 (0.0 B) TX bytes:1596 (1.5 KB)
- lo Link encap:Local Loopback
- inet addr:127.0.0.1 Mask:255.0.0.0
- inet6 addr: ::1/128 Scope:Host
- UP LOOPBACK RUNNING MTU:65536 Metric:1
- RX packets:0 errors:0 dropped:0 overruns:0 frame:0
- TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
- collisions:0 txqueuelen:0
- RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
- vagrant@m103:~$ mongod --port 27000 --dbpath /data/db/ --bind_ip "127.0.0.1,192.168.1.100" --auth
- 2019-01-11T22:57:20.791+0000 I CONTROL [initandlisten] MongoDB starting : pid=2010 port=27000 dbpath=/data/db/ 64-bit host=m103
- 2019-01-11T22:57:20.791+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:57:20.792+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:57:20.792+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:57:20.792+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:57:20.792+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:57:20.792+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:57:20.792+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:57:20.792+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:57:20.792+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:57:20.792+0000 I CONTROL [initandlisten] options: { net: { bindIp: "127.0.0.1,192.168.1.100", port: 27000 }, security: { authorization: "enabled" }, storage: { dbPath: "/data/db/" } }
- 2019-01-11T22:57:20.793+0000 E STORAGE [initandlisten] Failed to set up listener: SocketException: Cannot assign requested address
- 2019-01-11T22:57:20.793+0000 I CONTROL [initandlisten] now exiting
- 2019-01-11T22:57:20.793+0000 I CONTROL [initandlisten] shutting down with code:48
- vagrant@m103:~$ mongod --port 27000 --dbpath /data/db/ --bind_ip "127.0.0.1,192.168.103.100" --auth
- 2019-01-11T22:58:13.767+0000 I CONTROL [initandlisten] MongoDB starting : pid=2013 port=27000 dbpath=/data/db/ 64-bit host=m103
- 2019-01-11T22:58:13.768+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-11T22:58:13.768+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-11T22:58:13.768+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-11T22:58:13.768+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-11T22:58:13.768+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-11T22:58:13.768+0000 I CONTROL [initandlisten] build environment:
- 2019-01-11T22:58:13.768+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-11T22:58:13.768+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-11T22:58:13.768+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-11T22:58:13.768+0000 I CONTROL [initandlisten] options: { net: { bindIp: "127.0.0.1,192.168.103.100", port: 27000 }, security: { authorization: "enabled" }, storage: { dbPath: "/data/db/" } }
- 2019-01-11T22:58:13.772+0000 I - [initandlisten] Detected data files in /data/db/ created by the 'wiredTiger' storage engine, so setting the active storage engine to 'wiredTiger'.
- 2019-01-11T22:58:13.772+0000 I STORAGE [initandlisten]
- 2019-01-11T22:58:13.772+0000 I STORAGE [initandlisten] ** WARNING: Using the XFS filesystem is strongly recommended with the WiredTiger storage engine
- 2019-01-11T22:58:13.772+0000 I STORAGE [initandlisten] ** See http://dochub.mongodb.org/core/prodnotes-filesystem
- 2019-01-11T22:58:13.774+0000 I STORAGE [initandlisten] wiredtiger_open config: create,cache_size=488M,session_max=20000,eviction=(threads_min=4,threads_max=4),config_base=false,statistics=(fast),cache_cursors=false,compatibility=(release="3.0",require_max="3.0"),log=(enabled=true,archive=true,path=journal,compressor=snappy),file_manager=(close_idle_time=100000),statistics_log=(wait=0),verbose=(recovery_progress),
- 2019-01-11T22:58:15.089+0000 I STORAGE [initandlisten] WiredTiger message [1547247495:89929][2013:0x7fca5f1e9a80], txn-recover: Main recovery loop: starting at 2/7552
- 2019-01-11T22:58:15.244+0000 I STORAGE [initandlisten] WiredTiger message [1547247495:244435][2013:0x7fca5f1e9a80], txn-recover: Recovering log 2 through 3
- 2019-01-11T22:58:15.339+0000 I STORAGE [initandlisten] WiredTiger message [1547247495:339271][2013:0x7fca5f1e9a80], txn-recover: Recovering log 3 through 3
- 2019-01-11T22:58:15.409+0000 I STORAGE [initandlisten] WiredTiger message [1547247495:409918][2013:0x7fca5f1e9a80], txn-recover: Set global recovery timestamp: 0
- 2019-01-11T22:58:15.439+0000 I CONTROL [initandlisten]
- 2019-01-11T22:58:15.440+0000 I CONTROL [initandlisten] ** WARNING: /sys/kernel/mm/transparent_hugepage/enabled is 'always'.
- 2019-01-11T22:58:15.441+0000 I CONTROL [initandlisten] ** We suggest setting it to 'never'
- 2019-01-11T22:58:15.442+0000 I CONTROL [initandlisten]
- 2019-01-11T22:58:15.443+0000 I CONTROL [initandlisten] ** WARNING: /sys/kernel/mm/transparent_hugepage/defrag is 'always'.
- 2019-01-11T22:58:15.444+0000 I CONTROL [initandlisten] ** We suggest setting it to 'never'
- 2019-01-11T22:58:15.444+0000 I CONTROL [initandlisten]
- 2019-01-11T22:58:15.494+0000 I FTDC [initandlisten] Initializing full-time diagnostic data capture with directory '/data/db/diagnostic.data'
- 2019-01-11T22:58:15.496+0000 I NETWORK [initandlisten] waiting for connections on port 27000
- ^C2019-01-11T22:58:29.542+0000 I CONTROL [signalProcessingThread] got signal 2 (Interrupt), will terminate after current cmd ends
- 2019-01-11T22:58:29.544+0000 I NETWORK [signalProcessingThread] shutdown: going to close listening sockets...
- 2019-01-11T22:58:29.545+0000 I NETWORK [signalProcessingThread] removing socket file: /tmp/mongodb-27000.sock
- 2019-01-11T22:58:29.547+0000 I FTDC [signalProcessingThread] Shutting down full-time diagnostic data capture
- 2019-01-11T22:58:29.551+0000 I STORAGE [signalProcessingThread] WiredTigerKVEngine shutting down
- 2019-01-11T22:58:29.583+0000 I STORAGE [signalProcessingThread] shutdown: removing fs lock...
- 2019-01-11T22:58:29.584+0000 I CONTROL [signalProcessingThread] now exiting
- 2019-01-11T22:58:29.586+0000 I CONTROL [signalProcessingThread] shutting down with code:0
- vagrant@m103:~$ mongod --port 27000 --dbpath /data/db/ --bind_ip "127.0.0.1,192.168.103.100" --auth --fork
- BadValue: --fork has to be used with --logpath or --syslog
- try 'mongod --help' for more information
- vagrant@m103:~$ mongod --port 27000 --dbpath /data/db/ --logpath /data/mongd.log --bind_ip "127.0.0.1,192.168.103.100" --auth --fork
- about to fork child process, waiting until server is ready for connections.
- forked process: 2045
- child process started successfully, parent exiting
- vagrant@m103:~$ mongo
- MongoDB shell version v3.6.9
- connecting to: mongodb://127.0.0.1:27017
- 2019-01-11T23:00:40.498+0000 W NETWORK [thread1] Failed to connect to 127.0.0.1:27017, in(checking socket for error after poll), reason: Connection refused
- 2019-01-11T23:00:40.508+0000 E QUERY [thread1] Error: couldn't connect to server 127.0.0.1:27017, connection attempt failed :
- connect@src/mongo/shell/mongo.js:257:13
- @(connect):1:6
- exception: connect failed
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- > db.create.User({
- > user: "m103-admin",
- > pwd: "m103-pass",
- > roles: [
- > {role: "root",db:"admin"}
- > ]
- > })
- > ,
- >
- > '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- Implicit session: session { "id" : UUID("48a3c444-4a5b-4cb9-aed6-d3794ab3add9") }
- MongoDB server version: 3.6.9
- 2019-01-11T23:04:13.560+0000 E QUERY [thread1] SyntaxError: expected expression, got end of script @(shell eval):11:0
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- db.create.User({
- user: "m103-admin",
- pwd: "m103-pass",
- roles: [
- {role: "root",db:"admin"}
- ]
- })
- '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- Implicit session: session { "id" : UUID("40ec617f-61cb-4d08-bb5c-cadd38e55d0b") }
- MongoDB server version: 3.6.9
- 2019-01-11T23:04:32.651+0000 E QUERY [thread1] TypeError: db.create.User is not a function :
- @(shell eval):2:1
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- db.create.User({
- user: "m103-admin",
- pwd: "m103-pass",
- roles: [
- {role: "root",db:"admin"}
- ]
- })
- '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- Implicit session: session { "id" : UUID("efa7bbaf-7a6d-456a-bae5-ffd07f0d08d0") }
- MongoDB server version: 3.6.9
- 2019-01-11T23:05:11.601+0000 E QUERY [thread1] TypeError: db.create.User is not a function :
- @(shell eval):2:1
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- db.create.User({
- user: "m103-admin",
- pwd: "m103-pass",
- roles: [
- {role: "root",db:"admin"}
- ]
- })
- '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- Implicit session: session { "id" : UUID("c18b5fbe-fdc3-4dd6-a970-096164da43fa") }
- MongoDB server version: 3.6.9
- 2019-01-11T23:06:59.761+0000 E QUERY [thread1] TypeError: db.create.User is not a function :
- @(shell eval):2:1
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- db.create.User({
- user: "m103-admin",
- pwd: "m103-pass",
- roles: [
- {role: "root",db:"admin"}
- ]
- })
- '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- Implicit session: session { "id" : UUID("fe7a1046-d1a6-46d3-b7e1-9c2ae2f8b31d") }
- MongoDB server version: 3.6.9
- 2019-01-11T23:08:06.470+0000 E QUERY [thread1] TypeError: db.create.User is not a function :
- @(shell eval):2:1
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- db.create.User({
- user: "m103-admin",
- pwd: "m103-pass",
- roles: [
- {role: "root",db:"admin"}
- ]
- })
- '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- Implicit session: session { "id" : UUID("efb42ab5-023b-472d-a46d-8f7f95b86187") }
- MongoDB server version: 3.6.9
- 2019-01-11T23:08:48.517+0000 E QUERY [thread1] TypeError: db.create.User is not a function :
- @(shell eval):2:1
- vagrant@m103:~$ clear
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- db.create.User({
- user: "m103-admin",
- pwd: "m103-pass",
- roles: [
- {role: "root",db:"admin"}
- ]
- })
- '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- Implicit session: session { "id" : UUID("8a9c96f6-8a6e-4caf-a0d3-a18502aa53b0") }
- MongoDB server version: 3.6.9
- 2019-01-11T23:10:06.307+0000 E QUERY [thread1] TypeError: db.create.User is not a function :
- @(shell eval):2:1
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- db.createUser({
- user: "m103-admin",
- pwd: "m103-pass",
- roles: [
- {role: "root",db:"admin"}
- ]
- })
- '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- Implicit session: session { "id" : UUID("b50087b3-5a27-49b2-aab7-97c9774f40e4") }
- MongoDB server version: 3.6.9
- Successfully added user: {
- "user" : "m103-admin",
- "roles" : [
- {
- "role" : "root",
- "db" : "admin"
- }
- ]
- }
- vagrant@m103:~$ validate_lab_launch_mongd
- validate_lab_launch_mongd: command not found
- vagrant@m103:~$ validate_lab_launch_mongod
- 5a21c6dd403b6546001e79c0
- vagrant@m103:~$ validate_lab_launch_mongod
- 5a21c6dd403b6546001e79c0
- vagrant@m103:~$ pico /etc/mongod.conf
- vagrant@m103:~$ cp /etc/mongod.conf /etc/mongod.ocnf.bk
- cp: cannot create regular file '/etc/mongod.ocnf.bk': Permission denied
- vagrant@m103:~$ whoami
- vagrant
- vagrant@m103:~$ sudo cp /etc/mongod.conf /etc/mongod.conf.bk
- vagrant@m103:~$ sudo pico /etc/mongod.conf
- vagrant@m103:~$ mongo
- MongoDB shell version v3.6.9
- connecting to: mongodb://127.0.0.1:27017
- 2019-01-12T00:52:42.546+0000 W NETWORK [thread1] Failed to connect to 127.0.0.1:27017, in(checking socket for error after poll), reason: Connection refused
- 2019-01-12T00:52:42.547+0000 E QUERY [thread1] Error: couldn't connect to server 127.0.0.1:27017, connection attempt failed :
- connect@src/mongo/shell/mongo.js:257:13
- @(connect):1:6
- exception: connect failed
- vagrant@m103:~$ ps -ef | grep mongod
- vagrant 2045 1 0 00:29 ? 00:00:13 mongod --port 27000 --dbpath /data/db/ --logpath /data/mongd.log --bind_ip 127.0.0.1,192.168.103.100 --auth --fork
- vagrant 2272 1931 0 00:54 pts/0 00:00:00 grep --color=auto mongod
- vagrant@m103:~$ kill 2045
- vagrant@m103:~$ mongo
- MongoDB shell version v3.6.9
- connecting to: mongodb://127.0.0.1:27017
- 2019-01-12T00:54:51.042+0000 W NETWORK [thread1] Failed to connect to 127.0.0.1:27017, in(checking socket for error after poll), reason: Connection refused
- 2019-01-12T00:54:51.043+0000 E QUERY [thread1] Error: couldn't connect to server 127.0.0.1:27017, connection attempt failed :
- connect@src/mongo/shell/mongo.js:257:13
- @(connect):1:6
- exception: connect failed
- vagrant@m103:~$ mongod
- 2019-01-12T00:55:08.225+0000 I CONTROL [initandlisten] MongoDB starting : pid=2276 port=27017 dbpath=/data/db 64-bit host=m103
- 2019-01-12T00:55:08.225+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-12T00:55:08.225+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-12T00:55:08.225+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-12T00:55:08.225+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-12T00:55:08.225+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-12T00:55:08.225+0000 I CONTROL [initandlisten] build environment:
- 2019-01-12T00:55:08.225+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-12T00:55:08.226+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-12T00:55:08.226+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-12T00:55:08.226+0000 I CONTROL [initandlisten] options: {}
- 2019-01-12T00:55:08.226+0000 I - [initandlisten] Detected data files in /data/db created by the 'wiredTiger' storage engine, so setting the active storage engine to 'wiredTiger'.
- 2019-01-12T00:55:08.227+0000 I STORAGE [initandlisten]
- 2019-01-12T00:55:08.227+0000 I STORAGE [initandlisten] ** WARNING: Using the XFS filesystem is strongly recommended with the WiredTiger storage engine
- 2019-01-12T00:55:08.227+0000 I STORAGE [initandlisten] ** See http://dochub.mongodb.org/core/prodnotes-filesystem
- 2019-01-12T00:55:08.227+0000 I STORAGE [initandlisten] wiredtiger_open config: create,cache_size=488M,session_max=20000,eviction=(threads_min=4,threads_max=4),config_base=false,statistics=(fast),cache_cursors=false,compatibility=(release="3.0",require_max="3.0"),log=(enabled=true,archive=true,path=journal,compressor=snappy),file_manager=(close_idle_time=100000),statistics_log=(wait=0),verbose=(recovery_progress),
- 2019-01-12T00:55:09.171+0000 I STORAGE [initandlisten] WiredTiger message [1547254509:171044][2276:0x7f07b07eea80], txn-recover: Main recovery loop: starting at 4/17920
- 2019-01-12T00:55:09.312+0000 I STORAGE [initandlisten] WiredTiger message [1547254509:312674][2276:0x7f07b07eea80], txn-recover: Recovering log 4 through 5
- 2019-01-12T00:55:09.390+0000 I STORAGE [initandlisten] WiredTiger message [1547254509:390874][2276:0x7f07b07eea80], txn-recover: Recovering log 5 through 5
- 2019-01-12T00:55:09.462+0000 I STORAGE [initandlisten] WiredTiger message [1547254509:462978][2276:0x7f07b07eea80], txn-recover: Set global recovery timestamp: 0
- 2019-01-12T00:55:09.485+0000 I CONTROL [initandlisten]
- 2019-01-12T00:55:09.486+0000 I CONTROL [initandlisten] ** WARNING: Access control is not enabled for the database.
- 2019-01-12T00:55:09.486+0000 I CONTROL [initandlisten] ** Read and write access to data and configuration is unrestricted.
- 2019-01-12T00:55:09.486+0000 I CONTROL [initandlisten]
- 2019-01-12T00:55:09.486+0000 I CONTROL [initandlisten] ** WARNING: This server is bound to localhost.
- 2019-01-12T00:55:09.487+0000 I CONTROL [initandlisten] ** Remote systems will be unable to connect to this server.
- 2019-01-12T00:55:09.487+0000 I CONTROL [initandlisten] ** Start the server with --bind_ip <address> to specify which IP
- 2019-01-12T00:55:09.487+0000 I CONTROL [initandlisten] ** addresses it should serve responses from, or with --bind_ip_all to
- 2019-01-12T00:55:09.487+0000 I CONTROL [initandlisten] ** bind to all interfaces. If this behavior is desired, start the
- 2019-01-12T00:55:09.487+0000 I CONTROL [initandlisten] ** server with --bind_ip 127.0.0.1 to disable this warning.
- 2019-01-12T00:55:09.487+0000 I CONTROL [initandlisten]
- 2019-01-12T00:55:09.487+0000 I CONTROL [initandlisten]
- 2019-01-12T00:55:09.487+0000 I CONTROL [initandlisten] ** WARNING: /sys/kernel/mm/transparent_hugepage/enabled is 'always'.
- 2019-01-12T00:55:09.487+0000 I CONTROL [initandlisten] ** We suggest setting it to 'never'
- 2019-01-12T00:55:09.488+0000 I CONTROL [initandlisten]
- 2019-01-12T00:55:09.488+0000 I CONTROL [initandlisten] ** WARNING: /sys/kernel/mm/transparent_hugepage/defrag is 'always'.
- 2019-01-12T00:55:09.488+0000 I CONTROL [initandlisten] ** We suggest setting it to 'never'
- 2019-01-12T00:55:09.488+0000 I CONTROL [initandlisten]
- 2019-01-12T00:55:09.508+0000 I FTDC [initandlisten] Initializing full-time diagnostic data capture with directory '/data/db/diagnostic.data'
- 2019-01-12T00:55:09.510+0000 I NETWORK [initandlisten] waiting for connections on port 27017
- ^C2019-01-12T00:55:18.190+0000 I CONTROL [signalProcessingThread] got signal 2 (Interrupt), will terminate after current cmd ends
- 2019-01-12T00:55:18.191+0000 I NETWORK [signalProcessingThread] shutdown: going to close listening sockets...
- 2019-01-12T00:55:18.193+0000 I NETWORK [signalProcessingThread] removing socket file: /tmp/mongodb-27017.sock
- 2019-01-12T00:55:18.195+0000 I FTDC [signalProcessingThread] Shutting down full-time diagnostic data capture
- 2019-01-12T00:55:18.199+0000 I STORAGE [signalProcessingThread] WiredTigerKVEngine shutting down
- 2019-01-12T00:55:18.324+0000 I STORAGE [signalProcessingThread] shutdown: removing fs lock...
- 2019-01-12T00:55:18.325+0000 I CONTROL [signalProcessingThread] now exiting
- 2019-01-12T00:55:18.325+0000 I CONTROL [signalProcessingThread] shutting down with code:0
- vagrant@m103:~$ pico /etc/mongod.conf
- Error reading /home/vagrant/.nano_history: Permission denied
- Press Enter to continue starting nano.
- vagrant@m103:~$ mongod --config "/etc/mongod.conf"
- about to fork child process, waiting until server is ready for connections.
- forked process: 2310
- child process started successfully, parent exiting
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- db.createUser({
- user: "m103-admin",
- pwd: "m103-pass",
- roles: [
- {role: "root",db:"admin"}
- ]
- })
- '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- Implicit session: session { "id" : UUID("5ee3c722-47b0-4f22-84f7-d6265676eba7") }
- MongoDB server version: 3.6.9
- 2019-01-12T00:57:28.538+0000 E QUERY [thread1] Error: couldn't add user: there are no users authenticated :
- _getErrorWithCode@src/mongo/shell/utils.js:25:13
- DB.prototype.createUser@src/mongo/shell/db.js:1437:15
- @(shell eval):2:1
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- db.createUser({
- user: "m103-admin",
- pwd: "m103-pass",
- roles: [
- {role: "root",db:"admin"}
- ]
- })
- '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- Implicit session: session { "id" : UUID("3a8ac3f9-0abf-40e9-b7c1-8e6dd8aeb2c5") }
- MongoDB server version: 3.6.9
- 2019-01-12T00:57:52.989+0000 E QUERY [thread1] Error: couldn't add user: there are no users authenticated :
- _getErrorWithCode@src/mongo/shell/utils.js:25:13
- DB.prototype.createUser@src/mongo/shell/db.js:1437:15
- @(shell eval):2:1
- vagrant@m103:~$ validate_lab_configuration_file
- You need to bind the IP address to `192.168.103.100`
- vagrant@m103:~$ ps -ef |grep mongod
- vagrant 2310 1 1 00:56 ? 00:00:02 mongod --config /etc/mongod.conf
- vagrant 2356 1931 0 00:59 pts/0 00:00:00 grep --color=auto mongod
- vagrant@m103:~$ kill 2310
- vagrant@m103:~$ sudo pico /etc/mongod.conf
- vagrant@m103:~$ mongod
- 2019-01-12T01:01:20.272+0000 I CONTROL [initandlisten] MongoDB starting : pid=2362 port=27017 dbpath=/data/db 64-bit host=m103
- 2019-01-12T01:01:20.273+0000 I CONTROL [initandlisten] db version v3.6.9
- 2019-01-12T01:01:20.274+0000 I CONTROL [initandlisten] git version: 167861a164723168adfaaa866f310cb94010428f
- 2019-01-12T01:01:20.274+0000 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.1f 6 Jan 2014
- 2019-01-12T01:01:20.274+0000 I CONTROL [initandlisten] allocator: tcmalloc
- 2019-01-12T01:01:20.275+0000 I CONTROL [initandlisten] modules: enterprise
- 2019-01-12T01:01:20.275+0000 I CONTROL [initandlisten] build environment:
- 2019-01-12T01:01:20.275+0000 I CONTROL [initandlisten] distmod: ubuntu1404
- 2019-01-12T01:01:20.275+0000 I CONTROL [initandlisten] distarch: x86_64
- 2019-01-12T01:01:20.275+0000 I CONTROL [initandlisten] target_arch: x86_64
- 2019-01-12T01:01:20.275+0000 I CONTROL [initandlisten] options: {}
- 2019-01-12T01:01:20.275+0000 I - [initandlisten] Detected data files in /data/db created by the 'wiredTiger' storage engine, so setting the active storage engine to 'wiredTiger'.
- 2019-01-12T01:01:20.275+0000 I STORAGE [initandlisten]
- 2019-01-12T01:01:20.275+0000 I STORAGE [initandlisten] ** WARNING: Using the XFS filesystem is strongly recommended with the WiredTiger storage engine
- 2019-01-12T01:01:20.275+0000 I STORAGE [initandlisten] ** See http://dochub.mongodb.org/core/prodnotes-filesystem
- 2019-01-12T01:01:20.275+0000 I STORAGE [initandlisten] wiredtiger_open config: create,cache_size=488M,session_max=20000,eviction=(threads_min=4,threads_max=4),config_base=false,statistics=(fast),cache_cursors=false,compatibility=(release="3.0",require_max="3.0"),log=(enabled=true,archive=true,path=journal,compressor=snappy),file_manager=(close_idle_time=100000),statistics_log=(wait=0),verbose=(recovery_progress),
- 2019-01-12T01:01:21.226+0000 I STORAGE [initandlisten] WiredTiger message [1547254881:226332][2362:0x7f067ebc0a80], txn-recover: Main recovery loop: starting at 6/6528
- 2019-01-12T01:01:21.367+0000 I STORAGE [initandlisten] WiredTiger message [1547254881:367047][2362:0x7f067ebc0a80], txn-recover: Recovering log 6 through 7
- 2019-01-12T01:01:21.457+0000 I STORAGE [initandlisten] WiredTiger message [1547254881:457765][2362:0x7f067ebc0a80], txn-recover: Recovering log 7 through 7
- 2019-01-12T01:01:21.533+0000 I STORAGE [initandlisten] WiredTiger message [1547254881:533869][2362:0x7f067ebc0a80], txn-recover: Set global recovery timestamp: 0
- 2019-01-12T01:01:21.584+0000 I CONTROL [initandlisten]
- 2019-01-12T01:01:21.585+0000 I CONTROL [initandlisten] ** WARNING: Access control is not enabled for the database.
- 2019-01-12T01:01:21.586+0000 I CONTROL [initandlisten] ** Read and write access to data and configuration is unrestricted.
- 2019-01-12T01:01:21.587+0000 I CONTROL [initandlisten]
- 2019-01-12T01:01:21.588+0000 I CONTROL [initandlisten] ** WARNING: This server is bound to localhost.
- 2019-01-12T01:01:21.589+0000 I CONTROL [initandlisten] ** Remote systems will be unable to connect to this server.
- 2019-01-12T01:01:21.590+0000 I CONTROL [initandlisten] ** Start the server with --bind_ip <address> to specify which IP
- 2019-01-12T01:01:21.591+0000 I CONTROL [initandlisten] ** addresses it should serve responses from, or with --bind_ip_all to
- 2019-01-12T01:01:21.592+0000 I CONTROL [initandlisten] ** bind to all interfaces. If this behavior is desired, start the
- 2019-01-12T01:01:21.592+0000 I CONTROL [initandlisten] ** server with --bind_ip 127.0.0.1 to disable this warning.
- 2019-01-12T01:01:21.594+0000 I CONTROL [initandlisten]
- 2019-01-12T01:01:21.595+0000 I CONTROL [initandlisten]
- 2019-01-12T01:01:21.595+0000 I CONTROL [initandlisten] ** WARNING: /sys/kernel/mm/transparent_hugepage/enabled is 'always'.
- 2019-01-12T01:01:21.596+0000 I CONTROL [initandlisten] ** We suggest setting it to 'never'
- 2019-01-12T01:01:21.597+0000 I CONTROL [initandlisten]
- 2019-01-12T01:01:21.598+0000 I CONTROL [initandlisten] ** WARNING: /sys/kernel/mm/transparent_hugepage/defrag is 'always'.
- 2019-01-12T01:01:21.599+0000 I CONTROL [initandlisten] ** We suggest setting it to 'never'
- 2019-01-12T01:01:21.600+0000 I CONTROL [initandlisten]
- 2019-01-12T01:01:21.619+0000 I FTDC [initandlisten] Initializing full-time diagnostic data capture with directory '/data/db/diagnostic.data'
- 2019-01-12T01:01:21.622+0000 I NETWORK [initandlisten] waiting for connections on port 27017
- ^C2019-01-12T01:01:28.782+0000 I CONTROL [signalProcessingThread] got signal 2 (Interrupt), will terminate after current cmd ends
- 2019-01-12T01:01:28.783+0000 I NETWORK [signalProcessingThread] shutdown: going to close listening sockets...
- 2019-01-12T01:01:28.783+0000 I NETWORK [signalProcessingThread] removing socket file: /tmp/mongodb-27017.sock
- 2019-01-12T01:01:28.784+0000 I FTDC [signalProcessingThread] Shutting down full-time diagnostic data capture
- 2019-01-12T01:01:28.787+0000 I STORAGE [signalProcessingThread] WiredTigerKVEngine shutting down
- 2019-01-12T01:01:28.840+0000 I STORAGE [signalProcessingThread] shutdown: removing fs lock...
- 2019-01-12T01:01:28.841+0000 I CONTROL [signalProcessingThread] now exiting
- 2019-01-12T01:01:28.842+0000 I CONTROL [signalProcessingThread] shutting down with code:0
- vagrant@m103:~$ mongod --config "/etc/mongod.conf"
- about to fork child process, waiting until server is ready for connections.
- forked process: 2393
- child process started successfully, parent exiting
- vagrant@m103:~$ validate_lab_configuration_file
- Client experienced a timeout when connecting to the database - check that mongod is running on the correct port, and that your user was created with the correct settings.
- vagrant@m103:~$ validate_lab_configuration_file
- Client experienced a timeout when connecting to the database - check that mongod is running on the correct port, and that your user was created with the correct settings.
- vagrant@m103:~$ ps -ef |grep mongod
- vagrant 2393 1 5 01:01 ? 00:00:01 mongod --config /etc/mongod.conf
- vagrant 2432 1931 0 01:02 pts/0 00:00:00 grep --color=auto mongod
- vagrant@m103:~$ validate_lab_configuration_file
- Client experienced a timeout when connecting to the database - check that mongod is running on the correct port, and that your user was created with the correct settings.
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval '
- db.createUser({
- user: "m103-admin",
- pwd: "m103-pass",
- roles: [
- {role: "root",db:"admin"}
- ]
- })
- '
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- 2019-01-12T01:03:56.661+0000 W NETWORK [thread1] Failed to connect to 127.0.0.1:27000, in(checking socket for error after poll), reason: Connection refused
- 2019-01-12T01:03:56.661+0000 E QUERY [thread1] Error: couldn't connect to server localhost:27000, connection attempt failed :
- connect@src/mongo/shell/mongo.js:257:13
- @(connect):1:6
- exception: connect failed
- vagrant@m103:~$ mongo admin --host localhost:27000 --eval
- Error parsing command line: the required argument for option '--eval' is missing
- try 'mongo --help' for more information
- vagrant@m103:~$ mongo admin --host localhost:27000
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- 2019-01-12T01:04:26.048+0000 W NETWORK [thread1] Failed to connect to 127.0.0.1:27000, in(checking socket for error after poll), reason: Connection refused
- 2019-01-12T01:04:26.048+0000 E QUERY [thread1] Error: couldn't connect to server localhost:27000, connection attempt failed :
- connect@src/mongo/shell/mongo.js:257:13
- @(connect):1:6
- exception: connect failed
- vagrant@m103:~$ mongo admin --host localhost:27000
- MongoDB shell version v3.6.9
- connecting to: mongodb://localhost:27000/admin
- 2019-01-12T01:05:21.056+0000 W NETWORK [thread1] Failed to connect to 127.0.0.1:27000, in(checking socket for error after poll), reason: Connection refused
- 2019-01-12T01:05:21.056+0000 E QUERY [thread1] Error: couldn't connect to server localhost:27000, connection attempt failed :
- connect@src/mongo/shell/mongo.js:257:13
- @(connect):1:6
- exception: connect failed
- vagrant@m103:~$ mongo
- MongoDB shell version v3.6.9
- connecting to: mongodb://127.0.0.1:27017
- 2019-01-12T01:05:23.976+0000 W NETWORK [thread1] Failed to connect to 127.0.0.1:27017, in(checking socket for error after poll), reason: Connection refused
- 2019-01-12T01:05:23.977+0000 E QUERY [thread1] Error: couldn't connect to server 127.0.0.1:27017, connection attempt failed :
- connect@src/mongo/shell/mongo.js:257:13
- @(connect):1:6
- exception: connect failed
- vagrant@m103:~$ ps aux |grep mongod
- vagrant 2393 1.3 2.7 1097748 55748 ? Sl 01:01 0:03 mongod --config /etc/mongod.conf
- vagrant 2454 0.0 0.0 8868 644 pts/0 S+ 01:05 0:00 grep --color=auto mongod
- vagrant@m103:~$ validate_lab_configuration_file
- Client experienced a timeout when connecting to the database - check that mongod is running on the correct port, and that your user was created with the correct settings.
- vagrant@m103:~$ sudo pico /etc/mongod.conf
- GNU nano 2.2.6 File: /etc/mongod.conf
- # mongod.conf
- # for documentation of all options, see:
- # http://docs.mongodb.org/manual/reference/configuration-options/
- # Where and how to store data.
- storage:
- dbPath: /data/db
- journal:
- enabled: true
- # engine:
- # mmapv1:
- # wiredTiger:
- # where to write logging data.
- systemLog:
- destination: file
- logAppend: true
- path: /data/mongod.log
- # network interfaces
- net:
- port: 27000
- bindIp: 127.0.0.2,192.168.103.100
- # how the process runs
- processManagement:
- timeZoneInfo: /usr/share/zoneinfo
- fork: true
- #security:
- #operationProfiling:
- #replication:
- #sharding:
- ## Enterprise-Only Options:
- #auditLog:
- #snmp:
- security:
- authorization: enabled
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement